Commit Graph

15049 Commits

Author SHA1 Message Date
Kristian Rietveld
76cfd8bfac Bug 621076 - GtkTreeModelFilter does not emit all signals in some ...
The bulk of the fix is to walk the chain of ancestors, starting at the
root level, and check if the visibility of any of the ancestors has
changed.  If yes, the necessary signals are emitted so that this change
is propagated properly.  This walk is done after a node has been
inserted, changed or deleted, see function
gtk_tree_model_filter_check_ancestors().

Bug reported, and initial debugging and analysis, by Xavier Claessens.
2011-08-22 21:30:31 +02:00
Kristian Rietveld
c8783d3339 Decrease code duplication in _remove_elt_from_level take two 2011-08-22 21:30:31 +02:00
Kristian Rietveld
df754517dd Decrease amount of code duplication in _remove_elt_from_level 2011-08-22 21:30:31 +02:00
Kristian Rietveld
a9fd6b7f85 Rename gtk_tree_model_filter_remove_node for internal consistency 2011-08-22 21:30:31 +02:00
Kristian Rietveld
7a82045ca8 Change signature of gtk_tree_model_filter_remove_node 2011-08-22 21:30:31 +02:00
Xavier Claessens
22adfc67e5 Add thorough unit test for bug #621076
Minor edits and additions by Kristian Rietveld.
2011-08-22 21:30:30 +02:00
Kristian Rietveld
a172697d47 Corrections to has-child filter tests 2011-08-22 21:30:30 +02:00
Kristian Rietveld
74764f28bc Improve specific_has_child_filter() test to also verify signals 2011-08-22 21:30:30 +02:00
Kristian Rietveld
ebb12d5f06 Improve specific_root_has_child_filter test to also verify signals 2011-08-22 21:30:30 +02:00
Kristian Rietveld
5bd3c52c0f Have a separate category for tests of gtk_tree_model_filter_row_deleted 2011-08-22 21:30:30 +02:00
Kristian Rietveld
3452b0493d Add two unit tests for gtk_tree_model_filter_row_inserted 2011-08-22 21:30:30 +02:00
Kristian Rietveld
4f33f10511 Use g_assert_cmpint instead of g_assert in check_level_length() 2011-08-22 21:30:30 +02:00
Kristian Rietveld
7b3c2751ee Refactor emitting row-inserted for new nodes to a common code path
Suggested by Xavier Claessens / bug 621076.
2011-08-22 21:30:30 +02:00
Kristian Rietveld
bcb00d9a43 Fix comment 2011-08-22 21:30:30 +02:00
Kristian Rietveld
f064d07bda Factor out find_elt_with_offset
Suggested by Xavier Claessens / bug 621076.
2011-08-22 21:30:30 +02:00
Kristian Rietveld
60f3f92e95 Refactor to a common code path for inserts of nodes in levels
Suggested by Xavier Claessens / bug 621076.

(Additional obseration: this should speed up the filter model's
handling of row-inserted as a binary search is now used instead
of a linear scan).
2011-08-22 21:30:30 +02:00
Xavier Claessens
dc12c373dc Improve error messages of signal monitor 2011-08-22 21:30:30 +02:00
Kristian Rietveld
e0f12ce020 Factor out another part of gtk_tree_model_filter_row_deleted 2011-08-22 21:30:30 +02:00
Kristian Rietveld
1686e515d6 Three more TreeModelFilter remove ancestor tests 2011-08-22 21:30:30 +02:00
Kristian Rietveld
df0fcfb940 In sort model also emit row-deleted after updating the data structures 2011-08-22 21:30:30 +02:00
Kristian Rietveld
e9c960929b Correct GtkTreeModelFilter to never unref an already deleted child node 2011-08-22 21:30:30 +02:00
Kristian Rietveld
b27a6568b7 Improve filter model remove node unit tests 2011-08-22 21:30:29 +02:00
Kristian Rietveld
f0da89fa20 Print failed assertions for failed child iterator conversions 2011-08-22 21:30:29 +02:00
Kristian Rietveld
2f5fbcd10a Make _get_iter invalidate iterators when FALSE is returned 2011-08-22 21:30:29 +02:00
Kristian Rietveld
431987a2fa Add more unit tests for gtk_tree_model_filter_row_deleted() 2011-08-22 21:30:29 +02:00
Kristian Rietveld
56f83ad197 Further reduce variable shadowing by factoring code out into functions 2011-08-22 21:30:29 +02:00
Kristian Rietveld
cb8c608e49 Add unit test for bug 77977 for reference 2011-08-22 21:30:29 +02:00
Kristian Rietveld
ed603fa790 Add bug base and bug numbers to tree model unit tests 2011-08-22 21:30:29 +02:00
Kristian Rietveld
f1d791355a Move TreeModelSort specific tests to a new sortmodel.c file 2011-08-22 21:30:29 +02:00
Kristian Rietveld
b227aa06eb Make naming of tree model unit tests consistent
All test paths now start with the name of the class which is being
tested.
2011-08-22 21:30:29 +02:00
Kristian Rietveld
2cb9f03a66 Put all GtkTreeModel unit tests in a single binary
This to reduce linking time and have all tests in a single binary.
2011-08-22 21:30:29 +02:00
Chun-wei Fan
ad73ed298d Include C89 fallback code
gtk/gtkborderimage.c, gtk/gtklabel.c and gtk/gtkstyleproperty.c call
round() and/or rint(), which was only available in C99 compilers.

This adds the inclusion of the fallback implementation (gtk/fallback-c89.c)
to define these functions if they are not initially made available by the
compiler.

