Re: Win32 Lists Dialog


Subject: Re: Win32 Lists Dialog
From: Martin Sevior (msevior@mccubbin.ph.unimelb.edu.au)
Date: Sat Jul 14 2001 - 13:36:59 CDT


On Sat, 14 Jul 2001, Mike Nordell wrote:

> I've killed the preview flicker, but stumbled upon another preview problem.
> I'd like to know if this really works as it should on any platform.
>
> Bring up Lists Dialog. Select Type Bulleted. Select Type Numbered, Style
> Lower Case.
>
> It displays Dingbats. :-)
>
> I think the problem can be in AP_Dialog_Lists::fillFakeLabels: it sets
> "Symbol" for a bulleted list but never reverts to "NULL" font unless we're
> not displaying a list at all. Comments?
>

This works as expected on the Gnome build. However the reason is does is
not so obvious and happens this way because of the interplay between
setting a list type and setting a list style.

If you look in

ap_UnixDialog_Lists.cpp

at the static callback functions:

static void s_styleChangedNone (GtkWidget * widget, AP_UnixDialog_Lists *
me)
{
          me->setDirty();
        me->styleChanged ( 0 );
}

static void s_styleChangedBullet (GtkWidget * widget, AP_UnixDialog_Lists
* me)
{
          me->setDirty();
        me->styleChanged ( 1 );
}

static void s_styleChangedNumbered (GtkWidget * widget,
AP_UnixDialog_Lists * me)
{
          me->setDirty();
        me->styleChanged ( 2 );
}

These set the List Style to "None", "Bullet", "Numbered", set the default
list type to it's correct setting, most importantly, do a call to

fillUncustomizedValues(void),

from within the platform code.

Which sets all the member variables to their uncustomized defaults,
including the font name.

You can legally change the font for Numbered Lists so that is not
hardwired into fillFakeLabels().

Anyway to fix your problem, do a call to fillUncustomizedValues() after
you set m_newListType to "Numbered List", before you do a
event_preview_exposed() call.

Good Luck! Please ask me more questions if needed. I know that following
the logic of what's in platform and what's in XP is not easy. Maybe I
should have bit the bullet and changed to your code ages ago.

Cheers

Martin



This archive was generated by hypermail 2b25 : Sat Jul 14 2001 - 13:37:10 CDT