summaryrefslogtreecommitdiff
path: root/gtk/gtkmenubar.c
Commit message (Collapse)AuthorAgeFilesLines
* The big versioning cleanupMatthias Clasen2018-02-061-14/+0
| | | | | | | Remove all the old 2.x and 3.x version annotations. GTK+ 4 is a new start, and from the perspective of a GTK+ 4 developer all these APIs have been around since the beginning.
* gtk: Intern css namesMatthias Clasen2017-11-171-1/+1
| | | | This avoids a bunch of strdups at startup.
* Drop unused includes of gtkrender.hMatthias Clasen2017-10-251-1/+0
| | | | | | We don't use the gtk_render apis internally anymore. Drop these includes so it is clear where the remaining uses are.
* build: Enable -Wswitch-enum and -Wswitch-defaultBenjamin Otte2017-10-061-1/+4
| | | | | | | | | | | | | | | | | | | This patch makes that work using 1 of 2 options: 1. Add all missing enums to the switch statement or 2. Cast the switch argument to a uint to avoid having to do that (mostly for GdkEventType). I even found a bug while doing that: clearing a GtkImage with a surface did not notify thae surface property. The reason for enabling this flag even though it is tedious at times is that it is very useful when adding values to an enum, because it makes GTK immediately warn about all the switch statements where this enum is relevant. And I expect changes to enums to be frequent during the GTK4 development cycle.
* widget: Add baseline and out_clip parameters to size-allocateTimm Bäder2017-07-191-9/+10
| | | | | | | | | | | Since setting a clip is mandatory for almost all widgets, we can as well change the size-allocate signature to include a out_clip parameter, just like GtkCssGadget did. And since we now always propagate baselines, we might as well pass that one on to size-allocate. This way we can also make sure to transform the clip returned from size-allocate to parent-coordinates, i.e. the same coordinate space priv->allocation is in.
* menubar: Remove gadgetTimm Bäder2017-07-191-126/+12
|
* menus: Use gtk_widget_measure to measure widget sizesTimm Bäder2017-03-041-8/+8
|
* gadget: Remove gtk_css_gadget_draw()Benjamin Otte2016-12-201-1/+0
| | | | | | | And with it, remove the draw func from custom gadgets, that has been NULL everywhere. All gadgets are snapshot now.
* menu: Implement snapshot() for the menu codeBenjamin Otte2016-12-201-13/+11
|
* snapshot: Add a snapshot function to GtkCssCustomGadgetBenjamin Otte2016-11-151-0/+1
|
* menubar: We don't need an input windowBenjamin Otte2016-11-031-53/+3
| | | | Input is handled by the menuitems completely.
* menu: Don't set widget->windowBenjamin Otte2016-11-021-6/+47
| | | | | Instead, create an input window for the menubar and omit the window for the menu itself.
* widget: Use ::measure vfunc to measure sizeTimm Bäder2016-10-221-63/+23
| | | | | | | | Add a new ::measure vfunc similar to GtkCssGadget's that widget implementations have to override instead of the old get_preferred_width, get_preferred_height, get_preferred_width_for_height, get_preferred_height_for_width and get_preferred_height_and_baseline_for_width.
* API: container: Remove gtk_container_set_border_width()Benjamin Otte2016-10-161-3/+0
|
* Remove various unused style propertiesTimm Bäder2016-10-161-35/+0
|
* menubar: Remove duplicate flags valueBenjamin Otte2016-03-201-2/+1
| | | | http://www.viva64.com/en/b/0383/
* menubar: prefer early returnCosimo Cecchi2016-01-031-90/+91
|
* menubar: port to use a gadgetCosimo Cecchi2016-01-031-85/+128
|
* menubar: use gtk_container_class_handle_border_width()Cosimo Cecchi2016-01-031-20/+13
|
* Annotate deprecated style propertiesMatthias Clasen2015-11-161-2/+2
| | | | | | Use G_PARAM_DEPRECATED with deprecated style properties. This will make it easier to identify and remove such stale properties from css, since it will now trigger warnings.
* menubar: Ignore the shadow-type style propertyMatthias Clasen2015-11-161-41/+28
| | | | | The border can be controlled with regular CSS, so deprecate and ignore this style property.
* Cosmetic: Avoid explict state variablesMatthias Clasen2015-11-141-8/+4
| | | | Using the state of the context makes this more obviously correct.
* menubar: Use an element nameMatthias Clasen2015-11-021-7/+7
|
* stylecontext: Split render functions out into gtkrender.[ch]Benjamin Otte2014-10-031-0/+1
|
* GtkMenuBar: Use G_PARAM_EXPLICIT_NOTIFYMatthias Clasen2014-06-091-14/+14
|
* Window: Focus custom titlebar with F10Phillip Wood2014-03-091-75/+3
| | | | | | | | | | | | | | | As discussed on desktop-devel-list [1], "There should be an intuitive, consistent, immediate way to jump to the widgets that live in the header bar." F10 has been suggested for this as it is already used to active menubars. F10 will focus the custom titlebar widget if the window has one and it isn't already focused. If the titlebar widget doesn't exist or is already focused then F10 focuses the menubar if there is one. [1] https://mail.gnome.org/archives/desktop-devel-list/2014-February/msg00176.html https://bugzilla.gnome.org/show_bug.cgi?id=725141
* Allow applications to use gtk-menu-bar-accel in 3.12Matthias Clasen2014-03-031-17/+36
| | | | | | | | | gnome-terminal is still using this setting, so we'll let applications override it for another cycle. It is no longer backed by a system-wide setting, though, and it will still go away eventually. This partically reverts b26c74e5dac0b5fd869d2c8cc7a0edb6b01aeebd
* docs: use Returns: consistentlyWilliam Jon McCann2014-02-191-2/+2
| | | | Instead of Return value:
* Trivial cleanupMatthias Clasen2013-11-161-2/+2
|
* gtk: Use new macros for defining private dataEmmanuele Bassi2013-07-091-6/+2
| | | | https://bugzilla.gnome.org/show_bug.cgi?id=702996
* Deprecate and ignore gtk-menu-bar-accel settingWilliam Jon McCann2013-06-261-38/+19
| | | | Use 'F10' by default.
* Deprecate and ignore gtk-menu popup and popdown delay settingsWilliam Jon McCann2013-06-261-7/+3
| | | | | Just pick good defaults. The a11y team confirmed that they don't rely on them.
* widget: Adapt _gtk_widget_get_preferred_size_for_size()Benjamin Otte2013-05-011-1/+1
| | | | ... for baseline support byu taking two extra (possible NULL) arguments.
* sizerequest: Split out a common functionBenjamin Otte2013-04-221-20/+2
|
* menubar: deprecate internal-padding style propertyCosimo Cecchi2012-11-281-23/+18
| | | | https://bugzilla.gnome.org/show_bug.cgi?id=689168
* menubar: add support for CSS paddingCosimo Cecchi2012-11-281-20/+40
| | | | | | In preparation for the removal of the internal-padding style property. https://bugzilla.gnome.org/show_bug.cgi?id=689168
* gtkmodelmenu: simplify logic, expose bind APIRyan Lortie2012-09-171-0/+29
| | | | | | | | | | | | | | | Make the main (and only) entry-point to gtkmodelmenu.c the now-public gtk_menu_shell_bind_model(). Move the convenience constructors (gtk_menu_new_from_model() and gtk_menu_bar_new_from_model()) to their proper files. Remove the private header file. Simplify the code a bit by making the initial populate part of the bind() call. https://bugzilla.gnome.org/show_bug.cgi?id=682831
* Move the gtk_shadow_type check down to gtk_render_frameMatthias Clasen2012-09-161-9/+9
| | | | | | | | In gtk_menu_bar_draw, the check for shadow type != none disables rendering of the background instead of the frame. The check should be moved down to gtk_render_frame. Patch by Peter de Ridder, http://bugzilla.gnome.org/show_bug.cgi?id=670390
* Change FSF AddressJavier Jardón2012-02-271-3/+1
|
* menubar: Stop setting state flags on the style context for drawingRui Matos2011-12-191-4/+0
|
* menubar: Use gtk_widget_class_set_accessible_role()Benjamin Otte2011-07-181-0/+2
|
* menushell: Use GtkMenuShellAccessible as a11y objectBenjamin Otte2011-07-181-3/+0
| | | | Previously it was only used by GtkMenuBar, and that's a naming mismatch.
* Convert GailMenuShell to GtkMenuShellAccessibleMatthias Clasen2011-07-051-0/+3
|
* gtkcontainer: Move private functions to private headerJavier Jardón2011-06-061-0/+1
| | | | https://bugzilla.gnome.org/show_bug.cgi?id=651707
* all: avoid boxed structs copying where possibleCosimo Cecchi2011-05-181-20/+14
| | | | | | | Use the GtkStyleContext accessors for boxed properties where possible, to reduce allocations. https://bugzilla.gnome.org/show_bug.cgi?id=650420
* menuitem: Deprecate gtk_menu_item_set_right_justified()Benjamin Otte2011-05-021-2/+2
| | | | | | And the getter, too: gtk_menu_item_get_right_justified() and the corresponding property. Also make the only caller use the private structure (as it did before the recent patches).
* menubar: Rewrite size allocation to take natural sizes into accountBenjamin Otte2011-05-011-98/+111
| | | | Yay for properly ellipsizing menubars!
* menubar: Only query ipadding when we actually need itBenjamin Otte2011-05-011-2/+2
|
* menubar: Respect ipadding also in y directionBenjamin Otte2011-05-011-0/+1
|
* menubar: Implement height-for-width / width-for-heightBenjamin Otte2011-05-011-3/+32
| | | | | Pretty much just required hooking up the 2 vfuncs, the previous code reorg did the rest of the work.