Also remove the rint() implementation in gtk/gtklabel.c as it is now in
the fallback implmentation.
2011-08-20 11:17:44 +08:00
Chun-wei Fan
db3fecc5b9 Add fallback implemetation for rint()/round()
Add an implementation for rint() and round() for compilers that do not
define one or both of them.  Note that this file should be included
after config.h was included.
2011-08-20 11:17:43 +08:00
David Zeuthen
c68eeaa966 Bug 656851 – Allow use of GVariant in GtkListStore
Signed-off-by: David Zeuthen <davidz@redhat.com>
2011-08-18 17:49:40 -04:00
Matthias Clasen
915d32f59c Fix up symbol lists for recent api additions 2011-08-15 21:25:58 -04:00
Matthias Clasen
8cf52c8e6c Fix a typo 2011-08-15 19:24:59 -04:00
Matthias Clasen
6877893ed5 Make setting fontname work, independent of a screen 2011-08-15 18:57:58 -04:00
Matthias Clasen
1207757924 Keep the currently selected font over theme changes
When repopulating the list of fonts, don't loose the current
selection, unless the font is no longer in the list.
2011-08-15 18:57:57 -04:00
Matthias Clasen
9c85d4f6df Deprecate GtkFontSelection and GtkFontSelectionDialog 2011-08-15 18:57:57 -04:00
Matthias Clasen
930715665e Trivial formatting fix 2011-08-15 18:57:57 -04:00
Matthias Clasen
0ee89f1360 Add new symbols 2011-08-15 18:57:57 -04:00
Matthias Clasen
a09ee203ec Add filtering to the font chooser 2011-08-15 18:57:57 -04:00
Matthias Clasen
ba564088c3 Add 'no matches' functionality
Initial cut at showing a 'no matches' message if the font list
is empty.
2011-08-15 18:57:57 -04:00
Matthias Clasen
6fb69845b0 Make the fontchooser dialog come up in a reasonable size
This is not a perfect solution; we really just want to set
a nice default size, but GTK+ does not make that easy.
2011-08-15 18:57:57 -04:00
Matthias Clasen
7c4ad1f400 Just use a single grid
The subgrid didn't really add anything.
2011-08-15 18:57:57 -04:00
Matthias Clasen
43d62c08e3 Clean up error handling 2011-08-15 18:57:57 -04:00
Matthias Clasen
5b9857d9b9 Rename some statics
gtk_font_chooser_ref_{family,face} -> gtk_font_chooser_set_{family,face}
2011-08-15 18:57:57 -04:00
Matthias Clasen
8dbdfa7e73 Avoid extraneous signals at destroy time
We need to disconnect the cursor-changed handler before the
treeview gets destroyed, to avoid unwanted emissions.
2011-08-15 18:57:57 -04:00
Matthias Clasen
97d26ac9c0 Simplify a few things
Adwaita seems to misrender focus on entries with margins, so
use spacing instead. Also, don't use entry buffer unnecessarily.
2011-08-15 18:57:57 -04:00
Matthias Clasen
a18fab88a1 Trivial formatting fixes
Just committing these is easier than writing them up.
2011-08-15 18:57:57 -04:00
Alberto Ruiz
a58a2dc0d3 GtkFontChooserDialog: GtkFontButton now uses GtkFontChooserDialog instead of GtkFontSelectionDialog 2011-08-15 18:57:57 -04:00
Alberto Ruiz
e79842ce94 GtkFontChooser: get_font_name did not return the font size 2011-08-15 18:57:56 -04:00
Alberto Ruiz
d33088a805 GtkFontChooser: Stub code to handle empty list by search. 2011-08-15 18:57:56 -04:00
Alberto Ruiz
66a7add23f GtkFontChooser: font-name property notification wasn't properly propagated during size change from the spinbutton 2011-08-15 18:57:56 -04:00
Alberto Ruiz
52177f5e0d GtkFontChooser: Missing G_END_DECLS in fontchooser header 2011-08-15 18:57:56 -04:00
Alberto Ruiz
5795d3d616 GtkFontChooser: Using G_N_ELEMENTS instead of a define 2011-08-15 18:57:56 -04:00
Alberto Ruiz
9245a66e6f GtkFontChooser: Using the widget instead of the private struct as signal data in all conects 2011-08-15 18:57:56 -04:00
Alberto Ruiz
bf8ad994d4 GtkFontChooser: Fixed coding style wrt spacing around operators 2011-08-15 18:57:56 -04:00
Alberto Ruiz
26fb5c90b1 GtkFontChooser: Using explicit comparisons for g_strcmp0 2011-08-15 18:57:56 -04:00
Alberto Ruiz
ab1ebb072e GtkFontChooser: Added missing breaks in switch statements 2011-08-15 18:57:56 -04:00
Alberto Ruiz
c36d291acc GtkFontChooser: Setting all ought to be static functions as static 2011-08-15 18:57:56 -04:00
Alberto Ruiz
bf457d129e GtkFontChooserDialog: Add parent window as a parameter in the constructor 2011-08-15 18:57:56 -04:00
Alberto Ruiz
523190f69a GtkFontChooserDialog: Fix get_font_chooser public function name 2011-08-15 18:57:56 -04:00
Alberto Ruiz
23b15254bb GtkFontChooser: Set correct margin values between UI elements 2011-08-15 18:57:56 -04:00
Alberto Ruiz
a55d2f67b0 GtkFontChooserDialog: Use g_object_new to set initial values in the dialog constructor 2011-08-15 18:57:56 -04:00
Alberto Ruiz
01f279338f GtkFontChooser: Remove outdated Copyright information 2011-08-15 18:57:56 -04:00
Alberto Ruiz
1dda502bcb GtkFontChooser: Fix size synchronization between slider and spin button 2011-08-15 18:57:56 -04:00
Alberto Ruiz
cabfcbd18d GtkFontChooser: Cleanup comments and fix indentation alignments 2011-08-15 18:57:56 -04:00
Alberto Ruiz
e3f70857af GtkFontChooser: Remove default geometry defines 2011-08-15 18:57:55 -04:00
Alberto Ruiz
55d50b3cca GtkFontChooser: Fix scroll callback connected to treeview instead of preview 2011-08-15 18:57:55 -04:00
Alberto Ruiz
9dee34ad27 GtkFontChooser: Remove the themed color for the font title 2011-08-15 18:57:55 -04:00
Alberto Ruiz
f5a00f0c77 GtkFontChooser: Use a nested grid to achieve the right layout in the size controls 2011-08-15 18:57:55 -04:00
Alberto Ruiz
1075b7ac38 GtkFontChooser: Fix expand and fill properties for the grid layout 2011-08-15 18:57:55 -04:00
Alberto Ruiz
d9187472f5 GtkFontChooser: Use GtkBox instead of GtkVBox as base class. 2011-08-15 18:57:55 -04:00
Alberto Ruiz
b37863a5ba GtkFontChooser: Use const instead of G_CONST_RETURN 2011-08-15 18:57:55 -04:00
Alberto Ruiz
03ab18fa7a GtkFontChooser: Add preview entry to the grid 2011-08-15 18:57:55 -04:00
Alberto Ruiz
f60d0dc35a GtkFontChooser: Initial work to use GtkGrid 2011-08-15 18:57:55 -04:00
Alberto Ruiz
4163fa5d29 GtkFontChooser: GtkFontChooserDialog: Update documenation to reflect Since: 3.2 2011-08-15 18:57:55 -04:00
Alberto Ruiz
4add47946b GtkFontChooserDialog: Split the dialog out of gtkfontchooser.[ch] to gtkfontchooserdialog.[ch] 2011-08-15 18:57:55 -04:00
Alberto Ruiz
8e621f593e GtkFontChooser: Use symbolic icons in the filter entry 2011-08-15 18:57:55 -04:00
Alberto Ruiz
5ccc66d855 GtkFontChooser: Now shearch filters each individual term rather than the whole string at once 2011-08-15 18:57:55 -04:00
Alberto Ruiz
db2ef8ce51 GtkFontChooser: Restore automatic alignment on scroll to selection 2011-08-15 18:57:55 -04:00
Alberto Ruiz
7067d36adb GtkFontChooser: Removed support for deprecated functionality from GtkFontSelector 2011-08-15 18:57:55 -04:00
Alberto Ruiz
4bf22639d1 GtkFontChooser: Expose the new widget in gtk.h and add test cases 2011-08-15 18:57:55 -04:00
Alberto Ruiz
334ee81901 GtkFontChooser: Renaming the class names and fixing the tests 2011-08-15 18:57:55 -04:00
Alberto Ruiz
f2376ad401 GtkFontChooser: Remove wrong usage of GTK_DISABLE_DEPRECATED 2011-08-15 18:57:55 -04:00
Alberto Ruiz
bbe8d13c6e GtkFontChooser: Check if the deprecated widgets are present before updating the size list 2011-08-15 18:57:54 -04:00
Alberto Ruiz
1b00a3eb76 GtkFontChooser: Update fontlist on style change 2011-08-15 18:57:54 -04:00
Alberto Ruiz
6dec212d1d GtkFontChooser: Add a property to control whether the preview entry is shown or not 2011-08-15 18:57:54 -04:00
Alberto Ruiz
5eb614a25b GtkFontChooser: Add gtk_font_selection_dialog_get_select_button and use GTK_DISABLE_DEPRECATED in gtkfontsel.h 2011-08-15 18:57:54 -04:00
Alberto Ruiz
1ce5a04406 GtkFontChooser: Changed dialog label from OK to Select, deprecated get_ok_button and internal apply button. 2011-08-15 18:57:54 -04:00
Alberto Ruiz
31776e2a25 GtkFontChooser: implement gtk_font_selection_set/get_preview_text 2011-08-15 18:57:54 -04:00
Alberto Ruiz
14fbbf1420 GtkFontChooser: check if font name is NULL in gtk_font_selection_set_font_name 2011-08-15 18:57:54 -04:00
Alberto Ruiz
ea4603e5d1 GtkFontChooser: gtk_font_selection_set_font_name implementation 2011-08-15 18:57:54 -04:00
Alberto Ruiz
3f2b09422d GtkFontChooser: Setting the font-name property. Test updates. Remove warnings. 2011-08-15 18:57:54 -04:00
Alberto Ruiz
0aae453d77 GtkFontChooser: Improve bootstrapping of the deprecated lists 2011-08-15 18:57:54 -04:00
Alberto Ruiz
2ef00d23e3 GtkFontChooser: Update selection on deprecated size list selection 2011-08-15 18:57:54 -04:00
Alberto Ruiz
dc1a47ad70 GtkFontChooser: Update selection on deprecated face or font list selection 2011-08-15 18:57:54 -04:00
Alberto Ruiz
0ef0359566 GtkFontChooser: Update size when selecting an item of the deprecated size list 2011-08-15 18:57:54 -04:00
Alberto Ruiz
72a971b0e0 GtkFontChooser: Blocking the cursor change callbacks from happening on the deprecated widgets when selecting the font from the fontselector 2011-08-15 18:57:53 -04:00
Alberto Ruiz
c28b1e32e3 GtkFontChooser: Update deprecated font list on slection 2011-08-15 18:57:53 -04:00
Alberto Ruiz
1821eac1c1 GtkFontChooser: Refactoring the default font size, face and family assignment for clarity 2011-08-15 18:57:53 -04:00
Alberto Ruiz
aa10abacbc GtkFontChooser: Use the theme font as the default font 2011-08-15 18:57:53 -04:00
Alberto Ruiz
4b92872a97 GtkFontChooser: Add callbacks and improve test to take deprecated widgets into account 2011-08-15 18:57:53 -04:00
Alberto Ruiz
e80053c659 GtkFontChooser: Use GTK_DISABLE_DEPRECATED to encapsulate the deprecated functionality 2011-08-15 18:57:53 -04:00
Alberto Ruiz
3c0b6914e0 GtkFontChooser: Unref deprecated widgets on finalize 2011-08-15 18:57:53 -04:00
Alberto Ruiz
bb008411e0 GtkFontChooser: Use scrolled windows for the deprecated widgets 2011-08-15 18:57:53 -04:00
Alberto Ruiz
706167bbbd GtkFontChooser: Populate face names in the deprecated face list 2011-08-15 18:57:53 -04:00
Alberto Ruiz
0d112810f9 GtkFontChooser: Populate font family names in the deprecated family list 2011-08-15 18:57:53 -04:00
Alberto Ruiz
8826a10bc8 GtkFontChooser: Add tree view columns for the deprecated widgets 2011-08-15 18:57:53 -04:00
Alberto Ruiz
915b442dc1 GtkFontChooser: Fix segmentation fault in deprecated size list population 2011-08-15 18:57:53 -04:00
Alberto Ruiz
29a0685ee8 GtkFontChooser: Add deprecated calls to the test 2011-08-15 18:57:53 -04:00
Alberto Ruiz
1a2ef4db60 GtkFontChooser: update the size model for the deprecated size list 2011-08-15 18:57:53 -04:00
Alberto Ruiz
e08006f691 GtkFontChooser: initialization and destruction of deprecated widgets and data models 2011-08-15 18:57:53 -04:00
Alberto Ruiz
abc92d5030 GtkFontChooser: Initial support for deprecated functions 2011-08-15 18:57:53 -04:00
Alberto Ruiz
c96698e95f GtkFontChooser: Filter also by font face 2011-08-15 18:57:53 -04:00
Alberto Ruiz
58b2204651 GtkFontChooser: Layout improvements, spacing between elements and default widget size. 2011-08-15 18:57:53 -04:00
Alberto Ruiz
36156a6c49 GtkFontChooser: Layout improvements. Adding shadow to scrolled windows. Font+Face text is now bold. 2011-08-15 18:57:52 -04:00
Alberto Ruiz
f75e4d314a GtkFontChooser: Improvements on the size setting signals between the preview, scale and spinbutton. Adding more string fields to the model to allow for backwards compatibility. 2011-08-15 18:57:52 -04:00
Alberto Ruiz
1688512252 GtkFontChooser: Fixing mouse scroll zooming behaviour for the preview and the size controls 2011-08-15 18:57:52 -04:00
Alberto Ruiz
858e13cad6 GtkFontChooser: Setting a minimum width andfix the markup for the rows 2011-08-15 18:57:52 -04:00
Alberto Ruiz
af14106a63 GtkFontChooser: Ellipsize cell renderer and set a better size list 2011-08-15 18:57:52 -04:00
Alberto Ruiz
0db1b63b1f GtkFontChooser: Keep reference to the face and the family objects 2011-08-15 18:57:52 -04:00
Alberto Ruiz
88ab6f14d3 GtkFontChooser: Better cursor selection and model leak fixes 2011-08-15 18:57:52 -04:00
Alberto Ruiz
f3e9bb312e GtkFontChooser: Enable font selection 2011-08-15 18:57:52 -04:00
Alberto Ruiz
c9150374d9 GtkFontChooser: Setting a default vertical size 2011-08-15 18:57:52 -04:00
Alberto Ruiz
7f125d95e8 GtkFontChooser: Layout enhancements, using a scrolled window for the preview entry. 2011-08-15 18:57:52 -04:00
Alberto Ruiz
cbaca3e4bf GtkFontChooser: Fixed size updating in the preview 2011-08-15 18:57:52 -04:00
Alberto Ruiz
272f11069f GtkFontChooser: Improvements on the spin/slider interaction 2011-08-15 18:57:52 -04:00
Alberto Ruiz
c303d0b18c GtkFontChooser: The spinner now updates the slider size if it is within the range 2011-08-15 18:57:52 -04:00
Alberto Ruiz
1fa2c503a7 GtkFontChooser: Getting the refiltering right for the clear icon. Filter function speedups. 2011-08-15 18:57:52 -04:00
Alberto Ruiz
94ee606f62 GtkFontChooser: Search entry icon is now dynamic depending on the content 2011-08-15 18:57:52 -04:00
Alberto Ruiz
4db5ea20e8 GtkFontChooser: Set the initial size to the slider, initial callbacks for size change 2011-08-15 18:57:52 -04:00
Alberto Ruiz
fb19245493 GtkFontChooser: Live search implemented 2011-08-15 18:57:51 -04:00
Alberto Ruiz
693617700b GtkFontChooser: Inserted and deleted text callbacks 2011-08-15 18:57:51 -04:00
Alberto Ruiz
76809e128a GtkFontChooser: Adding a tree model filter for the search functionality 2011-08-15 18:57:51 -04:00
Alberto Ruiz
ce10919978 GtkFontChooser: Setting the default preview text and the default font size 2011-08-15 18:57:51 -04:00
Alberto Ruiz
9af88217d1 GtkFontChooser: Compilation warning cleanups 2011-08-15 18:57:51 -04:00
Alberto Ruiz
b79802789d GtkFontChooser: Iterate over faces as well as families to list them 2011-08-15 18:57:51 -04:00
Alberto Ruiz
f854a46890 GtkFontChooser: Improvements in the font face listing 2011-08-15 18:57:51 -04:00
Alberto Ruiz
8655384f51 GtkFontChooser: Set rules hint to TRUE in the main tree view 2011-08-15 18:57:51 -04:00
Alberto Ruiz
7611fe60f8 GtkFontChooser: Populated font list model 2011-08-15 18:57:51 -04:00
Alberto Ruiz
e570a91abb GtkFontChooser: Add column and cell renderer 2011-08-15 18:57:51 -04:00
Alberto Ruiz
6439fb4263 GtkFontChooser: Create functions to bootstrap the treeview column and settings and update the font list 2011-08-15 18:57:51 -04:00
Alberto Ruiz
48473b48e6 GtkFontChooser: Set vbox to no homogeneus 2011-08-15 18:57:51 -04:00
Alberto Ruiz
8a4cda71af GtkFontChooser: Setting the height of the preview and have a define for the top padding 2011-08-15 18:57:51 -04:00
Alberto Ruiz
6c44e85852 GtkFontChooser: Added slider and spin button 2011-08-15 18:57:51 -04:00
Alberto Ruiz
f0eef60123 GtkFontChooser: Adding the preview 2011-08-15 18:57:51 -04:00
Alberto Ruiz
f59b74622d GtkFontChooser: Adding the alignment to the selection 2011-08-15 18:57:51 -04:00
Alberto Ruiz
0c721d919c GtkFontChooser: Create alignment for the preview entry 2011-08-15 18:57:51 -04:00
Alberto Ruiz
1b302d3fad GtkFontChooser: Added main treeview 2011-08-15 18:57:51 -04:00
Alberto Ruiz
d46d1d7fcd GtkFontChooser: Avoid using show_all explicitely 2011-08-15 18:57:50 -04:00
Alberto Ruiz
810eda9cca GtkFontChooser: Create fundamental widgets for the new GtkFontSelection 2011-08-15 18:57:50 -04:00
Alberto Ruiz
9702e7c456 GtkFontChooser: Add private members to GtkFontSelectionPrivate 2011-08-15 18:57:50 -04:00
Alberto Ruiz
4f38ff9757 GtkFontChooser: Remove all cruft from the current GtkFontSelection implementation and start a new widget 2011-08-15 18:57:50 -04:00
Jesse van den Kieboom
99686a2fef Added gtk_text_iter_assign API
https://bugzilla.gnome.org/show_bug.cgi?id=645258
2011-08-15 15:29:23 +02:00
Paolo Borelli
508353fd15 Do not manually create empty label
gtk_notebook_update_labels will take care of creating it if needed.
2011-08-15 15:08:28 +02:00
Laszlo Pandy
991b782b75 Fix incomplete &gt; entities in docs. 2011-08-13 15:22:44 +02:00
Cosimo Cecchi
9d269bd7f2 settings: use the right RC parser for the gtk-visible-focus setting
Without the parser the property the property won't be settable by themes
using settings.ini
2011-08-11 15:38:45 +02:00
Jürg Billeter
c7bcef426b widget: Add transfer annotation for gtk_widget_set_window
gtk_widget_set_window does not add any reference to the window and
unrealize will destroy it.
2011-08-11 12:35:46 +02:00
Dan Winship
c4a5c99074 Fix cut-and-paste error in GtkEntryAccessible/GtkLabelAccessible
The y position of the character depends on the window's y coordinate,
not its x coordinate.
2011-08-10 15:19:56 -04:00
Matthias Clasen
2ba9c4b4a7 Make focus rectangles optional
This commit introduces a new setting, gtk-visible-focus, backed
by the Gtk/VisibleFocus X setting. Its three values control how
focus rectangles are displayed.

