Re: [HIG] GtkMessageDialog



On Fri, Dec 06, 2002 at 01:00:05PM +0100, Murray Cumming wrote:
> On Fri, 2002-12-06 at 12:56, Gregory Merchan wrote:
> > On Fri, Dec 06, 2002 at 10:59:47AM +0100, Murray Cumming wrote:
> > > On Thu, 2002-12-05 at 20:11, Gregory Merchan wrote:
> > > > GtkButtonsType has GTK_BUTTONS_CLOSE, GTK_BUTTONS_CANCEL, and
> > > > GTK_BUTTONS_YES_NO, none of which should be used.
> > > 
> > > Cancel should never be used? But it's used in the HIG's "reactor
> > > meltdown" example.
> > 
> > The button is fine, insofar as it's the second button. But
> > GTK_BUTTONS_CANCEL provides only the Cancel button; an alert (or any
> > dialog) with only Cancel is what should not be used.
> 
> GtkButtonsType is an ORable flag, I believe. Plus, custom buttons can be
> added afterwards with gtk_dialog_add_button().

It's just a plain enumeration, so not ORable.

  typedef enum
  {
    GTK_BUTTONS_NONE,
    GTK_BUTTONS_OK,
    GTK_BUTTONS_CLOSE,
    GTK_BUTTONS_CANCEL,
    GTK_BUTTONS_YES_NO,
    GTK_BUTTONS_OK_CANCEL
  } GtkButtonsType;

So long as the custom button is added, I guess it's ok. (No pun intended.)


> > > > I say the alert image should be in a column all to itself, but the HIG
> > > > doesn't. Doing so would also make leave GtkDialog an unsuitable parent
> > > > class.
> 
> Actually, the HIG seems to agree with you:
> http://developer.gnome.org/projects/gup/hig/draft_hig/windows.html#alert-windows

Look at the "Technical Details for Proper Layout" and Figure 3.18:

http://developer.gnome.org/projects/gup/hig/draft_hig/images/save_alert.png

I'm saying the column of the image should run to the bottom of the window
thus pushing any far left-reaching buttons to the right. Doing this would
require of GtkDialog that the first child of its GtkWindow be a GtkVBox,
instead of the current GtkHBox.


> > > > I would prefer to just see GtkMessageDialog removed and have a GtkAlert
> > > > class.
> > > 
> > > Are you aware of any efforts to reconcile the HIG and GtkMessageDialog,
> > > or to add something to libgnomeui for this? How can anyone reasonably be
> > > expected to comply with the HIG if it requires such effort.
> > 
> > I'm not aware of any, but my awareness here is limited to the gnome mailing
> > lists. As I understand it, the code should go into libegg for eventual
> > inclusion in Gtk+ proper and libgnomeui should be just desktop "glue" like
> > session management.
> 
> I believe that libegg is for new widgets. So far I'm not convinced that
> GtkMessageDialog can't be improved instead.

I'm thinking one of the improvements would be changing the name because
GtkAlert is less to type. :-)  


> > Both Seth and I had written our own GtkAlert classes and (iirc) offered
> > them for inclusion in Gtk+ proper. But this happened during a freeze and
> > wasn't revisted later, afaik.
> > 
> > HIG 1.0 has some errors which I hope no one complies with. An override
> > redirect alert would really suck; that's fixed in CVS.  Surprising to me
> > there have been people who've gone to (IMO) great lengths to comply.
> > Those great lengths shouldn't be necessary for compliance, and there's
> > work being done already to eliminate some of them.
> > 
> > One thing I'd really like to see I mentioned here:
> >   http://mail.gnome.org/archives/hig/2002-October/msg00018.html
> 
> If that isn't in bugzilla somewhere then it will never happen.

I don't know where to start to have GError messages suitable for alerts,
because I don't know which of primary and secondary text they should be.
I was hoping Seth, Calum, or someone else would have insight into that.


Cheers,
Greg Merchan



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