After an evaluation, GNOME has moved from Bugzilla to GitLab. Learn more about GitLab.
No new issues can be reported in GNOME Bugzilla anymore.
To report an issue in a GNOME project, go to GNOME GitLab.
Do not go to GNOME Gitlab for: Bluefish, Doxygen, GnuCash, GStreamer, java-gnome, LDTP, NetworkManager, Tomboy.
Bug 68938 - GtkDialog's separator should be removed
GtkDialog's separator should be removed
Status: RESOLVED FIXED
Product: gtk+
Classification: Platform
Component: Widget: Other
1.3.x
Other other
: Normal normal
: ---
Assigned To: Federico Mena Quintero
Federico Mena Quintero
Depends on:
Blocks:
 
 
Reported: 2002-01-17 18:28 UTC by jacob berkman
Modified: 2011-02-04 16:12 UTC
See Also:
GNOME target: ---
GNOME version: ---


Attachments
patch to deprecate the separator (4.11 KB, patch)
2002-01-17 18:28 UTC, jacob berkman
none Details | Review
patch to completely remove the separator (6.80 KB, patch)
2002-01-17 18:29 UTC, jacob berkman
none Details | Review
Patch to add a use_separator style property to GtkMessageDialog. (2.24 KB, patch)
2004-01-20 23:33 UTC, Federico Mena Quintero
none Details | Review

Description jacob berkman 2002-01-17 18:28:06 UTC
There is no good reason for GtkDialogs to have the separator, especially on
by default and not turn off-able in GtkMessageDialog.

Separation between the buttons in a GtkDialog and the contents can be done
with a GtkNotebook or a GtkFrame, or more rarely the developer can add the
separator manually.

Attached are two patches, one to remove it entirely and one to deprecate
the api, but remove it internally.  Another option would be to make it off
by default - although here the GtkDialogFlags would need to be changed a
little bit.
Comment 1 jacob berkman 2002-01-17 18:28:37 UTC
Created attachment 6424 [details] [review]
patch to deprecate the separator
Comment 2 jacob berkman 2002-01-17 18:29:11 UTC
Created attachment 6425 [details] [review]
patch to completely remove the separator
Comment 3 Seth Nickell 2002-01-22 01:34:47 UTC
We should at least set the default to off. The seperator is just extra
visual noise.
Comment 4 Havoc Pennington 2002-03-02 18:07:26 UTC
To avoid changing API at this point, the way I'd fix this is to have
apps written as if the separator were there (turning it off if there's
a notebook/frame, leaving it otherwise), and have a style property on
GtkDialog that optionally forces it off always.

Owen I can do this patch this weekend if you want.
Comment 5 Owen Taylor 2002-03-03 05:31:38 UTC
For GtkDialog, I think that it's best at this point to leave it
something up to application designers and style guide writers.
Making it an interacting style property and widget property
would be really confusing I think. (And if it was off by
default, most dialogs would look awful if someone turned it on.)

For GtkMessageDialog, I think it would be more reasonable to
make it a style property, since we have an idea of what
the entire dialog looks like... the interaction of this with
the GtkDialog methods, properties is a bit confusing though,
and you'd probably need some hooks in GtkDialog. (Or could
make it a GtkDialog style property and tell people to only
specify it for subclasses.)

I think this is a post-2.0.0 issue though; we could conceivably
add some sort of style property in 2.0.1, though it's 
more likely a 2.2 issue.

I'd actually like to have support for themes drawing things in
more customized ways in the future ... I think subtle color
differences or a faint line could be more effective than either
a separator or no separator.


Comment 6 Owen Taylor 2002-03-25 23:27:46 UTC
Moving non-critical or hard to fix bugs to 2.0.2
Comment 7 Matthias Clasen 2002-04-05 13:35:42 UTC
Move open bugs from milestones 2.0.[012] -- > 2.0.3, since 2.0.2 is already out.
Comment 8 Owen Taylor 2002-11-17 15:31:12 UTC
*** Bug 98779 has been marked as a duplicate of this bug. ***
Comment 9 Owen Taylor 2002-12-10 02:40:44 UTC
Plan of attack: 

 - Add private GtkDialog <=> GtkMessageDialog API to 
   say "ignore the ::has-separator property for this
   dialog"

 - Add a style property to GtkMessageDialog

 - Leave on vs. off for the separator as a theme decision
Comment 10 Federico Mena Quintero 2004-01-20 23:31:58 UTC
The attached patch adds a "use_separator" style property to
GtkMessageDialog, but it doesn't add the API to tell GtkDialog to
ignore its own has-separator property.  Do we really need that?
Comment 11 Federico Mena Quintero 2004-01-20 23:33:37 UTC
Created attachment 23575 [details] [review]
Patch to add a use_separator style property to GtkMessageDialog.
Comment 12 Matthias Clasen 2004-01-30 00:10:29 UTC
One thing I just noticed is that xgettext will probably have trouble
to pick up a string which is split over multiple lines, ie P_("bla" "bla")
Comment 13 Federico Mena Quintero 2004-02-03 20:10:07 UTC
Fixed on CVS, also with the addition of
_gtk_dialog_set_ignore_separator().

2004-02-03  Federico Mena Quintero  <federico@ximian.com>

	Fix #68938.

	* gtk/gtkdialog.c (GtkDialogPrivate): New private structure for
	GtkDialog; right now it only contains an ignore_separator field.
	(gtk_dialog_class_init): Register the private structure.
	(gtk_dialog_init): Initialize the priv->ignore_separator field.
	(_gtk_dialog_set_ignore_separator): New private function.
	(gtk_dialog_set_has_separator): Ignore the setting if appropriate.

	* gtk/gtkmessagedialog.c (gtk_message_dialog_class_init): Add a
	use_separator style property.
	(gtk_message_dialog_style_set): Change the dialog's separator
	based on the style property.
	(gtk_message_dialog_init): Set the dialog box to ignore the
	separator setting.