'always' is equivalent to the traditional GTK+ behaviour of always
rendering focus rectangles.

'never' does what it says, and is intended for keyboardless
situations, e.g. tablets.

'automatic' hides focus rectangles initially, until the user
interacts with the keyboard, at which point focus rectangles
become visible.

https://bugzilla.gnome.org/show_bug.cgi?id=649567
2011-08-10 16:34:20 +02:00
Rachid BM
99080af3ee Language improvements
Changed rgba to uppercase (Only in UI strings)
Fixed the typo: tolevel -> toplevel
2011-08-10 12:15:32 +01:00
Cosimo Cecchi
7e22b46c1f combobox: add a "combobox-entry" style class for comboboxes with entries
This way themes can use GtkComboBox.combobox-entry to match that
specific case, and GtkComboBox.combobox-entry .button to match the
button/arrow side of the widget.
2011-08-09 16:08:00 +02:00
Matthias Clasen
d324a99454 Fix entry drawing in the presence of margins
Margins need to be taken into account when comparing requisitions
and allocations, which GtkEntry (and subclasses) do for some reason.
2011-08-09 15:12:21 +02:00
Matthias Clasen
17f99f663f GtkGrid: Add a way to insert rows or columns
This is useful functionality that makes it easier to insert
things in the middle of an already populated grid.

