Alignment of markup labels in menu items



I'm trying to add the capability to add a label formatted with Pango
markup to buttons and menu items in the "high-level" interface to
gtk-fortran.

While the following is successful in producing subscripts in labels
when the markup flag is set, there is a problem with alignment: while
a plain text label is correctly centred in the pulldown menu, a markup
label begins at the centre (even if it does not actually include any
markup).

      if (markup) then
         item=gtk_menu_item_new()
         label_w=gtk_label_new(label)
         call gtk_label_set_markup(label_w, label)
         call gtk_container_add(item,label_w)
      else
         item = gtk_menu_item_new_with_label(label)
      end if

Am I missing something, or is that a fundamental limitation?

I'm using Gtk+-3.2.0, in Ubuntu 11.10, with gcc & gfortran 4.6.1.



[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]