Re: "Label" entries




On Fri, May 1, 2009 at 6:52 AM, Emmanuel Rodriguez <emmanuel rodriguez gmail com> wrote:


On Fri, May 1, 2009 at 5:37 AM, Matthew Braid <ptkperl mdb id au> wrote:
Hi again,

although I had to change line 430 from:

           Â$attributes = Gtk2::Pango::AttrList->new();

to:

           Â($attributes) = Gtk2::Pango->parse_markup('');

because the ye-ancient version of Gtk2 we have installed is obviously
not up to scratch.
I will upload the module and take this into account. It's a pity that people with an old version of Gtk2 can't use because of a missing function.
Â

$e->signal_connect("focus-in-event" => sub {$e->set_empty_markup("<b></b>")});
I will try to take a look at this.

I have released a new developer release (0.06_02) of Gtk2::Ex::Entry::Pango. It removes the default Pango markup when the entry is focused and it should also fix the dependencies problems with old versions of Gtk2 that are missing full Pango support.

In the case where you are writing your own widget that mimics this functionality take a look at the function "set_layout_attributes" you will see a if with "$self->has_focus" it should allow you to implement an entry that has it's default Pango text removed once the widget gains focus without the need to add listeners.
--
Emmanuel Rodriguez


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