Bug 653817
2011-08-08 13:13:48 +02:00
Will Thompson
5bfef8c80a GtkAppChooser: improve grammar in short_description
https://bugzilla.gnome.org/show_bug.cgi?id=656098
2011-08-07 12:12:11 +02:00
Ignacio Casal Quinteiro
92e1d27475 Fix warning 2011-08-06 19:02:16 +02:00
Federico Mena Quintero
d4b992506a Merge branch 'bgo593793-filechooser-recent-folders-master' 2011-08-02 11:46:05 -05:00
Federico Mena Quintero
2485273247 bgo#655822 - Put back the expand-folders schema in gsettings
Apparently schemas are part of the ABI contract; running apps crash if a
schema disapppears and they happen to access it.

Signed-off-by: Federico Mena Quintero <federico@gnome.org>
2011-08-02 11:45:47 -05:00
Pavel Holejsovsky
bb09982b66 Avoid introspection scanner warning on GtkPlug and GtkSocket
Make sure that sources with annotations are included into the list of
sources passed to introspection scanner.
2011-08-01 11:09:57 +02:00
Kristian Rietveld
dca9db124b Bug 655545 - condition can never be true in gtk_tree_view_real_set_cursor
Spotted by Ben Pfaff.
2011-07-30 23:01:38 +02:00
Federico Mena Quintero
af00ca81e1 Merge branch 'bgo593793-filechooser-recent-folders-master' 2011-07-27 18:56:39 -05:00
Federico Mena Quintero
9112cb4dfa Set the location mode when changing the operation mode
Signed-off-by: Federico Mena Quintero <federico@gnome.org>
2011-07-27 18:56:27 -05:00
Federico Mena Quintero
80d0efd94a Switch to OPERATION_MODE_BROWSE when switching to volume or file shortcuts
Signed-off-by: Federico Mena Quintero <federico@gnome.org>
2011-07-27 18:56:22 -05:00
Federico Mena Quintero
ff95a79d98 Remove the unused, initial-text logic from the location entry
Years ago, when the location entry only appeared in a popup window, it used to appear
populated with the current folder's path.  We had some logic to do this, but since now
the location entry appears in the main dialog, we can do away with that old code.

