summaryrefslogtreecommitdiff
path: root/gtk/gtkemojichooser.c
Commit message (Collapse)AuthorAgeFilesLines
* emojichooser: Avoid extraneous variation selectorsMatthias Clasen2023-04-301-3/+5
| | | | Only add a variation selector if there isn't one already.
* emojichooser: Stop using gtk_widget_get_allocationMatthias Clasen2023-03-291-21/+33
| | | | Replace all uses with gtk_widget_compute_bounds.
* Deprecate gtk_widget_translate_coordinatesMatthias Clasen2023-03-251-6/+8
| | | | | | | Update all (non-deprecated) callers to use gtk_widget_compute_point instead. Fixes: #5697
* emojichooser: Actually disable the recent sectionGuido Günther2022-12-071-1/+1
| | | | | | | The loop sets empty = FALSE when there are emojis but for that to work we need to initialize the value to TRUE initially. Fixes: 7928532bc5c33b2c6a10bae138ebc6dca1843cb0
* gtk: Stop using gtk_widget_show/hideMatthias Clasen2022-11-281-1/+1
| | | | | | | gtk_widget_set_visible and gtk_window_present are better alternatives, and calling gtk_widget_show on newly created widgets is no longer necessary anyway.
* emojichooser: Drop an unused includeMatthias Clasen2022-10-091-1/+0
|
* Drop gtkintl.hMatthias Clasen2022-09-241-1/+0
| | | | | Include gtkprivate.h for I_() and glib-i18n.h for gettext macros.
* emojichooser: Fix arrow keynavMatthias Clasen2022-08-191-52/+110
| | | | | | | | | | When some of the Emoji have been filtered out by a search term, arrow keynav would behave oddly and get stuck in invisible sections. Fix this by ignoring any filtered out children when moving between sections for arrow keynav. Fixes: #5076
* Rename clear_template to dispose_templateEmmanuele Bassi2022-07-111-1/+1
| | | | | Make it more clear that the function is supposed to be called during the dispose sequence of a widget.
* emojichooser: Use gtk_widget_clear_template()Emmanuele Bassi2022-07-111-2/+11
|
* Avoid copying static debug stringsMatthias Clasen2021-07-281-1/+1
| | | | | | The g_source_set_name calls were showing up as a major source of strdups in our profiles. Avoid that by using new GLib api when available.
* emoji: Try to load emoji data using both language and territoryMarco Trevisan (Treviño)2021-05-071-16/+34
| | | | | | | | | | | When loading the emoji data we just try to get the data for a language while there may be territory specializations and emojibase provides them. So, split the loading function and try to load the data for the fully defined language string (i.e. `it-ch`) before loading the generic one for the language (i.e. `it`) and eventually falling back to the generic english.
* emoji: remove duplicated includeMarco Trevisan (Treviño)2021-05-061-1/+0
|
* emoji: Use a portable and configuration-dependent path to load the dataMarco Trevisan (Treviño)2021-05-061-1/+5
| | | | | Load the emojis data in all the platforms, respecting the configured GTK_DATA_PREFIX
* emojichooser: Static analysis fixesMatthias Clasen2021-05-031-0/+2
|
* emojichooser: Use markdown for css treeMatthias Clasen2021-03-111-2/+2
|
* emojichooser: Convert docsMatthias Clasen2021-03-111-14/+13
|
* emojichooser: Make keynav work with != 7 columnsMatthias Clasen2021-01-251-3/+22
| | | | | | | The number of 7 columns was hardcoded in a few places related to keynav across sections. The flowbox does not have an api for it, but we can find out anyway how many columns there are.
* emojichooser: Add .emoji-searchbar style classnana-42020-12-141-0/+4
| | | | Similar to .emoji-toolbar, it would be nice to have this for styling.
* gtk/popover: Use gtk_popover_present() instead of going via GtkNativeJonas Ådahl2020-12-071-1/+1
| | | | This makes it more explicit that managers of popovers make it "present".
* emoji chooser: Fix incremental loadingMatthias Clasen2020-12-041-4/+4
| | | | | | | | | This broke when we started using GDK_PROFILER_CURRENT_TIME for timekeeping - that gets defined to 0 when we're building without sysprof, so we can use it to make such determinations. Go back to using g_get_monotonic_time(). Fixes: #3438
* Remove unneeded gtkstylecontext.h includesTimm Bäder2020-10-141-1/+0
|
* Redo the handling of Emoji dataemoji-data-cldrMatthias Clasen2020-10-041-30/+110
| | | | | | | | | | | | | | | Use the data files from https://github.com/milesj/emojibase.git as source for our Emoji data. Slightly change our data format by adding a group to each item, in both the Emoji data and in the setting for recent-emoji. Install translated versions of the data as separate resource bundles in $prefix/gtk-4.0/emoji, and load them when appropriate. Currently, we have data for de, en, es, fr, zh, with data taken from Unicode 13 and CLDR 13. Fixes: #950 #1511
* Emoji: Drop the shortname field from emoji.dataMatthias Clasen2020-10-031-5/+5
| | | | | | Match the name for Emoji completion, and display it too. 'man worker' looks a lot more natural in the UI than ':man_worker:'.
* Do case-folding and tokenization when creating emoji.dataMatthias Clasen2020-10-031-5/+36
| | | | | We can avoid doing the extra work of case-folding and tokenization whenever we filter in the Emoji chooser.
* emoji: Add keywords to the dataMatthias Clasen2020-10-031-4/+10
| | | | And use them for matching in the Emoji chooser.
* emojichooser: Allow inserting multiple EmojiMatthias Clasen2020-10-011-1/+26
| | | | | | | | | Don't close the Emoji chooser when the Control key is held while clicking. So you can insert multiple Emoji without having to reopen the chooser every time. Fixes: #1002
* emojichooser: Fix typo in css classTimm Bäder2020-09-151-1/+1
|
* emojichooser: Grab focus on mapMatthias Clasen2020-08-241-0/+11
| | | | | This is the right thing to do, since we have a visible entry and want text input to go there.
* Port tracing to the sysprof collector apiMatthias Clasen2020-08-211-8/+6
| | | | Use the new sysprof collector api to do tracing.
* Fix minor typosYuri Chornoivan2020-06-181-1/+1
|
* emojichooser: Unparent the variations popup on dispose and before adding a ↵Carlos Garcia Campos2020-06-021-0/+14
| | | | | | | new one This was causing warnings when destroying the emoji chooser because it had children left.
* Change coordinate translation apis to take doublesMatthias Clasen2020-05-171-1/+1
| | | | | | Change gtk_widget_translate_coordinates and gtk_native_get_surface_transform to operate on doubles. Update all callers.
* Replace most remaining uses of container apiMatthias Clasen2020-05-111-4/+10
| | | | These are all on GtkBox or enumerating children.
* docs: Fix several missing references in the documentationCorentin Noël2020-05-111-2/+2
| | | | This fixes several typos and missing references
* flowboxchild: Derive from GtkWidgetMatthias Clasen2020-05-041-2/+2
| | | | | | | We want to remove GtkBin and GtkContainer as they don't provide much useful functionality anymore. See #2681
* Use gtk_popover_set_child throughoutMatthias Clasen2020-05-041-1/+1
| | | | | Replace all uses of gtk_container_add on popovers by gtk_popover_set_child.
* Assorted documentation fixesMatthias Clasen2020-04-201-0/+6
|
* emojichooser: Drop focus adjustment settingMatthias Clasen2020-04-181-5/+0
| | | | | It is not needed here, we are now scrolling differently.
* emojichooser: link sections for keynavMatthias Clasen2020-04-141-26/+106
| | | | Make Up/Down jump between sections in the Emoji grid.
* flowbox: Add a private api to disable move-cursorMatthias Clasen2020-04-141-0/+3
| | | | | | | | Without this, it seems impossible to make cross-section keynav in the Emoji chooser work. I've tried, but got lost between the focus, grab_focus, move_cursor and keynav-failed vfuncs and signals, and their competing implementations GtkFlowBox and GtkEmojiChooser.
* emojichooser: Improve keynav, againMatthias Clasen2020-04-141-0/+38
| | | | | When the focus is moved to one of the Emoji children, scroll it into view.
* emojichooser: Improve keynavMatthias Clasen2020-04-141-5/+62
| | | | | Add an action to scroll to the next or previous section, and bind it to Ctrl-n/Ctrl-p.
* emojichooser: Stop using ::popup-menuMatthias Clasen2020-03-251-13/+27
| | | | This signal is going away. Use an action instead.
* Revert "Merge branch 'disable-window-test' into 'master'"Matthias Clasen2020-03-191-27/+13
| | | | | This reverts commit 3ac4c76b18cc89a841ce09f0943539f16988fd21, reversing changes made to 6ec96d2e989d029a303b8b20ec72b86f974c0e87.
* emojichooser: Stop using ::popup-menuMatthias Clasen2020-03-181-13/+27
| | | | This signal is going away. Use an action instead.
* emojichooser: Fix keynavMatthias Clasen2020-03-171-0/+17
| | | | | Make arrow and tab keys work in the variations popover again.
* emojichooser: Make the variation picker work againMatthias Clasen2020-03-171-2/+47
| | | | We can't attach popovers to unsuspecting widget anymore.
* emojichooser: Avoid using gtk_widget_destroy()Timm Bäder2020-02-251-3/+4
|
* popover: Drop ::relative-toMatthias Clasen2020-02-241-1/+2
| | | | | | | | | It is enough to just set the parent (and make the parent call gtk_native_check_resize in size_allocate). This commit removes the relative_to argument to the constructors of GtkPopover and GtkPopoverMenu, and updates all callers.