Underlined blue static text
Mart Raudsepp
leio at dustbite.net
Thu Feb 1 13:03:40 PST 2007
On Thu, 2007-02-01 at 18:34 +0100, Vadim Zeitlin wrote:
> On Thu, 01 Feb 2007 04:47:34 +0200 Mart Raudsepp <leio at dustbite.net> wrote:
>
> MR> How about trying -1 for a->end_index instead of GetLabel.Len(), that
> MR> seems to mean "until the end".
>
> This doesn't change anything unfortunately.
I believe we are creating the label with gtk_label_new_with_mnemonic and
that sets use_markup to FALSE and use_underline to TRUE.
As I noted in earlier mail, gtk_label_set_attributes does anything
useful only if use_underline and use_markup are both FALSE.
_with_mnemonic calls set use_underline to TRUE.
We could perhaps call it with gtk_label_new instead and assume there are
no mnemonics in Font.GetUnderlined case (and document it?) as if the
whole label is underlined the mnemonic wouldn't be visible and then
having an action on it would be unexpected to the user.
So I propose to create the label with gtk_label_new(NULL) and then in
pseudo code:
if (font is underlined) {
gtk_label_set_text(string);
set_pango_attrs();
} else {
convert_mnemonics_to_gtk_way();
gtk_label_set_text_with_mnemonic(strings);
}
Changing gtk_label_new to gtk_label_new_with_mnemonic in my pure gtk
test code makes the whole text not be underlined indeed, so that should
be the problem we are having.
> MR> I need to handle my reoccurring "Not enough free disk space" problems to
> MR> get a local compilation of wx going again and try it inside wxGTK code.
>
> I need to learn how to use the GTK+ debug packages under Debian. For some
> reason if I try to run any wx application with LD_LIBRARY_PATH set to
> /usr/lib/debug/usr/lib it simply crashes (*without* any symbols in the
> stack trace). I'm sure it must be something obvious but I still have no
> idea what.
There are libraries in /usr/lib/debug/usr/lib? There should be only
*.debug files that contain the debug ELF section of the library. A
reasonably recent gdb should just understand it. LD_LIBRARY_PATH set to
there shouldn't have any benefits or effects to my knowledge.
I believe wxStackWalker and co don't understand split debug files very
well, but I'll investigate and if necessary bring to wx-dev at a later
date.
I managed to offload some stuff to another computer in the family and
after rearranging some data on mine from one partition to another, I
should be back in action with large code bases for some time.
Regards,
Mart Raudsepp
More information about the wx-users
mailing list