Signed-off-by: Federico Mena Quintero <federico@gnome.org>
2011-07-27 18:56:18 -05:00
Federico Mena Quintero
fa2e287687 Create the location_entry in a single function
We had duplicated code to create the entry in two cases, for Open and for Save modes.

Signed-off-by: Federico Mena Quintero <federico@gnome.org>
2011-07-27 18:56:15 -05:00
Federico Mena Quintero
9ed65c5620 Only unset the entry's contents if the entry exists
Signed-off-by: Federico Mena Quintero <federico@gnome.org>
2011-07-27 18:56:11 -05:00
Federico Mena Quintero
6c31de64b3 Discard the search widgets in a separate function
Signed-off-by: Federico Mena Quintero <federico@gnome.org>
2011-07-27 18:56:06 -05:00
Federico Mena Quintero
3de864cfff Move the widgets above the hpaned to their own box
This way we can re-create the contents of that box easily without disrupting
the rest of the file chooser.

Signed-off-by: Federico Mena Quintero <federico@gnome.org>
2011-07-27 18:56:02 -05:00
Federico Mena Quintero
c1fbdb4fd0 Make operation_mode_set() handle SEARCH and RECENT modes as well
Signed-off-by: Federico Mena Quintero <federico@gnome.org>
2011-07-27 18:55:58 -05:00
Federico Mena Quintero
cccf35f862 Centralize changing the operation mode in operation_mode_set()
This will be the central function to switch operation modes:  stop searches or the recent-files
process; switch widgets, etc.

We factor out the common code from recent_switch_to_browse_mode() and search_switch_to_browse_mode(),
and remove those functions.  All the code that switched modes by hand now calls
the central operation_mode_set().

Signed-off-by: Federico Mena Quintero <federico@gnome.org>
2011-07-27 18:55:54 -05:00
Federico Mena Quintero
7726276fe9 Remove duplicated code from *_switch_to_browse_mode()
That code indeed lives in operation_mode_stop(), so use it instead of
having inlined duplicates.

Signed-off-by: Federico Mena Quintero <federico@gnome.org>
2011-07-27 18:55:50 -05:00
Federico Mena Quintero
9e6e6575de Rename stop_operation() to operation_mode_stop()
We'll now prefix functions to change the impl->operation_mode with 'operation_mode',
for clarity.

Signed-off-by: Federico Mena Quintero <federico@gnome.org>
2011-07-27 18:55:45 -05:00
Federico Mena Quintero
8962e0383f Save selection to recent-files in the asynchronous Save cases
Various paths in SAVE or CREATE_FOLDER return from ::should_respond() but
leave an asynchronous process running.  This process checks some things
in the user's selection, for example, 'does the file exist, and if so
do we need to bring up an overwrite-confirmation dialog?'.  When these
async processes complete *and* it is indeed time for the dialog to
be terminated (via the response-requested signal), we also need to
save the selection to the recently-used list - as ::should_respond() does
by itself in the cases when it can request a response immediately.

Signed-off-by: Federico Mena Quintero <federico@gnome.org>
2011-07-27 18:54:52 -05:00
Federico Mena Quintero
7985ab786d Log to recent-files when confirming the file chooser
To make life easier for users, when apps don't properly update the recently-used list
after choosing a file, we now do that directly from the file chooser.

Signed-off-by: Federico Mena Quintero <federico@gnome.org>
2011-07-27 18:54:42 -05:00
Kristian Rietveld
8d69f3daf2 Bug 508601 - Copying from GTK+ applications causes crash
In GtkClipboardOwner pasteboard:provideDataForType do not call
_gtk_quartz_set_selection_data_for_pasteboard() is selection_data.length
is smaller than 0.  The function relies on having a positive length,
since it stores the length in a uint ...
2011-07-25 22:05:52 +02:00
Matthias Clasen
093612a46c Use G_DEFINE_TYPE for GtkIconViewItemAccessible 2011-07-25 00:46:34 -04:00
Matthias Clasen
2c6c0fe329 Minor cleanups 2011-07-25 00:34:08 -04:00
Matthias Clasen
a4560cdfbb Rework AtkText implementation
Use a PangoLayout, instead of storing a text buffer per item.
And use gtkpango api instead of implementing it all ourselves.
2011-07-25 00:27:42 -04:00
Matthias Clasen
26a040e81b Drop some grandiosity from the AtkAction implementation
There is only one action here, no need to pretend otherwise.
2011-07-24 23:59:00 -04:00
Matthias Clasen
625947f9f2 Use G_DEFINE_TYPE for GtkIconViewAccessible 2011-07-24 23:48:41 -04:00
Matthias Clasen
fadd58a0fb Drop GtkIconViewAccessiblePrivate
Just put the members in GtkIconViewAccessible itself.
2011-07-24 23:28:57 -04:00
Matthias Clasen
8a544d54ea Move GtkBuildable implementation up before accessibility
Just code rearrangement, no other changes.
2011-07-24 23:04:02 -04:00
Matthias Clasen
2983f3fc14 Update gtk_widget_get_accessible() docs
Don't mention GTK_MODULES for loading a11y implementations
anymore.
2011-07-23 21:28:29 -04:00
Felix Riemann
e8486fdf71 gtkstyleproperty: fix small memory leak
The released value is a string array and thus g_free is not sufficient.

https://bugzilla.gnome.org/show_bug.cgi?id=655173
2011-07-23 21:40:59 +02:00
Matthias Clasen
2937a875a0 Ditch some long dead perl cruft 2011-07-23 13:44:45 -04:00
Matthias Clasen
c3be60198f Towards a working distcheck 2011-07-23 10:12:55 -04:00
Rico Tzschichholz
ecd5f73dd7 build: Fix makefile for new location of test image 2011-07-23 12:27:45 +02:00
Matthias Clasen
ec72283a65 some minor doc fixes 2011-07-22 22:00:34 -04:00
Matthias Clasen
f7e927b93c Try to make the docs build again
After some searching, it turns out that gtk-doc now interprets
markdown, and can no longer accept '-' in the docs without making
a mess. I hope that this does not affect more places in more
subtle ways.
2011-07-22 21:54:08 -04:00
Benjamin Otte
d82aeb8245 tests: Fix stylecontext test that we changed semantics for
We don't have different priorities for superclasses anymore.
2011-07-23 01:24:07 +02:00
Philip Withnall
0b4d8433d4 Bug 654266 — No longer possible to set empty text on a GtkProgressBar
Change the semantics of GtkProgressBar:text slightly so that it behaves as
it did before GTK+ 3.

Closes: bgo#654266
2011-07-23 00:09:30 +01:00
Andre Klapper
91706f7883 Don't use deprecated G_UNICODE_COMBINING_MARK 2011-07-22 19:56:49 +02:00
Benjamin Otte
d56e8c8e54 tests: Move declaration tests to new test infrastructure
This way, we can test more feature of them, in particular check for
different errors, which were causing test failures.
2011-07-21 02:43:54 +02:00
Benjamin Otte
47635a2434 themingengine: Return NULL for nonexistant theming engines
his also makes the function conform to its documentation.
2011-07-21 02:43:54 +02:00
Benjamin Otte
9062060304 css: Don't print both border-image-repeat values when they're identical 2011-07-21 02:43:54 +02:00
Benjamin Otte
72bc10a61c css: Ensure that font shorthand parsing sets font name and size 2011-07-21 02:43:54 +02:00
Benjamin Otte
5a1e1579b3 styleproperty: dump image surfaces as PNG data URLs
We're not able to load that (yet?), but it's useful for producing
diffable test dumps.
2011-07-21 02:43:54 +02:00
Andrea Cimitan
b3f03d092f roundedbox: Clamp border radius to box size
Note that clamping in rounded_box_grow() is not necessary as that
function cannot lead to overlap unless the rounded box was overlapping
previously.

https://bugzilla.gnome.org/show_bug.cgi?id=655009
2011-07-21 02:43:54 +02:00
Benjamin Otte
a02b82056a tests: Remove unused file from EXTRA_DIST 2011-07-21 02:43:54 +02:00
Benjamin Otte
b0b287f7b5 themingengine: Use the default way of indicating privates 2011-07-21 02:43:54 +02:00
Benjamin Otte
9e36bea907 styleproperty: An unnamed engine equals the default engine 2011-07-21 02:43:54 +02:00
Benjamin Otte
d314709af6 tests: Declare previously invalid CSS as valid now
The CSS is valid, it might just not work (though most of it will for
siblings).
2011-07-21 02:43:54 +02:00
Benjamin Otte
4f5e69fa2c tests: Fix whitespace between url and (
It's not allowed according to CSS (and browsers).
2011-07-21 02:43:54 +02:00
Benjamin Otte
5a1f371e12 cssprovider: Fix names for first and last child pseudo class
The correct name is :first-child, not :first
2011-07-21 02:43:53 +02:00
Ryan Lortie
4ead7b69ea Switch to g_format_size()
g_format_size_for_display() has been deprecated in GLib and replaced with
g_format_size().  Follow that change.
2011-07-20 20:22:26 +02:00
Benjamin Otte
75a43bb40c tests: Move empty css parser test to new CSS tests 2011-07-20 02:36:44 +02:00
Benjamin Otte
15674c5bd4 tests: Move stylecontext CSS tests
Use the new CSS infrastructure for part of the old CSS tests. This way
we can probably check for warning messages such as deprecations.
2011-07-20 02:36:44 +02:00
Benjamin Otte
1a763044fe cssprovider: Emit an error when parsing a binding fails 2011-07-20 02:36:44 +02:00
Benjamin Otte
b8465d289b cssprovider: Get the location right for semicolon warnings 2011-07-20 02:36:44 +02:00
Benjamin Otte
5eefc37b3f cssprovider: @import <string> is valid CSS
The parser rewrite insisted on @import url(<string>) syntax, but CSS
xplicitly allows omitting the url string.
2011-07-20 02:36:44 +02:00
Benjamin Otte
014165151f css: Use the correct free function 2011-07-20 02:36:44 +02:00
Benjamin Otte
ebadb36962 notebook: Remove unused private member variable 2011-07-20 02:36:44 +02:00
Benjamin Otte
1cdb47d960 notebook: Remove the homogenous private member variable
It's unused and therefor always FALSE, so we can remove the parts of the
code that branch based on it.
2011-07-19 12:53:06 +02:00
Benjamin Otte
6aa000f65b styleproperties: Add unset functions for shorthands
This fixes calls to gtk_style_properties_unset_property() for
shorthand properties.

https://bugzilla.gnome.org/show_bug.cgi?id=654678
2011-07-19 11:58:22 +02:00
Benjamin Otte
68ebc77a9a styleproperties: Add an unset vfunc to style properties
This makes unsetting work for shorthands.
2011-07-19 11:58:22 +02:00
Philip Withnall
fd705ce7c7 progressbar: Fix a signed/unsigned comparison 2011-07-18 19:35:02 +01:00
Benjamin Otte
b0e836e231 a11y: Merge gtksubmenuitem into gtkmenuitem
The reason why they were separate is historic, it's not useful to keep
the distinction.
2011-07-18 19:41:07 +02:00
Benjamin Otte
9306b266a0 a11y: Rename checksubmenuitem to checkmenuitem 2011-07-18 19:21:17 +02:00
Benjamin Otte
77f411c77a a11y: Remove gtkcheckmneuitemaccessible.[ch]
COde uses gtkchecksubmenuitemaccessible exclusively now. And I totally
dig these long finger-twisting names.
2011-07-18 19:05:28 +02:00
Benjamin Otte
fa16a54b21 a11y: Rename radiosubmenuitem to radiomenuitem 2011-07-18 19:01:40 +02:00
Benjamin Otte
438b78a27d a11y: Remove gtkradiomenuitemaccessible.[ch]
We use gtkradiosubmenuitemaccessible exclusively these days.
2011-07-18 18:47:12 +02:00
Benjamin Otte
d5ef8448bb checkbutton: Use gtk_widget_class_set_accessible_role() 2011-07-18 18:30:51 +02:00
Benjamin Otte
0c9b046af0 accellabel: Use gtk_widget_class_set_accessible_role() 2011-07-18 18:30:51 +02:00
Benjamin Otte
f2626b6183 menubar: Use gtk_widget_class_set_accessible_role() 2011-07-18 18:30:51 +02:00
Benjamin Otte
9c30ae02ee toolbar: Use gtk_widget_class_set_accessible_role() 2011-07-18 18:30:50 +02:00
Benjamin Otte
96245d4efb viewport: Use gtk_widget_class_set_accessible_role() 2011-07-18 18:30:50 +02:00
Benjamin Otte
d9bfa563d0 tearoffmenuitem: Use gtk_widget_class_set_accessible_role() 2011-07-18 18:30:50 +02:00
Benjamin Otte
480b5862d4 plug: Use gtk_widget_class_set_accessible_role() 2011-07-18 18:30:50 +02:00
Benjamin Otte
27f96820c8 fontsel: Use gtk_widget_class_set_accessible_role() 2011-07-18 18:30:50 +02:00
Benjamin Otte
c40875ad51 messagedialog: Use gtk_widget_class_set_accessible_role() 2011-07-18 18:30:50 +02:00
Benjamin Otte
6379faaa90 dialog: Use gtk_widget_class_set_accessible_role() 2011-07-18 18:30:50 +02:00
Benjamin Otte
2e570136f5 colorsel: Use gtk_widget_class_set_accessible_role() 2011-07-18 18:30:50 +02:00
Benjamin Otte
299b3bed96 filechooserdialog: Use gtk_widget_class_set_accessible_role() 2011-07-18 18:30:50 +02:00
Benjamin Otte
9c81336830 widget: Reset the accessible role when a new accessible type is set
We want the role to be kept in the accessible object. Using
gtk_widget_class_set_accessible_role() is only meant as a quick
workaround to requiring subclassing of the accessibles in the quite
common case where a subclass does not change the accessible
implementation at all and only has a different role.
2011-07-18 18:30:50 +02:00
Benjamin Otte
b61a200036 separatormenuitem: Use gtk_widget_class_accessible_set_role() 2011-07-18 18:30:50 +02:00
Benjamin Otte
094785bd68 separator: Use gtk_widget_class_accessible_set_role() 2011-07-18 18:30:50 +02:00
Benjamin Otte
017d02b9de hsv: Use gtk_widget_class_accessible_set_role() 2011-07-18 18:30:50 +02:00
Benjamin Otte
8815ccf5c4 calendar: Use gtk_widget_class_accessible_set_role() 2011-07-18 18:30:50 +02:00