Sign Up
Log In
Log In
or
Sign Up
Places
All Projects
Status Monitor
Collapse sidebar
home:dspinella:zlib-ng-staging
libgedit-amtk
libgedit-amtk-5.9.0.obscpio
Overview
Repositories
Revisions
Requests
Users
Attributes
Meta
File libgedit-amtk-5.9.0.obscpio of Package libgedit-amtk
07070100000000000041ED00000000000000000000000266D2F0DB00000000000000000000000000000000000000000000001D00000000libgedit-amtk-5.9.0/LICENSES07070100000001000081A400000000000000000000000166D2F0DB00001D07000000000000000000000000000000000000003300000000libgedit-amtk-5.9.0/LICENSES/LGPL-3.0-or-later.txtGNU LESSER GENERAL PUBLIC LICENSE Version 3, 29 June 2007 Copyright (C) 2007 Free Software Foundation, Inc. <https://fsf.org/> Everyone is permitted to copy and distribute verbatim copies of this license document, but changing it is not allowed. This version of the GNU Lesser General Public License incorporates the terms and conditions of version 3 of the GNU General Public License, supplemented by the additional permissions listed below. 0. Additional Definitions. As used herein, "this License" refers to version 3 of the GNU Lesser General Public License, and the "GNU GPL" refers to version 3 of the GNU General Public License. "The Library" refers to a covered work governed by this License, other than an Application or a Combined Work as defined below. An "Application" is any work that makes use of an interface provided by the Library, but which is not otherwise based on the Library. Defining a subclass of a class defined by the Library is deemed a mode of using an interface provided by the Library. A "Combined Work" is a work produced by combining or linking an Application with the Library. The particular version of the Library with which the Combined Work was made is also called the "Linked Version". The "Minimal Corresponding Source" for a Combined Work means the Corresponding Source for the Combined Work, excluding any source code for portions of the Combined Work that, considered in isolation, are based on the Application, and not on the Linked Version. The "Corresponding Application Code" for a Combined Work means the object code and/or source code for the Application, including any data and utility programs needed for reproducing the Combined Work from the Application, but excluding the System Libraries of the Combined Work. 1. Exception to Section 3 of the GNU GPL. You may convey a covered work under sections 3 and 4 of this License without being bound by section 3 of the GNU GPL. 2. Conveying Modified Versions. If you modify a copy of the Library, and, in your modifications, a facility refers to a function or data to be supplied by an Application that uses the facility (other than as an argument passed when the facility is invoked), then you may convey a copy of the modified version: a) under this License, provided that you make a good faith effort to ensure that, in the event an Application does not supply the function or data, the facility still operates, and performs whatever part of its purpose remains meaningful, or b) under the GNU GPL, with none of the additional permissions of this License applicable to that copy. 3. Object Code Incorporating Material from Library Header Files. The object code form of an Application may incorporate material from a header file that is part of the Library. You may convey such object code under terms of your choice, provided that, if the incorporated material is not limited to numerical parameters, data structure layouts and accessors, or small macros, inline functions and templates (ten or fewer lines in length), you do both of the following: a) Give prominent notice with each copy of the object code that the Library is used in it and that the Library and its use are covered by this License. b) Accompany the object code with a copy of the GNU GPL and this license document. 4. Combined Works. You may convey a Combined Work under terms of your choice that, taken together, effectively do not restrict modification of the portions of the Library contained in the Combined Work and reverse engineering for debugging such modifications, if you also do each of the following: a) Give prominent notice with each copy of the Combined Work that the Library is used in it and that the Library and its use are covered by this License. b) Accompany the Combined Work with a copy of the GNU GPL and this license document. c) For a Combined Work that displays copyright notices during execution, include the copyright notice for the Library among these notices, as well as a reference directing the user to the copies of the GNU GPL and this license document. d) Do one of the following: 0) Convey the Minimal Corresponding Source under the terms of this License, and the Corresponding Application Code in a form suitable for, and under terms that permit, the user to recombine or relink the Application with a modified version of the Linked Version to produce a modified Combined Work, in the manner specified by section 6 of the GNU GPL for conveying Corresponding Source. 1) Use a suitable shared library mechanism for linking with the Library. A suitable mechanism is one that (a) uses at run time a copy of the Library already present on the user's computer system, and (b) will operate properly with a modified version of the Library that is interface-compatible with the Linked Version. e) Provide Installation Information, but only if you would otherwise be required to provide such information under section 6 of the GNU GPL, and only to the extent that such information is necessary to install and execute a modified version of the Combined Work produced by recombining or relinking the Application with a modified version of the Linked Version. (If you use option 4d0, the Installation Information must accompany the Minimal Corresponding Source and Corresponding Application Code. If you use option 4d1, you must provide the Installation Information in the manner specified by section 6 of the GNU GPL for conveying Corresponding Source.) 5. Combined Libraries. You may place library facilities that are a work based on the Library side by side in a single library together with other library facilities that are not Applications and are not covered by this License, and convey such a combined library under terms of your choice, if you do both of the following: a) Accompany the combined library with a copy of the same work based on the Library, uncombined with any other library facilities, conveyed under the terms of this License. b) Give prominent notice with the combined library that part of it is a work based on the Library, and explaining where to find the accompanying uncombined form of the same work. 6. Revised Versions of the GNU Lesser General Public License. The Free Software Foundation may publish revised and/or new versions of the GNU Lesser General Public License from time to time. Such new versions will be similar in spirit to the present version, but may differ in detail to address new problems or concerns. Each version is given a distinguishing version number. If the Library as you received it specifies that a certain numbered version of the GNU Lesser General Public License "or any later version" applies to it, you have the option of following the terms and conditions either of that published version or of any later version published by the Free Software Foundation. If the Library as you received it does not specify a version number of the GNU Lesser General Public License, you may choose any version of the GNU Lesser General Public License ever published by the Free Software Foundation. If the Library as you received it specifies that a proxy can decide whether future versions of the GNU Lesser General Public License shall apply, that proxy's public statement of acceptance of any version is permanent authorization for you to choose that version for the Library. 07070100000002000081A400000000000000000000000166D2F0DB00001ACC000000000000000000000000000000000000001900000000libgedit-amtk-5.9.0/NEWSNews in 5.9.0, 2024-08-31 ------------------------- * Adopt new versioning scheme (this version is a stable one). * Move the project to: https://gitlab.gnome.org/World/gedit/libgedit-amtk * Use GtkImageMenuItem even if deprecated. * Build: add the 'tests' option. * Translation updates. News in 5.8.0, 2023-07-28 ------------------------- * Rename the project: Amtk -> libgedit-amtk. Hosted here: https://gedit-technology.net/ and https://github.com/gedit-technology/libgedit-amtk * A few code maintenance. * Docs: add note about GtkImageMenuItem. News in 5.6.1, 2022-11-17 ------------------------- * Revert unintentional soname bump, set 'soversion' back to 0. News in 5.6.0, 2022-11-02 ------------------------- * No changes. News in 5.5.2, 2022-10-24 ------------------------- * Add a function in AmtkApplicationWindow. * Build: fix a warning. News in 5.5.1, 2022-06-10 ------------------------- * The project is now hosted here: https://gitlab.gnome.org/World/amtk * Add a utils function. * Other minor improvement. News in 5.4.1, 2022-05-25 ------------------------- * Build system: check if compiler supports --version-script linker option. * Documentation improvements. News in 5.4.0, 2022-05-02 ------------------------- * Nothing. News in 5.3.2, 2022-04-18 ------------------------- * The project is now hosted here: https://gitlab.gnome.org/swilmet/amtk * Some files reorganization within the git repository. * Update the README.md file, etc. * Some code refactorings, it's now easier to copy part of the code (e.g., just one class) to another project. * Mark public API with G_MODULE_EXPORT, not the custom _AMTK_EXTERN macro. * REUSE way of applying licenses, and update license from LGPLv2.1+ to LGPLv3+. * Translation updates. News in 5.3.1, 2021-01-11 ------------------------- * Build: port to Meson, remove Autotools. * Translation updates. News in 5.2.0, 2020-09-10 ------------------------- * Translation updates. News in 5.1.2, 2020-09-04 ------------------------- * Build system: better support for Visual Studio. * Translation updates. News in 5.1.1, 2020-05-29 ------------------------- * Support detailed GAction names in factory functions. * Mark public API with _AMTK_EXTERN. * Microsoft Windows: better support. * Small maintenance stuff. * Translation updates. News in 5.0.2, 2020-01-25 ------------------------- * Small maintenance stuff. * Translation updates. News in 5.0.1, 2019-09-06 ------------------------- * Fix a small, new compilation warning. * Build from Git: allow building with gettext ≥ 0.20. * Write more development notes. * Translation updates. News in 5.0.0, 2018-07-16 ------------------------- * Moved to GNOME GitLab instance. * Some minor improvements. * Some new translations. News in 4.99.1, 2018-04-15 -------------------------- * Move Amtk to its own git repository (it was initially developed in Tepl). * Bump API/major version to 5, to avoid any problem if Tepl 4.0 is installed at the same time (which contains amtk-4). * AmtkFactory: add functions to create a simple GtkMenu directly from an array of AmtkActionInfoEntry's (will be useful in gnome-latex). * Extend Amtk to support a GUI with a GtkHeaderBar (now used in Devhelp): - AmtkFactory: add functions to create GMenuItem's and GtkShortcutsShortcut's. - Add convenience functions to create a GMenu and a GtkShortcutsWindow. - Add amtk_action_info_store_set_all_accels_to_app(). News in 3.99.1, 2017-12-09 -------------------------- * Amtk: - Improve amtk_utils_bind_g_action_to_gtk_action() to support _detailed_ GAction names. - Add amtk_utils_create_gtk_action(). News in 2.99.4, 2017-08-20 -------------------------- Amtk: * Add factory functions to create GtkMenuToolButton's and GtkCheckMenuItem's. * Improve API of amtk_application_window_connect_menu_to_statusbar(). * Add amtk_utils_bind_g_action_to_gtk_action(), to be able to port an application gradually to GAction while still using GtkUIManager. News in 2.99.3, 2017-08-09 -------------------------- Amtk: * Add amtk_init() and amtk_finalize(). * Remove AmtkFactoryMenu class, move its functions to its parent class AmtkFactory. * AmtkFactory: add functions to create GtkToolItem's. * Add amtk_application_window_create_open_recent_menu(). * Improvements to the documentation. * Other small code improvements. News in 2.99.2, 2017-07-18 -------------------------- Amtk: * The biggest change in this release is that the classes and functions related to actions and menus have been moved to a new shared library called Amtk (Actions, Menus and Toolbars Kit), since it was not really related to text editors, it is more general. But Amtk is still developed inside the Tepl repository. Amtk is a basic GtkUIManager replacement based on GAction (still under development, it is not yet finished, for example it doesn't handle toolbars). * Add AmtkFactory and AmtkFactoryMenu, which replace amtk_action_info_store_create_menu_item(). News in 2.99.1, 2017-06-15 -------------------------- * The library has been renamed from Gtef (GTK+ text editor framework) to Tepl (Text editor product line), to have a more beautiful name. The end of Tepl is pronounced like “apple”. News in 1.99.2, 2017-03-12 -------------------------- Basic GtkUIManager replacement based on GAction: * Add an easy way to create a GtkMenuItem from a GtefActionInfo. * Add a function to check that every GtefActionInfo in a GtefActionInfoStore has been used. * Add reference counting to GtefActionInfo. * Add GtefActionInfoCentralStore singleton class. * Add gtef_action_map_add_action_entries_check_dups(), to check if there are duplicates when adding GActions to a GActionMap. * Rename gtef_application_get_action_info_store() to gtef_application_get_app_action_info_store(). * Add GtefMenuShell, an extension of GtkMenuShell with the ::menu-item-selected and ::menu-item-deselected signals. * Add gtef_menu_item_get/set_long_description(). * Add GtefApplicationWindow, an extension of GtkApplicationWindow with: * A statusbar property. * A function to connect a GtefMenuShell to the statusbar, pushing/popping the long descriptions of GtkMenuItems when they are selected/deselected. * A function to connect a GtkRecentChooserMenu to the statusbar, pushing/popping the full paths. * A function to create a GtkMenuItem with a simple and generic GtkRecentChooserMenu as submenu. News in 1.99.1, 2017-01-26 -------------------------- Start a basic GtkUIManager replacement based on GAction: * Add gtef_utils_menu_item_set_icon_name() * Add GtefActionInfo * Add GtefActionInfoStore * Note that those classes are a little out of scope for a text editor library. I would be happy to move those classes to a better library once the feature is finished and well-tested. The classes were added to Gtef for convenience. 07070100000003000081A400000000000000000000000166D2F0DB0000023E000000000000000000000000000000000000001E00000000libgedit-amtk-5.9.0/README.mdlibgedit-amtk ============= Short description ----------------- Gedit Technology - Actions, Menus and Toolbars Kit Longer description ------------------ libgedit-amtk is part of Gedit Technology. It is a library based on GTK. Amtk is the acronym for “Actions, Menus and Toolbars Kit”. It is a basic GtkUIManager replacement based on GAction. It is suitable for both a traditional UI or a modern UI with a GtkHeaderBar. More information ---------------- libgedit-amtk currently targets **GTK 3**. [More information about libgedit-amtk](docs/more-information.md). 07070100000004000041ED00000000000000000000000266D2F0DB00000000000000000000000000000000000000000000001900000000libgedit-amtk-5.9.0/amtk07070100000005000081A400000000000000000000000166D2F0DB00001186000000000000000000000000000000000000003A00000000libgedit-amtk-5.9.0/amtk/amtk-action-info-central-store.c/* SPDX-FileCopyrightText: 2017 - Sébastien Wilmet <swilmet@gnome.org> * SPDX-License-Identifier: LGPL-3.0-or-later */ #include "amtk-action-info-central-store.h" #include "amtk-action-info.h" /** * SECTION:amtk-action-info-central-store * @Short_description: Aggregation of all #AmtkActionInfoStore's * @Title: AmtkActionInfoCentralStore * @See_also: #AmtkActionInfoStore * * #AmtkActionInfoCentralStore is a singleton class containing the aggregation * of all #AmtkActionInfoStore's. Each time an #AmtkActionInfo is added to an * #AmtkActionInfoStore, it is also added to the #AmtkActionInfoCentralStore. */ /* API design: * * Why both AmtkActionInfoStore and AmtkActionInfoCentralStore are needed? * * Advantage of AmtkActionInfoStore: * - amtk_action_info_store_check_all_used() * * Advantages of AmtkActionInfoCentralStore: * - The central store checks if there are no duplicated action names * (globally). * - Permits to write AmtkFactory functions that don't require an * AmtkActionInfoStore parameter. * * By having the two classes, we have the best of both worlds. We should not be * afraid to create a lot of classes, and see things in big, even if it's a bit * Java-ish. */ struct _AmtkActionInfoCentralStorePrivate { /* Key: owned gchar*: action name. * Value: owned AmtkActionInfo. */ GHashTable *hash_table; }; static AmtkActionInfoCentralStore *singleton = NULL; G_DEFINE_TYPE_WITH_PRIVATE (AmtkActionInfoCentralStore, amtk_action_info_central_store, G_TYPE_OBJECT) static void amtk_action_info_central_store_finalize (GObject *object) { AmtkActionInfoCentralStore *central_store = AMTK_ACTION_INFO_CENTRAL_STORE (object); g_hash_table_unref (central_store->priv->hash_table); if (singleton == central_store) { singleton = NULL; } G_OBJECT_CLASS (amtk_action_info_central_store_parent_class)->finalize (object); } static void amtk_action_info_central_store_class_init (AmtkActionInfoCentralStoreClass *klass) { GObjectClass *object_class = G_OBJECT_CLASS (klass); object_class->finalize = amtk_action_info_central_store_finalize; } static void amtk_action_info_central_store_init (AmtkActionInfoCentralStore *central_store) { central_store->priv = amtk_action_info_central_store_get_instance_private (central_store); central_store->priv->hash_table = g_hash_table_new_full (g_str_hash, g_str_equal, g_free, (GDestroyNotify) amtk_action_info_unref); } /** * amtk_action_info_central_store_get_singleton: * * Returns: (transfer none): the #AmtkActionInfoCentralStore singleton instance. * Since: 3.0 */ AmtkActionInfoCentralStore * amtk_action_info_central_store_get_singleton (void) { if (G_UNLIKELY (singleton == NULL)) { singleton = g_object_new (AMTK_TYPE_ACTION_INFO_CENTRAL_STORE, NULL); } return singleton; } void _amtk_action_info_central_store_unref_singleton (void) { if (singleton != NULL) { g_object_unref (singleton); } /* singleton is not set to NULL here, it is set to NULL in * amtk_action_info_central_store_finalize() (i.e. when we are sure that * the ref count reaches 0). */ } void _amtk_action_info_central_store_add (AmtkActionInfoCentralStore *central_store, AmtkActionInfo *info) { const gchar *action_name; g_return_if_fail (AMTK_IS_ACTION_INFO_CENTRAL_STORE (central_store)); g_return_if_fail (info != NULL); action_name = amtk_action_info_get_action_name (info); g_return_if_fail (action_name != NULL); if (g_hash_table_lookup (central_store->priv->hash_table, action_name) != NULL) { g_warning ("The AmtkActionInfoCentralStore already contains an AmtkActionInfo " "with the action name “%s”. Libraries must namespace their action names.", action_name); return; } g_hash_table_insert (central_store->priv->hash_table, g_strdup (action_name), amtk_action_info_ref (info)); } /** * amtk_action_info_central_store_lookup: * @central_store: the #AmtkActionInfoCentralStore. * @action_name: an action name. * * Returns: (transfer none): the found #AmtkActionInfo, or %NULL. * Since: 2.0 */ AmtkActionInfo * amtk_action_info_central_store_lookup (AmtkActionInfoCentralStore *central_store, const gchar *action_name) { g_return_val_if_fail (AMTK_IS_ACTION_INFO_CENTRAL_STORE (central_store), NULL); g_return_val_if_fail (action_name != NULL, NULL); return g_hash_table_lookup (central_store->priv->hash_table, action_name); } 07070100000006000081A400000000000000000000000166D2F0DB00000913000000000000000000000000000000000000003A00000000libgedit-amtk-5.9.0/amtk/amtk-action-info-central-store.h/* SPDX-FileCopyrightText: 2017 - Sébastien Wilmet <swilmet@gnome.org> * SPDX-License-Identifier: LGPL-3.0-or-later */ #ifndef AMTK_ACTION_INFO_CENTRAL_STORE_H #define AMTK_ACTION_INFO_CENTRAL_STORE_H #if !defined (AMTK_H_INSIDE) && !defined (AMTK_COMPILATION) #error "Only <amtk/amtk.h> can be included directly." #endif #include <glib-object.h> #include <amtk/amtk-action-info.h> G_BEGIN_DECLS #define AMTK_TYPE_ACTION_INFO_CENTRAL_STORE (amtk_action_info_central_store_get_type ()) #define AMTK_ACTION_INFO_CENTRAL_STORE(obj) (G_TYPE_CHECK_INSTANCE_CAST ((obj), AMTK_TYPE_ACTION_INFO_CENTRAL_STORE, AmtkActionInfoCentralStore)) #define AMTK_ACTION_INFO_CENTRAL_STORE_CLASS(klass) (G_TYPE_CHECK_CLASS_CAST ((klass), AMTK_TYPE_ACTION_INFO_CENTRAL_STORE, AmtkActionInfoCentralStoreClass)) #define AMTK_IS_ACTION_INFO_CENTRAL_STORE(obj) (G_TYPE_CHECK_INSTANCE_TYPE ((obj), AMTK_TYPE_ACTION_INFO_CENTRAL_STORE)) #define AMTK_IS_ACTION_INFO_CENTRAL_STORE_CLASS(klass) (G_TYPE_CHECK_CLASS_TYPE ((klass), AMTK_TYPE_ACTION_INFO_CENTRAL_STORE)) #define AMTK_ACTION_INFO_CENTRAL_STORE_GET_CLASS(obj) (G_TYPE_INSTANCE_GET_CLASS ((obj), AMTK_TYPE_ACTION_INFO_CENTRAL_STORE, AmtkActionInfoCentralStoreClass)) typedef struct _AmtkActionInfoCentralStore AmtkActionInfoCentralStore; typedef struct _AmtkActionInfoCentralStoreClass AmtkActionInfoCentralStoreClass; typedef struct _AmtkActionInfoCentralStorePrivate AmtkActionInfoCentralStorePrivate; struct _AmtkActionInfoCentralStore { GObject parent; AmtkActionInfoCentralStorePrivate *priv; }; struct _AmtkActionInfoCentralStoreClass { GObjectClass parent_class; gpointer padding[12]; }; G_MODULE_EXPORT GType amtk_action_info_central_store_get_type (void); G_MODULE_EXPORT AmtkActionInfoCentralStore * amtk_action_info_central_store_get_singleton (void); G_MODULE_EXPORT AmtkActionInfo *amtk_action_info_central_store_lookup (AmtkActionInfoCentralStore *central_store, const gchar *action_name); G_GNUC_INTERNAL void _amtk_action_info_central_store_add (AmtkActionInfoCentralStore *central_store, AmtkActionInfo *info); G_GNUC_INTERNAL void _amtk_action_info_central_store_unref_singleton (void); G_END_DECLS #endif /* AMTK_ACTION_INFO_CENTRAL_STORE_H */ 07070100000007000081A400000000000000000000000166D2F0DB00002343000000000000000000000000000000000000003200000000libgedit-amtk-5.9.0/amtk/amtk-action-info-store.c/* SPDX-FileCopyrightText: 2017, 2018 - Sébastien Wilmet <swilmet@gnome.org> * SPDX-License-Identifier: LGPL-3.0-or-later */ #include "amtk-action-info-store.h" #include "amtk-action-info.h" #include "amtk-action-info-central-store.h" /** * SECTION:amtk-action-info-store * @Short_description: A store of #AmtkActionInfo's * @Title: AmtkActionInfoStore * @See_also: #AmtkActionInfo, #AmtkActionInfoCentralStore * * #AmtkActionInfoStore contains a set of #AmtkActionInfo's. It is add-only, an * #AmtkActionInfo cannot be removed. * * #AmtkActionInfoStore is designed so that libraries can provide their own * store, to share action information (with translations) and possibly the * #GAction implementations as well. * * A library #AmtkActionInfoStore must namespace the action names to not have * conflicts when an #AmtkActionInfo is added to the * #AmtkActionInfoCentralStore. Examples of namespaced action names: * `"win.amtk-save"` or `"app.amtk-quit"`. * * An #AmtkActionInfoStore is meant to be something static, created on * application startup. See the [paragraph about static objects in * AmtkFactory][amtk-factory-static-objects]. So once an #AmtkActionInfo has * been added to an #AmtkActionInfoStore, it is discouraged to modify it * afterwards; an exception is to call amtk_action_info_set_accels() with * several accelerators after using amtk_action_info_store_add_entries() * (because an #AmtkActionInfoEntry can contain only one accelerator). */ struct _AmtkActionInfoStorePrivate { /* Key: owned gchar*: action name. * Value: owned AmtkActionInfo. */ GHashTable *hash_table; }; G_DEFINE_TYPE_WITH_PRIVATE (AmtkActionInfoStore, amtk_action_info_store, G_TYPE_OBJECT) static void amtk_action_info_store_finalize (GObject *object) { AmtkActionInfoStore *store = AMTK_ACTION_INFO_STORE (object); g_hash_table_unref (store->priv->hash_table); G_OBJECT_CLASS (amtk_action_info_store_parent_class)->finalize (object); } static void amtk_action_info_store_class_init (AmtkActionInfoStoreClass *klass) { GObjectClass *object_class = G_OBJECT_CLASS (klass); object_class->finalize = amtk_action_info_store_finalize; } static void amtk_action_info_store_init (AmtkActionInfoStore *store) { store->priv = amtk_action_info_store_get_instance_private (store); store->priv->hash_table = g_hash_table_new_full (g_str_hash, g_str_equal, g_free, (GDestroyNotify) amtk_action_info_unref); } /** * amtk_action_info_store_new: * * Returns: a new #AmtkActionInfoStore. * Since: 3.0 */ AmtkActionInfoStore * amtk_action_info_store_new (void) { return g_object_new (AMTK_TYPE_ACTION_INFO_STORE, NULL); } /** * amtk_action_info_store_add: * @store: an #AmtkActionInfoStore. * @info: an #AmtkActionInfo. * * Inserts @info into @store and into the #AmtkActionInfoCentralStore. Both the * @store and central store must <emphasis>not</emphasis> already contain an * #AmtkActionInfo with the same action name. The stores take their own * reference on @info. * * Since: 2.0 */ void amtk_action_info_store_add (AmtkActionInfoStore *store, AmtkActionInfo *info) { const gchar *action_name; AmtkActionInfoCentralStore *central_store; g_return_if_fail (AMTK_IS_ACTION_INFO_STORE (store)); g_return_if_fail (info != NULL); action_name = amtk_action_info_get_action_name (info); g_return_if_fail (action_name != NULL); if (g_hash_table_lookup (store->priv->hash_table, action_name) != NULL) { g_warning ("%s(): the AmtkActionInfoStore already contains an AmtkActionInfo " "with the action name “%s”.", G_STRFUNC, action_name); return; } g_hash_table_insert (store->priv->hash_table, g_strdup (action_name), amtk_action_info_ref (info)); central_store = amtk_action_info_central_store_get_singleton (); _amtk_action_info_central_store_add (central_store, info); } /** * amtk_action_info_store_add_entries: * @store: an #AmtkActionInfoStore. * @entries: (array length=n_entries) (element-type AmtkActionInfoEntry): a * pointer to the first item in an array of #AmtkActionInfoEntry structs. * @n_entries: the length of @entries, or -1 if @entries is %NULL-terminated. * @translation_domain: (nullable): a gettext domain, or %NULL. * * Calls amtk_action_info_store_add() for each entry. * * If @translation_domain is not %NULL, g_dgettext() is used to translate the * @label and @tooltip of each entry before setting them to the #AmtkActionInfo. * * An API similar to g_action_map_add_action_entries(). * * Since: 2.0 */ void amtk_action_info_store_add_entries (AmtkActionInfoStore *store, const AmtkActionInfoEntry *entries, gint n_entries, const gchar *translation_domain) { gint i; g_return_if_fail (AMTK_IS_ACTION_INFO_STORE (store)); g_return_if_fail (n_entries >= -1); g_return_if_fail (entries != NULL || n_entries == 0); for (i = 0; n_entries == -1 ? entries[i].action_name != NULL : i < n_entries; i++) { AmtkActionInfo *info; info = amtk_action_info_new_from_entry (&entries[i], translation_domain); amtk_action_info_store_add (store, info); amtk_action_info_unref (info); } } /** * amtk_action_info_store_lookup: * @store: an #AmtkActionInfoStore. * @action_name: an action name. * * Returns: (transfer none): the found #AmtkActionInfo, or %NULL. * Since: 2.0 */ AmtkActionInfo * amtk_action_info_store_lookup (AmtkActionInfoStore *store, const gchar *action_name) { g_return_val_if_fail (AMTK_IS_ACTION_INFO_STORE (store), NULL); g_return_val_if_fail (action_name != NULL, NULL); return g_hash_table_lookup (store->priv->hash_table, action_name); } static void set_accels_to_app_cb (gpointer key, gpointer value, gpointer user_data) { const gchar *action_name = key; const AmtkActionInfo *action_info = value; GtkApplication *application = GTK_APPLICATION (user_data); const gchar * const *accels; accels = amtk_action_info_get_accels (action_info); gtk_application_set_accels_for_action (application, action_name, accels); } /** * amtk_action_info_store_set_all_accels_to_app: * @store: an #AmtkActionInfoStore. * @application: a #GtkApplication. * * Calls gtk_application_set_accels_for_action() for all #AmtkActionInfo's part * of @store with the accelerators returned by amtk_action_info_get_accels(). * This function does *not* call amtk_action_info_mark_as_used(), because if it * did it would not be possible to detect dead code in @store with * amtk_action_info_store_check_all_used(). * * This function is not recommended if @store is provided by a library, because * a future version of the library may add accelerators that are not wanted in * the application. So for a library store, you should let #AmtkFactory call * gtk_application_set_accels_for_action(). * * This function can be convenient for an application store, in combination with * %AMTK_FACTORY_IGNORE_ACCELS_FOR_APP (and/or having a %NULL #GtkApplication in * #AmtkFactory). It has the advantage that * gtk_application_set_accels_for_action() is called only once per action, not * each time that a #GtkApplicationWindow is created. * * This function can also be useful if – for some actions – the objects are not * created directly with #AmtkFactory on application startup, but are created * later, on demand. For example to create a #GtkShortcutsWindow with * #AmtkFactory, containing information about actions that are not added to any * menu or toolbar. * * Since: 5.0 */ void amtk_action_info_store_set_all_accels_to_app (AmtkActionInfoStore *store, GtkApplication *application) { g_return_if_fail (AMTK_IS_ACTION_INFO_STORE (store)); g_return_if_fail (GTK_IS_APPLICATION (application)); g_hash_table_foreach (store->priv->hash_table, set_accels_to_app_cb, application); } static void check_used_cb (gpointer key, gpointer value, gpointer user_data) { const gchar *action_name = key; const AmtkActionInfo *action_info = value; if (!amtk_action_info_has_been_used (action_info)) { g_warning ("AmtkActionInfo with action_name='%s' has not been used.", action_name); } } /** * amtk_action_info_store_check_all_used: * @store: an #AmtkActionInfoStore. * * Checks for each #AmtkActionInfo of @store that it has been used (see * amtk_action_info_has_been_used()). If an #AmtkActionInfo has not been used, a * warning is printed and might indicate dead code. * * You probably want to call this function on the application store after * creating the menu and toolbar. But it can also be useful for a store provided * by a library, to easily see which actions are not used by the application. * * Since: 2.0 */ void amtk_action_info_store_check_all_used (AmtkActionInfoStore *store) { g_return_if_fail (AMTK_IS_ACTION_INFO_STORE (store)); g_hash_table_foreach (store->priv->hash_table, check_used_cb, NULL); } 07070100000008000081A400000000000000000000000166D2F0DB00000987000000000000000000000000000000000000003200000000libgedit-amtk-5.9.0/amtk/amtk-action-info-store.h/* SPDX-FileCopyrightText: 2017, 2018 - Sébastien Wilmet <swilmet@gnome.org> * SPDX-License-Identifier: LGPL-3.0-or-later */ #ifndef AMTK_ACTION_INFO_STORE_H #define AMTK_ACTION_INFO_STORE_H #if !defined (AMTK_H_INSIDE) && !defined (AMTK_COMPILATION) #error "Only <amtk/amtk.h> can be included directly." #endif #include <gtk/gtk.h> #include <amtk/amtk-action-info.h> G_BEGIN_DECLS #define AMTK_TYPE_ACTION_INFO_STORE (amtk_action_info_store_get_type ()) #define AMTK_ACTION_INFO_STORE(obj) (G_TYPE_CHECK_INSTANCE_CAST ((obj), AMTK_TYPE_ACTION_INFO_STORE, AmtkActionInfoStore)) #define AMTK_ACTION_INFO_STORE_CLASS(klass) (G_TYPE_CHECK_CLASS_CAST ((klass), AMTK_TYPE_ACTION_INFO_STORE, AmtkActionInfoStoreClass)) #define AMTK_IS_ACTION_INFO_STORE(obj) (G_TYPE_CHECK_INSTANCE_TYPE ((obj), AMTK_TYPE_ACTION_INFO_STORE)) #define AMTK_IS_ACTION_INFO_STORE_CLASS(klass) (G_TYPE_CHECK_CLASS_TYPE ((klass), AMTK_TYPE_ACTION_INFO_STORE)) #define AMTK_ACTION_INFO_STORE_GET_CLASS(obj) (G_TYPE_INSTANCE_GET_CLASS ((obj), AMTK_TYPE_ACTION_INFO_STORE, AmtkActionInfoStoreClass)) typedef struct _AmtkActionInfoStore AmtkActionInfoStore; typedef struct _AmtkActionInfoStoreClass AmtkActionInfoStoreClass; typedef struct _AmtkActionInfoStorePrivate AmtkActionInfoStorePrivate; struct _AmtkActionInfoStore { GObject parent; AmtkActionInfoStorePrivate *priv; }; struct _AmtkActionInfoStoreClass { GObjectClass parent_class; gpointer padding[12]; }; G_MODULE_EXPORT GType amtk_action_info_store_get_type (void); G_MODULE_EXPORT AmtkActionInfoStore * amtk_action_info_store_new (void); G_MODULE_EXPORT void amtk_action_info_store_add (AmtkActionInfoStore *store, AmtkActionInfo *info); G_MODULE_EXPORT void amtk_action_info_store_add_entries (AmtkActionInfoStore *store, const AmtkActionInfoEntry *entries, gint n_entries, const gchar *translation_domain); G_MODULE_EXPORT AmtkActionInfo * amtk_action_info_store_lookup (AmtkActionInfoStore *store, const gchar *action_name); G_MODULE_EXPORT void amtk_action_info_store_set_all_accels_to_app (AmtkActionInfoStore *store, GtkApplication *application); G_MODULE_EXPORT void amtk_action_info_store_check_all_used (AmtkActionInfoStore *store); G_END_DECLS #endif /* AMTK_ACTION_INFO_STORE_H */ 07070100000009000081A400000000000000000000000166D2F0DB000024F6000000000000000000000000000000000000002C00000000libgedit-amtk-5.9.0/amtk/amtk-action-info.c/* SPDX-FileCopyrightText: 2017, 2018, 2020 - Sébastien Wilmet <swilmet@gnome.org> * SPDX-License-Identifier: LGPL-3.0-or-later */ #include "amtk-config.h" #include "amtk-action-info.h" #include <glib/gi18n-lib.h> /** * SECTION:amtk-action-info * @Short_description: #GAction information * @Title: AmtkActionInfo * @See_also: #AmtkActionInfoStore * * An #AmtkActionInfo instance contains a set of information about a #GAction. * Those pieces of information are useful to create UI elements that trigger the * #GAction, for example a menu item or a toolbar item. * * The recommended way to create a set of #AmtkActionInfo's is to use the * amtk_action_info_store_add_entries() function. */ struct _AmtkActionInfo { gchar *action_name; gchar *icon_name; gchar *label; gchar *tooltip; /* Must never be NULL, must be a NULL-terminated array. This way, it * can be used directly as an argument to * gtk_application_set_accels_for_action(). */ gchar **accels; gint ref_count; guint used : 1; }; static void _amtk_action_info_free (AmtkActionInfo *info); G_DEFINE_BOXED_TYPE (AmtkActionInfo, amtk_action_info, amtk_action_info_copy, _amtk_action_info_free) static void _amtk_action_info_free (AmtkActionInfo *info) { if (info != NULL) { g_free (info->action_name); g_free (info->icon_name); g_free (info->label); g_free (info->tooltip); g_strfreev (info->accels); g_free (info); } } /** * amtk_action_info_new: * * Returns: a new #AmtkActionInfo. * Since: 2.0 */ AmtkActionInfo * amtk_action_info_new (void) { AmtkActionInfo *info; info = g_new0 (AmtkActionInfo, 1); info->accels = g_malloc0 (sizeof (gchar *)); info->ref_count = 1; return info; } /** * amtk_action_info_new_from_entry: * @info_entry: an #AmtkActionInfoEntry. * @translation_domain: (nullable): a gettext domain, or %NULL. * * Creates a new #AmtkActionInfo from an #AmtkActionInfoEntry. * * If @translation_domain is not %NULL, g_dgettext() is used to translate the * @label and @tooltip before setting them to the #AmtkActionInfo. * * Returns: a new #AmtkActionInfo. * Since: 2.0 */ AmtkActionInfo * amtk_action_info_new_from_entry (const AmtkActionInfoEntry *info_entry, const gchar *translation_domain) { AmtkActionInfo *info; info = amtk_action_info_new (); info->action_name = g_strdup (info_entry->action_name); info->icon_name = g_strdup (info_entry->icon_name); if (translation_domain != NULL) { info->label = g_strdup (g_dgettext (translation_domain, info_entry->label)); info->tooltip = g_strdup (g_dgettext (translation_domain, info_entry->tooltip)); } else { info->label = g_strdup (info_entry->label); info->tooltip = g_strdup (info_entry->tooltip); } if (info_entry->accel != NULL) { g_strfreev (info->accels); info->accels = g_malloc (2 * sizeof (gchar *)); info->accels[0] = g_strdup (info_entry->accel); info->accels[1] = NULL; } return info; } /** * amtk_action_info_ref: * @info: an #AmtkActionInfo. * * Increments the reference count of @info by one. * * Returns: the passed in @info. * Since: 2.0 */ AmtkActionInfo * amtk_action_info_ref (AmtkActionInfo *info) { g_return_val_if_fail (info != NULL, NULL); info->ref_count++; return info; } /** * amtk_action_info_unref: * @info: an #AmtkActionInfo. * * Decrements the reference count of @info by one. If the reference count drops * to 0, @info is freed. * * Since: 2.0 */ void amtk_action_info_unref (AmtkActionInfo *info) { g_return_if_fail (info != NULL); info->ref_count--; if (info->ref_count == 0) { _amtk_action_info_free (info); } } /** * amtk_action_info_copy: * @info: an #AmtkActionInfo. * * Returns: (transfer full): a copy of @info. The copy will have a reference * count of one. * Since: 2.0 */ AmtkActionInfo * amtk_action_info_copy (const AmtkActionInfo *info) { AmtkActionInfo *new_info; g_return_val_if_fail (info != NULL, NULL); new_info = amtk_action_info_new (); new_info->action_name = g_strdup (info->action_name); new_info->icon_name = g_strdup (info->icon_name); new_info->label = g_strdup (info->label); new_info->tooltip = g_strdup (info->tooltip); amtk_action_info_set_accels (new_info, (const gchar * const *)info->accels); return new_info; } /** * amtk_action_info_get_action_name: * @info: an #AmtkActionInfo. * * Returns: (nullable): the action name, or %NULL. Example: `"win.save"`. Can be * a detailed action name, see g_action_parse_detailed_name(). * Since: 2.0 */ const gchar * amtk_action_info_get_action_name (const AmtkActionInfo *info) { g_return_val_if_fail (info != NULL, NULL); return info->action_name; } /** * amtk_action_info_set_action_name: * @info: an #AmtkActionInfo. * @action_name: the action name. * * Sets the action name, for example `"win.save"`. Can be a detailed action * name, see g_action_parse_detailed_name(). * * Since: 2.0 */ void amtk_action_info_set_action_name (AmtkActionInfo *info, const gchar *action_name) { g_return_if_fail (info != NULL); g_return_if_fail (action_name != NULL); g_free (info->action_name); info->action_name = g_strdup (action_name); } /** * amtk_action_info_get_icon_name: * @info: an #AmtkActionInfo. * * Returns: (nullable): the icon name, or %NULL. * Since: 2.0 */ const gchar * amtk_action_info_get_icon_name (const AmtkActionInfo *info) { g_return_val_if_fail (info != NULL, NULL); return info->icon_name; } /** * amtk_action_info_set_icon_name: * @info: an #AmtkActionInfo. * @icon_name: (nullable): the icon name, or %NULL. * * Since: 2.0 */ void amtk_action_info_set_icon_name (AmtkActionInfo *info, const gchar *icon_name) { g_return_if_fail (info != NULL); g_free (info->icon_name); info->icon_name = g_strdup (icon_name); } /** * amtk_action_info_get_label: * @info: an #AmtkActionInfo. * * Gets the label. The label has normally a mnemonic. To remove the mnemonic, * there is the amtk_utils_remove_mnemonic() function. * * Returns: (nullable): the label (i.e. a short description), or %NULL. * Since: 2.0 */ const gchar * amtk_action_info_get_label (const AmtkActionInfo *info) { g_return_val_if_fail (info != NULL, NULL); return info->label; } /** * amtk_action_info_set_label: * @info: an #AmtkActionInfo. * @label: (nullable): the label (i.e. a short description), or %NULL. * * Sets the label with a mnemonic. To know how to encode the mnemonic, see the * documentation of gtk_label_new_with_mnemonic(). * * Since: 2.0 */ void amtk_action_info_set_label (AmtkActionInfo *info, const gchar *label) { g_return_if_fail (info != NULL); g_free (info->label); info->label = g_strdup (label); } /** * amtk_action_info_get_tooltip: * @info: an #AmtkActionInfo. * * Returns: (nullable): the tooltip (i.e. a long description), or %NULL. * Since: 2.0 */ const gchar * amtk_action_info_get_tooltip (const AmtkActionInfo *info) { g_return_val_if_fail (info != NULL, NULL); return info->tooltip; } /** * amtk_action_info_set_tooltip: * @info: an #AmtkActionInfo. * @tooltip: (nullable): the tooltip (i.e. a long description), or %NULL. * * Since: 2.0 */ void amtk_action_info_set_tooltip (AmtkActionInfo *info, const gchar *tooltip) { g_return_if_fail (info != NULL); g_free (info->tooltip); info->tooltip = g_strdup (tooltip); } /** * amtk_action_info_get_accels: * @info: an #AmtkActionInfo. * * Returns the accelerators. This function never returns %NULL, it always * returns a %NULL-terminated array, to be suitable for * gtk_application_set_accels_for_action(). * * Returns: (transfer none) (array zero-terminated=1): a %NULL-terminated array * of accelerators in the format understood by gtk_accelerator_parse(). * Since: 2.0 */ const gchar * const * amtk_action_info_get_accels (const AmtkActionInfo *info) { g_return_val_if_fail (info != NULL, NULL); g_assert (info->accels != NULL); return (const gchar * const *)info->accels; } /** * amtk_action_info_set_accels: * @info: an #AmtkActionInfo. * @accels: (array zero-terminated=1): a %NULL-terminated array of accelerators * in the format understood by gtk_accelerator_parse(). * * A function similar to gtk_application_set_accels_for_action(). * * @accels must not be %NULL, it must be a %NULL-terminated array, to be * consistent with gtk_application_set_accels_for_action(). * * Since: 2.0 */ void amtk_action_info_set_accels (AmtkActionInfo *info, const gchar * const *accels) { g_return_if_fail (info != NULL); g_return_if_fail (accels != NULL); g_strfreev (info->accels); info->accels = g_strdupv ((gchar **) accels); } /** * amtk_action_info_mark_as_used: * @info: an #AmtkActionInfo. * * Mark @info as used. An #AmtkFactory function that uses an #AmtkActionInfo * should call this function. See amtk_action_info_store_check_all_used(). * * Since: 3.0 */ void amtk_action_info_mark_as_used (AmtkActionInfo *info) { g_return_if_fail (info != NULL); info->used = TRUE; } /** * amtk_action_info_has_been_used: * @info: an #AmtkActionInfo. * * Returns whether @info has been used (for example by an #AmtkFactory * function). See also amtk_action_info_store_check_all_used(). * * Returns: whether @info has been used. * Since: 3.0 */ gboolean amtk_action_info_has_been_used (const AmtkActionInfo *info) { g_return_val_if_fail (info != NULL, FALSE); return info->used; } 0707010000000A000081A400000000000000000000000166D2F0DB00000CBF000000000000000000000000000000000000002C00000000libgedit-amtk-5.9.0/amtk/amtk-action-info.h/* SPDX-FileCopyrightText: 2017, 2020 - Sébastien Wilmet <swilmet@gnome.org> * SPDX-License-Identifier: LGPL-3.0-or-later */ #ifndef AMTK_ACTION_INFO_H #define AMTK_ACTION_INFO_H #if !defined (AMTK_H_INSIDE) && !defined (AMTK_COMPILATION) #error "Only <amtk/amtk.h> can be included directly." #endif #include <glib-object.h> #include <gmodule.h> G_BEGIN_DECLS #define AMTK_TYPE_ACTION_INFO (amtk_action_info_get_type ()) typedef struct _AmtkActionInfo AmtkActionInfo; typedef struct _AmtkActionInfoEntry AmtkActionInfoEntry; /** * AmtkActionInfoEntry: * @action_name: the action name. Can be a detailed action name, see * g_action_parse_detailed_name(). * @icon_name: the icon name, or %NULL. * @label: the label (i.e. a short description) with a mnemonic, or %NULL. * @accel: the accelerator, in the format understood by gtk_accelerator_parse(). * Or %NULL. * @tooltip: the tooltip (i.e. a long description), or %NULL. * * This struct defines a set of information for a single action. It is for use * with amtk_action_info_store_add_entries(). * * Like #GActionEntry, it is permissible to use an incomplete initialiser in * order to leave some of the later values as %NULL. Additional optional fields * may be added in the future. * * Since: 2.0 */ struct _AmtkActionInfoEntry { const gchar *action_name; const gchar *icon_name; const gchar *label; const gchar *accel; const gchar *tooltip; /*< private >*/ gpointer padding[3]; }; G_MODULE_EXPORT GType amtk_action_info_get_type (void); G_MODULE_EXPORT AmtkActionInfo * amtk_action_info_new (void); G_MODULE_EXPORT AmtkActionInfo * amtk_action_info_new_from_entry (const AmtkActionInfoEntry *info_entry, const gchar *translation_domain); G_MODULE_EXPORT AmtkActionInfo * amtk_action_info_ref (AmtkActionInfo *info); G_MODULE_EXPORT void amtk_action_info_unref (AmtkActionInfo *info); G_MODULE_EXPORT AmtkActionInfo * amtk_action_info_copy (const AmtkActionInfo *info); G_MODULE_EXPORT const gchar * amtk_action_info_get_action_name (const AmtkActionInfo *info); G_MODULE_EXPORT void amtk_action_info_set_action_name (AmtkActionInfo *info, const gchar *action_name); G_MODULE_EXPORT const gchar * amtk_action_info_get_icon_name (const AmtkActionInfo *info); G_MODULE_EXPORT void amtk_action_info_set_icon_name (AmtkActionInfo *info, const gchar *icon_name); G_MODULE_EXPORT const gchar * amtk_action_info_get_label (const AmtkActionInfo *info); G_MODULE_EXPORT void amtk_action_info_set_label (AmtkActionInfo *info, const gchar *label); G_MODULE_EXPORT const gchar * amtk_action_info_get_tooltip (const AmtkActionInfo *info); G_MODULE_EXPORT void amtk_action_info_set_tooltip (AmtkActionInfo *info, const gchar *tooltip); G_MODULE_EXPORT const gchar * const * amtk_action_info_get_accels (const AmtkActionInfo *info); G_MODULE_EXPORT void amtk_action_info_set_accels (AmtkActionInfo *info, const gchar * const *accels); G_MODULE_EXPORT void amtk_action_info_mark_as_used (AmtkActionInfo *info); G_MODULE_EXPORT gboolean amtk_action_info_has_been_used (const AmtkActionInfo *info); G_END_DECLS #endif /* AMTK_ACTION_INFO_H */ 0707010000000B000081A400000000000000000000000166D2F0DB00000A3E000000000000000000000000000000000000002B00000000libgedit-amtk-5.9.0/amtk/amtk-action-map.c/* SPDX-FileCopyrightText: 2017 - Sébastien Wilmet <swilmet@gnome.org> * SPDX-License-Identifier: LGPL-3.0-or-later */ #include "amtk-action-map.h" /** * SECTION:amtk-action-map * @Short_description: #GActionMap wrapper functions * @Title: AmtkActionMap * * #GActionMap wrapper functions. */ static void check_dups_in_array (const GActionEntry *entries, const gchar *action_name, gint action_num) { gint i; for (i = 0; i < action_num; i++) { const GActionEntry *entry = &entries[i]; if (g_strcmp0 (action_name, entry->name) == 0) { g_warning ("amtk_action_map_add_action_entries_check_dups(): " "the GActionEntry array contains duplicated entries for the action name '%s'. " "The first one will be dropped from the GActionMap.", action_name); return; } } } /** * amtk_action_map_add_action_entries_check_dups: * @action_map: a #GActionMap. * @entries: (array length=n_entries) (element-type GActionEntry): a pointer to * the first item in an array of #GActionEntry structs. * @n_entries: the length of @entries, or -1 if @entries is %NULL-terminated. * @user_data: the user data for signal connections. * * A wrapper function for g_action_map_add_action_entries() that checks * duplicates. * * This function first checks - for each entry - that the @action_map doesn't * already contain a #GAction with the same name. A warning is printed if an old * action will be dropped. In any case, it then calls * g_action_map_add_action_entries() with the same arguments as passed to this * function. * * This function also checks if there are duplicates in the @entries array * itself. * * Since: 2.0 */ void amtk_action_map_add_action_entries_check_dups (GActionMap *action_map, const GActionEntry *entries, gint n_entries, gpointer user_data) { gint i; g_return_if_fail (G_IS_ACTION_MAP (action_map)); g_return_if_fail (n_entries >= -1); g_return_if_fail (entries != NULL || n_entries == 0); for (i = 0; n_entries == -1 ? entries[i].name != NULL : i < n_entries; i++) { const GActionEntry *entry = &entries[i]; if (g_action_map_lookup_action (action_map, entry->name) != NULL) { g_warning ("%s(): the GActionMap already contains a GAction with the name '%s'. " "The old GAction will be dropped from the GActionMap.", G_STRFUNC, entry->name); } check_dups_in_array (entries, entry->name, i); } g_action_map_add_action_entries (action_map, entries, n_entries, user_data); } 0707010000000C000081A400000000000000000000000166D2F0DB00000254000000000000000000000000000000000000002B00000000libgedit-amtk-5.9.0/amtk/amtk-action-map.h/* SPDX-FileCopyrightText: 2017 - Sébastien Wilmet <swilmet@gnome.org> * SPDX-License-Identifier: LGPL-3.0-or-later */ #ifndef AMTK_ACTION_MAP_H #define AMTK_ACTION_MAP_H #if !defined (AMTK_H_INSIDE) && !defined (AMTK_COMPILATION) #error "Only <amtk/amtk.h> can be included directly." #endif #include <gio/gio.h> G_BEGIN_DECLS G_MODULE_EXPORT void amtk_action_map_add_action_entries_check_dups (GActionMap *action_map, const GActionEntry *entries, gint n_entries, gpointer user_data); G_END_DECLS #endif /* AMTK_ACTION_MAP_H */ 0707010000000D000081A400000000000000000000000166D2F0DB000048ED000000000000000000000000000000000000003300000000libgedit-amtk-5.9.0/amtk/amtk-application-window.c/* SPDX-FileCopyrightText: 2017 - Sébastien Wilmet <swilmet@gnome.org> * SPDX-License-Identifier: LGPL-3.0-or-later */ #include "amtk-config.h" #include "amtk-application-window.h" #include <glib/gi18n-lib.h> #include "amtk-action-info.h" #include "amtk-action-info-central-store.h" #include "amtk-menu-item.h" #include "amtk-menu-shell.h" #include "amtk-utils.h" /** * SECTION:amtk-application-window * @Short_description: An extension of GtkApplicationWindow * @Title: AmtkApplicationWindow * * #AmtkApplicationWindow extends the #GtkApplicationWindow class with a * #AmtkApplicationWindow:statusbar property and functions to show longer * descriptions of #GtkMenuItem's to the #GtkStatusbar. * * Note that #AmtkApplicationWindow extends the #GtkApplicationWindow class but * without subclassing it, because several libraries might want to extend * #GtkApplicationWindow and an application needs to be able to use all those * extensions at the same time. */ /* API design: * * AmtkApplicationWindow was first implemented in Tepl, and * TeplApplicationWindow needs to access the GtkApplicationWindow for the * GActionMap. Currently AmtkApplicationWindow could be renamed to AmtkWindow * and be an extension of GtkWindow instead of GtkApplicationWindow, it would * have the advantage to have shorter function names and be a little more * re-usable. But I think it's not a big problem to keep AmtkApplicationWindow * as is, because (1) the A in Amtk is all about GActions, so normally the app * already uses GtkApplicationWindow, (2) it is easy to port an application to * use GtkApplicationWindow, most of the time it's just changing the parent * class when subclassing GtkWindow, (3) it is more future-proof for Amtk to * have access to the GtkApplicationWindow, in case we want to add some features * that require the GActionMap or whatever. -- swilmet */ struct _AmtkApplicationWindowPrivate { GtkApplicationWindow *gtk_window; GtkStatusbar *statusbar; }; enum { PROP_0, PROP_APPLICATION_WINDOW, PROP_STATUSBAR, N_PROPERTIES }; #define AMTK_APPLICATION_WINDOW_KEY "amtk-application-window-key" #define MENU_SHELL_STATUSBAR_CONTEXT_ID_KEY "amtk-menu-shell-statusbar-context-id-key" #define MENU_SHELL_FOR_RECENT_CHOOSER_KEY "amtk-menu-shell-for-recent-chooser-key" static GParamSpec *properties[N_PROPERTIES]; G_DEFINE_TYPE_WITH_PRIVATE (AmtkApplicationWindow, amtk_application_window, G_TYPE_OBJECT) static void amtk_application_window_get_property (GObject *object, guint prop_id, GValue *value, GParamSpec *pspec) { AmtkApplicationWindow *amtk_window = AMTK_APPLICATION_WINDOW (object); switch (prop_id) { case PROP_APPLICATION_WINDOW: g_value_set_object (value, amtk_application_window_get_application_window (amtk_window)); break; case PROP_STATUSBAR: g_value_set_object (value, amtk_application_window_get_statusbar (amtk_window)); break; default: G_OBJECT_WARN_INVALID_PROPERTY_ID (object, prop_id, pspec); break; } } static void amtk_application_window_set_property (GObject *object, guint prop_id, const GValue *value, GParamSpec *pspec) { AmtkApplicationWindow *amtk_window = AMTK_APPLICATION_WINDOW (object); switch (prop_id) { case PROP_APPLICATION_WINDOW: g_assert (amtk_window->priv->gtk_window == NULL); amtk_window->priv->gtk_window = g_value_get_object (value); break; case PROP_STATUSBAR: amtk_application_window_set_statusbar (amtk_window, g_value_get_object (value)); break; default: G_OBJECT_WARN_INVALID_PROPERTY_ID (object, prop_id, pspec); break; } } static void amtk_application_window_dispose (GObject *object) { AmtkApplicationWindow *amtk_window = AMTK_APPLICATION_WINDOW (object); amtk_window->priv->gtk_window = NULL; g_clear_object (&amtk_window->priv->statusbar); G_OBJECT_CLASS (amtk_application_window_parent_class)->dispose (object); } static void amtk_application_window_class_init (AmtkApplicationWindowClass *klass) { GObjectClass *object_class = G_OBJECT_CLASS (klass); object_class->get_property = amtk_application_window_get_property; object_class->set_property = amtk_application_window_set_property; object_class->dispose = amtk_application_window_dispose; /** * AmtkApplicationWindow:application-window: * * The #GtkApplicationWindow. * * Since: 2.0 */ properties[PROP_APPLICATION_WINDOW] = g_param_spec_object ("application-window", "GtkApplicationWindow", "", GTK_TYPE_APPLICATION_WINDOW, G_PARAM_READWRITE | G_PARAM_CONSTRUCT_ONLY | G_PARAM_STATIC_STRINGS); /** * AmtkApplicationWindow:statusbar: * * The #GtkStatusbar. %NULL by default. * * Since: 2.0 */ properties[PROP_STATUSBAR] = g_param_spec_object ("statusbar", "GtkStatusbar", "", GTK_TYPE_STATUSBAR, G_PARAM_READWRITE | G_PARAM_STATIC_STRINGS); g_object_class_install_properties (object_class, N_PROPERTIES, properties); } static void amtk_application_window_init (AmtkApplicationWindow *amtk_window) { amtk_window->priv = amtk_application_window_get_instance_private (amtk_window); } /** * amtk_application_window_get_from_gtk_application_window: * @gtk_window: a #GtkApplicationWindow. * * Returns the #AmtkApplicationWindow of @gtk_window. The returned object is * guaranteed to be the same for the lifetime of @gtk_window. * * Returns: (transfer none): the #AmtkApplicationWindow of @gtk_window. * Since: 2.0 */ AmtkApplicationWindow * amtk_application_window_get_from_gtk_application_window (GtkApplicationWindow *gtk_window) { AmtkApplicationWindow *amtk_window; g_return_val_if_fail (GTK_IS_APPLICATION_WINDOW (gtk_window), NULL); amtk_window = g_object_get_data (G_OBJECT (gtk_window), AMTK_APPLICATION_WINDOW_KEY); if (amtk_window == NULL) { amtk_window = g_object_new (AMTK_TYPE_APPLICATION_WINDOW, "application-window", gtk_window, NULL); g_object_set_data_full (G_OBJECT (gtk_window), AMTK_APPLICATION_WINDOW_KEY, amtk_window, g_object_unref); } g_return_val_if_fail (AMTK_IS_APPLICATION_WINDOW (amtk_window), NULL); return amtk_window; } /** * amtk_application_window_get_application_window: * @amtk_window: an #AmtkApplicationWindow. * * Returns: (transfer none): the #GtkApplicationWindow of @amtk_window. * Since: 2.0 */ GtkApplicationWindow * amtk_application_window_get_application_window (AmtkApplicationWindow *amtk_window) { g_return_val_if_fail (AMTK_IS_APPLICATION_WINDOW (amtk_window), NULL); return amtk_window->priv->gtk_window; } /** * amtk_application_window_get_statusbar: * @amtk_window: an #AmtkApplicationWindow. * * Returns: (transfer none) (nullable): the #AmtkApplicationWindow:statusbar. * Since: 2.0 */ GtkStatusbar * amtk_application_window_get_statusbar (AmtkApplicationWindow *amtk_window) { g_return_val_if_fail (AMTK_IS_APPLICATION_WINDOW (amtk_window), NULL); return amtk_window->priv->statusbar; } /** * amtk_application_window_set_statusbar: * @amtk_window: an #AmtkApplicationWindow. * @statusbar: (nullable): a #GtkStatusbar, or %NULL. * * Sets the #AmtkApplicationWindow:statusbar property. * * Since: 2.0 */ void amtk_application_window_set_statusbar (AmtkApplicationWindow *amtk_window, GtkStatusbar *statusbar) { g_return_if_fail (AMTK_IS_APPLICATION_WINDOW (amtk_window)); g_return_if_fail (statusbar == NULL || GTK_IS_STATUSBAR (statusbar)); if (amtk_window->priv->statusbar == statusbar) { return; } if (statusbar != NULL) { g_object_ref_sink (statusbar); } if (amtk_window->priv->statusbar != NULL) { g_object_unref (amtk_window->priv->statusbar); } amtk_window->priv->statusbar = statusbar; g_object_notify_by_pspec (G_OBJECT (amtk_window), properties[PROP_STATUSBAR]); } /* Returns: %TRUE if a context ID exists and has been set to @context_id. */ static gboolean get_statusbar_context_id_for_menu_shell (AmtkApplicationWindow *amtk_window, AmtkMenuShell *amtk_menu_shell, gboolean create, guint *context_id) { gpointer data; g_assert (amtk_window->priv->statusbar != NULL); g_assert (context_id != NULL); data = g_object_get_data (G_OBJECT (amtk_menu_shell), MENU_SHELL_STATUSBAR_CONTEXT_ID_KEY); if (data == NULL && !create) { return FALSE; } if (data == NULL) { *context_id = gtk_statusbar_get_context_id (amtk_window->priv->statusbar, "Show long description of menu items."); g_object_set_data (G_OBJECT (amtk_menu_shell), MENU_SHELL_STATUSBAR_CONTEXT_ID_KEY, GUINT_TO_POINTER (*context_id)); } else { *context_id = GPOINTER_TO_UINT (data); } return TRUE; } /* Free the return value with g_free(). */ static gchar * get_menu_item_long_description (AmtkMenuShell *amtk_menu_shell, GtkMenuItem *menu_item) { const gchar *long_description; gpointer data; gboolean is_for_recent_chooser; long_description = amtk_menu_item_get_long_description (menu_item); if (long_description != NULL) { return g_strdup (long_description); } data = g_object_get_data (G_OBJECT (amtk_menu_shell), MENU_SHELL_FOR_RECENT_CHOOSER_KEY); is_for_recent_chooser = data != NULL ? GPOINTER_TO_INT (data) : FALSE; if (is_for_recent_chooser) { GtkMenuShell *gtk_menu_shell; GtkRecentChooserMenu *recent_chooser_menu; gchar *uri; GFile *file; gchar *parse_name; gchar *nicer_filename; gchar *ret; gtk_menu_shell = amtk_menu_shell_get_menu_shell (amtk_menu_shell); recent_chooser_menu = GTK_RECENT_CHOOSER_MENU (gtk_menu_shell); uri = amtk_utils_recent_chooser_menu_get_item_uri (recent_chooser_menu, menu_item); if (uri == NULL) { return NULL; } file = g_file_new_for_uri (uri); g_free (uri); parse_name = g_file_get_parse_name (file); g_object_unref (file); nicer_filename = _amtk_utils_replace_home_dir_with_tilde (parse_name); g_free (parse_name); /* Translators: %s is a filename. */ ret = g_strdup_printf (_("Open “%s”"), nicer_filename); g_free (nicer_filename); return ret; } return NULL; } static void menu_item_selected_cb (AmtkMenuShell *amtk_menu_shell, GtkMenuItem *menu_item, gpointer user_data) { AmtkApplicationWindow *amtk_window = AMTK_APPLICATION_WINDOW (user_data); gchar *long_description; guint context_id; if (amtk_window->priv->statusbar == NULL) { return; } long_description = get_menu_item_long_description (amtk_menu_shell, menu_item); if (long_description == NULL) { return; } get_statusbar_context_id_for_menu_shell (amtk_window, amtk_menu_shell, TRUE, &context_id); gtk_statusbar_push (amtk_window->priv->statusbar, context_id, long_description); g_free (long_description); } static void menu_item_deselected_cb (AmtkMenuShell *amtk_menu_shell, GtkMenuItem *menu_item, gpointer user_data) { AmtkApplicationWindow *amtk_window = AMTK_APPLICATION_WINDOW (user_data); const gchar *long_description; gpointer data; gboolean is_for_recent_chooser; guint context_id; if (amtk_window->priv->statusbar == NULL) { return; } long_description = amtk_menu_item_get_long_description (menu_item); data = g_object_get_data (G_OBJECT (amtk_menu_shell), MENU_SHELL_FOR_RECENT_CHOOSER_KEY); is_for_recent_chooser = data != NULL ? GPOINTER_TO_INT (data) : FALSE; if (long_description == NULL && !is_for_recent_chooser) { return; } if (get_statusbar_context_id_for_menu_shell (amtk_window, amtk_menu_shell, FALSE, &context_id)) { gtk_statusbar_pop (amtk_window->priv->statusbar, context_id); } } static void statusbar_notify_cb (AmtkApplicationWindow *amtk_window, GParamSpec *pspec, gpointer user_data) { AmtkMenuShell *amtk_menu_shell = AMTK_MENU_SHELL (user_data); g_object_set_data (G_OBJECT (amtk_menu_shell), MENU_SHELL_STATUSBAR_CONTEXT_ID_KEY, NULL); } /** * amtk_application_window_connect_menu_to_statusbar: * @amtk_window: an #AmtkApplicationWindow. * @menu_shell: a #GtkMenuShell. * * Connects to the #AmtkMenuShell::menu-item-selected and * #AmtkMenuShell::menu-item-deselected signals of @menu_shell to push/pop the * long description of #GtkMenuItem's to the #AmtkApplicationWindow:statusbar. * * The long description is retrieved with amtk_menu_item_get_long_description(). * So amtk_menu_item_set_long_description() must have been called, which is the * case if the #GtkMenuItem has been created with #AmtkFactory. * * Since: 2.0 */ void amtk_application_window_connect_menu_to_statusbar (AmtkApplicationWindow *amtk_window, GtkMenuShell *menu_shell) { AmtkMenuShell *amtk_menu_shell; g_return_if_fail (AMTK_IS_APPLICATION_WINDOW (amtk_window)); g_return_if_fail (GTK_IS_MENU_SHELL (menu_shell)); amtk_menu_shell = amtk_menu_shell_get_from_gtk_menu_shell (menu_shell); g_signal_connect_object (amtk_menu_shell, "menu-item-selected", G_CALLBACK (menu_item_selected_cb), amtk_window, 0); g_signal_connect_object (amtk_menu_shell, "menu-item-deselected", G_CALLBACK (menu_item_deselected_cb), amtk_window, 0); g_signal_connect_object (amtk_window, "notify::statusbar", G_CALLBACK (statusbar_notify_cb), amtk_menu_shell, 0); } /** * amtk_application_window_connect_recent_chooser_menu_to_statusbar: * @amtk_window: an #AmtkApplicationWindow. * @menu: a #GtkRecentChooserMenu. * * An alternative to gtk_recent_chooser_set_show_tips(). Shows the full path in * the #AmtkApplicationWindow:statusbar when a #GtkMenuItem of @menu is * selected. * * The full path is retrieved with * amtk_utils_recent_chooser_menu_get_item_uri(). * * Since: 2.0 */ void amtk_application_window_connect_recent_chooser_menu_to_statusbar (AmtkApplicationWindow *amtk_window, GtkRecentChooserMenu *menu) { AmtkMenuShell *amtk_menu_shell; g_return_if_fail (AMTK_IS_APPLICATION_WINDOW (amtk_window)); g_return_if_fail (GTK_IS_RECENT_CHOOSER_MENU (menu)); amtk_menu_shell = amtk_menu_shell_get_from_gtk_menu_shell (GTK_MENU_SHELL (menu)); g_object_set_data (G_OBJECT (amtk_menu_shell), MENU_SHELL_FOR_RECENT_CHOOSER_KEY, GINT_TO_POINTER (TRUE)); amtk_application_window_connect_menu_to_statusbar (amtk_window, GTK_MENU_SHELL (menu)); } /** * amtk_application_window_create_open_recent_menu_base: * * Creates the base of a simple and generic #GtkRecentChooserMenu. * * The #GtkRecentChooser is configured to show files only recently used with the * current application, as returned by g_get_application_name(). If recent files * are added to the default #GtkRecentManager with * gtk_recent_manager_add_item(), the files will normally show up in the * #GtkRecentChooserMenu. * * Returns: (transfer floating): a new #GtkRecentChooserMenu. * Since: 5.6 */ GtkRecentChooserMenu * amtk_application_window_create_open_recent_menu_base (void) { GtkRecentChooserMenu *recent_chooser_menu; GtkRecentChooser *recent_chooser; GtkRecentFilter *filter; recent_chooser_menu = GTK_RECENT_CHOOSER_MENU (gtk_recent_chooser_menu_new ()); recent_chooser = GTK_RECENT_CHOOSER (recent_chooser_menu); gtk_recent_chooser_set_local_only (recent_chooser, FALSE); gtk_recent_chooser_set_sort_type (recent_chooser, GTK_RECENT_SORT_MRU); filter = gtk_recent_filter_new (); gtk_recent_filter_add_application (filter, g_get_application_name ()); gtk_recent_chooser_set_filter (recent_chooser, filter); return recent_chooser_menu; } static void open_recent_file_cb (GtkRecentChooser *recent_chooser, gpointer user_data) { AmtkApplicationWindow *amtk_window = AMTK_APPLICATION_WINDOW (user_data); gchar *uri; GFile *files[1]; GtkApplication *app; uri = gtk_recent_chooser_get_current_uri (recent_chooser); files[0] = g_file_new_for_uri (uri); app = gtk_window_get_application (GTK_WINDOW (amtk_window->priv->gtk_window)); g_application_open (G_APPLICATION (app), files, 1, ""); g_free (uri); g_object_unref (files[0]); } /** * amtk_application_window_create_open_recent_menu: * @amtk_window: an #AmtkApplicationWindow. * * This function creates a #GtkRecentChooserMenu with * amtk_application_window_create_open_recent_menu_base(), and setup these * additional things: * * - The #GtkRecentChooserMenu is connected to the statusbar with * amtk_application_window_connect_recent_chooser_menu_to_statusbar(). * * - When the #GtkRecentChooser::item-activated signal is emitted, * g_application_open() is called (with an empty hint), so the #GApplication * must have the %G_APPLICATION_HANDLES_OPEN flag set. * * Returns: (transfer floating): a new #GtkRecentChooserMenu. * Since: 3.0 */ GtkWidget * amtk_application_window_create_open_recent_menu (AmtkApplicationWindow *amtk_window) { GtkRecentChooserMenu *recent_chooser_menu; g_return_val_if_fail (AMTK_IS_APPLICATION_WINDOW (amtk_window), NULL); recent_chooser_menu = amtk_application_window_create_open_recent_menu_base (); amtk_application_window_connect_recent_chooser_menu_to_statusbar (amtk_window, recent_chooser_menu); g_signal_connect_object (recent_chooser_menu, "item-activated", G_CALLBACK (open_recent_file_cb), amtk_window, 0); return GTK_WIDGET (recent_chooser_menu); } /** * amtk_application_window_create_open_recent_menu_item: * @amtk_window: an #AmtkApplicationWindow. * * Creates a #GtkMenuItem with a simple and generic #GtkRecentChooserMenu as * submenu. The #GtkRecentChooserMenu is created with * amtk_application_window_create_open_recent_menu(). * * Returns: (transfer floating): a new #GtkMenuItem. * Since: 2.0 */ GtkWidget * amtk_application_window_create_open_recent_menu_item (AmtkApplicationWindow *amtk_window) { GtkMenuItem *menu_item; gchar *long_description; GtkWidget *recent_chooser_menu; g_return_val_if_fail (AMTK_IS_APPLICATION_WINDOW (amtk_window), NULL); menu_item = GTK_MENU_ITEM (gtk_menu_item_new_with_mnemonic (_("Open _Recent"))); /* Translators: %s is the application name. */ long_description = g_strdup_printf (_("Open a file recently used with %s"), g_get_application_name ()); amtk_menu_item_set_long_description (menu_item, long_description); g_free (long_description); recent_chooser_menu = amtk_application_window_create_open_recent_menu (amtk_window); gtk_menu_item_set_submenu (menu_item, recent_chooser_menu); return GTK_WIDGET (menu_item); } /* ex:set ts=8 noet: */ 0707010000000E000081A400000000000000000000000166D2F0DB00000B13000000000000000000000000000000000000003300000000libgedit-amtk-5.9.0/amtk/amtk-application-window.h/* SPDX-FileCopyrightText: 2017 - Sébastien Wilmet <swilmet@gnome.org> * SPDX-License-Identifier: LGPL-3.0-or-later */ #ifndef AMTK_APPLICATION_WINDOW_H #define AMTK_APPLICATION_WINDOW_H #if !defined (AMTK_H_INSIDE) && !defined (AMTK_COMPILATION) #error "Only <amtk/amtk.h> can be included directly." #endif #include <gtk/gtk.h> G_BEGIN_DECLS #define AMTK_TYPE_APPLICATION_WINDOW (amtk_application_window_get_type ()) #define AMTK_APPLICATION_WINDOW(obj) (G_TYPE_CHECK_INSTANCE_CAST ((obj), AMTK_TYPE_APPLICATION_WINDOW, AmtkApplicationWindow)) #define AMTK_APPLICATION_WINDOW_CLASS(klass) (G_TYPE_CHECK_CLASS_CAST ((klass), AMTK_TYPE_APPLICATION_WINDOW, AmtkApplicationWindowClass)) #define AMTK_IS_APPLICATION_WINDOW(obj) (G_TYPE_CHECK_INSTANCE_TYPE ((obj), AMTK_TYPE_APPLICATION_WINDOW)) #define AMTK_IS_APPLICATION_WINDOW_CLASS(klass) (G_TYPE_CHECK_CLASS_TYPE ((klass), AMTK_TYPE_APPLICATION_WINDOW)) #define AMTK_APPLICATION_WINDOW_GET_CLASS(obj) (G_TYPE_INSTANCE_GET_CLASS ((obj), AMTK_TYPE_APPLICATION_WINDOW, AmtkApplicationWindowClass)) typedef struct _AmtkApplicationWindow AmtkApplicationWindow; typedef struct _AmtkApplicationWindowClass AmtkApplicationWindowClass; typedef struct _AmtkApplicationWindowPrivate AmtkApplicationWindowPrivate; struct _AmtkApplicationWindow { GObject parent; AmtkApplicationWindowPrivate *priv; }; struct _AmtkApplicationWindowClass { GObjectClass parent_class; gpointer padding[12]; }; G_MODULE_EXPORT GType amtk_application_window_get_type (void); G_MODULE_EXPORT AmtkApplicationWindow * amtk_application_window_get_from_gtk_application_window (GtkApplicationWindow *gtk_window); G_MODULE_EXPORT GtkApplicationWindow * amtk_application_window_get_application_window (AmtkApplicationWindow *amtk_window); G_MODULE_EXPORT GtkStatusbar * amtk_application_window_get_statusbar (AmtkApplicationWindow *amtk_window); G_MODULE_EXPORT void amtk_application_window_set_statusbar (AmtkApplicationWindow *amtk_window, GtkStatusbar *statusbar); G_MODULE_EXPORT void amtk_application_window_connect_menu_to_statusbar (AmtkApplicationWindow *amtk_window, GtkMenuShell *menu_shell); G_MODULE_EXPORT void amtk_application_window_connect_recent_chooser_menu_to_statusbar (AmtkApplicationWindow *amtk_window, GtkRecentChooserMenu *menu); G_MODULE_EXPORT GtkRecentChooserMenu * amtk_application_window_create_open_recent_menu_base (void); G_MODULE_EXPORT GtkWidget * amtk_application_window_create_open_recent_menu (AmtkApplicationWindow *amtk_window); G_MODULE_EXPORT GtkWidget * amtk_application_window_create_open_recent_menu_item (AmtkApplicationWindow *amtk_window); G_END_DECLS #endif /* AMTK_APPLICATION_WINDOW_H */ /* ex:set ts=8 noet: */ 0707010000000F000081A400000000000000000000000166D2F0DB00007AC6000000000000000000000000000000000000002800000000libgedit-amtk-5.9.0/amtk/amtk-factory.c/* SPDX-FileCopyrightText: 2017-2024 - Sébastien Wilmet <swilmet@gnome.org> * SPDX-License-Identifier: LGPL-3.0-or-later */ #include "amtk-factory.h" #include "amtk-action-info.h" #include "amtk-action-info-central-store.h" #include "amtk-menu-item.h" #include "amtk-utils.h" #include "amtk-enum-types.h" /** * SECTION:amtk-factory * @Short_description: Factory functions * @Title: AmtkFactory * * #AmtkFactory contains functions to create various objects such as a menu * item, a toolbar item or a #GtkShortcutsShortcut, from the information * provided by an #AmtkActionInfo. A factory function accesses an * #AmtkActionInfo from the #AmtkActionInfoCentralStore. * * A #GtkApplication can be associated so that factory functions can call * gtk_application_set_accels_for_action() with the accelerators returned by * amtk_action_info_get_accels(). Note that * gtk_application_set_accels_for_action() is called by factory functions and * not by amtk_action_info_store_add(), so that libraries can provide their own * store and the accelerators are set to the #GtkApplication only if an * #AmtkActionInfo is actually used. For an application store, * amtk_action_info_store_set_all_accels_to_app() is an alternative. * * #AmtkFactoryFlags permits to control how a factory function creates the * object, to ignore some steps. Factory functions are declined in two variants: * a simple form which takes the value of the #AmtkFactory:default-flags * property, and the same function with the `_full` suffix which takes an * #AmtkFactoryFlags argument and ignores the #AmtkFactory:default-flags. See * for example amtk_factory_create_menu_item() and * amtk_factory_create_menu_item_full(). * * # Static objects # {#amtk-factory-static-objects} * * An important detail is that once a factory function has created an object, * the object is not updated if the corresponding #AmtkActionInfo is modified * afterwards. #AmtkActionInfo doesn't have a notify signal, and it is anyway * discouraged to modify an #AmtkActionInfo after being added to an * #AmtkActionInfoStore. An #AmtkActionInfoStore is meant to be something * static, created on application startup. Updating automatically menu and * toolbar items is out of scope for the Amtk library. If for example action * accelerators can be modified at run-time, the menu needs to be re-generated. * * # Menus * * Some general notes about the functions that create #GtkMenuItem's: * - If not ignored by an #AmtkFactoryFlags, the first accelerator returned by * amtk_action_info_get_accels() is set to the #GtkAccelLabel of the * #GtkMenuItem. * - If not ignored by an #AmtkFactoryFlags, the tooltip is set with * amtk_menu_item_set_long_description(), which permits to display it in a * #GtkStatusbar with amtk_application_window_connect_menu_to_statusbar(). * * ## Code example to create a menu * * How to create a #GtkMenuBar with #AmtkFactory. Each submenu is created by a * separate function, to make the code clearer. * * |[ * static GtkWidget * * create_file_submenu (void) * { * GtkMenuShell *file_submenu; * AmtkFactory *factory; * * file_submenu = GTK_MENU_SHELL (gtk_menu_new ()); * * factory = amtk_factory_new_with_default_application (); * gtk_menu_shell_append (file_submenu, amtk_factory_create_menu_item (factory, "win.open")); * gtk_menu_shell_append (file_submenu, amtk_factory_create_menu_item (factory, "win.save")); * gtk_menu_shell_append (file_submenu, gtk_separator_menu_item_new ()); * gtk_menu_shell_append (file_submenu, amtk_factory_create_menu_item (factory, "app.quit")); * g_object_unref (factory); * * return GTK_WIDGET (file_submenu); * } * * static GtkWidget * * create_help_submenu (void) * { * GtkMenuShell *help_submenu; * AmtkFactory *factory; * * help_submenu = GTK_MENU_SHELL (gtk_menu_new ()); * * factory = amtk_factory_new_with_default_application (); * gtk_menu_shell_append (help_submenu, amtk_factory_create_menu_item (factory, "app.about")); * g_object_unref (factory); * * return GTK_WIDGET (help_submenu); * } * * static GtkWidget * * create_menu_bar (void) * { * GtkWidget *file_menu_item; * GtkWidget *help_menu_item; * GtkWidget *menu_bar; * * file_menu_item = gtk_menu_item_new_with_mnemonic ("_File"); * gtk_menu_item_set_submenu (GTK_MENU_ITEM (file_menu_item), * create_file_submenu ()); * * help_menu_item = gtk_menu_item_new_with_mnemonic ("_Help"); * gtk_menu_item_set_submenu (GTK_MENU_ITEM (help_menu_item), * create_help_submenu ()); * * menu_bar = gtk_menu_bar_new (); * gtk_menu_shell_append (GTK_MENU_SHELL (menu_bar), file_menu_item); * gtk_menu_shell_append (GTK_MENU_SHELL (menu_bar), help_menu_item); * * // Additionally, it is a good place to call * // amtk_action_info_store_check_all_used() here. * * return menu_bar; * } * ]| * * # Toolbars * * Some general notes about the functions that create #GtkToolItem's: * - The accelerators returned by amtk_action_info_get_accels() are not used for * documentation purposes in a toolbar, so the * %AMTK_FACTORY_IGNORE_ACCELS_FOR_DOC flag has no impact. The accelerators * are documented only in menu items. * * ## Code example to create a toolbar * * How to create a basic #GtkToolbar with #AmtkFactory. * * |[ * static GtkWidget * * create_toolbar (void) * { * GtkToolbar *toolbar; * AmtkFactory *factory; * * toolbar = GTK_TOOLBAR (gtk_toolbar_new ()); * * // Small performance improvement: * // Do not associate a GtkApplication, because the menu has already been * // generated, the menu contains all actions, so * // gtk_application_set_accels_for_action() has already been called for all * // actions. Another way is to set the AMTK_FACTORY_IGNORE_ACCELS_FOR_APP * // flag. * factory = amtk_factory_new (NULL); * gtk_toolbar_insert (toolbar, amtk_factory_create_tool_button (factory, "win.new-file"), -1); * gtk_toolbar_insert (toolbar, amtk_factory_create_tool_button (factory, "win.open"), -1); * gtk_toolbar_insert (toolbar, amtk_factory_create_tool_button (factory, "win.save"), -1); * gtk_toolbar_insert (toolbar, gtk_separator_tool_item_new (), -1); * gtk_toolbar_insert (toolbar, amtk_factory_create_tool_button (factory, "win.cut"), -1); * gtk_toolbar_insert (toolbar, amtk_factory_create_tool_button (factory, "win.copy"), -1); * gtk_toolbar_insert (toolbar, amtk_factory_create_tool_button (factory, "win.paste"), -1); * g_object_unref (factory); * * return GTK_WIDGET (toolbar); * } * ]| * * # Modern UI with a GtkHeaderBar * * To have an example code, see `tests/interactive-tests/test-headerbar.c` in * the git repository of Amtk. */ struct _AmtkFactoryPrivate { /* Weak ref */ GtkApplication *app; AmtkFactoryFlags default_flags; }; enum { PROP_0, PROP_APPLICATION, PROP_DEFAULT_FLAGS, N_PROPERTIES }; static GParamSpec *properties[N_PROPERTIES]; G_DEFINE_TYPE_WITH_PRIVATE (AmtkFactory, amtk_factory, G_TYPE_OBJECT) static void amtk_factory_get_property (GObject *object, guint prop_id, GValue *value, GParamSpec *pspec) { AmtkFactory *factory = AMTK_FACTORY (object); switch (prop_id) { case PROP_APPLICATION: g_value_set_object (value, amtk_factory_get_application (factory)); break; case PROP_DEFAULT_FLAGS: g_value_set_flags (value, amtk_factory_get_default_flags (factory)); break; default: G_OBJECT_WARN_INVALID_PROPERTY_ID (object, prop_id, pspec); break; } } static void amtk_factory_set_property (GObject *object, guint prop_id, const GValue *value, GParamSpec *pspec) { AmtkFactory *factory = AMTK_FACTORY (object); switch (prop_id) { case PROP_APPLICATION: g_assert (factory->priv->app == NULL); g_set_weak_pointer (&factory->priv->app, g_value_get_object (value)); break; case PROP_DEFAULT_FLAGS: amtk_factory_set_default_flags (factory, g_value_get_flags (value)); break; default: G_OBJECT_WARN_INVALID_PROPERTY_ID (object, prop_id, pspec); break; } } static void amtk_factory_dispose (GObject *object) { AmtkFactory *factory = AMTK_FACTORY (object); g_clear_weak_pointer (&factory->priv->app); G_OBJECT_CLASS (amtk_factory_parent_class)->dispose (object); } static void amtk_factory_class_init (AmtkFactoryClass *klass) { GObjectClass *object_class = G_OBJECT_CLASS (klass); object_class->get_property = amtk_factory_get_property; object_class->set_property = amtk_factory_set_property; object_class->dispose = amtk_factory_dispose; /** * AmtkFactory:application: * * The associated #GtkApplication (it is optional, it can be %NULL). * #AmtkFactory has a weak reference to the #GtkApplication. * * Since: 3.0 */ properties[PROP_APPLICATION] = g_param_spec_object ("application", "GtkApplication", "", GTK_TYPE_APPLICATION, G_PARAM_READWRITE | G_PARAM_CONSTRUCT_ONLY | G_PARAM_STATIC_STRINGS); /** * AmtkFactory:default-flags: * * The default #AmtkFactoryFlags. * * Since: 3.0 */ properties[PROP_DEFAULT_FLAGS] = g_param_spec_flags ("default-flags", "Default flags", "", AMTK_TYPE_FACTORY_FLAGS, AMTK_FACTORY_FLAGS_NONE, G_PARAM_READWRITE | G_PARAM_STATIC_STRINGS); g_object_class_install_properties (object_class, N_PROPERTIES, properties); } static void amtk_factory_init (AmtkFactory *factory) { factory->priv = amtk_factory_get_instance_private (factory); } /** * amtk_factory_new: * @application: (nullable): a #GtkApplication, or %NULL. * * Creates a new #AmtkFactory object. Associating a #GtkApplication is optional, * if it is %NULL gtk_application_set_accels_for_action() won't be called. * * Returns: a new #AmtkFactory. * Since: 3.0 */ AmtkFactory * amtk_factory_new (GtkApplication *application) { g_return_val_if_fail (application == NULL || GTK_IS_APPLICATION (application), NULL); return g_object_new (AMTK_TYPE_FACTORY, "application", application, NULL); } /** * amtk_factory_new_with_default_application: * * Calls amtk_factory_new() with g_application_get_default() (it must be a * #GtkApplication). * * Returns: a new #AmtkFactory with the default #GtkApplication. * Since: 3.0 */ AmtkFactory * amtk_factory_new_with_default_application (void) { return amtk_factory_new (GTK_APPLICATION (g_application_get_default ())); } /** * amtk_factory_get_application: * @factory: an #AmtkFactory. * * Returns: (transfer none) (nullable): the #AmtkFactory:application. * Since: 3.0 */ GtkApplication * amtk_factory_get_application (AmtkFactory *factory) { g_return_val_if_fail (AMTK_IS_FACTORY (factory), NULL); return factory->priv->app; } /** * amtk_factory_get_default_flags: * @factory: an #AmtkFactory. * * Returns: the #AmtkFactory:default-flags. * Since: 3.0 */ AmtkFactoryFlags amtk_factory_get_default_flags (AmtkFactory *factory) { g_return_val_if_fail (AMTK_IS_FACTORY (factory), AMTK_FACTORY_FLAGS_NONE); return factory->priv->default_flags; } /** * amtk_factory_set_default_flags: * @factory: an #AmtkFactory. * @default_flags: the new value. * * Sets the #AmtkFactory:default-flags property. * * Since: 3.0 */ void amtk_factory_set_default_flags (AmtkFactory *factory, AmtkFactoryFlags default_flags) { g_return_if_fail (AMTK_IS_FACTORY (factory)); if (factory->priv->default_flags != default_flags) { factory->priv->default_flags = default_flags; g_object_notify_by_pspec (G_OBJECT (factory), properties[PROP_DEFAULT_FLAGS]); } } static AmtkActionInfo * common_create (AmtkFactory *factory, const gchar *action_name, AmtkFactoryFlags flags) { AmtkActionInfoCentralStore *central_store; AmtkActionInfo *action_info; central_store = amtk_action_info_central_store_get_singleton (); action_info = amtk_action_info_central_store_lookup (central_store, action_name); if (action_info == NULL) { g_warning ("AmtkFactory create function: action name '%s' not found.", action_name); return NULL; } if ((flags & AMTK_FACTORY_IGNORE_ACCELS) == 0 && (flags & AMTK_FACTORY_IGNORE_ACCELS_FOR_APP) == 0 && factory->priv->app != NULL) { const gchar * const *accels; accels = amtk_action_info_get_accels (action_info); gtk_application_set_accels_for_action (factory->priv->app, action_name, accels); } amtk_action_info_mark_as_used (action_info); return action_info; } static AmtkActionInfo * common_create_widget (AmtkFactory *factory, const gchar *action_name, AmtkFactoryFlags flags, GtkWidget **widget) { AmtkActionInfo *action_info; action_info = common_create (factory, action_name, flags); if (action_info == NULL) { g_object_ref_sink (*widget); g_object_unref (*widget); *widget = NULL; return NULL; } if ((flags & AMTK_FACTORY_IGNORE_GACTION) == 0) { gtk_actionable_set_detailed_action_name (GTK_ACTIONABLE (*widget), action_name); } return action_info; } static AmtkActionInfo * common_create_menu_item (AmtkFactory *factory, const gchar *action_name, AmtkFactoryFlags flags, GtkMenuItem **menu_item) { AmtkActionInfo *action_info; const gchar * const *accels; const gchar *tooltip; action_info = common_create_widget (factory, action_name, flags, (GtkWidget **)menu_item); if (action_info == NULL) { return NULL; } if ((flags & AMTK_FACTORY_IGNORE_LABEL) == 0) { gtk_menu_item_set_use_underline (*menu_item, TRUE); gtk_menu_item_set_label (*menu_item, amtk_action_info_get_label (action_info)); } accels = amtk_action_info_get_accels (action_info); if ((flags & AMTK_FACTORY_IGNORE_ACCELS) == 0 && (flags & AMTK_FACTORY_IGNORE_ACCELS_FOR_DOC) == 0 && accels != NULL && accels[0] != NULL) { guint accel_key; GdkModifierType accel_mods; gtk_accelerator_parse (accels[0], &accel_key, &accel_mods); if (accel_key != 0 || accel_mods != 0) { GtkWidget *child; child = gtk_bin_get_child (GTK_BIN (*menu_item)); gtk_accel_label_set_accel (GTK_ACCEL_LABEL (child), accel_key, accel_mods); } } tooltip = amtk_action_info_get_tooltip (action_info); if ((flags & AMTK_FACTORY_IGNORE_TOOLTIP) == 0 && tooltip != NULL) { amtk_menu_item_set_long_description (*menu_item, tooltip); } return action_info; } static AmtkActionInfo * common_create_tool_button (AmtkFactory *factory, const gchar *action_name, AmtkFactoryFlags flags, GtkToolButton **tool_button) { AmtkActionInfo *action_info; const gchar *icon_name; const gchar *tooltip; action_info = common_create_widget (factory, action_name, flags, (GtkWidget **)tool_button); if (action_info == NULL) { return NULL; } if ((flags & AMTK_FACTORY_IGNORE_LABEL) == 0) { gtk_tool_button_set_use_underline (*tool_button, TRUE); gtk_tool_button_set_label (*tool_button, amtk_action_info_get_label (action_info)); } icon_name = amtk_action_info_get_icon_name (action_info); if ((flags & AMTK_FACTORY_IGNORE_ICON) == 0 && icon_name != NULL) { gtk_tool_button_set_icon_name (*tool_button, icon_name); } tooltip = amtk_action_info_get_tooltip (action_info); if ((flags & AMTK_FACTORY_IGNORE_TOOLTIP) == 0 && tooltip != NULL) { gtk_tool_item_set_tooltip_text (GTK_TOOL_ITEM (*tool_button), tooltip); } return action_info; } /** * amtk_factory_create_menu_item: * @factory: an #AmtkFactory. * @action_name: an action name. * * Creates a new #GtkMenuItem for @action_name with the * #AmtkFactory:default-flags. * * Returns: (transfer floating): a new #GtkMenuItem for @action_name. * Since: 3.0 */ GtkWidget * amtk_factory_create_menu_item (AmtkFactory *factory, const gchar *action_name) { g_return_val_if_fail (AMTK_IS_FACTORY (factory), NULL); g_return_val_if_fail (action_name != NULL, NULL); return amtk_factory_create_menu_item_full (factory, action_name, factory->priv->default_flags); } /** * amtk_factory_create_menu_item_full: * @factory: an #AmtkFactory. * @action_name: an action name. * @flags: #AmtkFactoryFlags. * * This function ignores the #AmtkFactory:default-flags property and takes the * @flags argument instead. * * Returns: (transfer floating): a new #GtkMenuItem for @action_name. * Since: 3.0 */ GtkWidget * amtk_factory_create_menu_item_full (AmtkFactory *factory, const gchar *action_name, AmtkFactoryFlags flags) { G_GNUC_BEGIN_IGNORE_DEPRECATIONS /* Use GtkImageMenuItem to place the icon correctly. */ GtkImageMenuItem *image_menu_item; AmtkActionInfo *action_info; const gchar *icon_name; g_return_val_if_fail (AMTK_IS_FACTORY (factory), NULL); g_return_val_if_fail (action_name != NULL, NULL); image_menu_item = GTK_IMAGE_MENU_ITEM (gtk_image_menu_item_new ()); action_info = common_create_menu_item (factory, action_name, flags, (GtkMenuItem **) &image_menu_item); if (action_info == NULL) { return NULL; } icon_name = amtk_action_info_get_icon_name (action_info); if ((flags & AMTK_FACTORY_IGNORE_ICON) == 0 && icon_name != NULL) { GtkWidget *image; image = gtk_image_new_from_icon_name (icon_name, GTK_ICON_SIZE_MENU); gtk_image_menu_item_set_image (image_menu_item, image); gtk_image_menu_item_set_always_show_image (image_menu_item, TRUE); } return GTK_WIDGET (image_menu_item); G_GNUC_END_IGNORE_DEPRECATIONS } /** * amtk_factory_create_check_menu_item: * @factory: an #AmtkFactory. * @action_name: an action name. * * Creates a new #GtkCheckMenuItem for @action_name with the * #AmtkFactory:default-flags. * * See the documentation of amtk_factory_create_check_menu_item_full() for more * information. * * Returns: (transfer floating): a new #GtkCheckMenuItem for @action_name. * Since: 3.0 */ GtkWidget * amtk_factory_create_check_menu_item (AmtkFactory *factory, const gchar *action_name) { g_return_val_if_fail (AMTK_IS_FACTORY (factory), NULL); g_return_val_if_fail (action_name != NULL, NULL); return amtk_factory_create_check_menu_item_full (factory, action_name, factory->priv->default_flags); } /** * amtk_factory_create_check_menu_item_full: * @factory: an #AmtkFactory. * @action_name: an action name. * @flags: #AmtkFactoryFlags. * * This function ignores the #AmtkFactory:default-flags property and takes the * @flags argument instead. * * Note that since it is a #GtkCheckMenuItem the icon is not set, even if it * would be possible with amtk_menu_item_set_icon_name(). * * If the action controls a boolean property, think about using * #GPropertyAction. * * Returns: (transfer floating): a new #GtkCheckMenuItem for @action_name. * Since: 3.0 */ GtkWidget * amtk_factory_create_check_menu_item_full (AmtkFactory *factory, const gchar *action_name, AmtkFactoryFlags flags) { GtkMenuItem *check_menu_item; AmtkActionInfo *action_info; g_return_val_if_fail (AMTK_IS_FACTORY (factory), NULL); g_return_val_if_fail (action_name != NULL, NULL); check_menu_item = GTK_MENU_ITEM (gtk_check_menu_item_new ()); action_info = common_create_menu_item (factory, action_name, flags, &check_menu_item); if (action_info == NULL) { return NULL; } return GTK_WIDGET (check_menu_item); } /** * amtk_factory_create_simple_menu: * @factory: an #AmtkFactory. * @entries: (array length=n_entries) (element-type AmtkActionInfoEntry): a * pointer to the first item in an array of #AmtkActionInfoEntry structs. * @n_entries: the length of @entries, or -1 if @entries is %NULL-terminated. * * Calls amtk_factory_create_simple_menu_full() with the * #AmtkFactory:default-flags. * * Returns: (transfer floating): a new simple #GtkMenu for @entries. * Since: 5.0 */ GtkWidget * amtk_factory_create_simple_menu (AmtkFactory *factory, const AmtkActionInfoEntry *entries, gint n_entries) { g_return_val_if_fail (AMTK_IS_FACTORY (factory), NULL); g_return_val_if_fail (n_entries >= -1, NULL); g_return_val_if_fail (entries != NULL || n_entries == 0, NULL); return amtk_factory_create_simple_menu_full (factory, entries, n_entries, factory->priv->default_flags); } /** * amtk_factory_create_simple_menu_full: * @factory: an #AmtkFactory. * @entries: (array length=n_entries) (element-type AmtkActionInfoEntry): a * pointer to the first item in an array of #AmtkActionInfoEntry structs. * @n_entries: the length of @entries, or -1 if @entries is %NULL-terminated. * @flags: #AmtkFactoryFlags. * * This function ignores the #AmtkFactory:default-flags property and takes the * @flags argument instead. * * This function: * - Creates a #GtkMenu; * - For each #AmtkActionInfoEntry action name from @entries, creates a * #GtkMenuItem with amtk_factory_create_menu_item_full() with the same @flags * as passed in to this function, and appends it to the #GtkMenu, in the same * order as provided by the @entries array. * * So this function is useful only if the #GtkMenu contains only simple * #GtkMenuItem's, not #GtkCheckMenuItem's nor #GtkRadioMenuItem's. * * Returns: (transfer floating): a new simple #GtkMenu for @entries. * Since: 5.0 */ GtkWidget * amtk_factory_create_simple_menu_full (AmtkFactory *factory, const AmtkActionInfoEntry *entries, gint n_entries, AmtkFactoryFlags flags) { GtkMenuShell *menu; gint i; g_return_val_if_fail (AMTK_IS_FACTORY (factory), NULL); g_return_val_if_fail (n_entries >= -1, NULL); g_return_val_if_fail (entries != NULL || n_entries == 0, NULL); menu = GTK_MENU_SHELL (gtk_menu_new ()); for (i = 0; n_entries == -1 ? entries[i].action_name != NULL : i < n_entries; i++) { const AmtkActionInfoEntry *cur_entry = &entries[i]; GtkWidget *menu_item; menu_item = amtk_factory_create_menu_item_full (factory, cur_entry->action_name, flags); gtk_menu_shell_append (menu, menu_item); } return GTK_WIDGET (menu); } /** * amtk_factory_create_gmenu_item: * @factory: an #AmtkFactory. * @action_name: an action name. * * Calls amtk_factory_create_gmenu_item_full() with the * #AmtkFactory:default-flags. * * Returns: (transfer full): a new #GMenuItem for @action_name. * Since: 5.0 */ GMenuItem * amtk_factory_create_gmenu_item (AmtkFactory *factory, const gchar *action_name) { g_return_val_if_fail (AMTK_IS_FACTORY (factory), NULL); g_return_val_if_fail (action_name != NULL, NULL); return amtk_factory_create_gmenu_item_full (factory, action_name, factory->priv->default_flags); } /** * amtk_factory_create_gmenu_item_full: * @factory: an #AmtkFactory. * @action_name: an action name. * @flags: #AmtkFactoryFlags. * * This function ignores the #AmtkFactory:default-flags property and takes the * @flags argument instead. * * Creates a new #GMenuItem for @action_name. It ignores the tooltip, i.e. the * return value of amtk_action_info_get_tooltip(). * * Returns: (transfer full): a new #GMenuItem for @action_name. * Since: 5.0 */ GMenuItem * amtk_factory_create_gmenu_item_full (AmtkFactory *factory, const gchar *action_name, AmtkFactoryFlags flags) { AmtkActionInfo *action_info; const gchar *label = NULL; const gchar *detailed_action = NULL; GMenuItem *menu_item; const gchar *icon_name; g_return_val_if_fail (AMTK_IS_FACTORY (factory), NULL); g_return_val_if_fail (action_name != NULL, NULL); action_info = common_create (factory, action_name, flags); if (action_info == NULL) { return NULL; } if ((flags & AMTK_FACTORY_IGNORE_LABEL) == 0) { label = amtk_action_info_get_label (action_info); } if ((flags & AMTK_FACTORY_IGNORE_GACTION) == 0) { detailed_action = action_name; } menu_item = g_menu_item_new (label, detailed_action); icon_name = amtk_action_info_get_icon_name (action_info); if ((flags & AMTK_FACTORY_IGNORE_ICON) == 0 && icon_name != NULL) { GIcon *icon; icon = g_themed_icon_new (icon_name); g_menu_item_set_icon (menu_item, icon); g_object_unref (icon); } return menu_item; } /** * amtk_factory_create_tool_button: * @factory: an #AmtkFactory. * @action_name: an action name. * * Creates a new #GtkToolButton for @action_name with the * #AmtkFactory:default-flags. * * Returns: (transfer floating): a new #GtkToolButton for @action_name. * Since: 3.0 */ GtkToolItem * amtk_factory_create_tool_button (AmtkFactory *factory, const gchar *action_name) { g_return_val_if_fail (AMTK_IS_FACTORY (factory), NULL); g_return_val_if_fail (action_name != NULL, NULL); return amtk_factory_create_tool_button_full (factory, action_name, factory->priv->default_flags); } /** * amtk_factory_create_tool_button_full: * @factory: an #AmtkFactory. * @action_name: an action name. * @flags: #AmtkFactoryFlags. * * This function ignores the #AmtkFactory:default-flags property and takes the * @flags argument instead. * * Returns: (transfer floating): a new #GtkToolButton for @action_name. * Since: 3.0 */ GtkToolItem * amtk_factory_create_tool_button_full (AmtkFactory *factory, const gchar *action_name, AmtkFactoryFlags flags) { GtkToolButton *tool_button; AmtkActionInfo *action_info; g_return_val_if_fail (AMTK_IS_FACTORY (factory), NULL); g_return_val_if_fail (action_name != NULL, NULL); tool_button = GTK_TOOL_BUTTON (gtk_tool_button_new (NULL, NULL)); action_info = common_create_tool_button (factory, action_name, flags, &tool_button); if (action_info == NULL) { return NULL; } return GTK_TOOL_ITEM (tool_button); } /** * amtk_factory_create_menu_tool_button: * @factory: an #AmtkFactory. * @action_name: an action name. * * Creates a new #GtkMenuToolButton for @action_name with the * #AmtkFactory:default-flags. * * See the documentation of amtk_factory_create_menu_tool_button_full() for more * information. * * Returns: (transfer floating): a new #GtkMenuToolButton for @action_name. * Since: 3.0 */ GtkMenuToolButton * amtk_factory_create_menu_tool_button (AmtkFactory *factory, const gchar *action_name) { g_return_val_if_fail (AMTK_IS_FACTORY (factory), NULL); g_return_val_if_fail (action_name != NULL, NULL); return amtk_factory_create_menu_tool_button_full (factory, action_name, factory->priv->default_flags); } /** * amtk_factory_create_menu_tool_button_full: * @factory: an #AmtkFactory. * @action_name: an action name. * @flags: #AmtkFactoryFlags. * * This function ignores the #AmtkFactory:default-flags property and takes the * @flags argument instead. * * After calling this function, you need to use the #GtkMenuToolButton API to * set the menu and also possibly set a tooltip to the arrow. * * Returns: (transfer floating): a new #GtkMenuToolButton for @action_name. * Since: 3.0 */ GtkMenuToolButton * amtk_factory_create_menu_tool_button_full (AmtkFactory *factory, const gchar *action_name, AmtkFactoryFlags flags) { GtkToolButton *menu_tool_button; AmtkActionInfo *action_info; g_return_val_if_fail (AMTK_IS_FACTORY (factory), NULL); g_return_val_if_fail (action_name != NULL, NULL); menu_tool_button = GTK_TOOL_BUTTON (gtk_menu_tool_button_new (NULL, NULL)); action_info = common_create_tool_button (factory, action_name, flags, &menu_tool_button); if (action_info == NULL) { return NULL; } return GTK_MENU_TOOL_BUTTON (menu_tool_button); } /** * amtk_factory_create_shortcut: * @factory: an #AmtkFactory. * @action_name: an action name. * * Calls amtk_factory_create_shortcut_full() with the * #AmtkFactory:default-flags. * * Returns: (transfer floating): a new #GtkShortcutsShortcut for @action_name. * Since: 5.0 */ GtkWidget * amtk_factory_create_shortcut (AmtkFactory *factory, const gchar *action_name) { g_return_val_if_fail (AMTK_IS_FACTORY (factory), NULL); g_return_val_if_fail (action_name != NULL, NULL); return amtk_factory_create_shortcut_full (factory, action_name, factory->priv->default_flags); } /** * amtk_factory_create_shortcut_full: * @factory: an #AmtkFactory. * @action_name: an action name. * @flags: #AmtkFactoryFlags. * * This function ignores the #AmtkFactory:default-flags property and takes the * @flags argument instead. * * This function creates a new #GtkShortcutsShortcut for @action_name. * * For the #GtkShortcutsShortcut:title, the tooltip has the priorioty, with the * label as fallback if the tooltip is %NULL (the mnemonic is removed from the * label with amtk_utils_remove_mnemonic()). This can be controlled with the * %AMTK_FACTORY_IGNORE_TOOLTIP and %AMTK_FACTORY_IGNORE_LABEL flags. * * The #GtkShortcutsShortcut:accelerator property is set with only the *first* * accel returned by amtk_action_info_get_accels(). This step can be ignored * with %AMTK_FACTORY_IGNORE_ACCELS or %AMTK_FACTORY_IGNORE_ACCELS_FOR_DOC. * * The #GtkShortcutsShortcut:action-name property is set to @action_name if the * %AMTK_FACTORY_IGNORE_GACTION flag isn't set. Note that with * #GtkShortcutsShortcut:action-name all accelerators are displayed (if set to * the #GtkApplication). * * So depending on whether you want to show only the first accelerator or all * accelerators, you need to set @flags appropriately. * * Returns: (transfer floating): a new #GtkShortcutsShortcut for @action_name. * Since: 5.0 */ GtkWidget * amtk_factory_create_shortcut_full (AmtkFactory *factory, const gchar *action_name, AmtkFactoryFlags flags) { AmtkActionInfo *action_info; GtkWidget *shortcut; const gchar *tooltip; const gchar *label; g_return_val_if_fail (AMTK_IS_FACTORY (factory), NULL); g_return_val_if_fail (action_name != NULL, NULL); action_info = common_create (factory, action_name, flags); if (action_info == NULL) { return NULL; } shortcut = g_object_new (GTK_TYPE_SHORTCUTS_SHORTCUT, NULL); gtk_widget_show (shortcut); tooltip = amtk_action_info_get_tooltip (action_info); label = amtk_action_info_get_label (action_info); if ((flags & AMTK_FACTORY_IGNORE_TOOLTIP) == 0 && tooltip != NULL) { g_object_set (shortcut, "title", tooltip, NULL); } else if ((flags & AMTK_FACTORY_IGNORE_LABEL) == 0 && label != NULL) { gchar *label_without_mnemonic; label_without_mnemonic = amtk_utils_remove_mnemonic (label); g_object_set (shortcut, "title", label_without_mnemonic, NULL); g_free (label_without_mnemonic); } if ((flags & AMTK_FACTORY_IGNORE_ACCELS) == 0 && (flags & AMTK_FACTORY_IGNORE_ACCELS_FOR_DOC) == 0) { const gchar * const *accels; accels = amtk_action_info_get_accels (action_info); g_object_set (shortcut, "accelerator", accels[0], NULL); } if ((flags & AMTK_FACTORY_IGNORE_GACTION) == 0) { g_object_set (shortcut, "action-name", action_name, NULL); } return shortcut; } 07070100000010000081A400000000000000000000000166D2F0DB000014F2000000000000000000000000000000000000002800000000libgedit-amtk-5.9.0/amtk/amtk-factory.h/* SPDX-FileCopyrightText: 2017, 2018, 2020 - Sébastien Wilmet <swilmet@gnome.org> * SPDX-License-Identifier: LGPL-3.0-or-later */ #ifndef AMTK_FACTORY_H #define AMTK_FACTORY_H #if !defined (AMTK_H_INSIDE) && !defined (AMTK_COMPILATION) #error "Only <amtk/amtk.h> can be included directly." #endif #include <gtk/gtk.h> #include <amtk/amtk-action-info.h> G_BEGIN_DECLS #define AMTK_TYPE_FACTORY (amtk_factory_get_type ()) #define AMTK_FACTORY(obj) (G_TYPE_CHECK_INSTANCE_CAST ((obj), AMTK_TYPE_FACTORY, AmtkFactory)) #define AMTK_FACTORY_CLASS(klass) (G_TYPE_CHECK_CLASS_CAST ((klass), AMTK_TYPE_FACTORY, AmtkFactoryClass)) #define AMTK_IS_FACTORY(obj) (G_TYPE_CHECK_INSTANCE_TYPE ((obj), AMTK_TYPE_FACTORY)) #define AMTK_IS_FACTORY_CLASS(klass) (G_TYPE_CHECK_CLASS_TYPE ((klass), AMTK_TYPE_FACTORY)) #define AMTK_FACTORY_GET_CLASS(obj) (G_TYPE_INSTANCE_GET_CLASS ((obj), AMTK_TYPE_FACTORY, AmtkFactoryClass)) typedef struct _AmtkFactory AmtkFactory; typedef struct _AmtkFactoryClass AmtkFactoryClass; typedef struct _AmtkFactoryPrivate AmtkFactoryPrivate; struct _AmtkFactory { GObject parent; AmtkFactoryPrivate *priv; }; struct _AmtkFactoryClass { GObjectClass parent_class; gpointer padding[12]; }; /** * AmtkFactoryFlags: * @AMTK_FACTORY_FLAGS_NONE: No flags. * @AMTK_FACTORY_IGNORE_GACTION: Do not associate the created object with the * #GAction. For example if the object to create is a #GtkActionable, do not * call gtk_actionable_set_detailed_action_name(). * @AMTK_FACTORY_IGNORE_ICON: Do not set an icon. * @AMTK_FACTORY_IGNORE_LABEL: Do not set a label/short description. * @AMTK_FACTORY_IGNORE_TOOLTIP: Do not set a tooltip/long description. * @AMTK_FACTORY_IGNORE_ACCELS: Ignore completely the accelerators. * @AMTK_FACTORY_IGNORE_ACCELS_FOR_DOC: Ignore the accelerators for * documentation purposes only. For example do not add/configure a * #GtkAccelLabel. * @AMTK_FACTORY_IGNORE_ACCELS_FOR_APP: Do not call * gtk_application_set_accels_for_action(). * * #AmtkFactoryFlags permits to control how a factory function creates the * object, to ignore some steps. * * Since: 3.0 */ typedef enum { AMTK_FACTORY_FLAGS_NONE = 0, AMTK_FACTORY_IGNORE_GACTION = 1 << 0, AMTK_FACTORY_IGNORE_ICON = 1 << 1, AMTK_FACTORY_IGNORE_LABEL = 1 << 2, AMTK_FACTORY_IGNORE_TOOLTIP = 1 << 3, AMTK_FACTORY_IGNORE_ACCELS = 1 << 4, AMTK_FACTORY_IGNORE_ACCELS_FOR_DOC = 1 << 5, AMTK_FACTORY_IGNORE_ACCELS_FOR_APP = 1 << 6, } AmtkFactoryFlags; G_MODULE_EXPORT GType amtk_factory_get_type (void); G_MODULE_EXPORT AmtkFactory * amtk_factory_new (GtkApplication *application); G_MODULE_EXPORT AmtkFactory * amtk_factory_new_with_default_application (void); G_MODULE_EXPORT GtkApplication * amtk_factory_get_application (AmtkFactory *factory); G_MODULE_EXPORT AmtkFactoryFlags amtk_factory_get_default_flags (AmtkFactory *factory); G_MODULE_EXPORT void amtk_factory_set_default_flags (AmtkFactory *factory, AmtkFactoryFlags default_flags); G_MODULE_EXPORT GtkWidget * amtk_factory_create_menu_item (AmtkFactory *factory, const gchar *action_name); G_MODULE_EXPORT GtkWidget * amtk_factory_create_menu_item_full (AmtkFactory *factory, const gchar *action_name, AmtkFactoryFlags flags); G_MODULE_EXPORT GtkWidget * amtk_factory_create_check_menu_item (AmtkFactory *factory, const gchar *action_name); G_MODULE_EXPORT GtkWidget * amtk_factory_create_check_menu_item_full (AmtkFactory *factory, const gchar *action_name, AmtkFactoryFlags flags); G_MODULE_EXPORT GtkWidget * amtk_factory_create_simple_menu (AmtkFactory *factory, const AmtkActionInfoEntry *entries, gint n_entries); G_MODULE_EXPORT GtkWidget * amtk_factory_create_simple_menu_full (AmtkFactory *factory, const AmtkActionInfoEntry *entries, gint n_entries, AmtkFactoryFlags flags); G_MODULE_EXPORT GMenuItem * amtk_factory_create_gmenu_item (AmtkFactory *factory, const gchar *action_name); G_MODULE_EXPORT GMenuItem * amtk_factory_create_gmenu_item_full (AmtkFactory *factory, const gchar *action_name, AmtkFactoryFlags flags); G_MODULE_EXPORT GtkToolItem * amtk_factory_create_tool_button (AmtkFactory *factory, const gchar *action_name); G_MODULE_EXPORT GtkToolItem * amtk_factory_create_tool_button_full (AmtkFactory *factory, const gchar *action_name, AmtkFactoryFlags flags); G_MODULE_EXPORT GtkMenuToolButton * amtk_factory_create_menu_tool_button (AmtkFactory *factory, const gchar *action_name); G_MODULE_EXPORT GtkMenuToolButton * amtk_factory_create_menu_tool_button_full (AmtkFactory *factory, const gchar *action_name, AmtkFactoryFlags flags); G_MODULE_EXPORT GtkWidget * amtk_factory_create_shortcut (AmtkFactory *factory, const gchar *action_name); G_MODULE_EXPORT GtkWidget * amtk_factory_create_shortcut_full (AmtkFactory *factory, const gchar *action_name, AmtkFactoryFlags flags); G_END_DECLS #endif /* AMTK_FACTORY_H */ 07070100000011000081A400000000000000000000000166D2F0DB0000054C000000000000000000000000000000000000002600000000libgedit-amtk-5.9.0/amtk/amtk-gmenu.c/* SPDX-FileCopyrightText: 2018 - Sébastien Wilmet <swilmet@gnome.org> * SPDX-License-Identifier: LGPL-3.0-or-later */ #include "amtk-gmenu.h" /** * SECTION:amtk-gmenu * @Short_description: #GMenu convenience functions * @Title: AmtkGmenu * * #GMenu convenience functions. */ /** * amtk_gmenu_append_item: * @menu: a #GMenu. * @item: (transfer full): a #GMenuItem to append. * * Like g_menu_append_item() but with (transfer full) for the @item parameter. * * Since: 5.0 */ void amtk_gmenu_append_item (GMenu *menu, GMenuItem *item) { g_return_if_fail (G_IS_MENU (menu)); g_return_if_fail (G_IS_MENU_ITEM (item)); g_menu_append_item (menu, item); g_object_unref (item); } /** * amtk_gmenu_append_section: * @menu: a #GMenu. * @label: (nullable): the section label, or %NULL. * @section: (transfer full): a #GMenu with the items of the section. * * Like g_menu_append_section() but with (transfer full) and a different type * for the @section parameter, and calls g_menu_freeze() on @section. * * Since: 5.0 */ void amtk_gmenu_append_section (GMenu *menu, const gchar *label, GMenu *section) { g_return_if_fail (G_IS_MENU (menu)); g_return_if_fail (G_IS_MENU (section)); g_menu_freeze (section); g_menu_append_section (menu, label, G_MENU_MODEL (section)); g_object_unref (section); } 07070100000012000081A400000000000000000000000166D2F0DB00000240000000000000000000000000000000000000002600000000libgedit-amtk-5.9.0/amtk/amtk-gmenu.h/* SPDX-FileCopyrightText: 2018 - Sébastien Wilmet <swilmet@gnome.org> * SPDX-License-Identifier: LGPL-3.0-or-later */ #ifndef AMTK_GMENU_H #define AMTK_GMENU_H #if !defined (AMTK_H_INSIDE) && !defined (AMTK_COMPILATION) #error "Only <amtk/amtk.h> can be included directly." #endif #include <gio/gio.h> G_BEGIN_DECLS G_MODULE_EXPORT void amtk_gmenu_append_item (GMenu *menu, GMenuItem *item); G_MODULE_EXPORT void amtk_gmenu_append_section (GMenu *menu, const gchar *label, GMenu *section); G_END_DECLS #endif /* AMTK_GMENU_H */ 07070100000013000081A400000000000000000000000166D2F0DB000009BD000000000000000000000000000000000000002500000000libgedit-amtk-5.9.0/amtk/amtk-init.c/* SPDX-FileCopyrightText: 2017-2020 - Sébastien Wilmet <swilmet@gnome.org> * SPDX-License-Identifier: LGPL-3.0-or-later */ #include "amtk-config.h" #include "amtk-init.h" #include <glib/gi18n-lib.h> #include "amtk-action-info-central-store.h" static gchar * get_locale_directory (void) { #ifdef G_OS_WIN32 gchar *base_dir; gchar *locale_dir; base_dir = g_win32_get_package_installation_directory_of_module (NULL); locale_dir = g_build_filename (base_dir, "share", "locale", NULL); g_free (base_dir); return locale_dir; #else return g_strdup (AMTK_LOCALEDIR); #endif } /** * amtk_init: * * Initializes the Amtk library (e.g. for the internationalization). * * This function can be called several times, but is meant to be called at the * beginning of main(), before any other Amtk function call. * * Since: 3.0 */ void amtk_init (void) { static gboolean done = FALSE; if (!done) { gchar *locale_dir; locale_dir = get_locale_directory (); bindtextdomain (GETTEXT_PACKAGE, locale_dir); g_free (locale_dir); bind_textdomain_codeset (GETTEXT_PACKAGE, "UTF-8"); done = TRUE; } } /** * amtk_finalize: * * Free the resources allocated by Amtk. For example it unrefs the singleton * objects. * * It is not mandatory to call this function, it's just to be friendlier to * memory debugging tools. This function is meant to be called at the end of * main(). It can be called several times. * * Since: 3.0 */ /* Another way is to use a DSO destructor, see gconstructor.h in GLib. * * The advantage of calling amtk_finalize() at the end of main() is that * gobject-list [1] correctly reports that all Amtk* objects have been finalized * when quitting the application. On the other hand a DSO destructor runs after * the gobject-list's last output, so it's much less convenient, see: * https://gitlab.gnome.org/GNOME/gtksourceview/commit/e761de9c2bee90c232875bbc41e6e73e1f63e145 * * [1] A tool for debugging the lifetime of GObjects: * https://github.com/danni/gobject-list */ void amtk_finalize (void) { static gboolean done = FALSE; /* Unref the singleton only once, even if this function is called * multiple times, to see if a reference is not released correctly. * Normally the singleton have a ref count of 1. If for some reason the * ref count is increased somewhere, it needs to be decreased * accordingly, at the right place. */ if (!done) { _amtk_action_info_central_store_unref_singleton (); done = TRUE; } } 07070100000014000081A400000000000000000000000166D2F0DB000001BF000000000000000000000000000000000000002500000000libgedit-amtk-5.9.0/amtk/amtk-init.h/* SPDX-FileCopyrightText: 2017 - Sébastien Wilmet <swilmet@gnome.org> * SPDX-License-Identifier: LGPL-3.0-or-later */ #ifndef AMTK_INIT_H #define AMTK_INIT_H #if !defined (AMTK_H_INSIDE) && !defined (AMTK_COMPILATION) #error "Only <amtk/amtk.h> can be included directly." #endif #include <gmodule.h> G_BEGIN_DECLS G_MODULE_EXPORT void amtk_init (void); G_MODULE_EXPORT void amtk_finalize (void); G_END_DECLS #endif /* AMTK_INIT_H */ 07070100000015000081A400000000000000000000000166D2F0DB00001019000000000000000000000000000000000000002A00000000libgedit-amtk-5.9.0/amtk/amtk-menu-item.c/* SPDX-FileCopyrightText: 2017 - Sébastien Wilmet <swilmet@gnome.org> * SPDX-License-Identifier: LGPL-3.0-or-later */ #include "amtk-menu-item.h" /** * SECTION:amtk-menu-item * @Short_description: #GtkMenuItem functions * @Title: AmtkMenuItem * * #GtkMenuItem functions. */ #define LONG_DESCRIPTION_KEY "amtk-menu-item-long-description-key" /** * amtk_menu_item_get_long_description: * @menu_item: a #GtkMenuItem. * * Returns: (nullable): the long description of @menu_item, previously set with * amtk_menu_item_set_long_description(). * Since: 2.0 */ const gchar * amtk_menu_item_get_long_description (GtkMenuItem *menu_item) { g_return_val_if_fail (GTK_IS_MENU_ITEM (menu_item), NULL); return g_object_get_data (G_OBJECT (menu_item), LONG_DESCRIPTION_KEY); } /** * amtk_menu_item_set_long_description: * @menu_item: a #GtkMenuItem. * @long_description: (nullable): the long description, or %NULL to unset it. * * Sets the long description of @menu_item. A possible use-case is to display it * in a #GtkStatusbar, or as a tooltip. * * Since: 2.0 */ void amtk_menu_item_set_long_description (GtkMenuItem *menu_item, const gchar *long_description) { g_return_if_fail (GTK_IS_MENU_ITEM (menu_item)); g_object_set_data_full (G_OBJECT (menu_item), LONG_DESCRIPTION_KEY, g_strdup (long_description), g_free); } /** * amtk_menu_item_set_icon_name: * @item: a #GtkMenuItem. * @icon_name: an icon name. * * Sets an icon to a #GtkMenuItem. * * If the child widget of @item is already a #GtkBox, all #GtkImage widgets * inside that box are first destroyed. A #GtkImage for @icon_name is then * inserted to the box. * * If the child widget of @item is not a #GtkBox (it's usually the * #GtkAccelLabel), it is replaced by a new #GtkBox and the initial child widget * is inserted to the #GtkBox, alongside the icon. * * As a consequence, if you want to call functions on the #GtkAccelLabel, it's * easier to do it before calling this function. * * Since: 2.0 * Deprecated: 5.9: Use #GtkImageMenuItem instead, even if deprecated. This * function doesn't place the icon at the right place. */ /* Based on gtk_model_menu_item_set_icon() from gtkmodelmenuitem.c (private * GTK class). * Copyright 2011, 2013 Canonical Limited */ void amtk_menu_item_set_icon_name (GtkMenuItem *item, const gchar *icon_name) { GtkWidget *child; g_return_if_fail (GTK_IS_MENU_ITEM (item)); child = gtk_bin_get_child (GTK_BIN (item)); /* There are only three possibilities here: * * - no child * - accel label child * - already a box * * Handle the no-child case by having GtkMenuItem create the accel * label, then we will only have two possible cases. */ if (child == NULL) { gtk_menu_item_get_label (item); child = gtk_bin_get_child (GTK_BIN (item)); g_return_if_fail (GTK_IS_LABEL (child)); } /* If it is a box, make sure there are no images inside of it already. */ if (GTK_IS_BOX (child)) { GList *children; children = gtk_container_get_children (GTK_CONTAINER (child)); while (children != NULL) { if (GTK_IS_IMAGE (children->data)) { gtk_widget_destroy (children->data); } children = g_list_delete_link (children, children); } } else { GtkWidget *box; if (icon_name == NULL) { return; } box = gtk_box_new (GTK_ORIENTATION_HORIZONTAL, 6); /* Reparent the child without destroying it */ g_object_ref (child); gtk_container_remove (GTK_CONTAINER (item), child); gtk_box_pack_end (GTK_BOX (box), child, TRUE, TRUE, 0); g_object_unref (child); gtk_container_add (GTK_CONTAINER (item), box); gtk_widget_show (box); /* Now we have a box */ child = box; } g_assert (GTK_IS_BOX (child)); /* child is now a box containing a label and no image. Add the icon, * if appropriate. */ if (icon_name != NULL) { GtkWidget *image; image = gtk_image_new_from_icon_name (icon_name, GTK_ICON_SIZE_MENU); gtk_image_set_pixel_size (GTK_IMAGE (image), 16); gtk_box_pack_start (GTK_BOX (child), image, FALSE, FALSE, 0); gtk_widget_show (image); } } 07070100000016000081A400000000000000000000000166D2F0DB000002CE000000000000000000000000000000000000002A00000000libgedit-amtk-5.9.0/amtk/amtk-menu-item.h/* SPDX-FileCopyrightText: 2017 - Sébastien Wilmet <swilmet@gnome.org> * SPDX-License-Identifier: LGPL-3.0-or-later */ #ifndef AMTK_MENU_ITEM_H #define AMTK_MENU_ITEM_H #if !defined (AMTK_H_INSIDE) && !defined (AMTK_COMPILATION) #error "Only <amtk/amtk.h> can be included directly." #endif #include <gtk/gtk.h> G_BEGIN_DECLS G_MODULE_EXPORT const gchar * amtk_menu_item_get_long_description (GtkMenuItem *menu_item); G_MODULE_EXPORT void amtk_menu_item_set_long_description (GtkMenuItem *menu_item, const gchar *long_description); G_MODULE_EXPORT void amtk_menu_item_set_icon_name (GtkMenuItem *item, const gchar *icon_name) G_GNUC_DEPRECATED; G_END_DECLS #endif /* AMTK_MENU_ITEM_H */ 07070100000017000081A400000000000000000000000166D2F0DB000025CB000000000000000000000000000000000000002B00000000libgedit-amtk-5.9.0/amtk/amtk-menu-shell.c/* SPDX-FileCopyrightText: 2016, 2017 - Sébastien Wilmet <swilmet@gnome.org> * SPDX-License-Identifier: LGPL-3.0-or-later */ #include "amtk-menu-shell.h" /** * SECTION:amtk-menu-shell * @Short_description: An extension of #GtkMenuShell * @Title: AmtkMenuShell * * #AmtkMenuShell extends the #GtkMenuShell abstract class with the * #AmtkMenuShell::menu-item-selected and #AmtkMenuShell::menu-item-deselected * convenience signals. * * One possible use-case is to push/pop longer descriptions of menu items to a * #GtkStatusbar, exactly like * amtk_application_window_connect_menu_to_statusbar() does. */ struct _AmtkMenuShellPrivate { GtkMenuShell *gtk_menu_shell; }; enum { PROP_0, PROP_MENU_SHELL, N_PROPERTIES }; enum { SIGNAL_MENU_ITEM_SELECTED, SIGNAL_MENU_ITEM_DESELECTED, N_SIGNALS }; #define AMTK_MENU_SHELL_KEY "amtk-menu-shell-key" static GParamSpec *properties[N_PROPERTIES]; static guint signals[N_SIGNALS]; G_DEFINE_TYPE_WITH_PRIVATE (AmtkMenuShell, amtk_menu_shell, G_TYPE_OBJECT) /* Prototypes */ static void connect_menu_shell (AmtkMenuShell *amtk_menu_shell, GtkMenuShell *gtk_menu_shell); static void disconnect_menu_shell (AmtkMenuShell *amtk_menu_shell, GtkMenuShell *gtk_menu_shell); static void menu_item_select_cb (GtkMenuItem *menu_item, gpointer user_data) { AmtkMenuShell *amtk_menu_shell = AMTK_MENU_SHELL (user_data); GtkWidget *submenu; submenu = gtk_menu_item_get_submenu (menu_item); if (GTK_IS_MENU_SHELL (submenu)) { connect_menu_shell (amtk_menu_shell, GTK_MENU_SHELL (submenu)); } g_signal_emit (amtk_menu_shell, signals[SIGNAL_MENU_ITEM_SELECTED], 0, menu_item); } static void menu_item_deselect_cb (GtkMenuItem *menu_item, gpointer user_data) { AmtkMenuShell *amtk_menu_shell = AMTK_MENU_SHELL (user_data); GtkWidget *submenu; submenu = gtk_menu_item_get_submenu (menu_item); if (GTK_IS_MENU_SHELL (submenu)) { disconnect_menu_shell (amtk_menu_shell, GTK_MENU_SHELL (submenu)); } g_signal_emit (amtk_menu_shell, signals[SIGNAL_MENU_ITEM_DESELECTED], 0, menu_item); } static void connect_menu_item (AmtkMenuShell *amtk_menu_shell, GtkMenuItem *menu_item) { g_signal_connect_object (menu_item, "select", G_CALLBACK (menu_item_select_cb), amtk_menu_shell, 0); g_signal_connect_object (menu_item, "deselect", G_CALLBACK (menu_item_deselect_cb), amtk_menu_shell, 0); } static void disconnect_menu_item (AmtkMenuShell *amtk_menu_shell, GtkMenuItem *menu_item) { g_signal_handlers_disconnect_by_func (menu_item, menu_item_select_cb, amtk_menu_shell); g_signal_handlers_disconnect_by_func (menu_item, menu_item_deselect_cb, amtk_menu_shell); } static void insert_cb (GtkMenuShell *gtk_menu_shell, GtkWidget *child, gint position, gpointer user_data) { AmtkMenuShell *amtk_menu_shell = AMTK_MENU_SHELL (user_data); if (GTK_IS_MENU_ITEM (child)) { connect_menu_item (amtk_menu_shell, GTK_MENU_ITEM (child)); } } static void remove_cb (GtkContainer *container, GtkWidget *child, gpointer user_data) { AmtkMenuShell *amtk_menu_shell = AMTK_MENU_SHELL (user_data); if (GTK_IS_MENU_ITEM (child)) { disconnect_menu_item (amtk_menu_shell, GTK_MENU_ITEM (child)); } } static void connect_menu_shell (AmtkMenuShell *amtk_menu_shell, GtkMenuShell *gtk_menu_shell) { GList *children; GList *l; children = gtk_container_get_children (GTK_CONTAINER (gtk_menu_shell)); for (l = children; l != NULL; l = l->next) { GtkMenuItem *menu_item = l->data; if (GTK_IS_MENU_ITEM (menu_item)) { connect_menu_item (amtk_menu_shell, menu_item); } } g_list_free (children); g_signal_connect_object (gtk_menu_shell, "insert", G_CALLBACK (insert_cb), amtk_menu_shell, 0); g_signal_connect_object (gtk_menu_shell, "remove", G_CALLBACK (remove_cb), amtk_menu_shell, 0); } static void disconnect_menu_shell (AmtkMenuShell *amtk_menu_shell, GtkMenuShell *gtk_menu_shell) { GList *children; GList *l; children = gtk_container_get_children (GTK_CONTAINER (gtk_menu_shell)); for (l = children; l != NULL; l = l->next) { GtkMenuItem *menu_item = l->data; if (GTK_IS_MENU_ITEM (menu_item)) { disconnect_menu_item (amtk_menu_shell, menu_item); } } g_list_free (children); g_signal_handlers_disconnect_by_func (gtk_menu_shell, insert_cb, amtk_menu_shell); g_signal_handlers_disconnect_by_func (gtk_menu_shell, remove_cb, amtk_menu_shell); } static void set_menu_shell (AmtkMenuShell *amtk_menu_shell, GtkMenuShell *gtk_menu_shell) { g_assert (amtk_menu_shell->priv->gtk_menu_shell == NULL); g_return_if_fail (GTK_IS_MENU_SHELL (gtk_menu_shell)); amtk_menu_shell->priv->gtk_menu_shell = gtk_menu_shell; connect_menu_shell (amtk_menu_shell, gtk_menu_shell); } static void amtk_menu_shell_get_property (GObject *object, guint prop_id, GValue *value, GParamSpec *pspec) { AmtkMenuShell *amtk_menu_shell = AMTK_MENU_SHELL (object); switch (prop_id) { case PROP_MENU_SHELL: g_value_set_object (value, amtk_menu_shell_get_menu_shell (amtk_menu_shell)); break; default: G_OBJECT_WARN_INVALID_PROPERTY_ID (object, prop_id, pspec); break; } } static void amtk_menu_shell_set_property (GObject *object, guint prop_id, const GValue *value, GParamSpec *pspec) { AmtkMenuShell *amtk_menu_shell = AMTK_MENU_SHELL (object); switch (prop_id) { case PROP_MENU_SHELL: set_menu_shell (amtk_menu_shell, g_value_get_object (value)); break; default: G_OBJECT_WARN_INVALID_PROPERTY_ID (object, prop_id, pspec); break; } } static void amtk_menu_shell_dispose (GObject *object) { AmtkMenuShell *amtk_menu_shell = AMTK_MENU_SHELL (object); amtk_menu_shell->priv->gtk_menu_shell = NULL; G_OBJECT_CLASS (amtk_menu_shell_parent_class)->dispose (object); } static void amtk_menu_shell_class_init (AmtkMenuShellClass *klass) { GObjectClass *object_class = G_OBJECT_CLASS (klass); object_class->get_property = amtk_menu_shell_get_property; object_class->set_property = amtk_menu_shell_set_property; object_class->dispose = amtk_menu_shell_dispose; /** * AmtkMenuShell:menu-shell: * * The #GtkMenuShell. * * Since: 2.0 */ properties[PROP_MENU_SHELL] = g_param_spec_object ("menu-shell", "GtkMenuShell", "", GTK_TYPE_MENU_SHELL, G_PARAM_READWRITE | G_PARAM_CONSTRUCT_ONLY | G_PARAM_STATIC_STRINGS); g_object_class_install_properties (object_class, N_PROPERTIES, properties); /** * AmtkMenuShell::menu-item-selected: * @amtk_menu_shell: the #AmtkMenuShell emitting the signal. * @menu_item: the #GtkMenuItem that has been selected. * * The ::menu-item-selected signal is emitted when the * #GtkMenuItem::select signal is emitted on a #GtkMenuItem belonging * (directly or indirectly through submenus) to @amtk_menu_shell. * * Since: 2.0 */ signals[SIGNAL_MENU_ITEM_SELECTED] = g_signal_new ("menu-item-selected", G_TYPE_FROM_CLASS (klass), G_SIGNAL_RUN_FIRST, G_STRUCT_OFFSET (AmtkMenuShellClass, menu_item_selected), NULL, NULL, NULL, G_TYPE_NONE, 1, GTK_TYPE_MENU_ITEM); /** * AmtkMenuShell::menu-item-deselected: * @amtk_menu_shell: the #AmtkMenuShell emitting the signal. * @menu_item: the #GtkMenuItem that has been deselected. * * The ::menu-item-deselected signal is emitted when the * #GtkMenuItem::deselect signal is emitted on a #GtkMenuItem belonging * (directly or indirectly through submenus) to @amtk_menu_shell. * * Since: 2.0 */ signals[SIGNAL_MENU_ITEM_DESELECTED] = g_signal_new ("menu-item-deselected", G_TYPE_FROM_CLASS (klass), G_SIGNAL_RUN_FIRST, G_STRUCT_OFFSET (AmtkMenuShellClass, menu_item_deselected), NULL, NULL, NULL, G_TYPE_NONE, 1, GTK_TYPE_MENU_ITEM); } static void amtk_menu_shell_init (AmtkMenuShell *amtk_menu_shell) { amtk_menu_shell->priv = amtk_menu_shell_get_instance_private (amtk_menu_shell); } /** * amtk_menu_shell_get_from_gtk_menu_shell: * @gtk_menu_shell: a #GtkMenuShell. * * Returns the #AmtkMenuShell of @gtk_menu_shell. The returned object is * guaranteed to be the same for the lifetime of @gtk_menu_shell. * * Returns: (transfer none): the #AmtkMenuShell of @gtk_menu_shell. * Since: 2.0 */ AmtkMenuShell * amtk_menu_shell_get_from_gtk_menu_shell (GtkMenuShell *gtk_menu_shell) { AmtkMenuShell *amtk_menu_shell; g_return_val_if_fail (GTK_IS_MENU_SHELL (gtk_menu_shell), NULL); amtk_menu_shell = g_object_get_data (G_OBJECT (gtk_menu_shell), AMTK_MENU_SHELL_KEY); if (amtk_menu_shell == NULL) { amtk_menu_shell = g_object_new (AMTK_TYPE_MENU_SHELL, "menu-shell", gtk_menu_shell, NULL); g_object_set_data_full (G_OBJECT (gtk_menu_shell), AMTK_MENU_SHELL_KEY, amtk_menu_shell, g_object_unref); } g_return_val_if_fail (AMTK_IS_MENU_SHELL (amtk_menu_shell), NULL); return amtk_menu_shell; } /** * amtk_menu_shell_get_menu_shell: * @amtk_menu_shell: an #AmtkMenuShell. * * Returns: (transfer none): the #GtkMenuShell of @amtk_menu_shell. * Since: 2.0 */ GtkMenuShell * amtk_menu_shell_get_menu_shell (AmtkMenuShell *amtk_menu_shell) { g_return_val_if_fail (AMTK_IS_MENU_SHELL (amtk_menu_shell), NULL); return amtk_menu_shell->priv->gtk_menu_shell; } /* ex:set ts=8 noet: */ 07070100000018000081A400000000000000000000000166D2F0DB00000727000000000000000000000000000000000000002B00000000libgedit-amtk-5.9.0/amtk/amtk-menu-shell.h/* SPDX-FileCopyrightText: 2017 - Sébastien Wilmet <swilmet@gnome.org> * SPDX-License-Identifier: LGPL-3.0-or-later */ #ifndef AMTK_MENU_SHELL_H #define AMTK_MENU_SHELL_H #if !defined (AMTK_H_INSIDE) && !defined (AMTK_COMPILATION) #error "Only <amtk/amtk.h> can be included directly." #endif #include <gtk/gtk.h> G_BEGIN_DECLS #define AMTK_TYPE_MENU_SHELL (amtk_menu_shell_get_type ()) #define AMTK_MENU_SHELL(obj) (G_TYPE_CHECK_INSTANCE_CAST ((obj), AMTK_TYPE_MENU_SHELL, AmtkMenuShell)) #define AMTK_MENU_SHELL_CLASS(klass) (G_TYPE_CHECK_CLASS_CAST ((klass), AMTK_TYPE_MENU_SHELL, AmtkMenuShellClass)) #define AMTK_IS_MENU_SHELL(obj) (G_TYPE_CHECK_INSTANCE_TYPE ((obj), AMTK_TYPE_MENU_SHELL)) #define AMTK_IS_MENU_SHELL_CLASS(klass) (G_TYPE_CHECK_CLASS_TYPE ((klass), AMTK_TYPE_MENU_SHELL)) #define AMTK_MENU_SHELL_GET_CLASS(obj) (G_TYPE_INSTANCE_GET_CLASS ((obj), AMTK_TYPE_MENU_SHELL, AmtkMenuShellClass)) typedef struct _AmtkMenuShell AmtkMenuShell; typedef struct _AmtkMenuShellClass AmtkMenuShellClass; typedef struct _AmtkMenuShellPrivate AmtkMenuShellPrivate; struct _AmtkMenuShell { GObject parent; AmtkMenuShellPrivate *priv; }; struct _AmtkMenuShellClass { GObjectClass parent_class; /* Signals */ void (* menu_item_selected) (AmtkMenuShell *amtk_menu_shell, GtkMenuItem *menu_item); void (* menu_item_deselected) (AmtkMenuShell *amtk_menu_shell, GtkMenuItem *menu_item); gpointer padding[12]; }; G_MODULE_EXPORT GType amtk_menu_shell_get_type (void); G_MODULE_EXPORT AmtkMenuShell * amtk_menu_shell_get_from_gtk_menu_shell (GtkMenuShell *gtk_menu_shell); G_MODULE_EXPORT GtkMenuShell * amtk_menu_shell_get_menu_shell (AmtkMenuShell *amtk_menu_shell); G_END_DECLS #endif /* AMTK_MENU_SHELL_H */ /* ex:set ts=8 noet: */ 07070100000019000081A400000000000000000000000166D2F0DB00000899000000000000000000000000000000000000002A00000000libgedit-amtk-5.9.0/amtk/amtk-shortcuts.c/* SPDX-FileCopyrightText: 2018 - Sébastien Wilmet <swilmet@gnome.org> * SPDX-License-Identifier: LGPL-3.0-or-later */ #include "amtk-shortcuts.h" /** * SECTION:amtk-shortcuts * @Short_description: GtkShortcuts convenience functions * @Title: AmtkShortcuts * * Convenience functions to create a #GtkShortcutsWindow. At the time of writing * the GtkShortcuts* classes don't provide any function. * * You need to also use gtk_container_add(), and g_object_set() to set other * properties. */ /** * amtk_shortcuts_window_new: * @parent: the #GtkWindow:transient-for. * * Creates a new #GtkShortcutsWindow. The #GtkWindow:modal property is set to * %TRUE. * * It is on purpose that the return type is #GtkShortcutsWindow, not #GtkWidget * or something else, so in C when you declare the variable as * #GtkShortcutsWindow it's easier to find it later (searching "GtkShortcuts" * will return something in your codebase). * * Returns: (transfer floating): a new #GtkShortcutsWindow. * Since: 5.0 */ GtkShortcutsWindow * amtk_shortcuts_window_new (GtkWindow *parent) { GtkShortcutsWindow *shortcuts_window; g_return_val_if_fail (GTK_IS_WINDOW (parent), NULL); shortcuts_window = g_object_new (GTK_TYPE_SHORTCUTS_WINDOW, NULL); gtk_window_set_modal (GTK_WINDOW (shortcuts_window), TRUE); gtk_window_set_transient_for (GTK_WINDOW (shortcuts_window), parent); return shortcuts_window; } /** * amtk_shortcuts_section_new: * @title: the #GtkShortcutsSection:title. * * Returns: (transfer floating): a new #GtkShortcutsSection. * Since: 5.0 */ GtkContainer * amtk_shortcuts_section_new (const gchar *title) { GtkContainer *section; section = g_object_new (GTK_TYPE_SHORTCUTS_SECTION, "title", title, NULL); gtk_widget_show (GTK_WIDGET (section)); return section; } /** * amtk_shortcuts_group_new: * @title: the #GtkShortcutsGroup:title. * * Returns: (transfer floating): a new #GtkShortcutsGroup. * Since: 5.0 */ GtkContainer * amtk_shortcuts_group_new (const gchar *title) { GtkContainer *group; group = g_object_new (GTK_TYPE_SHORTCUTS_GROUP, "title", title, NULL); gtk_widget_show (GTK_WIDGET (group)); return group; } 0707010000001A000081A400000000000000000000000166D2F0DB0000026F000000000000000000000000000000000000002A00000000libgedit-amtk-5.9.0/amtk/amtk-shortcuts.h/* SPDX-FileCopyrightText: 2018 - Sébastien Wilmet <swilmet@gnome.org> * SPDX-License-Identifier: LGPL-3.0-or-later */ #ifndef AMTK_SHORTCUTS_H #define AMTK_SHORTCUTS_H #if !defined (AMTK_H_INSIDE) && !defined (AMTK_COMPILATION) #error "Only <amtk/amtk.h> can be included directly." #endif #include <gtk/gtk.h> G_BEGIN_DECLS G_MODULE_EXPORT GtkShortcutsWindow * amtk_shortcuts_window_new (GtkWindow *parent); G_MODULE_EXPORT GtkContainer * amtk_shortcuts_section_new (const gchar *title); G_MODULE_EXPORT GtkContainer * amtk_shortcuts_group_new (const gchar *title); G_END_DECLS #endif /* AMTK_SHORTCUTS_H */ 0707010000001B000081A400000000000000000000000166D2F0DB00003673000000000000000000000000000000000000002600000000libgedit-amtk-5.9.0/amtk/amtk-utils.c/* SPDX-FileCopyrightText: 2017-2022 - Sébastien Wilmet <swilmet@gnome.org> * SPDX-License-Identifier: LGPL-3.0-or-later */ #include "amtk-utils.h" #include <string.h> #include "amtk-action-info.h" #include "amtk-action-info-central-store.h" /** * SECTION:amtk-utils * @title: AmtkUtils * @short_description: Utility functions * * Utility functions. */ static gchar * get_home_dir_without_trailing_slash (const gchar *home_dir) { gchar *utf8_home_dir; gsize length; if (home_dir == NULL) { return NULL; } utf8_home_dir = g_filename_to_utf8 (home_dir, -1, NULL, NULL, NULL); if (utf8_home_dir == NULL) { return NULL; } length = strlen (utf8_home_dir); if (length == 0) { g_free (utf8_home_dir); return NULL; } if (utf8_home_dir[length - 1] == '/') { utf8_home_dir[length - 1] = '\0'; } return utf8_home_dir; } /* Like tepl_utils_replace_home_dir_with_tilde() but with an additional home_dir * parameter, for unit tests. */ static gchar * _tepl_utils_replace_home_dir_with_tilde_with_param (const gchar *filename, const gchar *home_dir) { gchar *home_dir_without_trailing_slash; gchar *home_dir_with_trailing_slash; gchar *ret; g_return_val_if_fail (filename != NULL, NULL); home_dir_without_trailing_slash = get_home_dir_without_trailing_slash (home_dir); if (home_dir_without_trailing_slash == NULL) { return g_strdup (filename); } home_dir_with_trailing_slash = g_strdup_printf ("%s/", home_dir_without_trailing_slash); if (g_str_equal (filename, home_dir_without_trailing_slash) || g_str_equal (filename, home_dir_with_trailing_slash)) { ret = g_strdup ("~"); goto out; } if (g_str_has_prefix (filename, home_dir_with_trailing_slash)) { ret = g_strdup_printf ("~/%s", filename + strlen (home_dir_with_trailing_slash)); goto out; } ret = g_strdup (filename); out: g_free (home_dir_without_trailing_slash); g_free (home_dir_with_trailing_slash); return ret; } /* * _amtk_utils_replace_home_dir_with_tilde: * @filename: the filename. * * Replaces the home directory with a tilde, if the home directory is present in * the @filename. * * Returns: the new filename. Free with g_free(). */ /* This function is a copy from tepl-utils, which originally comes from gedit. */ gchar * _amtk_utils_replace_home_dir_with_tilde (const gchar *filename) { return _tepl_utils_replace_home_dir_with_tilde_with_param (filename, g_get_home_dir ()); } /** * amtk_utils_remove_mnemonic: * @str: a string. * * Removes the mnemonics from @str. Single underscores are removed, and two * consecutive underscores are replaced by one underscore (see the documentation * of gtk_label_new_with_mnemonic()). * * Returns: (transfer full): the new string with the mnemonics removed. Free * with g_free() when no longer needed. * Since: 5.0 */ gchar * amtk_utils_remove_mnemonic (const gchar *str) { gchar *new_str; gint str_pos; gint new_str_pos = 0; gboolean prev_char_is_underscore_skipped = FALSE; g_return_val_if_fail (str != NULL, NULL); new_str = g_malloc (strlen (str) + 1); for (str_pos = 0; str[str_pos] != '\0'; str_pos++) { gchar cur_char = str[str_pos]; if (cur_char == '_' && !prev_char_is_underscore_skipped) { prev_char_is_underscore_skipped = TRUE; } else { new_str[new_str_pos++] = cur_char; prev_char_is_underscore_skipped = FALSE; } } new_str[new_str_pos] = '\0'; return new_str; } static gint get_menu_item_position (GtkMenuShell *menu_shell, GtkMenuItem *item) { GList *children; GList *l; gint pos; gboolean found = FALSE; children = gtk_container_get_children (GTK_CONTAINER (menu_shell)); for (l = children, pos = 0; l != NULL; l = l->next, pos++) { GtkMenuItem *cur_item = l->data; if (cur_item == item) { found = TRUE; break; } } g_list_free (children); return found ? pos : -1; } /** * amtk_utils_recent_chooser_menu_get_item_uri: * @menu: a #GtkRecentChooserMenu. * @item: a #GtkMenuItem. * * Gets the URI of @item. @item must be a child of @menu. @menu must be a * #GtkRecentChooserMenu. * * This function has been written because the value returned by * gtk_recent_chooser_get_current_uri() is not updated when #GtkMenuItem's of a * #GtkRecentChooserMenu are selected/deselected. * * Returns: the URI of @item. Free with g_free() when no longer needed. * Since: 2.0 */ gchar * amtk_utils_recent_chooser_menu_get_item_uri (GtkRecentChooserMenu *menu, GtkMenuItem *item) { gint pos; gchar **all_uris; gsize length; gchar *item_uri = NULL; g_return_val_if_fail (GTK_IS_RECENT_CHOOSER_MENU (menu), NULL); g_return_val_if_fail (GTK_IS_MENU_ITEM (item), NULL); { GtkWidget *item_parent; item_parent = gtk_widget_get_parent (GTK_WIDGET (item)); g_return_val_if_fail (item_parent == GTK_WIDGET (menu), NULL); } pos = get_menu_item_position (GTK_MENU_SHELL (menu), item); g_return_val_if_fail (pos >= 0, NULL); all_uris = gtk_recent_chooser_get_uris (GTK_RECENT_CHOOSER (menu), &length); if ((gsize)pos < length) { item_uri = g_strdup (all_uris[pos]); } g_strfreev (all_uris); return item_uri; } static gboolean variant_type_equal_null_safe (const GVariantType *type1, const GVariantType *type2) { if (type1 == NULL || type2 == NULL) { return type1 == NULL && type2 == NULL; } return g_variant_type_equal (type1, type2); } #define AMTK_GVARIANT_PARAM_KEY "amtk-gvariant-param-key" G_GNUC_BEGIN_IGNORE_DEPRECATIONS static void gtk_action_activate_cb (GtkAction *gtk_action, GAction *g_action) { GVariant *param; param = g_object_get_data (G_OBJECT (gtk_action), AMTK_GVARIANT_PARAM_KEY); g_action_activate (g_action, param); } /** * amtk_utils_bind_g_action_to_gtk_action: * @g_action_map: a #GActionMap. * @detailed_g_action_name_without_prefix: a detailed #GAction name without the * #GActionMap prefix; the #GAction must be present in @g_action_map. * @gtk_action_group: a #GtkActionGroup. * @gtk_action_name: a #GtkAction name present in @gtk_action_group. * * Utility function to be able to port an application gradually to #GAction, * when #GtkUIManager and #GtkAction are still used. Porting to #GAction should * be the first step. * * For @detailed_g_action_name_without_prefix, see the * g_action_parse_detailed_name() function. The `"app."` or `"win."` prefix (or * any other #GActionMap prefix) must not be included in * @detailed_g_action_name_without_prefix. For example a valid * @detailed_g_action_name_without_prefix is `"open"` or * `"insert-command::foobar"`. * * The same #GAction can be bound to several #GtkAction's (with different * parameter values for the #GAction), but the reverse is not true, one * #GtkAction cannot be bound to several #GAction's. * * This function: * - Calls g_action_activate() when the #GtkAction #GtkAction::activate signal * is emitted. * - Binds the #GAction #GAction:enabled property to the #GtkAction * #GtkAction:sensitive property. The binding is done with the * %G_BINDING_BIDIRECTIONAL and %G_BINDING_SYNC_CREATE flags, the source is * the #GAction and the target is the #GtkAction. * * When using this function, you should set the callback to %NULL in the * corresponding #GtkActionEntry. * * Since: 4.0 */ void amtk_utils_bind_g_action_to_gtk_action (GActionMap *g_action_map, const gchar *detailed_g_action_name_without_prefix, GtkActionGroup *gtk_action_group, const gchar *gtk_action_name) { gchar *g_action_name = NULL; GVariant *target_value = NULL; GAction *g_action; GtkAction *gtk_action; GError *error = NULL; g_return_if_fail (G_IS_ACTION_MAP (g_action_map)); g_return_if_fail (detailed_g_action_name_without_prefix != NULL); g_return_if_fail (GTK_IS_ACTION_GROUP (gtk_action_group)); g_return_if_fail (gtk_action_name != NULL); g_action_parse_detailed_name (detailed_g_action_name_without_prefix, &g_action_name, &target_value, &error); /* The doc of g_action_parse_detailed_name() doesn't explain if it * returns a floating ref for the GVariant. */ if (target_value != NULL && g_variant_is_floating (target_value)) { g_variant_ref_sink (target_value); } if (error != NULL) { g_warning ("Error when parsing detailed GAction name '%s': %s", detailed_g_action_name_without_prefix, error->message); g_clear_error (&error); goto out; } g_action = g_action_map_lookup_action (g_action_map, g_action_name); if (g_action == NULL) { g_warn_if_reached (); goto out; } /* Sanity check, ensure that the GVariant target has the good type. */ { const GVariantType *g_action_param_type; const GVariantType *target_value_type = NULL; g_action_param_type = g_action_get_parameter_type (g_action); if (target_value != NULL) { target_value_type = g_variant_get_type (target_value); } if (!variant_type_equal_null_safe (g_action_param_type, target_value_type)) { g_warn_if_reached (); goto out; } } gtk_action = gtk_action_group_get_action (gtk_action_group, gtk_action_name); if (gtk_action == NULL) { g_warn_if_reached (); goto out; } if (target_value != NULL) { g_object_set_data_full (G_OBJECT (gtk_action), AMTK_GVARIANT_PARAM_KEY, g_variant_ref (target_value), (GDestroyNotify)g_variant_unref); } g_signal_connect_object (gtk_action, "activate", G_CALLBACK (gtk_action_activate_cb), g_action, 0); g_object_bind_property (g_action, "enabled", gtk_action, "sensitive", G_BINDING_BIDIRECTIONAL | G_BINDING_SYNC_CREATE); out: g_free (g_action_name); if (target_value != NULL) { g_variant_unref (target_value); } } /** * amtk_utils_create_gtk_action: * @g_action_map: a #GActionMap. * @detailed_g_action_name_with_prefix: a detailed #GAction name with the * #GActionMap prefix; the #GAction must be present in @g_action_map. * @gtk_action_group: a #GtkActionGroup. * @gtk_action_name: the name of the #GtkAction to create and add to * @gtk_action_group. * * Utility function to be able to port an application gradually to #GAction and * #AmtkActionInfo, when #GtkUIManager is still used. This function goes one * step further compared to amtk_utils_bind_g_action_to_gtk_action(). With * amtk_utils_bind_g_action_to_gtk_action(), only the #GAction must exist. With * amtk_utils_create_gtk_action(), both the #GAction and #AmtkActionInfo must * exist (so typically you need to convert the #GtkActionEntry's into * #AmtkActionInfoEntry's). * * This function creates a #GtkAction from a #GAction plus its corresponding * #AmtkActionInfo. * * The #GtkAction is created with the information provided by the * #AmtkActionInfo (retrieved with amtk_action_info_central_store_lookup() with * @detailed_g_action_name_with_prefix as argument). Only the first accelerator * is taken into account. * * Once the #GtkAction is created, it is added to the @gtk_action_group, and * amtk_utils_bind_g_action_to_gtk_action() is called. * * Since: 4.0 */ void amtk_utils_create_gtk_action (GActionMap *g_action_map, const gchar *detailed_g_action_name_with_prefix, GtkActionGroup *gtk_action_group, const gchar *gtk_action_name) { AmtkActionInfoCentralStore *central_store; AmtkActionInfo *g_action_info; GtkAction *gtk_action; const gchar * const *accels; const gchar *first_accel; const gchar *detailed_g_action_name_without_prefix; g_return_if_fail (G_IS_ACTION_MAP (g_action_map)); g_return_if_fail (detailed_g_action_name_with_prefix != NULL); g_return_if_fail (GTK_IS_ACTION_GROUP (gtk_action_group)); g_return_if_fail (gtk_action_name != NULL); central_store = amtk_action_info_central_store_get_singleton (); g_action_info = amtk_action_info_central_store_lookup (central_store, detailed_g_action_name_with_prefix); gtk_action = gtk_action_new (gtk_action_name, amtk_action_info_get_label (g_action_info), amtk_action_info_get_tooltip (g_action_info), NULL); gtk_action_set_icon_name (gtk_action, amtk_action_info_get_icon_name (g_action_info)); accels = amtk_action_info_get_accels (g_action_info); first_accel = accels != NULL ? accels[0] : NULL; gtk_action_group_add_action_with_accel (gtk_action_group, gtk_action, first_accel); g_object_unref (gtk_action); detailed_g_action_name_without_prefix = strchr (detailed_g_action_name_with_prefix, '.'); if (detailed_g_action_name_without_prefix != NULL) { detailed_g_action_name_without_prefix++; } else { detailed_g_action_name_without_prefix = detailed_g_action_name_with_prefix; } amtk_utils_bind_g_action_to_gtk_action (g_action_map, detailed_g_action_name_without_prefix, gtk_action_group, gtk_action_name); } G_GNUC_END_IGNORE_DEPRECATIONS /** * amtk_utils_get_shrinkable_menubar: * @menubar: a #GtkMenuBar. * * This function wraps @menubar into a container, to allow the menubar to shrink * below its minimum width. * * A possible use-case: have two applications side-by-side on a single screen. * * Returns: (transfer floating): a new widget that contains @menubar. * Since: 5.6 */ GtkWidget * amtk_utils_get_shrinkable_menubar (GtkMenuBar *menubar) { GtkWidget *viewport; GtkWidget *hpaned; /* Note, this solution might work with other kinds of widgets than a * GtkMenuBar. But it would require more testing. If a more general * solution is desirable, another function can be added. */ g_return_val_if_fail (GTK_IS_MENU_BAR (menubar), NULL); viewport = gtk_viewport_new (NULL, NULL); gtk_widget_show (viewport); gtk_viewport_set_shadow_type (GTK_VIEWPORT (viewport), GTK_SHADOW_NONE); hpaned = gtk_paned_new (GTK_ORIENTATION_HORIZONTAL); gtk_widget_show (hpaned); /* Packing */ gtk_container_add (GTK_CONTAINER (viewport), GTK_WIDGET (menubar)); gtk_paned_add1 (GTK_PANED (hpaned), viewport); return hpaned; } 0707010000001C000081A400000000000000000000000166D2F0DB00000552000000000000000000000000000000000000002600000000libgedit-amtk-5.9.0/amtk/amtk-utils.h/* SPDX-FileCopyrightText: 2017 - Sébastien Wilmet <swilmet@gnome.org> * SPDX-License-Identifier: LGPL-3.0-or-later */ #ifndef AMTK_UTILS_H #define AMTK_UTILS_H #if !defined (AMTK_H_INSIDE) && !defined (AMTK_COMPILATION) #error "Only <amtk/amtk.h> can be included directly." #endif #include <gtk/gtk.h> G_BEGIN_DECLS /* File utilities */ G_GNUC_INTERNAL gchar * _amtk_utils_replace_home_dir_with_tilde (const gchar *filename); /* String utilities */ G_MODULE_EXPORT gchar * amtk_utils_remove_mnemonic (const gchar *str); /* GTK utilities */ G_MODULE_EXPORT gchar * amtk_utils_recent_chooser_menu_get_item_uri (GtkRecentChooserMenu *menu, GtkMenuItem *item); G_GNUC_BEGIN_IGNORE_DEPRECATIONS G_MODULE_EXPORT void amtk_utils_bind_g_action_to_gtk_action (GActionMap *g_action_map, const gchar *detailed_g_action_name_without_prefix, GtkActionGroup *gtk_action_group, const gchar *gtk_action_name); G_MODULE_EXPORT void amtk_utils_create_gtk_action (GActionMap *g_action_map, const gchar *detailed_g_action_name_with_prefix, GtkActionGroup *gtk_action_group, const gchar *gtk_action_name); G_GNUC_END_IGNORE_DEPRECATIONS G_MODULE_EXPORT GtkWidget * amtk_utils_get_shrinkable_menubar (GtkMenuBar *menubar); G_END_DECLS #endif /* AMTK_UTILS_H */ 0707010000001D000081A400000000000000000000000166D2F0DB000002A7000000000000000000000000000000000000002000000000libgedit-amtk-5.9.0/amtk/amtk.h/* SPDX-FileCopyrightText: 2017, 2018 - Sébastien Wilmet <swilmet@gnome.org> * SPDX-License-Identifier: LGPL-3.0-or-later */ #ifndef AMTK_H #define AMTK_H #define AMTK_H_INSIDE #include <amtk/amtk-enum-types.h> #include <amtk/amtk-action-info.h> #include <amtk/amtk-action-info-store.h> #include <amtk/amtk-action-info-central-store.h> #include <amtk/amtk-action-map.h> #include <amtk/amtk-application-window.h> #include <amtk/amtk-factory.h> #include <amtk/amtk-gmenu.h> #include <amtk/amtk-init.h> #include <amtk/amtk-menu-item.h> #include <amtk/amtk-menu-shell.h> #include <amtk/amtk-shortcuts.h> #include <amtk/amtk-utils.h> #undef AMTK_H_INSIDE #endif /* AMTK_H */ 0707010000001E000081A400000000000000000000000166D2F0DB00000BE6000000000000000000000000000000000000002500000000libgedit-amtk-5.9.0/amtk/meson.buildamtk_public_headers = [ 'amtk.h', 'amtk-action-info-central-store.h', 'amtk-action-info.h', 'amtk-action-info-store.h', 'amtk-action-map.h', 'amtk-application-window.h', 'amtk-factory.h', 'amtk-gmenu.h', 'amtk-init.h', 'amtk-menu-item.h', 'amtk-menu-shell.h', 'amtk-shortcuts.h', 'amtk-utils.h', ] amtk_public_c_files = [ 'amtk-action-info.c', 'amtk-action-info-central-store.c', 'amtk-action-info-store.c', 'amtk-action-map.c', 'amtk-application-window.c', 'amtk-factory.c', 'amtk-gmenu.c', 'amtk-init.c', 'amtk-menu-item.c', 'amtk-menu-shell.c', 'amtk-shortcuts.c', 'amtk-utils.c', ] headers_install_dir = get_option('includedir') / '@0@-@1@/amtk/'.format(meson.project_name(), AMTK_API_VERSION) install_headers( amtk_public_headers, install_dir: headers_install_dir ) amtk_enum_types = GNOME.mkenums_simple( 'amtk-enum-types', decorator: 'G_MODULE_EXPORT', header_prefix: '#include <gmodule.h>', sources: amtk_public_headers, install_header: true, install_dir: headers_install_dir ) amtk_static_lib = static_library( 'libgedit-amtk-static', [amtk_public_c_files, amtk_enum_types], pic: true, # amtk_static_lib is potentially linked in a shared library. include_directories: ROOT_INCLUDE_DIR, dependencies: AMTK_DEPS, c_args: '-DAMTK_COMPILATION' ) # For unit tests, to be able to test private functions. AMTK_STATIC_DEP = declare_dependency( include_directories: ROOT_INCLUDE_DIR, link_with: amtk_static_lib, sources: amtk_enum_types[1], dependencies: AMTK_DEPS ) symbol_map = 'symbol.map' amtk_lib_link_args = c_compiler.get_supported_link_arguments([ '-Wl,--version-script,@0@/@1@'.format(meson.current_source_dir(), symbol_map), ]) amtk_lib = library( 'gedit-amtk-@0@'.format(AMTK_API_VERSION), dependencies: AMTK_DEPS, link_args: amtk_lib_link_args, link_depends: symbol_map, # link_whole is not supported with MSVC, so we use extract_all_objects(). objects: amtk_static_lib.extract_all_objects(recursive: false), soversion: 0, install: true ) AMTK_LIB_DEP = declare_dependency( include_directories: ROOT_INCLUDE_DIR, link_with: amtk_lib, sources: amtk_enum_types[1], dependencies: AMTK_DEPS ) PKG_CONFIG.generate(amtk_lib, filebase: '@0@-@1@'.format(meson.project_name(), AMTK_API_VERSION), name: meson.project_name(), description: 'Actions, Menus and Toolbars Kit', subdirs: '@0@-@1@'.format(meson.project_name(), AMTK_API_VERSION), libraries: AMTK_DEPS, ) if get_option('gobject_introspection') GNOME.generate_gir( amtk_lib, export_packages: '@0@-@1@'.format(meson.project_name(), AMTK_API_VERSION), header: 'amtk/amtk.h', identifier_prefix: 'Amtk', include_directories: ROOT_INCLUDE_DIR, includes: ['Gtk-3.0'], install: true, namespace: 'Amtk', nsversion: AMTK_API_VERSION, sources: [ amtk_public_headers, amtk_public_c_files, amtk_enum_types ], # Support for deps being built as subprojects: dependencies: AMTK_DEPS, ) endif 0707010000001F000081A400000000000000000000000166D2F0DB00000023000000000000000000000000000000000000002400000000libgedit-amtk-5.9.0/amtk/symbol.map{ global: amtk_*; local: *; }; 07070100000020000041ED00000000000000000000000266D2F0DB00000000000000000000000000000000000000000000001A00000000libgedit-amtk-5.9.0/build07070100000021000081A400000000000000000000000166D2F0DB00000002000000000000000000000000000000000000002500000000libgedit-amtk-5.9.0/build/.gitignore* 07070100000022000041ED00000000000000000000000266D2F0DB00000000000000000000000000000000000000000000001900000000libgedit-amtk-5.9.0/docs07070100000023000081A400000000000000000000000166D2F0DB000008D6000000000000000000000000000000000000002300000000libgedit-amtk-5.9.0/docs/dev-noteslibgedit-amtk notes - possible things to do or to investigate ============================================================= - Add convenient API to replace a placeholder by a list of menu/toolbar items? And be able to update the placeholder content when the application runs (so mark items to recognize them later, to know that they are part of the placeholder). Or create a Placeholder object that contains the list of items, so when the Placeholder object is modified, the menu/toolbar is updated accordingly. Or, the application can re-generate the whole submenu or a toolbar each time that it is needed. Or a submenu could be created on-the-fly, upon receiving a signal to open the submenu (?). In these cases, a full-blown placeholder mechanism is not needed, but perhaps a few utility functions would help. A good test-bed for this is the gnome-latex application. - Add one more sanity check: check that a GAction is *implemented* when (or after) creating a menu or toolbar item for that action? Because currently when the GAction is not implemented, the menu/toolbar item is just insensitive, there is no warning, no way to know if the menu/toolbar item was set as insensitive explicitly/intentionally or not. - An AmtkActionInfo could have a field for the default AmtkFactoryFlags (or to force some flags). For example setting AMTK_FACTORY_IGNORE_ACCELS_FOR_APP for the tepl-cut/copy/paste/select-all actions. But it's perhaps a bit messy. - To prevent apps from modifying ActionInfos of libs, maybe seal an ActionInfo when it is added to a store, except for mark_as_used(). But it's maybe a bit too paranoid. Or instead of sealing, have a builder class that creates an immutable ActionInfo, see: https://blogs.gnome.org/otte/2018/02/03/builders/ - ActionInfo and ActionInfoEntry could have one more field for an identifier, because when using a detailed GAction name the name can become a bit hairy (small tip / side note: to "git grep" it the `--fixed-strings` argument is needed). The detailed GAction name would be the equivalent of the callback in a GtkActionEntry. Because currently, to avoid such hairy names, more GActions need to be implemented, that can in turn call common functions. 07070100000024000081A400000000000000000000000166D2F0DB000002D1000000000000000000000000000000000000002D00000000libgedit-amtk-5.9.0/docs/more-information.mdlibgedit-amtk - more information ================================ Old name -------- libgedit-amtk was simply named Amtk until November 2022. Amtk 5.6.x are the last versions with the name "Amtk". libgedit-amtk 5.8.x are the first versions with the name "libgedit-amtk". Dependencies ------------ - GLib - GTK 3 Documentation ------------- See the `gtk_doc` Meson option. A convenient way to read the API documentation is with the [Devhelp](https://wiki.gnome.org/Apps/Devhelp) application. See also other files in this directory for additional notes. Tarballs -------- - [libgedit-amtk tarballs](https://download.gnome.org/sources/libgedit-amtk/) - [Old amtk tarballs](https://download.gnome.org/sources/amtk/) 07070100000025000041ED00000000000000000000000266D2F0DB00000000000000000000000000000000000000000000002300000000libgedit-amtk-5.9.0/docs/reference07070100000026000081A400000000000000000000000166D2F0DB00000788000000000000000000000000000000000000003700000000libgedit-amtk-5.9.0/docs/reference/gradual-porting.xml<?xml version="1.0"?> <!DOCTYPE refentry PUBLIC "-//OASIS//DTD DocBook XML V4.3//EN" "http://www.oasis-open.org/docbook/xml/4.3/docbookx.dtd" [ <!ENTITY % local.common.attrib "xmlns:xi CDATA #FIXED 'http://www.w3.org/2003/XInclude'"> <!ENTITY % gtkdocentities SYSTEM "xml/gtkdocentities.ent"> %gtkdocentities; ]> <refentry id="gradual-porting"> <refmeta> <refentrytitle>Gradual Porting</refentrytitle> </refmeta> <refnamediv> <refname>Gradual Porting</refname> <refpurpose> Gradually porting away from <link linkend="GtkAction">GtkAction</link> and <link linkend="GtkUIManager">GtkUIManager</link>. </refpurpose> </refnamediv> <para> Even if you don't want to use libgedit-amtk in the end, libgedit-amtk can help to gradually move away from <link linkend="GtkAction">GtkAction</link> and <link linkend="GtkUIManager">GtkUIManager</link>. </para> <refsect1> <title>Moving gradually to <link linkend="GAction">GAction</link></title> <para> libgedit-amtk provides the following functions that can help: </para> <itemizedlist> <listitem> <para> <link linkend="amtk-utils-bind-g-action-to-gtk-action">amtk_utils_bind_g_action_to_gtk_action()</link> </para> </listitem> <listitem> <para> <link linkend="amtk-utils-create-gtk-action">amtk_utils_create_gtk_action()</link> </para> </listitem> </itemizedlist> </refsect1> <refsect1> <title>Moving gradually away from <link linkend="GtkUIManager">GtkUIManager</link></title> <para> For example if you have already ported a submenu, but not the whole menu, you can use the <link linkend="gtk-ui-manager-get-widget">gtk_ui_manager_get_widget()</link> function to get a <link linkend="GtkMenuItem">GtkMenuItem</link>, and then set the submenu with <link linkend="gtk-menu-item-set-submenu">gtk_menu_item_set_submenu()</link>. </para> </refsect1> </refentry> 07070100000027000081A400000000000000000000000166D2F0DB00000ADC000000000000000000000000000000000000003A00000000libgedit-amtk-5.9.0/docs/reference/libgedit-amtk-docs.xml<?xml version="1.0"?> <!DOCTYPE book PUBLIC "-//OASIS//DTD DocBook XML V4.3//EN" "http://www.oasis-open.org/docbook/xml/4.3/docbookx.dtd" [ <!ENTITY % local.common.attrib "xmlns:xi CDATA #FIXED 'http://www.w3.org/2003/XInclude'"> <!ENTITY % gtkdocentities SYSTEM "xml/gtkdocentities.ent"> %gtkdocentities; ]> <book id="index"> <bookinfo> <title>libgedit-amtk &package_api_version; Reference Manual</title> <releaseinfo>for &package_string;</releaseinfo> </bookinfo> <xi:include href="libgedit-amtk-intro.xml"/> <xi:include href="gradual-porting.xml"/> <part id="api-reference"> <title>libgedit-amtk API Reference</title> <xi:include href="xml/amtk-init.xml"/> <xi:include href="xml/amtk-application-window.xml"/> <xi:include href="xml/amtk-action-info.xml"/> <xi:include href="xml/amtk-action-info-store.xml"/> <xi:include href="xml/amtk-action-info-central-store.xml"/> <xi:include href="xml/amtk-action-map.xml"/> <xi:include href="xml/amtk-factory.xml"/> <xi:include href="xml/amtk-gmenu.xml"/> <xi:include href="xml/amtk-menu-item.xml"/> <xi:include href="xml/amtk-menu-shell.xml"/> <xi:include href="xml/amtk-shortcuts.xml"/> <xi:include href="xml/amtk-utils.xml"/> </part> <part id="annexes"> <title>Annexes</title> <chapter id="object-tree"> <title>Object Hierarchy</title> <xi:include href="xml/tree_index.sgml"/> </chapter> <xi:include href="xml/annotation-glossary.xml"><xi:fallback /></xi:include> <index id="api-index-full"> <title>Index of all symbols</title> <xi:include href="xml/api-index-full.xml"><xi:fallback /></xi:include> </index> <index role="deprecated"> <title>Index of deprecated symbols</title> <xi:include href="xml/api-index-deprecated.xml"><xi:fallback /></xi:include> </index> <index id="api-index-2-0" role="2.0"> <title>Index of new symbols in 2.0</title> <xi:include href="xml/api-index-2.0.xml"><xi:fallback /></xi:include> </index> <index id="api-index-3-0" role="3.0"> <title>Index of new symbols in 3.0</title> <xi:include href="xml/api-index-3.0.xml"><xi:fallback /></xi:include> </index> <index id="api-index-4-0" role="4.0"> <title>Index of new symbols in 4.0</title> <xi:include href="xml/api-index-4.0.xml"><xi:fallback /></xi:include> </index> <index id="api-index-5-0" role="5.0"> <title>Index of new symbols in 5.0</title> <xi:include href="xml/api-index-5.0.xml"><xi:fallback /></xi:include> </index> <index id="api-index-5-6" role="5.6"> <title>Index of new symbols in 5.6</title> <xi:include href="xml/api-index-5.6.xml"><xi:fallback /></xi:include> </index> </part> </book> 07070100000028000081A400000000000000000000000166D2F0DB00001C3A000000000000000000000000000000000000003B00000000libgedit-amtk-5.9.0/docs/reference/libgedit-amtk-intro.xml<?xml version="1.0"?> <!DOCTYPE refentry PUBLIC "-//OASIS//DTD DocBook XML V4.3//EN" "http://www.oasis-open.org/docbook/xml/4.3/docbookx.dtd" [ <!ENTITY % local.common.attrib "xmlns:xi CDATA #FIXED 'http://www.w3.org/2003/XInclude'"> <!ENTITY % gtkdocentities SYSTEM "xml/gtkdocentities.ent"> %gtkdocentities; ]> <refentry id="libgedit-amtk-intro"> <refmeta> <refentrytitle>libgedit-amtk Introduction</refentrytitle> </refmeta> <refnamediv> <refname>libgedit-amtk Introduction</refname> <refpurpose> Introduction to the Actions, Menus and Toolbars Kit for GTK applications. </refpurpose> </refnamediv> <para> Amtk is the acronym for “Actions, Menus and Toolbars Kit”. Amtk has been initially created as a basic <link linkend="GtkUIManager">GtkUIManager</link> replacement based on <link linkend="GAction">GAction</link>. <link linkend="GtkUIManager">GtkUIManager</link> has been deprecated in GTK 3 (and removed in GTK 4), without a good replacement for applications that want to keep a traditional UI (with a <link linkend="GtkMenuBar">GtkMenuBar</link>, a <link linkend="GtkToolbar">GtkToolbar</link> and a <link linkend="GtkStatusbar">GtkStatusbar</link>). libgedit-amtk is now suitable for both a traditional UI and for a new UI with a <link linkend="GtkHeaderBar">GtkHeaderBar</link> and a “sandwich menu”. </para> <para> With libgedit-amtk, menus, toolbars or other objects like <link linkend="GtkShortcutsWindow">GtkShortcutsWindow</link> are created programmatically (not with a *.ui file), but with convenient APIs. The support for an XML format will maybe be added in the future. </para> <para> Note that the heavy-lifting is still done by GTK of course (and GIO for <link linkend="GAction">GAction</link>). This library is just a small layer on top, providing an alternative way of doing things. </para> <refsect1> <title>General advantages</title> <itemizedlist> <listitem> <para> Primarily, encoding the information about an action only once, to create various objects such as a menu item, a toolbar item, a <link linkend="GtkShortcutsShortcut">GtkShortcutsShortcut</link>, etc. The information needed about an action: a label (i.e. a short description), possibly an icon, a tooltip (i.e. a longer description) and keyboard shortcuts. This is implemented by <link linkend="AmtkActionInfo">AmtkActionInfo</link>, with <link linkend="AmtkFactory">AmtkFactory</link> functions to create various objects. </para> <para> This also has the nice benefit that all the information about an action is centralized in only one place, to keep related information close together. This permits to more easily catch inconsistencies. </para> </listitem> <listitem> <para> libgedit-amtk has been designed to be able to share <link linkend="AmtkActionInfo">AmtkActionInfo</link>'s in a library (with translations); this is a bit similar to <link linkend="GtkStockItem">GtkStockItem</link>, to reduce the amount of work that an application (and translators) need to do. As a result the library can provide a higher-level API. </para> </listitem> </itemizedlist> </refsect1> <refsect1> <title>Advantages for a traditional UI</title> <itemizedlist> <listitem> <para> When writing an XML file to create a <link linkend="GMenu">GMenu</link> with the format understood by <link linkend="GtkBuilder">GtkBuilder</link> (see the class description of <link linkend="GtkApplicationWindow">GtkApplicationWindow</link>), the information in the XML file can be used only to create a <link linkend="GMenu">GMenu</link>, not a toolbar. It is not a good programming practice to duplicate the information. With libgedit-amtk the information is encoded just once, in <link linkend="AmtkActionInfo">AmtkActionInfo</link>'s, and menu and toolbar items are created with <link linkend="AmtkFactory">AmtkFactory</link> which uses the information provided by the <link linkend="AmtkActionInfo">AmtkActionInfo</link>'s. </para> </listitem> <listitem> <para> Something that is not possible to do with the support of <link linkend="GMenu">GMenu</link> in GTK, that libgedit-amtk solves when using <link linkend="GtkMenuItem">GtkMenuItem</link>'s: when a <link linkend="GtkMenuItem">GtkMenuItem</link> is selected (e.g. when the mouse hovers it), showing a longer description in the <link linkend="GtkStatusbar">GtkStatusbar</link>. This is implemented by <link linkend="AmtkApplicationWindow">AmtkApplicationWindow</link>. It makes the UI better self-discoverable, to improve the usability. </para> </listitem> <listitem> <para> Related to the previous point: having a <link linkend="GtkRecentChooser">GtkRecentChooser</link> menu that shows in a <link linkend="GtkStatusbar">GtkStatusbar</link> the full file path when a menu item is selected. This is implemented by <link linkend="amtk-application-window-connect-recent-chooser-menu-to-statusbar">amtk_application_window_connect_recent_chooser_menu_to_statusbar()</link>. </para> </listitem> </itemizedlist> </refsect1> <refsect1> <title>Sanity checks</title> <para> libgedit-amtk has several functions to do various sanity checks. They normally don't impact too much the performances, so it is recommended to always run them, although they could be disabled on production. The functions: </para> <itemizedlist> <listitem> <para> <link linkend="amtk-action-map-add-action-entries-check-dups">amtk_action_map_add_action_entries_check_dups()</link> </para> </listitem> <listitem> <para> <link linkend="amtk-action-info-store-check-all-used">amtk_action_info_store_check_all_used()</link> </para> </listitem> <listitem> <para> Another sanity check, but which cannot be disabled: the <link linkend="AmtkActionInfoCentralStore">AmtkActionInfoCentralStore</link> checks that each <link linkend="AmtkActionInfo">AmtkActionInfo</link> has a unique action name. Which means that <link linkend="AmtkActionInfo">AmtkActionInfo</link>'s provided by a library must be namespaced. </para> </listitem> </itemizedlist> </refsect1> <refsect1> <title>GTK dependency</title> <para> libgedit-amtk &package_api_version; depends on GTK 3. </para> </refsect1> <refsect1> <title>pkg-config name</title> <para> For libgedit-amtk &package_api_version;, the pkg-config name is: <code>amtk-&package_api_version;</code> </para> <para> To compile a program that uses libgedit-amtk &package_api_version;, you can for example use the following command: </para> <para> <code>$ gcc hello.c `pkg-config --cflags --libs amtk-&package_api_version;` -o hello</code> </para> </refsect1> </refentry> 07070100000029000081A400000000000000000000000166D2F0DB0000126F000000000000000000000000000000000000003E00000000libgedit-amtk-5.9.0/docs/reference/libgedit-amtk-sections.txt<INCLUDE>amtk/amtk.h</INCLUDE> <SECTION> <FILE>amtk-init</FILE> <TITLE>Amtk Initialization and Finalization</TITLE> amtk_init amtk_finalize <SUBSECTION Standard> AMTK_H_INSIDE </SECTION> <SECTION> <FILE>amtk-application-window</FILE> AmtkApplicationWindow amtk_application_window_get_from_gtk_application_window amtk_application_window_get_application_window amtk_application_window_get_statusbar amtk_application_window_set_statusbar amtk_application_window_connect_menu_to_statusbar amtk_application_window_connect_recent_chooser_menu_to_statusbar amtk_application_window_create_open_recent_menu_base amtk_application_window_create_open_recent_menu amtk_application_window_create_open_recent_menu_item <SUBSECTION Standard> AMTK_APPLICATION_WINDOW AMTK_APPLICATION_WINDOW_CLASS AMTK_APPLICATION_WINDOW_GET_CLASS AMTK_IS_APPLICATION_WINDOW AMTK_IS_APPLICATION_WINDOW_CLASS AMTK_TYPE_APPLICATION_WINDOW AmtkApplicationWindowClass AmtkApplicationWindowPrivate amtk_application_window_get_type </SECTION> <SECTION> <FILE>amtk-action-info</FILE> AmtkActionInfo AmtkActionInfoEntry amtk_action_info_new amtk_action_info_new_from_entry amtk_action_info_ref amtk_action_info_unref amtk_action_info_copy amtk_action_info_get_action_name amtk_action_info_set_action_name amtk_action_info_get_icon_name amtk_action_info_set_icon_name amtk_action_info_get_label amtk_action_info_set_label amtk_action_info_get_tooltip amtk_action_info_set_tooltip amtk_action_info_get_accels amtk_action_info_set_accels amtk_action_info_mark_as_used amtk_action_info_has_been_used <SUBSECTION Standard> amtk_action_info_get_type AMTK_TYPE_ACTION_INFO </SECTION> <SECTION> <FILE>amtk-action-info-store</FILE> AmtkActionInfoStore amtk_action_info_store_new amtk_action_info_store_add amtk_action_info_store_add_entries amtk_action_info_store_lookup amtk_action_info_store_set_all_accels_to_app amtk_action_info_store_check_all_used <SUBSECTION Standard> AMTK_ACTION_INFO_STORE AMTK_ACTION_INFO_STORE_CLASS AMTK_ACTION_INFO_STORE_GET_CLASS AMTK_IS_ACTION_INFO_STORE AMTK_IS_ACTION_INFO_STORE_CLASS AMTK_TYPE_ACTION_INFO_STORE AmtkActionInfoStoreClass AmtkActionInfoStorePrivate amtk_action_info_store_get_type </SECTION> <SECTION> <FILE>amtk-action-info-central-store</FILE> AmtkActionInfoCentralStore amtk_action_info_central_store_get_singleton amtk_action_info_central_store_lookup <SUBSECTION Standard> AMTK_ACTION_INFO_CENTRAL_STORE AMTK_ACTION_INFO_CENTRAL_STORE_CLASS AMTK_ACTION_INFO_CENTRAL_STORE_GET_CLASS AMTK_IS_ACTION_INFO_CENTRAL_STORE AMTK_IS_ACTION_INFO_CENTRAL_STORE_CLASS AMTK_TYPE_ACTION_INFO_CENTRAL_STORE AmtkActionInfoCentralStoreClass AmtkActionInfoCentralStorePrivate amtk_action_info_central_store_get_type </SECTION> <SECTION> <FILE>amtk-action-map</FILE> amtk_action_map_add_action_entries_check_dups </SECTION> <SECTION> <FILE>amtk-factory</FILE> AmtkFactory AmtkFactoryFlags amtk_factory_new amtk_factory_new_with_default_application amtk_factory_get_application amtk_factory_get_default_flags amtk_factory_set_default_flags amtk_factory_create_menu_item amtk_factory_create_menu_item_full amtk_factory_create_check_menu_item amtk_factory_create_check_menu_item_full amtk_factory_create_simple_menu amtk_factory_create_simple_menu_full amtk_factory_create_gmenu_item amtk_factory_create_gmenu_item_full amtk_factory_create_tool_button amtk_factory_create_tool_button_full amtk_factory_create_menu_tool_button amtk_factory_create_menu_tool_button_full amtk_factory_create_shortcut amtk_factory_create_shortcut_full <SUBSECTION Standard> AMTK_FACTORY AMTK_FACTORY_CLASS AMTK_FACTORY_GET_CLASS AMTK_IS_FACTORY AMTK_IS_FACTORY_CLASS AMTK_TYPE_FACTORY AmtkFactoryClass AmtkFactoryPrivate amtk_factory_get_type AMTK_TYPE_FACTORY_FLAGS amtk_factory_flags_get_type </SECTION> <SECTION> <FILE>amtk-gmenu</FILE> amtk_gmenu_append_item amtk_gmenu_append_section </SECTION> <SECTION> <FILE>amtk-menu-item</FILE> amtk_menu_item_get_long_description amtk_menu_item_set_long_description amtk_menu_item_set_icon_name </SECTION> <SECTION> <FILE>amtk-menu-shell</FILE> AmtkMenuShell amtk_menu_shell_get_from_gtk_menu_shell amtk_menu_shell_get_menu_shell <SUBSECTION Standard> AMTK_IS_MENU_SHELL AMTK_IS_MENU_SHELL_CLASS AMTK_MENU_SHELL AMTK_MENU_SHELL_CLASS AMTK_MENU_SHELL_GET_CLASS AMTK_TYPE_MENU_SHELL AmtkMenuShellClass AmtkMenuShellPrivate amtk_menu_shell_get_type </SECTION> <SECTION> <FILE>amtk-shortcuts</FILE> amtk_shortcuts_window_new amtk_shortcuts_section_new amtk_shortcuts_group_new </SECTION> <SECTION> <FILE>amtk-utils</FILE> amtk_utils_remove_mnemonic amtk_utils_recent_chooser_menu_get_item_uri amtk_utils_bind_g_action_to_gtk_action amtk_utils_create_gtk_action amtk_utils_get_shrinkable_menubar </SECTION> 0707010000002A000081A400000000000000000000000166D2F0DB000004F4000000000000000000000000000000000000002F00000000libgedit-amtk-5.9.0/docs/reference/meson.buildsubdir('xml') FS.copyfile( 'libgedit-amtk-sections.txt', 'libgedit-amtk-@0@-sections.txt'.format(AMTK_API_VERSION) ) gtkdoc_module_name = 'libgedit-amtk-@0@'.format(AMTK_API_VERSION) html_dir = get_option('prefix') / GNOME.gtkdoc_html_dir(gtkdoc_module_name) glib_docpath = dependency('glib-2.0').get_variable(pkgconfig: 'prefix') / 'share/gtk-doc/html/glib' gobject_docpath = dependency('gobject-2.0').get_variable(pkgconfig: 'prefix') / 'share/gtk-doc/html/gobject' gio_docpath = dependency('gio-2.0').get_variable(pkgconfig: 'prefix') / 'share/gtk-doc/html/gio' gtk_docpath = dependency('gtk+-3.0').get_variable(pkgconfig: 'prefix') / 'share/gtk-doc/html/gtk3' GNOME.gtkdoc( gtkdoc_module_name, main_xml: 'libgedit-amtk-docs.xml', src_dir: include_directories('../../amtk/'), dependencies: AMTK_LIB_DEP, scan_args: ['--rebuild-types'], gobject_typesfile: 'libgedit-amtk-@0@.types'.format(AMTK_API_VERSION), fixxref_args: [ '--html-dir=@0@'.format(html_dir), '--extra-dir=@0@'.format(glib_docpath), '--extra-dir=@0@'.format(gobject_docpath), '--extra-dir=@0@'.format(gio_docpath), '--extra-dir=@0@'.format(gtk_docpath) ], content_files: [ 'libgedit-amtk-intro.xml', 'gradual-porting.xml', ], install: true ) 0707010000002B000041ED00000000000000000000000266D2F0DB00000000000000000000000000000000000000000000002700000000libgedit-amtk-5.9.0/docs/reference/xml0707010000002C000081A400000000000000000000000166D2F0DB00000062000000000000000000000000000000000000003D00000000libgedit-amtk-5.9.0/docs/reference/xml/gtkdocentities.ent.in<!ENTITY package_string "@PACKAGE_STRING@"> <!ENTITY package_api_version "@PACKAGE_API_VERSION@"> 0707010000002D000081A400000000000000000000000166D2F0DB000001A0000000000000000000000000000000000000003300000000libgedit-amtk-5.9.0/docs/reference/xml/meson.buildgtkdocentities_conf_data = configuration_data() gtkdocentities_conf_data.set('PACKAGE_STRING', '@0@ @1@'.format(meson.project_name(), meson.project_version())) gtkdocentities_conf_data.set('PACKAGE_API_VERSION', AMTK_API_VERSION) gtkdocentities_filename = 'gtkdocentities.ent' configure_file( input: gtkdocentities_filename + '.in', output: gtkdocentities_filename, configuration: gtkdocentities_conf_data ) 0707010000002E000081A400000000000000000000000166D2F0DB000000F4000000000000000000000000000000000000002400000000libgedit-amtk-5.9.0/docs/roadmap.mdlibgedit-amtk roadmap ===================== - See the dev-notes file for possible tasks. - Port to GTK 4, see if creating a traditional UI with GTK 4 is still (easily) possible. If some features are missing compared to GTK 3, fill the gap. 0707010000002F000081A400000000000000000000000166D2F0DB00000518000000000000000000000000000000000000002700000000libgedit-amtk-5.9.0/libgedit-amtk.doap<?xml version="1.0" encoding="UTF-8"?> <Project xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#" xmlns:rdfs="http://www.w3.org/2000/01/rdf-schema#" xmlns:foaf="http://xmlns.com/foaf/0.1/" xmlns:gnome="http://api.gnome.org/doap-extensions#" xmlns="http://usefulinc.com/ns/doap#"> <name>libgedit-amtk</name> <shortdesc xml:lang="en">Gedit Technology - Actions, Menus and Toolbars Kit</shortdesc> <description xml:lang="en"> libgedit-amtk is part of Gedit Technology. It is a library based on GTK. Amtk is the acronym for “Actions, Menus and Toolbars Kit”. It is a basic GtkUIManager replacement based on GAction. It is suitable for both a traditional UI or a modern UI with a GtkHeaderBar. </description> <homepage rdf:resource="https://gitlab.gnome.org/World/gedit/libgedit-amtk" /> <download-page rdf:resource="https://download.gnome.org/sources/libgedit-amtk/" /> <bug-database rdf:resource="https://gitlab.gnome.org/World/gedit/libgedit-amtk/-/issues" /> <programming-language>C</programming-language> <maintainer> <foaf:Person> <foaf:name>Sébastien Wilmet</foaf:name> <foaf:mbox rdf:resource="mailto:swilmet@mailfence.com" /> <gnome:userid>swilmet</gnome:userid> </foaf:Person> </maintainer> </Project> 07070100000030000081A400000000000000000000000166D2F0DB00000C80000000000000000000000000000000000000002000000000libgedit-amtk-5.9.0/meson.build# Convention: # - Local variables in lower_case. # - Global variables in UPPER_CASE. # See: https://github.com/mesonbuild/meson/issues/2607 project( 'libgedit-amtk', 'c', meson_version: '>= 0.64', version: '5.9.0', default_options: ['warning_level=2'] ) GNOME = import('gnome') PKG_CONFIG = import('pkgconfig') I18N = import('i18n') FS = import('fs') # API version, used for parallel installability. AMTK_API_VERSION = '5' AMTK_DEPS = [ dependency('gio-2.0', version: '>= 2.56'), dependency('gtk+-3.0', version: '>= 3.22') ] # amtk-config.h config_data = configuration_data() GETTEXT_PACKAGE_NAME = '@0@-@1@'.format(meson.project_name(), AMTK_API_VERSION) config_data.set_quoted('GETTEXT_PACKAGE', GETTEXT_PACKAGE_NAME) config_data.set_quoted('AMTK_LOCALEDIR', get_option('prefix') / get_option('localedir')) configure_file( output: 'amtk-config.h', configuration: config_data ) # Misc ROOT_INCLUDE_DIR = include_directories('.') add_project_arguments( '-DG_LOG_DOMAIN="@0@"'.format(meson.project_name()), language: 'c' ) ##### # CFLAGS # Some flags are missing when using only the builtin warning_level meson option, # even at the maximum level. # The following warning_cflags suppose that warning_level=2. c_compiler = meson.get_compiler('c') warning_cflags = [] if c_compiler.get_id() == 'msvc' # Use GLib's msvc_recommended_pragmas.h to filter out # the warnings we don't really need to worry about, # but do make the ones we want to be wary stand out warning_cflags += [ '-FImsvc_recommended_pragmas.h', ] else # Try to mimic the AX_COMPILER_FLAGS Autotools macro. warning_cflags += [ '-fno-strict-aliasing', '-Wundef', '-Wnested-externs', '-Wwrite-strings', '-Wpointer-arith', '-Wmissing-declarations', '-Wmissing-prototypes', '-Wstrict-prototypes', '-Wredundant-decls', '-Wno-unused-parameter', '-Wno-missing-field-initializers', '-Wdeclaration-after-statement', '-Wformat=2', '-Wold-style-definition', '-Wcast-align', '-Wformat-nonliteral', '-Wformat-security', '-Wsign-compare', '-Wstrict-aliasing', '-Wshadow', '-Winline', '-Wpacked', '-Wmissing-format-attribute', '-Wmissing-noreturn', '-Winit-self', '-Wredundant-decls', '-Wmissing-include-dirs', '-Wunused-but-set-variable', '-Warray-bounds', '-Wimplicit-function-declaration', '-Wreturn-type', '-Wswitch-enum', '-Wswitch-default', '-Wduplicated-cond', '-Wduplicated-branches', '-Wlogical-op', '-Wrestrict', '-Wnull-dereference', '-Wjump-misses-init', '-Wdouble-promotion' ] endif supported_warning_cflags = c_compiler.get_supported_arguments(warning_cflags) add_project_arguments(supported_warning_cflags, language: 'c') ##### end CFLAGS subdir('po') subdir('amtk') if get_option('tests') subdir('tests') endif if get_option('gtk_doc') subdir('docs/reference') endif summary('API version', AMTK_API_VERSION) summary('Prefix', get_option('prefix')) summary('GObject Introspection', get_option('gobject_introspection')) summary('API documentation', get_option('gtk_doc')) summary('Build tests', get_option('tests')) 07070100000031000081A400000000000000000000000166D2F0DB0000015B000000000000000000000000000000000000002600000000libgedit-amtk-5.9.0/meson_options.txtoption( 'gobject_introspection', type: 'boolean', value: true, description: 'Build GObject Introspection data (requires gobject-introspection)' ) option( 'gtk_doc', type: 'boolean', value: true, description: 'Build API reference (requires gtk-doc)' ) option( 'tests', type: 'boolean', value: true, description: 'Build tests' ) 07070100000032000041ED00000000000000000000000266D2F0DB00000000000000000000000000000000000000000000001700000000libgedit-amtk-5.9.0/po07070100000033000081A400000000000000000000000166D2F0DB000000B1000000000000000000000000000000000000001F00000000libgedit-amtk-5.9.0/po/LINGUAS# Set of available languages. # Please keep this list sorted alphabetically. ca cs da de el en_GB es eu fr fur hr id hu it ja ka lt ms nl pl pt pt_BR ro ru sr sl sv tr uk zh_CN 07070100000034000081A400000000000000000000000166D2F0DB00000156000000000000000000000000000000000000002300000000libgedit-amtk-5.9.0/po/POTFILES.in# List of source files containing translatable strings. amtk/amtk-action-info.c amtk/amtk-action-info-central-store.c amtk/amtk-action-info-store.c amtk/amtk-action-map.c amtk/amtk-application-window.c amtk/amtk-factory.c amtk/amtk-gmenu.c amtk/amtk-init.c amtk/amtk-menu-item.c amtk/amtk-menu-shell.c amtk/amtk-shortcuts.c amtk/amtk-utils.c 07070100000035000081A400000000000000000000000166D2F0DB00000000000000000000000000000000000000000000002500000000libgedit-amtk-5.9.0/po/POTFILES.skip07070100000036000081A400000000000000000000000166D2F0DB0000040E000000000000000000000000000000000000001D00000000libgedit-amtk-5.9.0/po/ca.po# Catalan translation for amtk. # Copyright (C) 2021 amtk's COPYRIGHT HOLDER # This file is distributed under the same license as the amtk package. # Jordi Mas <jmas@softcatala.org>, 2021 # msgid "" msgstr "" "Project-Id-Version: amtk master\n" "Report-Msgid-Bugs-To: https://gitlab.gnome.org/GNOME/amtk/issues\n" "POT-Creation-Date: 2021-01-11 09:38+0000\n" "PO-Revision-Date: 2021-01-11 09:38+0000\n" "Last-Translator: Jordi Mas <jmas@softcatala.org>\n" "Language-Team: Catalan <gnome@llistes.softcatala.org>\n" "Language: ca\n" "MIME-Version: 1.0\n" "Content-Type: text/plain; charset=UTF-8\n" "Content-Transfer-Encoding: 8bit\n" #. Translators: %s is a filename. #: amtk/amtk-application-window.c:374 #, c-format msgid "Open “%s”" msgstr "Obre «%s»" #: amtk/amtk-application-window.c:630 msgid "Open _Recent" msgstr "_Obre'n un recent" #. Translators: %s is the application name. #: amtk/amtk-application-window.c:633 #, c-format msgid "Open a file recently used with %s" msgstr "Obre un fitxer utilitzat recentment amb %s" 07070100000037000081A400000000000000000000000166D2F0DB00002A37000000000000000000000000000000000000001D00000000libgedit-amtk-5.9.0/po/cs.po# Czech translation for tepl. # Copyright (C) 2017 tepl's COPYRIGHT HOLDER # This file is distributed under the same license as the tepl package. # Marek Černocký <marek@manet.cz>, 2017, 2018. # msgid "" msgstr "" "Project-Id-Version: tepl master\n" "Report-Msgid-Bugs-To: https://bugzilla.gnome.org/enter_bug.cgi?" "product=tepl&keywords=I18N+L10N&component=general\n" "POT-Creation-Date: 2017-12-01 09:23+0000\n" "PO-Revision-Date: 2018-02-07 08:02+0100\n" "Last-Translator: Marek Černocký <marek@manet.cz>\n" "Language-Team: čeština <gnome-cs-list@gnome.org>\n" "Language: cs\n" "MIME-Version: 1.0\n" "Content-Type: text/plain; charset=UTF-8\n" "Content-Transfer-Encoding: 8bit\n" "Plural-Forms: nplurals=3; plural=(n==1) ? 0 : (n>=2 && n<=4) ? 1 : 2;\n" "X-Generator: Gtranslator 2.91.7\n" #. Translators: %s is a filename. #: amtk/amtk-application-window.c:374 #, c-format msgid "Open “%s”" msgstr "Otevřít „%s“" #: amtk/amtk-application-window.c:630 msgid "Open _Recent" msgstr "Otevřít ne_dávné" #. Translators: %s is the application name. #: amtk/amtk-application-window.c:633 #, c-format msgid "Open a file recently used with %s" msgstr "Otevřít soubor nedávno použitý aplikací %s" #. action, icon, label, accel, tooltip #. File menu #. Why "file" and not "document"? "Document" is not the best #. word because the action is not always to create a new #. document. For example a LaTeX document can be composed of #. several _files_. Or for source code we do not really create a #. new "document". #: tepl/tepl-application.c:92 msgid "_New" msgstr "_Nový" #: tepl/tepl-application.c:93 msgid "New file" msgstr "Nový soubor" #: tepl/tepl-application.c:95 msgid "New _Window" msgstr "No_vé okno" #: tepl/tepl-application.c:96 msgid "Create a new window" msgstr "Vytvořit nové okno" #: tepl/tepl-application.c:98 tepl/tepl-application-window.c:178 msgid "_Open" msgstr "_Otevřít" #: tepl/tepl-application.c:99 msgid "Open a file" msgstr "Otevřít soubor" #: tepl/tepl-application.c:101 tepl/tepl-close-confirm-dialog-single.c:144 #: tepl/tepl-tab.c:752 msgid "_Save" msgstr "_Uložit" #: tepl/tepl-application.c:102 msgid "Save the current file" msgstr "Uložit aktuální soubor" #: tepl/tepl-application.c:104 msgid "Save _As" msgstr "Uložit j_ako" #: tepl/tepl-application.c:105 msgid "Save the current file to a different location" msgstr "Uložit aktuální soubor na jiné místo" #. Edit menu #: tepl/tepl-application.c:109 msgid "_Undo" msgstr "_Zpět" #: tepl/tepl-application.c:110 msgid "Undo the last action" msgstr "Vrátit zpět poslední úkon" #: tepl/tepl-application.c:112 msgid "_Redo" msgstr "Zno_vu" #: tepl/tepl-application.c:113 msgid "Redo the last undone action" msgstr "Znovu provást poslední vrácený úkon" #: tepl/tepl-application.c:115 msgid "Cu_t" msgstr "_Vyjmout" #: tepl/tepl-application.c:116 msgid "Cut the selection" msgstr "Vyjmout výběr" #: tepl/tepl-application.c:118 msgid "_Copy" msgstr "_Kopírovat" #: tepl/tepl-application.c:119 msgid "Copy the selection" msgstr "Kopírovat výběr" #: tepl/tepl-application.c:121 msgid "_Paste" msgstr "V_ložit" #: tepl/tepl-application.c:122 msgid "Paste the clipboard" msgstr "Vložit obsah schránky" #: tepl/tepl-application.c:124 msgid "_Delete" msgstr "_Smazat" #: tepl/tepl-application.c:125 msgid "Delete the selected text" msgstr "Smazat vybraný text" #: tepl/tepl-application.c:127 msgid "Select _All" msgstr "Vybr_at vše" #: tepl/tepl-application.c:128 msgid "Select all the text" msgstr "Vybrat všechen text" #: tepl/tepl-application.c:130 msgid "_Indent" msgstr "Odsad_it" #: tepl/tepl-application.c:131 msgid "Indent the selected lines" msgstr "Odsadit vybrané řádky" #: tepl/tepl-application.c:133 msgid "_Unindent" msgstr "Zr_ušit odsazení" #: tepl/tepl-application.c:134 msgid "Unindent the selected lines" msgstr "Zrušit odsazení vybraných řádků" #. Create a GtkFileChooserDialog, not a GtkFileChooserNative, because #. * with GtkFileChooserNative the GFile that we obtain (in flatpak) #. * doesn't have the real path to the file, so it would screw up some #. * features for text editors: #. * - showing the directory in parentheses in the window title, or in the #. * tab tooltip; #. * - opening a recent file. #. * Basically everywhere where the directory is shown. #. #: tepl/tepl-application-window.c:174 msgid "Open File" msgstr "Otevření souboru" #: tepl/tepl-application-window.c:177 #: tepl/tepl-close-confirm-dialog-single.c:138 tepl/tepl-tab.c:751 msgid "_Cancel" msgstr "_Zrušit" #: tepl/tepl-application-window.c:708 msgid "Read-Only" msgstr "Jen ke čtení" #: tepl/tepl-close-confirm-dialog-single.c:133 #, c-format msgid "Save changes to file “%s” before closing?" msgstr "Uložit před zavřením změny do souboru „%s“?" #: tepl/tepl-close-confirm-dialog-single.c:137 msgid "Close _without Saving" msgstr "Zavřít _bez uložení" #: tepl/tepl-close-confirm-dialog-single.c:150 msgid "_Save As…" msgstr "Uložit j_ako…" #. UTF-8 first, so that it's the first encoding returned by #. * tepl_encoding_get_all(). #. #: tepl/tepl-encoding.c:115 tepl/tepl-encoding.c:132 tepl/tepl-encoding.c:133 #: tepl/tepl-encoding.c:134 tepl/tepl-encoding.c:135 tepl/tepl-encoding.c:136 #: tepl/tepl-encoding.c:137 tepl/tepl-encoding.c:138 msgid "Unicode" msgstr "Unikód" #. FIXME GEOSTD8 ? #: tepl/tepl-encoding.c:117 tepl/tepl-encoding.c:129 tepl/tepl-encoding.c:157 #: tepl/tepl-encoding.c:180 msgid "Western" msgstr "Západoevropské" #: tepl/tepl-encoding.c:118 tepl/tepl-encoding.c:158 tepl/tepl-encoding.c:178 msgid "Central European" msgstr "Středoevropské" #: tepl/tepl-encoding.c:119 msgid "South European" msgstr "Jihoevropské" #: tepl/tepl-encoding.c:120 tepl/tepl-encoding.c:127 tepl/tepl-encoding.c:185 msgid "Baltic" msgstr "Baltické" #: tepl/tepl-encoding.c:121 tepl/tepl-encoding.c:159 tepl/tepl-encoding.c:166 #: tepl/tepl-encoding.c:168 tepl/tepl-encoding.c:169 tepl/tepl-encoding.c:179 msgid "Cyrillic" msgstr "Azbuka" #: tepl/tepl-encoding.c:122 tepl/tepl-encoding.c:162 tepl/tepl-encoding.c:184 msgid "Arabic" msgstr "Arabské" #: tepl/tepl-encoding.c:123 tepl/tepl-encoding.c:181 msgid "Greek" msgstr "Řecké" #: tepl/tepl-encoding.c:124 msgid "Hebrew Visual" msgstr "Hebrejské vizuální" #: tepl/tepl-encoding.c:125 tepl/tepl-encoding.c:160 tepl/tepl-encoding.c:182 msgid "Turkish" msgstr "Turecké" #: tepl/tepl-encoding.c:126 msgid "Nordic" msgstr "Skandinávské" #: tepl/tepl-encoding.c:128 msgid "Celtic" msgstr "Keltské" #: tepl/tepl-encoding.c:130 msgid "Romanian" msgstr "Rumunské" #: tepl/tepl-encoding.c:140 msgid "Armenian" msgstr "Armenské" #: tepl/tepl-encoding.c:141 tepl/tepl-encoding.c:142 tepl/tepl-encoding.c:150 msgid "Chinese Traditional" msgstr "Čínské tradiční" #: tepl/tepl-encoding.c:143 msgid "Cyrillic/Russian" msgstr "Azbuka ruská" #: tepl/tepl-encoding.c:145 tepl/tepl-encoding.c:146 tepl/tepl-encoding.c:147 #: tepl/tepl-encoding.c:164 tepl/tepl-encoding.c:172 msgid "Japanese" msgstr "Japonské" #: tepl/tepl-encoding.c:149 tepl/tepl-encoding.c:165 tepl/tepl-encoding.c:167 #: tepl/tepl-encoding.c:175 msgid "Korean" msgstr "Korejské" #: tepl/tepl-encoding.c:152 tepl/tepl-encoding.c:153 tepl/tepl-encoding.c:154 msgid "Chinese Simplified" msgstr "Čínské zjednodušené" #: tepl/tepl-encoding.c:155 msgid "Georgian" msgstr "Gruzínské" #: tepl/tepl-encoding.c:161 tepl/tepl-encoding.c:183 msgid "Hebrew" msgstr "Hebrejské" #: tepl/tepl-encoding.c:170 msgid "Cyrillic/Ukrainian" msgstr "Azbuka ukrajinská" #: tepl/tepl-encoding.c:173 tepl/tepl-encoding.c:176 tepl/tepl-encoding.c:186 msgid "Vietnamese" msgstr "Vietnamské" #: tepl/tepl-encoding.c:174 msgid "Thai" msgstr "Thajské" #: tepl/tepl-encoding.c:370 msgid "Unknown" msgstr "Neznámé" #. Translators: This is the sorted list of encodings used by Tepl for #. * automatic detection of the file encoding. You may want to customize #. * it adding encodings that are common in your country, for instance the #. * GB18030 encoding for the Chinese translation. You may also want to #. * remove the ISO-8859-15 encoding (covering English and most Western #. * European languages) if you think people in your country will rarely #. * use it. 'CURRENT' is a magic value used by Tepl and it represents #. * the encoding for the current locale, so please don't translate the #. * 'CURRENT' term. Keep the same format: square brackets, single quotes, #. * commas. #. #: tepl/tepl-encoding.c:695 msgid "['UTF-8', 'CURRENT', 'ISO-8859-15', 'UTF-16']" msgstr "['UTF-8', 'CURRENT', 'ISO-8859-2', 'WINDOWS-1250', 'UTF-16']" #: tepl/tepl-encoding-converter.c:302 #, c-format msgid "Conversion from character set “%s” to “%s” is not supported." msgstr "Převod ze znakové sady „%s“ do „%s“ není podporován." #: tepl/tepl-encoding-converter.c:311 #, c-format msgid "Could not open converter from “%s” to “%s”: %s" msgstr "Nelze otevřít převodník z „%s“ do „%s“: %s" #: tepl/tepl-encoding-converter.c:368 msgid "The input data contains an invalid sequence." msgstr "Vstupní data obsahují neplatnou posloupnost." #: tepl/tepl-encoding-converter.c:377 #, c-format msgid "Error when converting data: %s" msgstr "Chyba při převodu dat: %s" #: tepl/tepl-encoding-converter.c:556 msgid "The input data ends with an incomplete multi-byte sequence." msgstr "Vstupní data končí neúplnou víceznakovou posloupností." #: tepl/tepl-encoding-converter.c:579 msgid "The input content ends with incomplete data." msgstr "Obsah vstupu končí neúplnými daty." #: tepl/tepl-file.c:413 #, c-format msgid "Untitled File %d" msgstr "Nepojmenovaný soubor %d" #: tepl/tepl-file-content-loader.c:331 #, c-format msgid "The file is too big. Maximum %s can be loaded." msgstr "Soubor je příliš velký. Načteno může být nanejvýše %s." #: tepl/tepl-file-loader.c:872 msgid "It is not possible to detect the character encoding automatically." msgstr "Není možné automaticky zjistit kódování znaků." #: tepl/tepl-file-saver.c:784 msgid "The file is externally modified." msgstr "Soubor byl externě změněn." #: tepl/tepl-file-saver.c:1318 msgid "The buffer contains invalid characters." msgstr "Vyrovnávací paměť obsahuje neplatné znaky." #: tepl/tepl-tab.c:534 msgid "Error when loading the file." msgstr "Chyba při načítání souboru." #: tepl/tepl-tab.c:748 msgid "Save File" msgstr "Uložení souboru" #. Translators: location of a file. #: tepl/tepl-tab-label.c:273 msgid "Location:" msgstr "Umístění:" #: tepl/tepl-tab-label.c:342 msgid "Close file" msgstr "Zavřít soubor" #: tepl/tepl-tab-saving.c:64 msgid "Error when saving the file." msgstr "Chyba při ukládání souboru." 07070100000038000081A400000000000000000000000166D2F0DB0000292C000000000000000000000000000000000000001D00000000libgedit-amtk-5.9.0/po/da.po# Danish translation of tepl. # Copyright (C) 2018 Free Software Foundation, Inc. # This file is distributed under the same license as the tepl package. # Joe Hansen <joedalton2@yahoo.dk>, 2018. # msgid "" msgstr "" "Project-Id-Version: tepl\n" "Report-Msgid-Bugs-To: https://bugzilla.gnome.org/enter_bug.cgi?" "product=tepl&keywords=I18N+L10N&component=general\n" "POT-Creation-Date: 2018-02-07 07:03+0000\n" "PO-Revision-Date: 2018-02-24 02:00+0200\n" "Last-Translator: Joe Hansen <joedalton2@yahoo.dk>\n" "Language-Team: Danish <dansk@dansk-gruppen.dk>\n" "Language: da\n" "MIME-Version: 1.0\n" "Content-Type: text/plain; charset=UTF-8\n" "Content-Transfer-Encoding: 8bit\n" #. Translators: %s is a filename. #: amtk/amtk-application-window.c:374 #, c-format msgid "Open “%s”" msgstr "Åbn “%s”" #: amtk/amtk-application-window.c:630 msgid "Open _Recent" msgstr "Åbn _seneste" #. Translators: %s is the application name. #: amtk/amtk-application-window.c:633 #, c-format msgid "Open a file recently used with %s" msgstr "Åbn en fil brugt for nylig med %s" #. action, icon, label, accel, tooltip #. File menu #. Why "file" and not "document"? "Document" is not the best #. word because the action is not always to create a new #. document. For example a LaTeX document can be composed of #. several _files_. Or for source code we do not really create a #. new "document". #: tepl/tepl-application.c:92 msgid "_New" msgstr "_Ny" #: tepl/tepl-application.c:93 msgid "New file" msgstr "Ny fil" #: tepl/tepl-application.c:95 msgid "New _Window" msgstr "Nyt _vindue" #: tepl/tepl-application.c:96 msgid "Create a new window" msgstr "Opret et nyt vindue" #: tepl/tepl-application.c:98 tepl/tepl-application-window.c:178 msgid "_Open" msgstr "_Åbn" #: tepl/tepl-application.c:99 msgid "Open a file" msgstr "Åbn en fil" #: tepl/tepl-application.c:101 tepl/tepl-close-confirm-dialog-single.c:144 #: tepl/tepl-tab.c:752 msgid "_Save" msgstr "_Gem" #: tepl/tepl-application.c:102 msgid "Save the current file" msgstr "Gem den nuværende fil" #: tepl/tepl-application.c:104 msgid "Save _As" msgstr "Gem _som" #: tepl/tepl-application.c:105 msgid "Save the current file to a different location" msgstr "Gem den nuværende fil til en anden placering" #. Edit menu #: tepl/tepl-application.c:109 msgid "_Undo" msgstr "_Genskab" #: tepl/tepl-application.c:110 msgid "Undo the last action" msgstr "Genskab den sidste handling" #: tepl/tepl-application.c:112 msgid "_Redo" msgstr "_Omgør" #: tepl/tepl-application.c:113 msgid "Redo the last undone action" msgstr "Omgør den sidste genskab-handling" #: tepl/tepl-application.c:115 msgid "Cu_t" msgstr "K_lip" #: tepl/tepl-application.c:116 msgid "Cut the selection" msgstr "Klip markeringen" #: tepl/tepl-application.c:118 msgid "_Copy" msgstr "_Kopier" #: tepl/tepl-application.c:119 msgid "Copy the selection" msgstr "Kopier markeringen" #: tepl/tepl-application.c:121 msgid "_Paste" msgstr "_Indsæt" #: tepl/tepl-application.c:122 msgid "Paste the clipboard" msgstr "Indsæt udklipsholderen" #: tepl/tepl-application.c:124 msgid "_Delete" msgstr "_Slet" #: tepl/tepl-application.c:125 msgid "Delete the selected text" msgstr "Slet den markerede tekst" #: tepl/tepl-application.c:127 msgid "Select _All" msgstr "Vælg _alt" #: tepl/tepl-application.c:128 msgid "Select all the text" msgstr "Vælg al teksten" #: tepl/tepl-application.c:130 msgid "_Indent" msgstr "Indr_yk" #: tepl/tepl-application.c:131 msgid "Indent the selected lines" msgstr "Indryk de markerede linjer" #: tepl/tepl-application.c:133 msgid "_Unindent" msgstr "_Fjern indryk" #: tepl/tepl-application.c:134 msgid "Unindent the selected lines" msgstr "Fjern indrykning af de valge linjer" #. Create a GtkFileChooserDialog, not a GtkFileChooserNative, because #. * with GtkFileChooserNative the GFile that we obtain (in flatpak) #. * doesn't have the real path to the file, so it would screw up some #. * features for text editors: #. * - showing the directory in parentheses in the window title, or in the #. * tab tooltip; #. * - opening a recent file. #. * Basically everywhere where the directory is shown. #. #: tepl/tepl-application-window.c:174 msgid "Open File" msgstr "Åbn fil" #: tepl/tepl-application-window.c:177 #: tepl/tepl-close-confirm-dialog-single.c:138 tepl/tepl-tab.c:751 msgid "_Cancel" msgstr "_Annullér" #: tepl/tepl-application-window.c:708 msgid "Read-Only" msgstr "Skrivebeskyttet" #: tepl/tepl-close-confirm-dialog-single.c:133 #, c-format msgid "Save changes to file “%s” before closing?" msgstr "Gem ændringer til filen “%s” før lukning?" #: tepl/tepl-close-confirm-dialog-single.c:137 msgid "Close _without Saving" msgstr "Luk _uden at gemme" #: tepl/tepl-close-confirm-dialog-single.c:150 msgid "_Save As…" msgstr "_Gem som …" #. UTF-8 first, so that it's the first encoding returned by #. * tepl_encoding_get_all(). #. #: tepl/tepl-encoding.c:115 tepl/tepl-encoding.c:132 tepl/tepl-encoding.c:133 #: tepl/tepl-encoding.c:134 tepl/tepl-encoding.c:135 tepl/tepl-encoding.c:136 #: tepl/tepl-encoding.c:137 tepl/tepl-encoding.c:138 msgid "Unicode" msgstr "Unicode" #. FIXME GEOSTD8 ? #: tepl/tepl-encoding.c:117 tepl/tepl-encoding.c:129 tepl/tepl-encoding.c:157 #: tepl/tepl-encoding.c:180 msgid "Western" msgstr "Vestlig" #: tepl/tepl-encoding.c:118 tepl/tepl-encoding.c:158 tepl/tepl-encoding.c:178 msgid "Central European" msgstr "Centraleuropæisk" #: tepl/tepl-encoding.c:119 msgid "South European" msgstr "Sydeuropæisk" #: tepl/tepl-encoding.c:120 tepl/tepl-encoding.c:127 tepl/tepl-encoding.c:185 msgid "Baltic" msgstr "Baltisk" #: tepl/tepl-encoding.c:121 tepl/tepl-encoding.c:159 tepl/tepl-encoding.c:166 #: tepl/tepl-encoding.c:168 tepl/tepl-encoding.c:169 tepl/tepl-encoding.c:179 msgid "Cyrillic" msgstr "Kyrillisk" #: tepl/tepl-encoding.c:122 tepl/tepl-encoding.c:162 tepl/tepl-encoding.c:184 msgid "Arabic" msgstr "Arabisk" #: tepl/tepl-encoding.c:123 tepl/tepl-encoding.c:181 msgid "Greek" msgstr "Græsk" #: tepl/tepl-encoding.c:124 msgid "Hebrew Visual" msgstr "Hebraisk visuelt" #: tepl/tepl-encoding.c:125 tepl/tepl-encoding.c:160 tepl/tepl-encoding.c:182 msgid "Turkish" msgstr "Tyrkisk" #: tepl/tepl-encoding.c:126 msgid "Nordic" msgstr "Nordisk" #: tepl/tepl-encoding.c:128 msgid "Celtic" msgstr "Keltisk" #: tepl/tepl-encoding.c:130 msgid "Romanian" msgstr "Rumænsk" #: tepl/tepl-encoding.c:140 msgid "Armenian" msgstr "Armensk" #: tepl/tepl-encoding.c:141 tepl/tepl-encoding.c:142 tepl/tepl-encoding.c:150 msgid "Chinese Traditional" msgstr "Kinesisk traditionelt" #: tepl/tepl-encoding.c:143 msgid "Cyrillic/Russian" msgstr "Kyrillisk/russisk" #: tepl/tepl-encoding.c:145 tepl/tepl-encoding.c:146 tepl/tepl-encoding.c:147 #: tepl/tepl-encoding.c:164 tepl/tepl-encoding.c:172 msgid "Japanese" msgstr "Japansk" #: tepl/tepl-encoding.c:149 tepl/tepl-encoding.c:165 tepl/tepl-encoding.c:167 #: tepl/tepl-encoding.c:175 msgid "Korean" msgstr "Koreansk" #: tepl/tepl-encoding.c:152 tepl/tepl-encoding.c:153 tepl/tepl-encoding.c:154 msgid "Chinese Simplified" msgstr "Kinesisk forenklet" #: tepl/tepl-encoding.c:155 msgid "Georgian" msgstr "Georgisk" #: tepl/tepl-encoding.c:161 tepl/tepl-encoding.c:183 msgid "Hebrew" msgstr "Hebraisk" #: tepl/tepl-encoding.c:170 msgid "Cyrillic/Ukrainian" msgstr "Kyrillisk/ukrainsk" #: tepl/tepl-encoding.c:173 tepl/tepl-encoding.c:176 tepl/tepl-encoding.c:186 msgid "Vietnamese" msgstr "Vietnamesisk" #: tepl/tepl-encoding.c:174 msgid "Thai" msgstr "Thai" #: tepl/tepl-encoding.c:370 msgid "Unknown" msgstr "Ukendt" #. Translators: This is the sorted list of encodings used by Tepl for #. * automatic detection of the file encoding. You may want to customize #. * it adding encodings that are common in your country, for instance the #. * GB18030 encoding for the Chinese translation. You may also want to #. * remove the ISO-8859-15 encoding (covering English and most Western #. * European languages) if you think people in your country will rarely #. * use it. 'CURRENT' is a magic value used by Tepl and it represents #. * the encoding for the current locale, so please don't translate the #. * 'CURRENT' term. Keep the same format: square brackets, single quotes, #. * commas. #. #: tepl/tepl-encoding.c:695 msgid "['UTF-8', 'CURRENT', 'ISO-8859-15', 'UTF-16']" msgstr "['UTF-8', 'CURRENT', 'ISO-8859-15', 'UTF-16']" #: tepl/tepl-encoding-converter.c:302 #, c-format msgid "Conversion from character set “%s” to “%s” is not supported." msgstr "Konvertering fra tegnsættet “%s” til “%s” er ikke understøttet." #: tepl/tepl-encoding-converter.c:311 #, c-format msgid "Could not open converter from “%s” to “%s”: %s" msgstr "Kunne ikke åbne konverteringsprogram fra “%s” til “%s”: %s" #: tepl/tepl-encoding-converter.c:368 msgid "The input data contains an invalid sequence." msgstr "Inddataene indeholder en ugyldig sekvens." #: tepl/tepl-encoding-converter.c:377 #, c-format msgid "Error when converting data: %s" msgstr "Der opstod en fejl under konvertering af data: %s" #: tepl/tepl-encoding-converter.c:556 msgid "The input data ends with an incomplete multi-byte sequence." msgstr "Inddataene ender med en ufuldstændig multi-byte-sekvens." #: tepl/tepl-encoding-converter.c:579 msgid "The input content ends with incomplete data." msgstr "Inddataindholdet ender med ufuldstændige data." #: tepl/tepl-file.c:413 #, c-format msgid "Untitled File %d" msgstr "Filen %d er uden titel" #: tepl/tepl-file-content-loader.c:331 #, c-format msgid "The file is too big. Maximum %s can be loaded." msgstr "Filen er for stor. Maksimalt %s kan indlæses." #: tepl/tepl-file-loader.c:872 msgid "It is not possible to detect the character encoding automatically." msgstr "Det er ikke muligt at udlede tegnkodningen automatisk." #: tepl/tepl-file-saver.c:784 msgid "The file is externally modified." msgstr "Filen bliver ændret eksternt." #: tepl/tepl-file-saver.c:1318 msgid "The buffer contains invalid characters." msgstr "Mellemlageret indeholder ugyldige tegn." #: tepl/tepl-tab.c:534 msgid "Error when loading the file." msgstr "Fejl under indlæsning af filen." #: tepl/tepl-tab.c:748 msgid "Save File" msgstr "Gem fil" #. Translators: location of a file. #: tepl/tepl-tab-label.c:273 msgid "Location:" msgstr "Placering:" #: tepl/tepl-tab-label.c:342 msgid "Close file" msgstr "Luk fil" #: tepl/tepl-tab-saving.c:64 msgid "Error when saving the file." msgstr "Der opstod en fejl, da filen blev gemt." 07070100000039000081A400000000000000000000000166D2F0DB00002B46000000000000000000000000000000000000001D00000000libgedit-amtk-5.9.0/po/de.po# German translation for tepl. # Copyright (C) YEAR THE PACKAGE'S COPYRIGHT HOLDER # This file is distributed under the same license as the tepl package. # Christian Kirbach <christian.kirbach@gmail.com>, 2017. # Mario Blättermann <mario.blaettermann@gmail.com>, 2017. # Tim Sabsch <tim@sabsch.com>, 2018. # msgid "" msgstr "" "Project-Id-Version: tepl master\n" "Report-Msgid-Bugs-To: https://bugzilla.gnome.org/enter_bug.cgi?" "product=tepl&keywords=I18N+L10N&component=general\n" "POT-Creation-Date: 2017-12-01 09:23+0000\n" "PO-Revision-Date: 2018-02-27 17:06+0100\n" "Last-Translator: Tim Sabsch <tim@sabsch.com>\n" "Language-Team: German <gnome-de@gnome.org>\n" "Language: de\n" "MIME-Version: 1.0\n" "Content-Type: text/plain; charset=UTF-8\n" "Content-Transfer-Encoding: 8bit\n" "X-Generator: Poedit 2.0.6\n" "Plural-Forms: nplurals=2; plural=(n != 1);\n" #. Translators: %s is a filename. #: amtk/amtk-application-window.c:374 #, c-format msgid "Open “%s”" msgstr "»%s« öffnen" #: amtk/amtk-application-window.c:630 msgid "Open _Recent" msgstr "Zu_letzt geöffnet" #. Translators: %s is the application name. #: amtk/amtk-application-window.c:633 #, c-format msgid "Open a file recently used with %s" msgstr "Eine kürzlich von »%s« verwendete Datei öffnen" #. action, icon, label, accel, tooltip #. File menu #. Why "file" and not "document"? "Document" is not the best #. word because the action is not always to create a new #. document. For example a LaTeX document can be composed of #. several _files_. Or for source code we do not really create a #. new "document". #: tepl/tepl-application.c:92 msgid "_New" msgstr "_Neu" #: tepl/tepl-application.c:93 msgid "New file" msgstr "Neue Datei" #: tepl/tepl-application.c:95 msgid "New _Window" msgstr "Neues _Fenster" #: tepl/tepl-application.c:96 msgid "Create a new window" msgstr "Ein neues Fenster öffnen" #: tepl/tepl-application.c:98 tepl/tepl-application-window.c:178 msgid "_Open" msgstr "Ö_ffnen" #: tepl/tepl-application.c:99 msgid "Open a file" msgstr "Eine Datei öffnen" #: tepl/tepl-application.c:101 tepl/tepl-close-confirm-dialog-single.c:144 #: tepl/tepl-tab.c:752 msgid "_Save" msgstr "_Speichern" #: tepl/tepl-application.c:102 msgid "Save the current file" msgstr "Aktuelle Datei speichern" #: tepl/tepl-application.c:104 msgid "Save _As" msgstr "Speichern _unter" #: tepl/tepl-application.c:105 msgid "Save the current file to a different location" msgstr "Datei an einem anderen Ort speichern" #. Edit menu #: tepl/tepl-application.c:109 msgid "_Undo" msgstr "_Rückgängig" #: tepl/tepl-application.c:110 msgid "Undo the last action" msgstr "Letzte Aktion rückgängig machen" #: tepl/tepl-application.c:112 msgid "_Redo" msgstr "_Wiederholen" #: tepl/tepl-application.c:113 msgid "Redo the last undone action" msgstr "Die letzte zurückgenommene Aktion wiederholen" #: tepl/tepl-application.c:115 msgid "Cu_t" msgstr "_Ausschneiden" #: tepl/tepl-application.c:116 msgid "Cut the selection" msgstr "Die Auswahl ausschneiden" #: tepl/tepl-application.c:118 msgid "_Copy" msgstr "_Kopieren" #: tepl/tepl-application.c:119 msgid "Copy the selection" msgstr "Die Auswahl kopieren" #: tepl/tepl-application.c:121 msgid "_Paste" msgstr "_Einfügen" #: tepl/tepl-application.c:122 msgid "Paste the clipboard" msgstr "Den Inhalt der Zwischenablage einfügen" #: tepl/tepl-application.c:124 msgid "_Delete" msgstr "_Löschen" #: tepl/tepl-application.c:125 msgid "Delete the selected text" msgstr "Ausgewählten Text löschen" #: tepl/tepl-application.c:127 msgid "Select _All" msgstr "Alles au_swählen" #: tepl/tepl-application.c:128 msgid "Select all the text" msgstr "Den gesamten Text auswählen" #: tepl/tepl-application.c:130 msgid "_Indent" msgstr "Ein_rücken" #: tepl/tepl-application.c:131 msgid "Indent the selected lines" msgstr "Die ausgewählten Zeilen einrücken" #: tepl/tepl-application.c:133 msgid "_Unindent" msgstr "A_usrücken" #: tepl/tepl-application.c:134 msgid "Unindent the selected lines" msgstr "Die ausgewählten Zeilen ausrücken" #. Create a GtkFileChooserDialog, not a GtkFileChooserNative, because #. * with GtkFileChooserNative the GFile that we obtain (in flatpak) #. * doesn't have the real path to the file, so it would screw up some #. * features for text editors: #. * - showing the directory in parentheses in the window title, or in the #. * tab tooltip; #. * - opening a recent file. #. * Basically everywhere where the directory is shown. #. #: tepl/tepl-application-window.c:174 msgid "Open File" msgstr "Datei öffnen" #: tepl/tepl-application-window.c:177 #: tepl/tepl-close-confirm-dialog-single.c:138 tepl/tepl-tab.c:751 msgid "_Cancel" msgstr "A_bbrechen" #: tepl/tepl-application-window.c:708 msgid "Read-Only" msgstr "Schreibgeschützt" #: tepl/tepl-close-confirm-dialog-single.c:133 #, c-format msgid "Save changes to file “%s” before closing?" msgstr "Änderungen an der Datei »%s« vor dem Schließen speichern?" #: tepl/tepl-close-confirm-dialog-single.c:137 msgid "Close _without Saving" msgstr "Ohne Speichern s_chließen" #: tepl/tepl-close-confirm-dialog-single.c:150 msgid "_Save As…" msgstr "Speichern _unter …" #. UTF-8 first, so that it's the first encoding returned by #. * tepl_encoding_get_all(). #. #: tepl/tepl-encoding.c:115 tepl/tepl-encoding.c:132 tepl/tepl-encoding.c:133 #: tepl/tepl-encoding.c:134 tepl/tepl-encoding.c:135 tepl/tepl-encoding.c:136 #: tepl/tepl-encoding.c:137 tepl/tepl-encoding.c:138 msgid "Unicode" msgstr "Unicode" #. FIXME GEOSTD8 ? #: tepl/tepl-encoding.c:117 tepl/tepl-encoding.c:129 tepl/tepl-encoding.c:157 #: tepl/tepl-encoding.c:180 msgid "Western" msgstr "Westeuropäisch" #: tepl/tepl-encoding.c:118 tepl/tepl-encoding.c:158 tepl/tepl-encoding.c:178 msgid "Central European" msgstr "Mitteleuropäisch" #: tepl/tepl-encoding.c:119 msgid "South European" msgstr "Südeuropäisch" #: tepl/tepl-encoding.c:120 tepl/tepl-encoding.c:127 tepl/tepl-encoding.c:185 msgid "Baltic" msgstr "Baltisch" #: tepl/tepl-encoding.c:121 tepl/tepl-encoding.c:159 tepl/tepl-encoding.c:166 #: tepl/tepl-encoding.c:168 tepl/tepl-encoding.c:169 tepl/tepl-encoding.c:179 msgid "Cyrillic" msgstr "Kyrillisch" #: tepl/tepl-encoding.c:122 tepl/tepl-encoding.c:162 tepl/tepl-encoding.c:184 msgid "Arabic" msgstr "Arabisch" #: tepl/tepl-encoding.c:123 tepl/tepl-encoding.c:181 msgid "Greek" msgstr "Griechisch" #: tepl/tepl-encoding.c:124 msgid "Hebrew Visual" msgstr "Hebräisch (visuell)" #: tepl/tepl-encoding.c:125 tepl/tepl-encoding.c:160 tepl/tepl-encoding.c:182 msgid "Turkish" msgstr "Türkisch" #: tepl/tepl-encoding.c:126 msgid "Nordic" msgstr "Skandinavisch" #: tepl/tepl-encoding.c:128 msgid "Celtic" msgstr "Keltisch" #: tepl/tepl-encoding.c:130 msgid "Romanian" msgstr "Rumänisch" #: tepl/tepl-encoding.c:140 msgid "Armenian" msgstr "Armenisch" #: tepl/tepl-encoding.c:141 tepl/tepl-encoding.c:142 tepl/tepl-encoding.c:150 msgid "Chinese Traditional" msgstr "Chinesisch (traditionell)" #: tepl/tepl-encoding.c:143 msgid "Cyrillic/Russian" msgstr "Kyrillisch/Russisch" #: tepl/tepl-encoding.c:145 tepl/tepl-encoding.c:146 tepl/tepl-encoding.c:147 #: tepl/tepl-encoding.c:164 tepl/tepl-encoding.c:172 msgid "Japanese" msgstr "Japanisch" #: tepl/tepl-encoding.c:149 tepl/tepl-encoding.c:165 tepl/tepl-encoding.c:167 #: tepl/tepl-encoding.c:175 msgid "Korean" msgstr "Koreanisch" #: tepl/tepl-encoding.c:152 tepl/tepl-encoding.c:153 tepl/tepl-encoding.c:154 msgid "Chinese Simplified" msgstr "Chinesisch (vereinfacht)" #: tepl/tepl-encoding.c:155 msgid "Georgian" msgstr "Georgisch" #: tepl/tepl-encoding.c:161 tepl/tepl-encoding.c:183 msgid "Hebrew" msgstr "Hebräisch" #: tepl/tepl-encoding.c:170 msgid "Cyrillic/Ukrainian" msgstr "Kyrillisch/Ukrainisch" #: tepl/tepl-encoding.c:173 tepl/tepl-encoding.c:176 tepl/tepl-encoding.c:186 msgid "Vietnamese" msgstr "Vietnamesisch" #: tepl/tepl-encoding.c:174 msgid "Thai" msgstr "Thailändisch" #: tepl/tepl-encoding.c:370 msgid "Unknown" msgstr "Unbekannt" # translator-comments beachten. #. Translators: This is the sorted list of encodings used by Tepl for #. * automatic detection of the file encoding. You may want to customize #. * it adding encodings that are common in your country, for instance the #. * GB18030 encoding for the Chinese translation. You may also want to #. * remove the ISO-8859-15 encoding (covering English and most Western #. * European languages) if you think people in your country will rarely #. * use it. 'CURRENT' is a magic value used by Tepl and it represents #. * the encoding for the current locale, so please don't translate the #. * 'CURRENT' term. Keep the same format: square brackets, single quotes, #. * commas. #. #: tepl/tepl-encoding.c:695 msgid "['UTF-8', 'CURRENT', 'ISO-8859-15', 'UTF-16']" msgstr "['UTF-8', 'CURRENT', 'ISO-8859-15', 'UTF-16']" #: tepl/tepl-encoding-converter.c:302 #, c-format msgid "Conversion from character set “%s” to “%s” is not supported." msgstr "Umwandlung von Zeichensatz »%s« in »%s« wird nicht unterstützt." #: tepl/tepl-encoding-converter.c:311 #, c-format msgid "Could not open converter from “%s” to “%s”: %s" msgstr "Konverter von »%s« in »%s« konnte nicht geöffnet werden: %s" #: tepl/tepl-encoding-converter.c:368 msgid "The input data contains an invalid sequence." msgstr "Die EIngabedaten enthalten eine ungültige Folge." #: tepl/tepl-encoding-converter.c:377 #, c-format msgid "Error when converting data: %s" msgstr "Fehler beim Konvertieren der Daten: %s" #: tepl/tepl-encoding-converter.c:556 msgid "The input data ends with an incomplete multi-byte sequence." msgstr "Die Eingabedaten endenn mit einer unvollständigen Folge mehrerer Byte." #: tepl/tepl-encoding-converter.c:579 msgid "The input content ends with incomplete data." msgstr "Die Eingabe endet mit unvollständigen Daten." #: tepl/tepl-file.c:413 #, c-format msgid "Untitled File %d" msgstr "Unbenannte Datei %d" #: tepl/tepl-file-content-loader.c:331 #, c-format msgid "The file is too big. Maximum %s can be loaded." msgstr "Die Datei ist zu groß. Es können höchstens %s geladen werden." #: tepl/tepl-file-loader.c:872 msgid "It is not possible to detect the character encoding automatically." msgstr "Die Zeichenkodierung kann nicht automatisch erkannt werden." #: tepl/tepl-file-saver.c:784 msgid "The file is externally modified." msgstr "Die Datei wurde extern verändert." #: tepl/tepl-file-saver.c:1318 msgid "The buffer contains invalid characters." msgstr "Zwischenspeicher enthält ungültige Zeichen." #: tepl/tepl-tab.c:534 msgid "Error when loading the file." msgstr "Beim Laden der Datei trat ein Fehler auf." #: tepl/tepl-tab.c:748 msgid "Save File" msgstr "Datei speichern" #. Translators: location of a file. #: tepl/tepl-tab-label.c:273 msgid "Location:" msgstr "Ort:" #: tepl/tepl-tab-label.c:342 msgid "Close file" msgstr "Datei schließen" #: tepl/tepl-tab-saving.c:64 msgid "Error when saving the file." msgstr "Beim Speichern der Datei trat ein Fehler auf." 0707010000003A000081A400000000000000000000000166D2F0DB000004BE000000000000000000000000000000000000001D00000000libgedit-amtk-5.9.0/po/el.po# Greek translation for amtk. # Copyright (C) 2020 amtk's COPYRIGHT HOLDER # This file is distributed under the same license as the amtk package. # Efstathios Iosifidis <eiosifidis@gnome.org>, 2020. # msgid "" msgstr "" "Project-Id-Version: amtk master\n" "Report-Msgid-Bugs-To: https://gitlab.gnome.org/GNOME/amtk/issues\n" "POT-Creation-Date: 2020-09-28 20:26+0000\n" "PO-Revision-Date: 2020-10-01 01:55+0300\n" "Language-Team: Greek <gnome-el-list@gnome.org>\n" "Language: el\n" "MIME-Version: 1.0\n" "Content-Type: text/plain; charset=UTF-8\n" "Content-Transfer-Encoding: 8bit\n" "Plural-Forms: nplurals=2; plural=(n != 1);\n" "Last-Translator: Efstathios Iosifidis <eiosifidis@gnome.org>\n" "X-Generator: Poedit 2.3\n" #. Translators: %s is a filename. #: amtk/amtk-application-window.c:374 #, c-format msgid "Open “%s”" msgstr "Άνοιγμα «%s»" #: amtk/amtk-application-window.c:630 msgid "Open _Recent" msgstr "Άνοιγμα _πρόσφατου" #. Translators: %s is the application name. #: amtk/amtk-application-window.c:633 #, c-format msgid "Open a file recently used with %s" msgstr "Άνοιγμα ενός αρχείου που χρησιμοποιήθηκε πρόσφατα με %s" 0707010000003B000081A400000000000000000000000166D2F0DB00000461000000000000000000000000000000000000002000000000libgedit-amtk-5.9.0/po/en_GB.po# British English translation for amtk. # Copyright (C) 2019 amtk's COPYRIGHT HOLDER # This file is distributed under the same license as the amtk package. # Zander Brown <zbrown@gnome.org>, 2019. # msgid "" msgstr "" "Project-Id-Version: amtk master\n" "Report-Msgid-Bugs-To: https://gitlab.gnome.org/GNOME/amtk/issues\n" "POT-Creation-Date: 2019-03-16 13:53+0000\n" "PO-Revision-Date: 2019-08-23 21:54+0100\n" "Last-Translator: Zander Brown <zbrown@gnome.org>\n" "Language-Team: English - United Kingdom <en_GB@li.org>\n" "Language: en_GB\n" "MIME-Version: 1.0\n" "Content-Type: text/plain; charset=UTF-8\n" "Content-Transfer-Encoding: 8bit\n" "Plural-Forms: nplurals=2; plural=(n != 1);\n" "X-Generator: Gtranslator 3.32.1\n" #. Translators: %s is a filename. #: amtk/amtk-application-window.c:374 #, c-format msgid "Open “%s”" msgstr "Open “%s”" #: amtk/amtk-application-window.c:630 msgid "Open _Recent" msgstr "Open _Recent" #. Translators: %s is the application name. #: amtk/amtk-application-window.c:633 #, c-format msgid "Open a file recently used with %s" msgstr "Open a recently used file with %s" 0707010000003C000081A400000000000000000000000166D2F0DB00002A8B000000000000000000000000000000000000001D00000000libgedit-amtk-5.9.0/po/es.po# Spanish translation for tepl. # Copyright (C) 2017 tepl's COPYRIGHT HOLDER # This file is distributed under the same license as the tepl package. # Daniel Mustieles <daniel.mustieles@gmail.com>, 2017. # msgid "" msgstr "" "Project-Id-Version: tepl master\n" "Report-Msgid-Bugs-To: https://bugzilla.gnome.org/enter_bug.cgi?" "product=tepl&keywords=I18N+L10N&component=general\n" "POT-Creation-Date: 2017-12-01 09:23+0000\n" "PO-Revision-Date: 2017-12-14 14:15+0100\n" "Last-Translator: Daniel Mustieles <daniel.mustieles@gmail.com>\n" "Language-Team: es <gnome-es-list@gnome.org>\n" "Language: es\n" "MIME-Version: 1.0\n" "Content-Type: text/plain; charset=UTF-8\n" "Content-Transfer-Encoding: 8bit\n" "Plural-Forms: nplurals=2; plural=(n != 1);\n" "X-Generator: Gtranslator 2.91.6\n" #. Translators: %s is a filename. #: amtk/amtk-application-window.c:374 #, c-format msgid "Open “%s”" msgstr "Abrir «%s»" #: amtk/amtk-application-window.c:630 msgid "Open _Recent" msgstr "Abir _reciente" #. Translators: %s is the application name. #: amtk/amtk-application-window.c:633 #, c-format msgid "Open a file recently used with %s" msgstr "Abrir un archivo usado recientemente con %s" #. action, icon, label, accel, tooltip #. File menu #. Why "file" and not "document"? "Document" is not the best #. word because the action is not always to create a new #. document. For example a LaTeX document can be composed of #. several _files_. Or for source code we do not really create a #. new "document". #: tepl/tepl-application.c:92 msgid "_New" msgstr "_Nuevo" #: tepl/tepl-application.c:93 msgid "New file" msgstr "Archivo nuevo" #: tepl/tepl-application.c:95 msgid "New _Window" msgstr "_Ventana nueva" #: tepl/tepl-application.c:96 msgid "Create a new window" msgstr "Crear una ventana nueva" #: tepl/tepl-application.c:98 tepl/tepl-application-window.c:178 msgid "_Open" msgstr "Ab_rir" #: tepl/tepl-application.c:99 msgid "Open a file" msgstr "Abrir un archivo" #: tepl/tepl-application.c:101 tepl/tepl-close-confirm-dialog-single.c:144 #: tepl/tepl-tab.c:752 msgid "_Save" msgstr "_Guardar" #: tepl/tepl-application.c:102 msgid "Save the current file" msgstr "Guardar el archivo actual" #: tepl/tepl-application.c:104 msgid "Save _As" msgstr "Guardar _como" #: tepl/tepl-application.c:105 msgid "Save the current file to a different location" msgstr "Guarda el archivo actual en un lugar diferente" #. Edit menu #: tepl/tepl-application.c:109 msgid "_Undo" msgstr "Des_hacer" #: tepl/tepl-application.c:110 msgid "Undo the last action" msgstr "Deshace la última acción" #: tepl/tepl-application.c:112 msgid "_Redo" msgstr "_Rehacer" #: tepl/tepl-application.c:113 msgid "Redo the last undone action" msgstr "Rehacer la última acción deshecha" #: tepl/tepl-application.c:115 msgid "Cu_t" msgstr "C_ortar" #: tepl/tepl-application.c:116 msgid "Cut the selection" msgstr "Cortar la selección" #: tepl/tepl-application.c:118 msgid "_Copy" msgstr "_Copiar" #: tepl/tepl-application.c:119 msgid "Copy the selection" msgstr "Copiar la selección" #: tepl/tepl-application.c:121 msgid "_Paste" msgstr "_Pegar" #: tepl/tepl-application.c:122 msgid "Paste the clipboard" msgstr "Pegar del portapapeles" #: tepl/tepl-application.c:124 msgid "_Delete" msgstr "_Eliminar" #: tepl/tepl-application.c:125 msgid "Delete the selected text" msgstr "Eliminar el texto seleccionado" #: tepl/tepl-application.c:127 msgid "Select _All" msgstr "Seleccionar _todo" #: tepl/tepl-application.c:128 msgid "Select all the text" msgstr "Seleccionar todo el texto" #: tepl/tepl-application.c:130 msgid "_Indent" msgstr "_Sangrar" #: tepl/tepl-application.c:131 msgid "Indent the selected lines" msgstr "Sangrar las líneas seleccionadas" #: tepl/tepl-application.c:133 msgid "_Unindent" msgstr "Qui_tar sangrado" #: tepl/tepl-application.c:134 msgid "Unindent the selected lines" msgstr "Quitar sangrado de las líneas seleccionadas" #. Create a GtkFileChooserDialog, not a GtkFileChooserNative, because #. * with GtkFileChooserNative the GFile that we obtain (in flatpak) #. * doesn't have the real path to the file, so it would screw up some #. * features for text editors: #. * - showing the directory in parentheses in the window title, or in the #. * tab tooltip; #. * - opening a recent file. #. * Basically everywhere where the directory is shown. #. #: tepl/tepl-application-window.c:174 msgid "Open File" msgstr "Abrir archivo" #: tepl/tepl-application-window.c:177 #: tepl/tepl-close-confirm-dialog-single.c:138 tepl/tepl-tab.c:751 msgid "_Cancel" msgstr "_Cancelar" #: tepl/tepl-application-window.c:708 msgid "Read-Only" msgstr "Sólo lectura" #: tepl/tepl-close-confirm-dialog-single.c:133 #, c-format msgid "Save changes to file “%s” before closing?" msgstr "¿Quiere guardar los cambios en el archivo «%s» antes de cerrar?" #: tepl/tepl-close-confirm-dialog-single.c:137 msgid "Close _without Saving" msgstr "Cerrar _sin guardar" #: tepl/tepl-close-confirm-dialog-single.c:150 #| msgid "Save _As" msgid "_Save As…" msgstr "Guardar _como…" #. UTF-8 first, so that it's the first encoding returned by #. * tepl_encoding_get_all(). #. #: tepl/tepl-encoding.c:115 tepl/tepl-encoding.c:132 tepl/tepl-encoding.c:133 #: tepl/tepl-encoding.c:134 tepl/tepl-encoding.c:135 tepl/tepl-encoding.c:136 #: tepl/tepl-encoding.c:137 tepl/tepl-encoding.c:138 msgid "Unicode" msgstr "Unicode" #. FIXME GEOSTD8 ? #: tepl/tepl-encoding.c:117 tepl/tepl-encoding.c:129 tepl/tepl-encoding.c:157 #: tepl/tepl-encoding.c:180 msgid "Western" msgstr "Occidental" #: tepl/tepl-encoding.c:118 tepl/tepl-encoding.c:158 tepl/tepl-encoding.c:178 msgid "Central European" msgstr "Europa central" #: tepl/tepl-encoding.c:119 msgid "South European" msgstr "Europa del sur" #: tepl/tepl-encoding.c:120 tepl/tepl-encoding.c:127 tepl/tepl-encoding.c:185 msgid "Baltic" msgstr "Báltico" #: tepl/tepl-encoding.c:121 tepl/tepl-encoding.c:159 tepl/tepl-encoding.c:166 #: tepl/tepl-encoding.c:168 tepl/tepl-encoding.c:169 tepl/tepl-encoding.c:179 msgid "Cyrillic" msgstr "Cirílico" #: tepl/tepl-encoding.c:122 tepl/tepl-encoding.c:162 tepl/tepl-encoding.c:184 msgid "Arabic" msgstr "Árabe" #: tepl/tepl-encoding.c:123 tepl/tepl-encoding.c:181 msgid "Greek" msgstr "Griego" #: tepl/tepl-encoding.c:124 msgid "Hebrew Visual" msgstr "Hebreo visual" #: tepl/tepl-encoding.c:125 tepl/tepl-encoding.c:160 tepl/tepl-encoding.c:182 msgid "Turkish" msgstr "Turco" #: tepl/tepl-encoding.c:126 msgid "Nordic" msgstr "Nórdico" #: tepl/tepl-encoding.c:128 msgid "Celtic" msgstr "Celta" #: tepl/tepl-encoding.c:130 msgid "Romanian" msgstr "Rumano" #: tepl/tepl-encoding.c:140 msgid "Armenian" msgstr "Armenio" #: tepl/tepl-encoding.c:141 tepl/tepl-encoding.c:142 tepl/tepl-encoding.c:150 msgid "Chinese Traditional" msgstr "Chino tradicional" #: tepl/tepl-encoding.c:143 msgid "Cyrillic/Russian" msgstr "Cirílico/Ruso" #: tepl/tepl-encoding.c:145 tepl/tepl-encoding.c:146 tepl/tepl-encoding.c:147 #: tepl/tepl-encoding.c:164 tepl/tepl-encoding.c:172 msgid "Japanese" msgstr "Japones" #: tepl/tepl-encoding.c:149 tepl/tepl-encoding.c:165 tepl/tepl-encoding.c:167 #: tepl/tepl-encoding.c:175 msgid "Korean" msgstr "Coreano" #: tepl/tepl-encoding.c:152 tepl/tepl-encoding.c:153 tepl/tepl-encoding.c:154 msgid "Chinese Simplified" msgstr "Chino simplificado" #: tepl/tepl-encoding.c:155 msgid "Georgian" msgstr "Georgiano" #: tepl/tepl-encoding.c:161 tepl/tepl-encoding.c:183 msgid "Hebrew" msgstr "Hebreo" #: tepl/tepl-encoding.c:170 msgid "Cyrillic/Ukrainian" msgstr "Cirílico/Ucraniano" #: tepl/tepl-encoding.c:173 tepl/tepl-encoding.c:176 tepl/tepl-encoding.c:186 msgid "Vietnamese" msgstr "Vietnamita" #: tepl/tepl-encoding.c:174 msgid "Thai" msgstr "Tailandés" #: tepl/tepl-encoding.c:370 msgid "Unknown" msgstr "Desconocido" #. Translators: This is the sorted list of encodings used by Tepl for #. * automatic detection of the file encoding. You may want to customize #. * it adding encodings that are common in your country, for instance the #. * GB18030 encoding for the Chinese translation. You may also want to #. * remove the ISO-8859-15 encoding (covering English and most Western #. * European languages) if you think people in your country will rarely #. * use it. 'CURRENT' is a magic value used by Tepl and it represents #. * the encoding for the current locale, so please don't translate the #. * 'CURRENT' term. Keep the same format: square brackets, single quotes, #. * commas. #. #: tepl/tepl-encoding.c:695 msgid "['UTF-8', 'CURRENT', 'ISO-8859-15', 'UTF-16']" msgstr "['UTF-8', 'CURRENT', 'ISO-8859-15', 'UTF-16']" #: tepl/tepl-encoding-converter.c:302 #, c-format msgid "Conversion from character set “%s” to “%s” is not supported." msgstr "" "La conversión desde el conjunto de caracteres «%s» a «%s» no está soportada." #: tepl/tepl-encoding-converter.c:311 #, c-format msgid "Could not open converter from “%s” to “%s”: %s" msgstr "No se pudo abrir el conversor de «%s» a «%s»: %s" #: tepl/tepl-encoding-converter.c:368 msgid "The input data contains an invalid sequence." msgstr "Los datos de entrada contienen una secuencia no válida." #: tepl/tepl-encoding-converter.c:377 #, c-format msgid "Error when converting data: %s" msgstr "Error al convertir los datos: %s" #: tepl/tepl-encoding-converter.c:556 msgid "The input data ends with an incomplete multi-byte sequence." msgstr "" "Los datos de entrada terminan con una secuencia de varios bytes incompleta." #: tepl/tepl-encoding-converter.c:579 msgid "The input content ends with incomplete data." msgstr "El contenido de la entrada termina con datos incompletos." #: tepl/tepl-file.c:413 #, c-format msgid "Untitled File %d" msgstr "Archivo sin título %d" #: tepl/tepl-file-content-loader.c:331 #, c-format msgid "The file is too big. Maximum %s can be loaded." msgstr "El archivo es demasiado grande. Sólo se puede cargar un máximo de %s." #: tepl/tepl-file-loader.c:872 msgid "It is not possible to detect the character encoding automatically." msgstr "No es posible detectar la codificación de caracteres automáticamente." #: tepl/tepl-file-saver.c:784 msgid "The file is externally modified." msgstr "El archivo se ha modificado externamente." #: tepl/tepl-file-saver.c:1318 msgid "The buffer contains invalid characters." msgstr "El búfer contiene caracteres no válidos." #: tepl/tepl-tab.c:534 msgid "Error when loading the file." msgstr "Error al cargar el archivo." #: tepl/tepl-tab.c:748 msgid "Save File" msgstr "Guardar archivo" #. Translators: location of a file. #: tepl/tepl-tab-label.c:273 msgid "Location:" msgstr "Ubicación:" #: tepl/tepl-tab-label.c:342 #| msgid "New file" msgid "Close file" msgstr "Cerrar archivo" #: tepl/tepl-tab-saving.c:64 msgid "Error when saving the file." msgstr "Error al guardar el archivo." 0707010000003D000081A400000000000000000000000166D2F0DB00000439000000000000000000000000000000000000001D00000000libgedit-amtk-5.9.0/po/eu.po# Basque translation for amtk. # Copyright (C) 2019 amtk's COPYRIGHT HOLDER # This file is distributed under the same license as the amtk package. # Asier Sarasua Garmendia <asier.sarasua@gmail.com>, 2019. # msgid "" msgstr "" "Project-Id-Version: amtk master\n" "Report-Msgid-Bugs-To: https://gitlab.gnome.org/GNOME/amtk/issues\n" "POT-Creation-Date: 2019-09-06 16:25+0000\n" "PO-Revision-Date: 2019-09-15 10:00+0100\n" "Last-Translator: Asier Sarasua Garmendia <asier.sarasua@gmail.com>\n" "Language-Team: Basque <librezale@librezale.eus>\n" "Language: eu\n" "MIME-Version: 1.0\n" "Content-Type: text/plain; charset=UTF-8\n" "Content-Transfer-Encoding: 8bit\n" #. Translators: %s is a filename. #: amtk/amtk-application-window.c:374 #, c-format msgid "Open “%s”" msgstr "Ireki “%s”" #: amtk/amtk-application-window.c:630 msgid "Open _Recent" msgstr "Ireki _oraintsukoa" #. Translators: %s is the application name. #: amtk/amtk-application-window.c:633 #, c-format msgid "Open a file recently used with %s" msgstr "Ireki berriki erabilitako fitxategi bat %s erabilita" 0707010000003E000081A400000000000000000000000166D2F0DB00000480000000000000000000000000000000000000001D00000000libgedit-amtk-5.9.0/po/fr.po# French translation for amtk. # Copyright (C) 2018 amtk's COPYRIGHT HOLDER # This file is distributed under the same license as the amtk package. # Charles Monzat <charles.monzat@numericable.fr>, 2018. # msgid "" msgstr "" "Project-Id-Version: amtk master\n" "Report-Msgid-Bugs-To: https://gitlab.gnome.org/GNOME/amtk/issues\n" "POT-Creation-Date: 2018-08-12 11:12+0000\n" "PO-Revision-Date: 2018-08-30 15:27+0200\n" "Last-Translator: Charles Monzat <charles.monzat@numericable.fr>\n" "Language-Team: français <gnomefr@traduc.org>\n" "Language: fr\n" "MIME-Version: 1.0\n" "Content-Type: text/plain; charset=UTF-8\n" "Content-Transfer-Encoding: 8bit\n" "Plural-Forms: nplurals=2; plural=(n > 1);\n" "X-Generator: Gtranslator 2.91.7\n" #. Translators: %s is a filename. #: amtk/amtk-application-window.c:374 #, c-format msgid "Open “%s”" msgstr "Ouvrir « %s »" #: amtk/amtk-application-window.c:630 msgid "Open _Recent" msgstr "_Récemment ouverts" #. Translators: %s is the application name. #: amtk/amtk-application-window.c:633 #, c-format msgid "Open a file recently used with %s" msgstr "Ouvrir un fichier récemment utilisé avec %s" 0707010000003F000081A400000000000000000000000166D2F0DB000018A1000000000000000000000000000000000000001E00000000libgedit-amtk-5.9.0/po/fur.po# Friulian translation for tepl. # Copyright (C) 2017 tepl's COPYRIGHT HOLDER # This file is distributed under the same license as the tepl package. # Fabio Tomat <f.t.public@gmail.com>, 2017. # msgid "" msgstr "" "Project-Id-Version: tepl master\n" "Report-Msgid-Bugs-To: \n" "POT-Creation-Date: 2017-04-03 05:53+0000\n" "PO-Revision-Date: 2017-04-08 20:42+0200\n" "Language-Team: Friulian <fur@li.org>\n" "Language: fur\n" "MIME-Version: 1.0\n" "Content-Type: text/plain; charset=UTF-8\n" "Content-Transfer-Encoding: 8bit\n" "Last-Translator: Fabio Tomat <f.t.public@gmail.com>\n" "X-Generator: Poedit 1.8.12\n" #. Translators: %s is a filename. #: tepl/tepl-application-window.c:356 #, c-format msgid "Open “%s”" msgstr "Vierç “%s”" #: tepl/tepl-application-window.c:575 msgid "Open _Recent" msgstr "Vierç _resint" #. Translators: %s is the application name. #: tepl/tepl-application-window.c:578 #, c-format msgid "Open a file recently used with %s" msgstr "Vierç un file doprât di resint cun %s" #. UTF-8 first, so that it's the first encoding returned by #. * tepl_encoding_get_all(). #. #: tepl/tepl-encoding.c:115 tepl/tepl-encoding.c:132 tepl/tepl-encoding.c:133 #: tepl/tepl-encoding.c:134 tepl/tepl-encoding.c:135 tepl/tepl-encoding.c:136 #: tepl/tepl-encoding.c:137 tepl/tepl-encoding.c:138 msgid "Unicode" msgstr "Unicode" #. FIXME GEOSTD8 ? #: tepl/tepl-encoding.c:117 tepl/tepl-encoding.c:129 tepl/tepl-encoding.c:157 #: tepl/tepl-encoding.c:180 msgid "Western" msgstr "Ocidentâl" #: tepl/tepl-encoding.c:118 tepl/tepl-encoding.c:158 tepl/tepl-encoding.c:178 msgid "Central European" msgstr "European centrâl" #: tepl/tepl-encoding.c:119 msgid "South European" msgstr "European dal sud" #: tepl/tepl-encoding.c:120 tepl/tepl-encoding.c:127 tepl/tepl-encoding.c:185 msgid "Baltic" msgstr "Baltic" #: tepl/tepl-encoding.c:121 tepl/tepl-encoding.c:159 tepl/tepl-encoding.c:166 #: tepl/tepl-encoding.c:168 tepl/tepl-encoding.c:169 tepl/tepl-encoding.c:179 msgid "Cyrillic" msgstr "Cirilic" #: tepl/tepl-encoding.c:122 tepl/tepl-encoding.c:162 tepl/tepl-encoding.c:184 msgid "Arabic" msgstr "Arap" #: tepl/tepl-encoding.c:123 tepl/tepl-encoding.c:181 msgid "Greek" msgstr "Grêc" #: tepl/tepl-encoding.c:124 msgid "Hebrew Visual" msgstr "Ebraic Visuâl" #: tepl/tepl-encoding.c:125 tepl/tepl-encoding.c:160 tepl/tepl-encoding.c:182 msgid "Turkish" msgstr "Turc" #: tepl/tepl-encoding.c:126 msgid "Nordic" msgstr "Nordic" #: tepl/tepl-encoding.c:128 msgid "Celtic" msgstr "Celtic" #: tepl/tepl-encoding.c:130 msgid "Romanian" msgstr "Rumen" #: tepl/tepl-encoding.c:140 msgid "Armenian" msgstr "Armen" #: tepl/tepl-encoding.c:141 tepl/tepl-encoding.c:142 tepl/tepl-encoding.c:150 msgid "Chinese Traditional" msgstr "Cinês tradizionâl" #: tepl/tepl-encoding.c:143 msgid "Cyrillic/Russian" msgstr "Cirilic/Rus" #: tepl/tepl-encoding.c:145 tepl/tepl-encoding.c:146 tepl/tepl-encoding.c:147 #: tepl/tepl-encoding.c:164 tepl/tepl-encoding.c:172 msgid "Japanese" msgstr "Gjaponês" #: tepl/tepl-encoding.c:149 tepl/tepl-encoding.c:165 tepl/tepl-encoding.c:167 #: tepl/tepl-encoding.c:175 msgid "Korean" msgstr "Corean" #: tepl/tepl-encoding.c:152 tepl/tepl-encoding.c:153 tepl/tepl-encoding.c:154 msgid "Chinese Simplified" msgstr "Cinês semplificât" #: tepl/tepl-encoding.c:155 msgid "Georgian" msgstr "Gjeorgjan" #: tepl/tepl-encoding.c:161 tepl/tepl-encoding.c:183 msgid "Hebrew" msgstr "Ebraic" #: tepl/tepl-encoding.c:170 msgid "Cyrillic/Ukrainian" msgstr "Cirilic/Ucrain" #: tepl/tepl-encoding.c:173 tepl/tepl-encoding.c:176 tepl/tepl-encoding.c:186 msgid "Vietnamese" msgstr "Vietnamît" #: tepl/tepl-encoding.c:174 msgid "Thai" msgstr "Tailandês" #: tepl/tepl-encoding.c:365 msgid "Unknown" msgstr "No cognossût" #. Translators: This is the sorted list of encodings used by Tepl for #. * automatic detection of the file encoding. You may want to customize #. * it adding encodings that are common in your country, for instance the #. * GB18030 encoding for the Chinese translation. You may also want to #. * remove the ISO-8859-15 encoding (covering English and most Western #. * European languages) if you think people in your country will rarely #. * use it. 'CURRENT' is a magic value used by Tepl and it represents #. * the encoding for the current locale, so please don't translate the #. * 'CURRENT' term. Keep the same format: square brackets, single quotes, #. * commas. #. #: tepl/tepl-encoding.c:640 msgid "['UTF-8', 'CURRENT', 'ISO-8859-15', 'UTF-16']" msgstr "['UTF-8', 'CURRENT', 'ISO-8859-15', 'UTF-16']" #: tepl/tepl-encoding-converter.c:302 #, c-format msgid "Conversion from character set “%s” to “%s” is not supported." msgstr "La conversion de cumbinazion di caratars “%s” a “%s” no je supuartade." #: tepl/tepl-encoding-converter.c:311 #, c-format msgid "Could not open converter from “%s” to “%s”: %s" msgstr "Impussibil convertî di “%s” a “%s”: %s" #: tepl/tepl-encoding-converter.c:368 msgid "The input data contains an invalid sequence." msgstr "I dâts in jentrade a contegnin une secuence no valide." #: tepl/tepl-encoding-converter.c:377 #, c-format msgid "Error when converting data: %s" msgstr "Erôr tal convertî i dâts: %s" #: tepl/tepl-encoding-converter.c:556 msgid "The input data ends with an incomplete multi-byte sequence." msgstr "I dâts in jentrade a finissin cuntune secuence di byte multiplis incomplete." #: tepl/tepl-encoding-converter.c:579 msgid "The input content ends with incomplete data." msgstr "Il contignût de jentrade al finìs cun dâts incomplets." #: tepl/tepl-file.c:413 #, c-format msgid "Untitled File %d" msgstr "File cence titul %d" #: tepl/tepl-file-content-loader.c:334 #, c-format msgid "The file is too big. Maximum %s can be loaded." msgstr "Il file al è masse grant. Si pues cjariâ al massim %s." #: tepl/tepl-file-loader.c:925 msgid "It is not possible to detect the character encoding automatically." msgstr "Nol è pussibil individuâ la codifiche dal caratar in automatic." #: tepl/tepl-file-saver.c:784 msgid "The file is externally modified." msgstr "Il file al è modificât di difûr di chi." #: tepl/tepl-file-saver.c:1318 msgid "The buffer contains invalid characters." msgstr "Il buffer al conten caratars no valits." 07070100000040000081A400000000000000000000000166D2F0DB0000048D000000000000000000000000000000000000001D00000000libgedit-amtk-5.9.0/po/hr.po# Croatian translation for amtk. # Copyright (C) 2020 amtk's COPYRIGHT HOLDER # This file is distributed under the same license as the amtk package. # FIRST AUTHOR <EMAIL@ADDRESS>, YEAR. # msgid "" msgstr "" "Project-Id-Version: amtk master\n" "Report-Msgid-Bugs-To: https://gitlab.gnome.org/GNOME/amtk/issues\n" "POT-Creation-Date: 2020-09-13 12:36+0000\n" "PO-Revision-Date: 2020-09-13 14:37+0200\n" "Last-Translator: gogo <trebelnik2@gmail.com>\n" "Language-Team: Croatian <hr@li.org>\n" "Language: hr\n" "MIME-Version: 1.0\n" "Content-Type: text/plain; charset=UTF-8\n" "Content-Transfer-Encoding: 8bit\n" "Plural-Forms: nplurals=3; plural=(n%10==1 && n%100!=11 ? 0 : n%10>=2 && n" "%10<=4 && (n%100<10 || n%100>=20) ? 1 : 2);\n" "X-Generator: Poedit 2.3\n" #. Translators: %s is a filename. #: amtk/amtk-application-window.c:374 #, c-format msgid "Open “%s”" msgstr "Otvori “%s”" #: amtk/amtk-application-window.c:630 msgid "Open _Recent" msgstr "Otvori _nedavno" #. Translators: %s is the application name. #: amtk/amtk-application-window.c:633 #, c-format msgid "Open a file recently used with %s" msgstr "Otvori nedavno korištenu datoteku s %s" 07070100000041000081A400000000000000000000000166D2F0DB00002AE3000000000000000000000000000000000000001D00000000libgedit-amtk-5.9.0/po/hu.po# Hungarian translation for tepl. # Copyright (C) 2017, 2018 Free Software Foundation, Inc. # This file is distributed under the same license as the tepl package. # # Balázs Úr <urbalazs at gmail dot com>, 2017, 2018. msgid "" msgstr "" "Project-Id-Version: tepl master\n" "Report-Msgid-Bugs-To: https://bugzilla.gnome.org/enter_bug.cgi?" "product=tepl&keywords=I18N+L10N&component=general\n" "POT-Creation-Date: 2017-12-01 09:23+0000\n" "PO-Revision-Date: 2018-02-26 23:33+0100\n" "Last-Translator: Balázs Úr <urbalazs@gmail.com>\n" "Language-Team: Hungarian <openscope at googlegroups dot com>\n" "Language: hu\n" "MIME-Version: 1.0\n" "Content-Type: text/plain; charset=UTF-8\n" "Content-Transfer-Encoding: 8bit\n" "Plural-Forms: nplurals=2; plural=(n != 1);\n" "X-Generator: Lokalize 1.2\n" #. Translators: %s is a filename. #: amtk/amtk-application-window.c:374 #, c-format msgid "Open “%s”" msgstr "„%s” megnyitása" #: amtk/amtk-application-window.c:630 msgid "Open _Recent" msgstr "_Legutóbbi megnyitása" #. Translators: %s is the application name. #: amtk/amtk-application-window.c:633 #, c-format msgid "Open a file recently used with %s" msgstr "A(z) %s alkalmazással legutóbb használt fájl megnyitása" #. action, icon, label, accel, tooltip #. File menu #. Why "file" and not "document"? "Document" is not the best #. word because the action is not always to create a new #. document. For example a LaTeX document can be composed of #. several _files_. Or for source code we do not really create a #. new "document". #: tepl/tepl-application.c:92 msgid "_New" msgstr "Ú_j" #: tepl/tepl-application.c:93 msgid "New file" msgstr "Új fájl" #: tepl/tepl-application.c:95 msgid "New _Window" msgstr "Új _ablak" #: tepl/tepl-application.c:96 msgid "Create a new window" msgstr "Új ablak létrehozása" #: tepl/tepl-application.c:98 tepl/tepl-application-window.c:178 msgid "_Open" msgstr "_Megnyitás" #: tepl/tepl-application.c:99 msgid "Open a file" msgstr "Fájl megnyitása" #: tepl/tepl-application.c:101 tepl/tepl-close-confirm-dialog-single.c:144 #: tepl/tepl-tab.c:752 msgid "_Save" msgstr "M_entés" #: tepl/tepl-application.c:102 msgid "Save the current file" msgstr "Jelenlegi fájl mentése" #: tepl/tepl-application.c:104 msgid "Save _As" msgstr "Men_tés másként" #: tepl/tepl-application.c:105 msgid "Save the current file to a different location" msgstr "Jelenlegi fájl mentése egy másik helyre" #. Edit menu #: tepl/tepl-application.c:109 msgid "_Undo" msgstr "V_isszavonás" #: tepl/tepl-application.c:110 msgid "Undo the last action" msgstr "Az utolsó művelet visszavonása" #: tepl/tepl-application.c:112 msgid "_Redo" msgstr "Új_ra" #: tepl/tepl-application.c:113 msgid "Redo the last undone action" msgstr "A visszavont művelet ismételt végrehajtása" #: tepl/tepl-application.c:115 msgid "Cu_t" msgstr "_Kivágás" #: tepl/tepl-application.c:116 msgid "Cut the selection" msgstr "A kijelölés kivágása" #: tepl/tepl-application.c:118 msgid "_Copy" msgstr "_Másolás" #: tepl/tepl-application.c:119 msgid "Copy the selection" msgstr "A kijelölés másolása" #: tepl/tepl-application.c:121 msgid "_Paste" msgstr "_Beillesztés" #: tepl/tepl-application.c:122 msgid "Paste the clipboard" msgstr "A vágólap tartalmának beillesztése" #: tepl/tepl-application.c:124 msgid "_Delete" msgstr "_Törlés" #: tepl/tepl-application.c:125 msgid "Delete the selected text" msgstr "A kijelölt szöveg törlése" #: tepl/tepl-application.c:127 msgid "Select _All" msgstr "Az össz_es kijelölése" #: tepl/tepl-application.c:128 msgid "Select all the text" msgstr "Az összes szöveg kijelölése" #: tepl/tepl-application.c:130 msgid "_Indent" msgstr "_Behúzás" #: tepl/tepl-application.c:131 msgid "Indent the selected lines" msgstr "A kijelölt sorok behúzása" #: tepl/tepl-application.c:133 msgid "_Unindent" msgstr "Behúzás _visszavonása" #: tepl/tepl-application.c:134 msgid "Unindent the selected lines" msgstr "A kijelölt sorok behúzásának visszavonása" #. Create a GtkFileChooserDialog, not a GtkFileChooserNative, because #. * with GtkFileChooserNative the GFile that we obtain (in flatpak) #. * doesn't have the real path to the file, so it would screw up some #. * features for text editors: #. * - showing the directory in parentheses in the window title, or in the #. * tab tooltip; #. * - opening a recent file. #. * Basically everywhere where the directory is shown. #. #: tepl/tepl-application-window.c:174 msgid "Open File" msgstr "Fájl megnyitása" #: tepl/tepl-application-window.c:177 #: tepl/tepl-close-confirm-dialog-single.c:138 tepl/tepl-tab.c:751 msgid "_Cancel" msgstr "_Mégse" #: tepl/tepl-application-window.c:708 msgid "Read-Only" msgstr "Írásvédett" #: tepl/tepl-close-confirm-dialog-single.c:133 #, c-format msgid "Save changes to file “%s” before closing?" msgstr "Menti a változtatásokat a(z) „%s” fájlba bezárás előtt?" #: tepl/tepl-close-confirm-dialog-single.c:137 msgid "Close _without Saving" msgstr "Bezárás mentés _nélkül" #: tepl/tepl-close-confirm-dialog-single.c:150 msgid "_Save As…" msgstr "M_entés másként…" #. UTF-8 first, so that it's the first encoding returned by #. * tepl_encoding_get_all(). #. #: tepl/tepl-encoding.c:115 tepl/tepl-encoding.c:132 tepl/tepl-encoding.c:133 #: tepl/tepl-encoding.c:134 tepl/tepl-encoding.c:135 tepl/tepl-encoding.c:136 #: tepl/tepl-encoding.c:137 tepl/tepl-encoding.c:138 msgid "Unicode" msgstr "Unicode" #. FIXME GEOSTD8 ? #: tepl/tepl-encoding.c:117 tepl/tepl-encoding.c:129 tepl/tepl-encoding.c:157 #: tepl/tepl-encoding.c:180 msgid "Western" msgstr "Nyugati" #: tepl/tepl-encoding.c:118 tepl/tepl-encoding.c:158 tepl/tepl-encoding.c:178 msgid "Central European" msgstr "Közép-európai" #: tepl/tepl-encoding.c:119 msgid "South European" msgstr "Dél-európai" #: tepl/tepl-encoding.c:120 tepl/tepl-encoding.c:127 tepl/tepl-encoding.c:185 msgid "Baltic" msgstr "Balti" #: tepl/tepl-encoding.c:121 tepl/tepl-encoding.c:159 tepl/tepl-encoding.c:166 #: tepl/tepl-encoding.c:168 tepl/tepl-encoding.c:169 tepl/tepl-encoding.c:179 msgid "Cyrillic" msgstr "Cirill" #: tepl/tepl-encoding.c:122 tepl/tepl-encoding.c:162 tepl/tepl-encoding.c:184 msgid "Arabic" msgstr "Arab" #: tepl/tepl-encoding.c:123 tepl/tepl-encoding.c:181 msgid "Greek" msgstr "Görög" #: tepl/tepl-encoding.c:124 msgid "Hebrew Visual" msgstr "Héber (képi)" #: tepl/tepl-encoding.c:125 tepl/tepl-encoding.c:160 tepl/tepl-encoding.c:182 msgid "Turkish" msgstr "Török" #: tepl/tepl-encoding.c:126 msgid "Nordic" msgstr "Északi" #: tepl/tepl-encoding.c:128 msgid "Celtic" msgstr "Kelta" #: tepl/tepl-encoding.c:130 msgid "Romanian" msgstr "Román" #: tepl/tepl-encoding.c:140 msgid "Armenian" msgstr "Örmény" #: tepl/tepl-encoding.c:141 tepl/tepl-encoding.c:142 tepl/tepl-encoding.c:150 msgid "Chinese Traditional" msgstr "Hagyományos kínai" #: tepl/tepl-encoding.c:143 msgid "Cyrillic/Russian" msgstr "Cirill/orosz" #: tepl/tepl-encoding.c:145 tepl/tepl-encoding.c:146 tepl/tepl-encoding.c:147 #: tepl/tepl-encoding.c:164 tepl/tepl-encoding.c:172 msgid "Japanese" msgstr "Japán" #: tepl/tepl-encoding.c:149 tepl/tepl-encoding.c:165 tepl/tepl-encoding.c:167 #: tepl/tepl-encoding.c:175 msgid "Korean" msgstr "Koreai" #: tepl/tepl-encoding.c:152 tepl/tepl-encoding.c:153 tepl/tepl-encoding.c:154 msgid "Chinese Simplified" msgstr "Egyszerűsített kínai" #: tepl/tepl-encoding.c:155 msgid "Georgian" msgstr "Grúz" #: tepl/tepl-encoding.c:161 tepl/tepl-encoding.c:183 msgid "Hebrew" msgstr "Héber" #: tepl/tepl-encoding.c:170 msgid "Cyrillic/Ukrainian" msgstr "Cirill/ukrán" #: tepl/tepl-encoding.c:173 tepl/tepl-encoding.c:176 tepl/tepl-encoding.c:186 msgid "Vietnamese" msgstr "Vietnami" #: tepl/tepl-encoding.c:174 msgid "Thai" msgstr "Thai" #: tepl/tepl-encoding.c:370 msgid "Unknown" msgstr "Ismeretlen" #. Translators: This is the sorted list of encodings used by Tepl for #. * automatic detection of the file encoding. You may want to customize #. * it adding encodings that are common in your country, for instance the #. * GB18030 encoding for the Chinese translation. You may also want to #. * remove the ISO-8859-15 encoding (covering English and most Western #. * European languages) if you think people in your country will rarely #. * use it. 'CURRENT' is a magic value used by Tepl and it represents #. * the encoding for the current locale, so please don't translate the #. * 'CURRENT' term. Keep the same format: square brackets, single quotes, #. * commas. #. #: tepl/tepl-encoding.c:695 msgid "['UTF-8', 'CURRENT', 'ISO-8859-15', 'UTF-16']" msgstr "['UTF-8', 'CURRENT', 'ISO-8859-2', 'WINDOWS-1250', 'IBM852', 'UTF-16']" #: tepl/tepl-encoding-converter.c:302 #, c-format msgid "Conversion from character set “%s” to “%s” is not supported." msgstr "A(z) „%s” és „%s” karakterkészletek közötti átalakítás nem támogatott." #: tepl/tepl-encoding-converter.c:311 #, c-format msgid "Could not open converter from “%s” to “%s”: %s" msgstr "" "A(z) „%s” karakterkészletről „%s” karakterkészletre átalakító nem nyitható " "meg: %s" #: tepl/tepl-encoding-converter.c:368 msgid "The input data contains an invalid sequence." msgstr "A bemeneti adat érvénytelen sorozatot tartalmaz." #: tepl/tepl-encoding-converter.c:377 #, c-format msgid "Error when converting data: %s" msgstr "Hiba az adatok átalakításakor: %s" #: tepl/tepl-encoding-converter.c:556 msgid "The input data ends with an incomplete multi-byte sequence." msgstr "A bemeneti adat egy befejezetlen több-bájtos sorozattal végződik." #: tepl/tepl-encoding-converter.c:579 msgid "The input content ends with incomplete data." msgstr "A bemeneti tartalom befejezetlen adattal végződik." #: tepl/tepl-file.c:413 #, c-format msgid "Untitled File %d" msgstr "%d. névtelen fájl" #: tepl/tepl-file-content-loader.c:331 #, c-format msgid "The file is too big. Maximum %s can be loaded." msgstr "A fájl túl nagy. Legfeljebb %s lehet betöltve." #: tepl/tepl-file-loader.c:872 msgid "It is not possible to detect the character encoding automatically." msgstr "Nem lehetséges a karakterkódolást automatikusan felismerni." #: tepl/tepl-file-saver.c:784 msgid "The file is externally modified." msgstr "A fájlt külsőleg módosították." #: tepl/tepl-file-saver.c:1318 msgid "The buffer contains invalid characters." msgstr "A puffer érvénytelen karaktereket tartalmaz." #: tepl/tepl-tab.c:534 msgid "Error when loading the file." msgstr "Hiba a fájl betöltésekor." #: tepl/tepl-tab.c:748 msgid "Save File" msgstr "Fájl mentése" #. Translators: location of a file. #: tepl/tepl-tab-label.c:273 msgid "Location:" msgstr "Hely:" #: tepl/tepl-tab-label.c:342 msgid "Close file" msgstr "Fájl bezárása" #: tepl/tepl-tab-saving.c:64 msgid "Error when saving the file." msgstr "Hiba a fájl mentésekor." 07070100000042000081A400000000000000000000000166D2F0DB00003682000000000000000000000000000000000000001D00000000libgedit-amtk-5.9.0/po/id.po# Indonesian translation for tepl. # Copyright (C) 2017 tepl's COPYRIGHT HOLDER # This file is distributed under the same license as the tepl package. # Andika Triwidada <atriwidada@gnome.org>, 2017. # msgid "" msgstr "" "Project-Id-Version: tepl master\n" "Report-Msgid-Bugs-To: https://bugzilla.gnome.org/enter_bug.cgi?" "product=tepl&keywords=I18N+L10N&component=general\n" "POT-Creation-Date: 2017-12-01 09:23+0000\n" "PO-Revision-Date: 2017-12-05 14:52+0700\n" "Last-Translator: Kukuh Syafaat <syafaatkukuh@gmail.com>\n" "Language-Team: Indonesian <gnome-l10n-id@googlegroups.com>\n" "Language: id\n" "MIME-Version: 1.0\n" "Content-Type: text/plain; charset=UTF-8\n" "Content-Transfer-Encoding: 8bit\n" "X-Generator: Poedit 2.0.4\n" #. Translators: %s is a filename. #: amtk/amtk-application-window.c:374 #, c-format msgid "Open “%s”" msgstr "Membuka \"%s\"" #: amtk/amtk-application-window.c:630 msgid "Open _Recent" msgstr "Buka Te_rkini" #. Translators: %s is the application name. #: amtk/amtk-application-window.c:633 #, c-format msgid "Open a file recently used with %s" msgstr "Membuka dokumen yang baru-baru ini dipakai dengan %s" #. action, icon, label, accel, tooltip #. File menu #. Why "file" and not "document"? "Document" is not the best #. word because the action is not always to create a new #. document. For example a LaTeX document can be composed of #. several _files_. Or for source code we do not really create a #. new "document". #: tepl/tepl-application.c:92 msgid "_New" msgstr "_Baru" #: tepl/tepl-application.c:93 msgid "New file" msgstr "Berkas baru" #: tepl/tepl-application.c:95 msgid "New _Window" msgstr "_Jendela Baru" #: tepl/tepl-application.c:96 msgid "Create a new window" msgstr "Membuat jendela baru" #: tepl/tepl-application.c:98 tepl/tepl-application-window.c:178 msgid "_Open" msgstr "_Buka" #: tepl/tepl-application.c:99 msgid "Open a file" msgstr "Buka suatu berkas" #: tepl/tepl-application.c:101 tepl/tepl-close-confirm-dialog-single.c:144 #: tepl/tepl-tab.c:752 msgid "_Save" msgstr "_Simpan" #: tepl/tepl-application.c:102 msgid "Save the current file" msgstr "Simpan berkas saat ini" #: tepl/tepl-application.c:104 msgid "Save _As" msgstr "Simp_an Sebagai" #: tepl/tepl-application.c:105 msgid "Save the current file to a different location" msgstr "Simpan berkas saat ini ke lokasi yang berbeda" #. Edit menu #: tepl/tepl-application.c:109 msgid "_Undo" msgstr "Tak _Jadi" #: tepl/tepl-application.c:110 msgid "Undo the last action" msgstr "Batalkan aksi terakhir" #: tepl/tepl-application.c:112 msgid "_Redo" msgstr "_Jadi Lagi" #: tepl/tepl-application.c:113 msgid "Redo the last undone action" msgstr "Jadikan lagi aksi terakhir yang dibatalkan" #: tepl/tepl-application.c:115 msgid "Cu_t" msgstr "Po_tong" #: tepl/tepl-application.c:116 msgid "Cut the selection" msgstr "Potong bagian yang dipilih" #: tepl/tepl-application.c:118 msgid "_Copy" msgstr "Sali_n" #: tepl/tepl-application.c:119 msgid "Copy the selection" msgstr "Salin bagian yang dipilih" #: tepl/tepl-application.c:121 msgid "_Paste" msgstr "Tem_pel" #: tepl/tepl-application.c:122 msgid "Paste the clipboard" msgstr "Tempel papan klip" #: tepl/tepl-application.c:124 msgid "_Delete" msgstr "_Hapus" #: tepl/tepl-application.c:125 msgid "Delete the selected text" msgstr "Hapus teks yang dipilih" #: tepl/tepl-application.c:127 msgid "Select _All" msgstr "Pilih Semu_a" #: tepl/tepl-application.c:128 msgid "Select all the text" msgstr "Pilih semua teks" #: tepl/tepl-application.c:130 msgid "_Indent" msgstr "_Indentasi" #: tepl/tepl-application.c:131 msgid "Indent the selected lines" msgstr "Indentasi baris yang dipilih" #: tepl/tepl-application.c:133 msgid "_Unindent" msgstr "Hap_us indentasi" #: tepl/tepl-application.c:134 msgid "Unindent the selected lines" msgstr "Hapus indentasi baris yang dipilih" #. Create a GtkFileChooserDialog, not a GtkFileChooserNative, because #. * with GtkFileChooserNative the GFile that we obtain (in flatpak) #. * doesn't have the real path to the file, so it would screw up some #. * features for text editors: #. * - showing the directory in parentheses in the window title, or in the #. * tab tooltip; #. * - opening a recent file. #. * Basically everywhere where the directory is shown. #. #: tepl/tepl-application-window.c:174 msgid "Open File" msgstr "Buka Berkas" #: tepl/tepl-application-window.c:177 #: tepl/tepl-close-confirm-dialog-single.c:138 tepl/tepl-tab.c:751 msgid "_Cancel" msgstr "Ba_tal" #: tepl/tepl-application-window.c:708 msgid "Read-Only" msgstr "Hanya-Baca" #: tepl/tepl-close-confirm-dialog-single.c:133 #, c-format msgid "Save changes to file “%s” before closing?" msgstr "Simpan perubahan ke berkas \"%s\" sebelum ditutup?" #: tepl/tepl-close-confirm-dialog-single.c:137 msgid "Close _without Saving" msgstr "Tutup _tanpa Menyimpan" #: tepl/tepl-close-confirm-dialog-single.c:150 msgid "_Save As…" msgstr "_Simpan Sebagai…" #. UTF-8 first, so that it's the first encoding returned by #. * tepl_encoding_get_all(). #. #: tepl/tepl-encoding.c:115 tepl/tepl-encoding.c:132 tepl/tepl-encoding.c:133 #: tepl/tepl-encoding.c:134 tepl/tepl-encoding.c:135 tepl/tepl-encoding.c:136 #: tepl/tepl-encoding.c:137 tepl/tepl-encoding.c:138 msgid "Unicode" msgstr "Unikode" #. FIXME GEOSTD8 ? #: tepl/tepl-encoding.c:117 tepl/tepl-encoding.c:129 tepl/tepl-encoding.c:157 #: tepl/tepl-encoding.c:180 msgid "Western" msgstr "Barat" #: tepl/tepl-encoding.c:118 tepl/tepl-encoding.c:158 tepl/tepl-encoding.c:178 msgid "Central European" msgstr "Eropa Tengah" #: tepl/tepl-encoding.c:119 msgid "South European" msgstr "Eropa Selatan" #: tepl/tepl-encoding.c:120 tepl/tepl-encoding.c:127 tepl/tepl-encoding.c:185 msgid "Baltic" msgstr "Baltik" #: tepl/tepl-encoding.c:121 tepl/tepl-encoding.c:159 tepl/tepl-encoding.c:166 #: tepl/tepl-encoding.c:168 tepl/tepl-encoding.c:169 tepl/tepl-encoding.c:179 msgid "Cyrillic" msgstr "Sirilik" #: tepl/tepl-encoding.c:122 tepl/tepl-encoding.c:162 tepl/tepl-encoding.c:184 msgid "Arabic" msgstr "Arab" #: tepl/tepl-encoding.c:123 tepl/tepl-encoding.c:181 msgid "Greek" msgstr "Yunani" #: tepl/tepl-encoding.c:124 msgid "Hebrew Visual" msgstr "Ibrani Visual" #: tepl/tepl-encoding.c:125 tepl/tepl-encoding.c:160 tepl/tepl-encoding.c:182 msgid "Turkish" msgstr "Turki" #: tepl/tepl-encoding.c:126 msgid "Nordic" msgstr "Nordik" #: tepl/tepl-encoding.c:128 msgid "Celtic" msgstr "Seltik" #: tepl/tepl-encoding.c:130 msgid "Romanian" msgstr "Rumania" #: tepl/tepl-encoding.c:140 msgid "Armenian" msgstr "Armenia" #: tepl/tepl-encoding.c:141 tepl/tepl-encoding.c:142 tepl/tepl-encoding.c:150 msgid "Chinese Traditional" msgstr "Cina Tradisional" #: tepl/tepl-encoding.c:143 msgid "Cyrillic/Russian" msgstr "Sirilik/Rusia" #: tepl/tepl-encoding.c:145 tepl/tepl-encoding.c:146 tepl/tepl-encoding.c:147 #: tepl/tepl-encoding.c:164 tepl/tepl-encoding.c:172 msgid "Japanese" msgstr "Jepang" #: tepl/tepl-encoding.c:149 tepl/tepl-encoding.c:165 tepl/tepl-encoding.c:167 #: tepl/tepl-encoding.c:175 msgid "Korean" msgstr "Korea" #: tepl/tepl-encoding.c:152 tepl/tepl-encoding.c:153 tepl/tepl-encoding.c:154 msgid "Chinese Simplified" msgstr "Cina Sederhana" #: tepl/tepl-encoding.c:155 msgid "Georgian" msgstr "Georgia" #: tepl/tepl-encoding.c:161 tepl/tepl-encoding.c:183 msgid "Hebrew" msgstr "Ibrani" #: tepl/tepl-encoding.c:170 msgid "Cyrillic/Ukrainian" msgstr "Sirilik/Ukraina" #: tepl/tepl-encoding.c:173 tepl/tepl-encoding.c:176 tepl/tepl-encoding.c:186 msgid "Vietnamese" msgstr "Vietnam" #: tepl/tepl-encoding.c:174 msgid "Thai" msgstr "Thai" #: tepl/tepl-encoding.c:370 msgid "Unknown" msgstr "Tidak Dikenal" #. Translators: This is the sorted list of encodings used by Tepl for #. * automatic detection of the file encoding. You may want to customize #. * it adding encodings that are common in your country, for instance the #. * GB18030 encoding for the Chinese translation. You may also want to #. * remove the ISO-8859-15 encoding (covering English and most Western #. * European languages) if you think people in your country will rarely #. * use it. 'CURRENT' is a magic value used by Tepl and it represents #. * the encoding for the current locale, so please don't translate the #. * 'CURRENT' term. Keep the same format: square brackets, single quotes, #. * commas. #. #: tepl/tepl-encoding.c:695 msgid "['UTF-8', 'CURRENT', 'ISO-8859-15', 'UTF-16']" msgstr "['UTF-8', 'CURRENT', 'ISO-8859-15', 'UTF-16']" #: tepl/tepl-encoding-converter.c:302 #, c-format msgid "Conversion from character set “%s” to “%s” is not supported." msgstr "Konversi dari gugus karakter \"%s\" ke \"%s\" tak didukung." #: tepl/tepl-encoding-converter.c:311 #, c-format msgid "Could not open converter from “%s” to “%s”: %s" msgstr "Tidak dapat membuka pengubah dari \"%s\" menjadi \"%s\": %s" #: tepl/tepl-encoding-converter.c:368 msgid "The input data contains an invalid sequence." msgstr "Data masukan memuat suatu urutan yang tidak valid." #: tepl/tepl-encoding-converter.c:377 #, c-format msgid "Error when converting data: %s" msgstr "Galat saat mengonversi data: %s" #: tepl/tepl-encoding-converter.c:556 msgid "The input data ends with an incomplete multi-byte sequence." msgstr "Data masukan diakhiri dengan urutan multi-byte yang tidak lengkap." #: tepl/tepl-encoding-converter.c:579 msgid "The input content ends with incomplete data." msgstr "Isi masukan berakhir dengan data yang tidak lengkap." #: tepl/tepl-file.c:413 #, c-format msgid "Untitled File %d" msgstr "Berkas Tanpa Nama %d" #: tepl/tepl-file-content-loader.c:331 #, c-format msgid "The file is too big. Maximum %s can be loaded." msgstr "Berkas telalu besar. Maksimum %s dapat dimuat." #: tepl/tepl-file-loader.c:872 msgid "It is not possible to detect the character encoding automatically." msgstr "Tak mungkin mendeteksi pengkodean karakter secara otomatis." #: tepl/tepl-file-saver.c:784 msgid "The file is externally modified." msgstr "Berkas telah diubah secara eksternal." #: tepl/tepl-file-saver.c:1318 msgid "The buffer contains invalid characters." msgstr "Penyangga mengandung karakter tak valid." #: tepl/tepl-tab.c:534 msgid "Error when loading the file." msgstr "Galat saat memuat berkas." #: tepl/tepl-tab.c:748 msgid "Save File" msgstr "Simpan Berkas" #. Translators: location of a file. #: tepl/tepl-tab-label.c:273 msgid "Location:" msgstr "Lokasi:" #: tepl/tepl-tab-label.c:342 msgid "Close file" msgstr "Tutup berkas" #: tepl/tepl-tab-saving.c:64 msgid "Error when saving the file." msgstr "Galat saat menyimpan berkas." #~ msgid "Could not find the file “%s”." #~ msgstr "Tak bisa temukan berkas \"%s\"." #~ msgid "Please check that you typed the location correctly and try again." #~ msgstr "" #~ "Silakan periksa apakah lokasi yang Anda ketikkan benar dan coba lagi." #~ msgid "Unable to handle “%s:” locations." #~ msgstr "Tak bisa menangani lokasi \"%s:\"." #~ msgid "The location of the file cannot be accessed." #~ msgstr "Lokasi berkas tak dapat diakses." #~ msgid "“%s” is a directory." #~ msgstr "\"%s\" adalah direktori." #~ msgid "“%s” is not a valid location." #~ msgstr "\"%s\" bukan lokasi yang sah." #~ msgid "" #~ "Host “%s” could not be found. Please check that your proxy settings are " #~ "correct and try again." #~ msgstr "" #~ "Host \"%s\" tidak dapat ditemukan. Silakan periksa apakah tatanan proksi " #~ "Anda sudah benar dan coba lagi." #~ msgid "" #~ "Hostname was invalid. Please check that you typed the location correctly " #~ "and try again." #~ msgstr "" #~ "Nama host tidak valid. Silakan periksa lokasi yg Anda tik dan coba lagi." #~ msgid "“%s” is not a regular file." #~ msgstr "\"%s\" bukan berkas reguler." #~ msgid "Connection timed out. Please try again." #~ msgstr "Koneksi melewati waktu tunggu. Silakan coba lagi." #~ msgid "Unexpected error: %s" #~ msgstr "Kesalahan yang tidak diduga: %s" #~ msgid "_Retry" #~ msgstr "_Ulangi" #~ msgid "Edit Any_way" #~ msgstr "Sunt_ing Saja" #~ msgid "" #~ "The number of followed links is limited and the actual file could not be " #~ "found within this limit." #~ msgstr "" #~ "Cacah taut yang diikuti terbatas dan berkas sesungguhnya tak ditemukan " #~ "dalam batas ini." #~ msgid "You do not have the permissions necessary to open the file." #~ msgstr "Anda tidak memiliki izin yang diperlukan untuk membuka berkas." #~ msgid "" #~ "Unable to detect the character encoding.\n" #~ "Please check that you are not trying to open a binary file.\n" #~ "Select a character encoding from the menu and try again." #~ msgstr "" #~ "Tidak bisa mendeteksi pengkodean karakter.\n" #~ "Harap periksa bahwa Anda tidak mencoba membuka suatu berkas biner.\n" #~ "Pilih suatu pengkodean karakter dari menu dan cobalah lagi." #~ msgid "There was a problem opening the file “%s”." #~ msgstr "Ada masalah ketika membuka berkas \"%s\"." #~ msgid "" #~ "The file you opened has some invalid characters. If you continue editing " #~ "this file you could corrupt it.\n" #~ "You can also choose another character encoding and try again." #~ msgstr "" #~ "Berkas yang Anda buka memiliki beberapa karakter yang tidak valid. Bila " #~ "Anda melanjutkan menyunting berkas ini Anda bisa merusaknya.\n" #~ "Anda juga dapat memilih pengkodean karakter yang lain dan mencoba lagi." #~ msgid "Could not open the file “%s” using the “%s” character encoding." #~ msgstr "" #~ "Tak dapat membuka berkas \"%s\" menggunakan pengkodean karakter \"%s\"." #~ msgid "" #~ "Please check that you are not trying to open a binary file.\n" #~ "Select a different character encoding from the menu and try again." #~ msgstr "" #~ "Harap periksa bahwa Anda tidak mencoba membuka suatu berkas biner.\n" #~ "Pilih suatu pengkodean karakter lain dari menu dan cobalah lagi." #~ msgid "Could not open the file “%s”." #~ msgstr "Tidak bisa membuka berkas \"%s\"." 07070100000043000081A400000000000000000000000166D2F0DB00000488000000000000000000000000000000000000001D00000000libgedit-amtk-5.9.0/po/it.po# Italian translation for amtk. # Copyright (C) 2018 Free Software Foundation, Ltd # This file is distributed under the same license as the amtk package. # Milo Casagrande <milo@ubuntu.com>, 2018. # msgid "" msgstr "" "Project-Id-Version: amtk master\n" "Report-Msgid-Bugs-To: https://bugzilla.gnome.org/enter_bug.cgi?" "product=amtk&keywords=I18N+L10N&component=general\n" "POT-Creation-Date: 2018-04-16 06:06+0000\n" "PO-Revision-Date: 2018-04-16 14:35+0200\n" "Language-Team: Italian <gnome-it-list@gnome.org>\n" "Language: it\n" "MIME-Version: 1.0\n" "Content-Type: text/plain; charset=UTF-8\n" "Content-Transfer-Encoding: 8bit\n" "Plural-Forms: nplurals=2; plural=(n != 1);\n" "Last-Translator: Milo Casagrande <milo@milo.name>\n" "X-Generator: Poedit 2.0.6\n" #. Translators: %s is a filename. #: amtk/amtk-application-window.c:374 #, c-format msgid "Open “%s”" msgstr "Apri «%s»" #: amtk/amtk-application-window.c:630 msgid "Open _Recent" msgstr "Apri _recenti" #. Translators: %s is the application name. #: amtk/amtk-application-window.c:633 #, c-format msgid "Open a file recently used with %s" msgstr "Apre un file usato di recente con %s" 07070100000044000081A400000000000000000000000166D2F0DB0000046A000000000000000000000000000000000000001D00000000libgedit-amtk-5.9.0/po/ja.po# Japanese translation for amtk. # Copyright (C) 2019 amtk's COPYRIGHT HOLDER # This file is distributed under the same license as the amtk package. # sicklylife <translation@sicklylife.jp>, 2019. # msgid "" msgstr "" "Project-Id-Version: amtk master\n" "Report-Msgid-Bugs-To: https://gitlab.gnome.org/GNOME/amtk/issues\n" "POT-Creation-Date: 2019-09-15 08:15+0000\n" "PO-Revision-Date: 2019-09-22 21:50+0900\n" "Last-Translator: sicklylife <translation@sicklylife.jp>\n" "Language-Team: Japanese <gnome-translation@gnome.gr.jp>\n" "Language: ja\n" "MIME-Version: 1.0\n" "Content-Type: text/plain; charset=UTF-8\n" "Content-Transfer-Encoding: 8bit\n" "Plural-Forms: nplurals=1; plural=0;\n" #. Translators: %s is a filename. #: amtk/amtk-application-window.c:374 #, c-format msgid "Open “%s”" msgstr "“%s”を開く" #: amtk/amtk-application-window.c:630 msgid "Open _Recent" msgstr "最近使用したものを開く(_R)" #. Translators: %s is the application name. #: amtk/amtk-application-window.c:633 #, c-format msgid "Open a file recently used with %s" msgstr "%s で最近使用したファイルを開きます" 07070100000045000081A400000000000000000000000166D2F0DB000004E1000000000000000000000000000000000000001D00000000libgedit-amtk-5.9.0/po/ka.po# Georgian translation for libgedit-amtk-5. # Copyright (C) 2023 libgedit-amtk-5's authors # This file is distributed under the same license as the libgedit-amtk-5 package. # Ekaterine Papava <papava.e@gtu.ge>, 2023. # msgid "" msgstr "" "Project-Id-Version: libgedit-amtk-5\n" "Report-Msgid-Bugs-To: \n" "POT-Creation-Date: 2023-07-29 15:49+0200\n" "PO-Revision-Date: 2023-07-29 15:51+0200\n" "Last-Translator: Ekaterine Papava <papava.e@gtu.ge>\n" "Language-Team: Georgian <(nothing)>\n" "Language: ka\n" "MIME-Version: 1.0\n" "Content-Type: text/plain; charset=UTF-8\n" "Content-Transfer-Encoding: 8bit\n" "Plural-Forms: nplurals=2; plural=(n != 1);\n" "X-Generator: Poedit 3.3.2\n" #. Translators: %s is a filename. #: amtk/amtk-application-window.c:359 #, c-format msgid "Open “%s”" msgstr "\"%s\"-ის გახსნა" #: amtk/amtk-application-window.c:635 msgid "Open _Recent" msgstr "_უახლესი ფაილების გახსნა" #. Translators: %s is the application name. #: amtk/amtk-application-window.c:638 #, c-format msgid "Open a file recently used with %s" msgstr "%s-სთან ერთად ახლახანს გამოყენებული ფაილის გახსნა" 07070100000046000081A400000000000000000000000166D2F0DB000004B4000000000000000000000000000000000000001D00000000libgedit-amtk-5.9.0/po/lt.po# Lithuanian translation for amtk. # Copyright (C) 2019 amtk's COPYRIGHT HOLDER # This file is distributed under the same license as the amtk package. # Aurimas Černius <aurisc4@gmail.com>, 2019. # msgid "" msgstr "" "Project-Id-Version: amtk master\n" "Report-Msgid-Bugs-To: https://gitlab.gnome.org/GNOME/amtk/issues\n" "POT-Creation-Date: 2019-02-27 14:16+0000\n" "PO-Revision-Date: 2019-03-16 15:51+0200\n" "Last-Translator: Aurimas Černius <aurisc4@gmail.com>\n" "Language-Team: Lietuvių <gnome-lt@lists.akl.lt>\n" "Language: lt\n" "MIME-Version: 1.0\n" "Content-Type: text/plain; charset=UTF-8\n" "Content-Transfer-Encoding: 8bit\n" "Plural-Forms: nplurals=3; plural=(n%10==1 && n%100!=11 ? 0 : n%10>=2 && (n" "%100<10 || n%100>=20) ? 1 : 2)\n" "X-Generator: Gtranslator 3.30.1\n" #. Translators: %s is a filename. #: amtk/amtk-application-window.c:374 #, c-format msgid "Open “%s”" msgstr "Atverti „%s“" #: amtk/amtk-application-window.c:630 msgid "Open _Recent" msgstr "Atverti _neseniai naudotą" #. Translators: %s is the application name. #: amtk/amtk-application-window.c:633 #, c-format msgid "Open a file recently used with %s" msgstr "Atverti neseniai naudotą failą su %s" 07070100000047000081A400000000000000000000000166D2F0DB00000039000000000000000000000000000000000000002300000000libgedit-amtk-5.9.0/po/meson.buildI18N.gettext( GETTEXT_PACKAGE_NAME, preset: 'glib' ) 07070100000048000081A400000000000000000000000166D2F0DB00000411000000000000000000000000000000000000001D00000000libgedit-amtk-5.9.0/po/ms.po# Malay translation for amtk. # Copyright (C) 2020 amtk's COPYRIGHT HOLDER # This file is distributed under the same license as the amtk package. # abuyop <abuyop@gmail.com>, 2020. # msgid "" msgstr "" "Project-Id-Version: amtk master\n" "Report-Msgid-Bugs-To: https://gitlab.gnome.org/GNOME/amtk/issues\n" "POT-Creation-Date: 2019-11-06 07:15+0000\n" "PO-Revision-Date: 2020-01-21 23:08+0800\n" "Language-Team: Malay <ms@li.org>\n" "Language: ms\n" "MIME-Version: 1.0\n" "Content-Type: text/plain; charset=UTF-8\n" "Content-Transfer-Encoding: 8bit\n" "Last-Translator: abuyop <abuyop@gmail.com>\n" "X-Generator: Poedit 2.0.6\n" #. Translators: %s is a filename. #: amtk/amtk-application-window.c:374 #, c-format msgid "Open “%s”" msgstr "Buka \"%s\"" #: amtk/amtk-application-window.c:630 msgid "Open _Recent" msgstr "Buka Ba_ru-baru Ini" #. Translators: %s is the application name. #: amtk/amtk-application-window.c:633 #, c-format msgid "Open a file recently used with %s" msgstr "Buka satu fail digunakan baru-baru ini dengan %s" 07070100000049000081A400000000000000000000000166D2F0DB00000456000000000000000000000000000000000000001D00000000libgedit-amtk-5.9.0/po/nl.po# Dutch translation for amtk. # Copyright (C) 2019 amtk's COPYRIGHT HOLDER # This file is distributed under the same license as the amtk package. # Nathan Follens <nthn@unseen.is>, 2019. # msgid "" msgstr "" "Project-Id-Version: amtk master\n" "Report-Msgid-Bugs-To: https://gitlab.gnome.org/GNOME/amtk/issues\n" "POT-Creation-Date: 2018-08-30 14:56+0000\n" "PO-Revision-Date: 2019-01-17 21:41+0100\n" "Language-Team: Dutch <gnome-nl-list@gnome.org>\n" "Language: nl\n" "MIME-Version: 1.0\n" "Content-Type: text/plain; charset=UTF-8\n" "Content-Transfer-Encoding: 8bit\n" "Plural-Forms: nplurals=2; plural=(n != 1);\n" "Last-Translator: Nathan Follens <nthn@unseen.is>\n" "X-Generator: Poedit 2.2\n" #. Translators: %s is a filename. #: amtk/amtk-application-window.c:374 #, c-format msgid "Open “%s”" msgstr "‘%s’ openen" #: amtk/amtk-application-window.c:630 msgid "Open _Recent" msgstr "_Recent bestand openen" #. Translators: %s is the application name. #: amtk/amtk-application-window.c:633 #, c-format msgid "Open a file recently used with %s" msgstr "Open een bestand recent gebruikt met %s" 0707010000004A000081A400000000000000000000000166D2F0DB0000383E000000000000000000000000000000000000001D00000000libgedit-amtk-5.9.0/po/pl.po# Polish translation for tepl. # Copyright © 2017 the tepl authors. # This file is distributed under the same license as the tepl package. # Piotr Drąg <piotrdrag@gmail.com>, 2017. # Aviary.pl <community-poland@mozilla.org>, 2017. # msgid "" msgstr "" "Project-Id-Version: tepl\n" "Report-Msgid-Bugs-To: https://bugzilla.gnome.org/enter_bug.cgi?" "product=tepl&keywords=I18N+L10N&component=general\n" "POT-Creation-Date: 2017-12-01 09:23+0000\n" "PO-Revision-Date: 2017-12-03 18:37+0100\n" "Last-Translator: Piotr Drąg <piotrdrag@gmail.com>\n" "Language-Team: Polish <community-poland@mozilla.org>\n" "Language: pl\n" "MIME-Version: 1.0\n" "Content-Type: text/plain; charset=UTF-8\n" "Content-Transfer-Encoding: 8bit\n" "Plural-Forms: nplurals=3; plural=(n==1 ? 0 : n%10>=2 && n%10<=4 && (n%100<10 " "|| n%100>=20) ? 1 : 2);\n" #. Translators: %s is a filename. #: amtk/amtk-application-window.c:374 #, c-format msgid "Open “%s”" msgstr "Otwórz „%s”" #: amtk/amtk-application-window.c:630 msgid "Open _Recent" msgstr "Ostatnio używane doku_menty" #. Translators: %s is the application name. #: amtk/amtk-application-window.c:633 #, c-format msgid "Open a file recently used with %s" msgstr "Otwarcie pliku ostatnio używanego w programie %s" #. action, icon, label, accel, tooltip #. File menu #. Why "file" and not "document"? "Document" is not the best #. word because the action is not always to create a new #. document. For example a LaTeX document can be composed of #. several _files_. Or for source code we do not really create a #. new "document". #: tepl/tepl-application.c:92 msgid "_New" msgstr "_Nowy" #: tepl/tepl-application.c:93 msgid "New file" msgstr "Nowy plik" #: tepl/tepl-application.c:95 msgid "New _Window" msgstr "No_we okno" #: tepl/tepl-application.c:96 msgid "Create a new window" msgstr "Otwiera nowe okno" #: tepl/tepl-application.c:98 tepl/tepl-application-window.c:178 msgid "_Open" msgstr "_Otwórz" #: tepl/tepl-application.c:99 msgid "Open a file" msgstr "Otwiera plik" #: tepl/tepl-application.c:101 tepl/tepl-close-confirm-dialog-single.c:144 #: tepl/tepl-tab.c:752 msgid "_Save" msgstr "_Zapisz" #: tepl/tepl-application.c:102 msgid "Save the current file" msgstr "Zapisuje obecny plik" #: tepl/tepl-application.c:104 msgid "Save _As" msgstr "Z_apisz jako" #: tepl/tepl-application.c:105 msgid "Save the current file to a different location" msgstr "Zapisuje obecny plik w innym miejscu" #. Edit menu #: tepl/tepl-application.c:109 msgid "_Undo" msgstr "_Cofnij" #: tepl/tepl-application.c:110 msgid "Undo the last action" msgstr "Cofa ostatnie działanie" #: tepl/tepl-application.c:112 msgid "_Redo" msgstr "P_onów" #: tepl/tepl-application.c:113 msgid "Redo the last undone action" msgstr "Ponawia ostatnio cofnięte działanie" #: tepl/tepl-application.c:115 msgid "Cu_t" msgstr "_Wytnij" #: tepl/tepl-application.c:116 msgid "Cut the selection" msgstr "Wycina zaznaczenie" #: tepl/tepl-application.c:118 msgid "_Copy" msgstr "S_kopiuj" #: tepl/tepl-application.c:119 msgid "Copy the selection" msgstr "Kopiuje zaznaczenie" #: tepl/tepl-application.c:121 msgid "_Paste" msgstr "Wk_lej" #: tepl/tepl-application.c:122 msgid "Paste the clipboard" msgstr "Wkleja zawartość schowka" #: tepl/tepl-application.c:124 msgid "_Delete" msgstr "_Usuń" #: tepl/tepl-application.c:125 msgid "Delete the selected text" msgstr "Usuwa zaznaczony tekst" #: tepl/tepl-application.c:127 msgid "Select _All" msgstr "Z_aznacz wszystko" #: tepl/tepl-application.c:128 msgid "Select all the text" msgstr "Zaznacza cały tekst" #: tepl/tepl-application.c:130 msgid "_Indent" msgstr "_Dodaj wcięcie" #: tepl/tepl-application.c:131 msgid "Indent the selected lines" msgstr "Dodaje wcięcie do zaznaczonych wierszy" #: tepl/tepl-application.c:133 msgid "_Unindent" msgstr "_Usuń wcięcie" #: tepl/tepl-application.c:134 msgid "Unindent the selected lines" msgstr "Usuwa wcięcie z zaznaczonych wierszy" #. Create a GtkFileChooserDialog, not a GtkFileChooserNative, because #. * with GtkFileChooserNative the GFile that we obtain (in flatpak) #. * doesn't have the real path to the file, so it would screw up some #. * features for text editors: #. * - showing the directory in parentheses in the window title, or in the #. * tab tooltip; #. * - opening a recent file. #. * Basically everywhere where the directory is shown. #. #: tepl/tepl-application-window.c:174 msgid "Open File" msgstr "Otwarcie pliku" #: tepl/tepl-application-window.c:177 #: tepl/tepl-close-confirm-dialog-single.c:138 tepl/tepl-tab.c:751 msgid "_Cancel" msgstr "_Anuluj" #: tepl/tepl-application-window.c:708 msgid "Read-Only" msgstr "Tylko do odczytu" #: tepl/tepl-close-confirm-dialog-single.c:133 #, c-format msgid "Save changes to file “%s” before closing?" msgstr "Zapisać zmiany przed zamknięciem pliku „%s”?" #: tepl/tepl-close-confirm-dialog-single.c:137 msgid "Close _without Saving" msgstr "Zamknij _bez zapisywania" #: tepl/tepl-close-confirm-dialog-single.c:150 msgid "_Save As…" msgstr "Zapi_sz jako…" #. UTF-8 first, so that it's the first encoding returned by #. * tepl_encoding_get_all(). #. #: tepl/tepl-encoding.c:115 tepl/tepl-encoding.c:132 tepl/tepl-encoding.c:133 #: tepl/tepl-encoding.c:134 tepl/tepl-encoding.c:135 tepl/tepl-encoding.c:136 #: tepl/tepl-encoding.c:137 tepl/tepl-encoding.c:138 msgid "Unicode" msgstr "unikod" #. FIXME GEOSTD8 ? #: tepl/tepl-encoding.c:117 tepl/tepl-encoding.c:129 tepl/tepl-encoding.c:157 #: tepl/tepl-encoding.c:180 msgid "Western" msgstr "zachodnie" #: tepl/tepl-encoding.c:118 tepl/tepl-encoding.c:158 tepl/tepl-encoding.c:178 msgid "Central European" msgstr "środkowoeuropejskie" #: tepl/tepl-encoding.c:119 msgid "South European" msgstr "południowoeuropejskie" #: tepl/tepl-encoding.c:120 tepl/tepl-encoding.c:127 tepl/tepl-encoding.c:185 msgid "Baltic" msgstr "bałtyckie" #: tepl/tepl-encoding.c:121 tepl/tepl-encoding.c:159 tepl/tepl-encoding.c:166 #: tepl/tepl-encoding.c:168 tepl/tepl-encoding.c:169 tepl/tepl-encoding.c:179 msgid "Cyrillic" msgstr "cyrylica" #: tepl/tepl-encoding.c:122 tepl/tepl-encoding.c:162 tepl/tepl-encoding.c:184 msgid "Arabic" msgstr "arabskie" #: tepl/tepl-encoding.c:123 tepl/tepl-encoding.c:181 msgid "Greek" msgstr "greckie" #: tepl/tepl-encoding.c:124 msgid "Hebrew Visual" msgstr "hebrajskie (wizualne)" #: tepl/tepl-encoding.c:125 tepl/tepl-encoding.c:160 tepl/tepl-encoding.c:182 msgid "Turkish" msgstr "tureckie" #: tepl/tepl-encoding.c:126 msgid "Nordic" msgstr "skandynawskie" #: tepl/tepl-encoding.c:128 msgid "Celtic" msgstr "celtyckie" #: tepl/tepl-encoding.c:130 msgid "Romanian" msgstr "rumuńskie" #: tepl/tepl-encoding.c:140 msgid "Armenian" msgstr "ormiańskie" #: tepl/tepl-encoding.c:141 tepl/tepl-encoding.c:142 tepl/tepl-encoding.c:150 msgid "Chinese Traditional" msgstr "chińskie (tradycyjne)" #: tepl/tepl-encoding.c:143 msgid "Cyrillic/Russian" msgstr "cyrylica/rosyjskie" #: tepl/tepl-encoding.c:145 tepl/tepl-encoding.c:146 tepl/tepl-encoding.c:147 #: tepl/tepl-encoding.c:164 tepl/tepl-encoding.c:172 msgid "Japanese" msgstr "japońskie" #: tepl/tepl-encoding.c:149 tepl/tepl-encoding.c:165 tepl/tepl-encoding.c:167 #: tepl/tepl-encoding.c:175 msgid "Korean" msgstr "koreańskie" #: tepl/tepl-encoding.c:152 tepl/tepl-encoding.c:153 tepl/tepl-encoding.c:154 msgid "Chinese Simplified" msgstr "chińskie (uproszczone)" #: tepl/tepl-encoding.c:155 msgid "Georgian" msgstr "gruzińskie" #: tepl/tepl-encoding.c:161 tepl/tepl-encoding.c:183 msgid "Hebrew" msgstr "hebrajskie" #: tepl/tepl-encoding.c:170 msgid "Cyrillic/Ukrainian" msgstr "cyrylica/ukraińskie" #: tepl/tepl-encoding.c:173 tepl/tepl-encoding.c:176 tepl/tepl-encoding.c:186 msgid "Vietnamese" msgstr "wietnamskie" #: tepl/tepl-encoding.c:174 msgid "Thai" msgstr "tajskie" #: tepl/tepl-encoding.c:370 msgid "Unknown" msgstr "nieznane" #. Translators: This is the sorted list of encodings used by Tepl for #. * automatic detection of the file encoding. You may want to customize #. * it adding encodings that are common in your country, for instance the #. * GB18030 encoding for the Chinese translation. You may also want to #. * remove the ISO-8859-15 encoding (covering English and most Western #. * European languages) if you think people in your country will rarely #. * use it. 'CURRENT' is a magic value used by Tepl and it represents #. * the encoding for the current locale, so please don't translate the #. * 'CURRENT' term. Keep the same format: square brackets, single quotes, #. * commas. #. #: tepl/tepl-encoding.c:695 msgid "['UTF-8', 'CURRENT', 'ISO-8859-15', 'UTF-16']" msgstr "['UTF-8', 'CURRENT', 'ISO-8859-2', 'WINDOWS-1250', 'UTF-16']" #: tepl/tepl-encoding-converter.c:302 #, c-format msgid "Conversion from character set “%s” to “%s” is not supported." msgstr "Konwersja z zestawu znaków „%s” do „%s” jest nieobsługiwana." #: tepl/tepl-encoding-converter.c:311 #, c-format msgid "Could not open converter from “%s” to “%s”: %s" msgstr "Nie można otworzyć konwertera z „%s” do „%s”: %s" #: tepl/tepl-encoding-converter.c:368 msgid "The input data contains an invalid sequence." msgstr "Dane wejściowe zawierają nieprawidłową sekwencję." #: tepl/tepl-encoding-converter.c:377 #, c-format msgid "Error when converting data: %s" msgstr "Błąd podczas konwersji danych: %s" #: tepl/tepl-encoding-converter.c:556 msgid "The input data ends with an incomplete multi-byte sequence." msgstr "Dane wejściowe kończą się niepełną sekwencją wielobajtową." #: tepl/tepl-encoding-converter.c:579 msgid "The input content ends with incomplete data." msgstr "Treść wejściowa kończą się niepełnymi danymi." #: tepl/tepl-file.c:413 #, c-format msgid "Untitled File %d" msgstr "%d. plik bez tytułu" #: tepl/tepl-file-content-loader.c:331 #, c-format msgid "The file is too big. Maximum %s can be loaded." msgstr "Plik jest za duży. Maksymalnie można wczytać %s." #: tepl/tepl-file-loader.c:872 msgid "It is not possible to detect the character encoding automatically." msgstr "Nie można automatycznie wykryć kodowania znaków." #: tepl/tepl-file-saver.c:784 msgid "The file is externally modified." msgstr "Plik został zmodyfikowany poza programem." #: tepl/tepl-file-saver.c:1318 msgid "The buffer contains invalid characters." msgstr "Bufor zawiera nieprawidłowe znaki." #: tepl/tepl-tab.c:534 msgid "Error when loading the file." msgstr "Błąd podczas wczytywania pliku." #: tepl/tepl-tab.c:748 msgid "Save File" msgstr "Zapis pliku" #. Translators: location of a file. #: tepl/tepl-tab-label.c:273 msgid "Location:" msgstr "Położenie:" #: tepl/tepl-tab-label.c:342 msgid "Close file" msgstr "Zamyka plik" #: tepl/tepl-tab-saving.c:64 msgid "Error when saving the file." msgstr "Błąd podczas zapisywania pliku." #~ msgid "Could not find the file “%s”." #~ msgstr "Nie można odnaleźć pliku „%s”." #~ msgid "Please check that you typed the location correctly and try again." #~ msgstr "" #~ "Proszę sprawdzić, czy wprowadzone zostało poprawne położenie i spróbować " #~ "ponownie." #~ msgid "Unable to handle “%s:” locations." #~ msgstr "Nie można obsłużyć położeń „%s:”." #~ msgid "The location of the file cannot be accessed." #~ msgstr "Nie można uzyskać dostępu do położenia pliku." #~ msgid "“%s” is a directory." #~ msgstr "„%s” jest katalogiem." #~ msgid "“%s” is not a valid location." #~ msgstr "„%s” nie jest prawidłowym położeniem." #~ msgid "" #~ "Host “%s” could not be found. Please check that your proxy settings are " #~ "correct and try again." #~ msgstr "" #~ "Nie można odnaleźć komputera „%s”. Proszę sprawdzić poprawność ustawień " #~ "pośrednika i spróbować ponownie." #~ msgid "" #~ "Hostname was invalid. Please check that you typed the location correctly " #~ "and try again." #~ msgstr "" #~ "Nazwa komputera jest nieprawidłowa. Proszę sprawdzić, czy wprowadzone " #~ "położenie jest poprawne i spróbować ponownie." #~ msgid "“%s” is not a regular file." #~ msgstr "„%s” nie jest zwykłym plikiem." #~ msgid "Connection timed out. Please try again." #~ msgstr "Przekroczono czas połączenia. Proszę spróbować ponownie." #~ msgid "Unexpected error: %s" #~ msgstr "Nieoczekiwany błąd: %s" #~ msgid "_Retry" #~ msgstr "P_onów" #~ msgid "Edit Any_way" #~ msgstr "_Modyfikuj mimo to" #~ msgid "" #~ "The number of followed links is limited and the actual file could not be " #~ "found within this limit." #~ msgstr "" #~ "Liczba dowiązań do podążenia jest ograniczona. Plik nie został " #~ "odnaleziony w zakresie tego ograniczenia." #~ msgid "You do not have the permissions necessary to open the file." #~ msgstr "Brak odpowiednich uprawnień do otwarcia tego pliku." #~ msgid "" #~ "Unable to detect the character encoding.\n" #~ "Please check that you are not trying to open a binary file.\n" #~ "Select a character encoding from the menu and try again." #~ msgstr "" #~ "Nie można wykryć kodowania znaków.\n" #~ "Proszę sprawdzić, czy otwierany plik nie jest binarny.\n" #~ "Można także wybrać kodowanie znaków w menu i spróbować ponownie." #~ msgid "There was a problem opening the file “%s”." #~ msgstr "Wystąpił problem podczas otwierania pliku „%s”." #~ msgid "" #~ "The file you opened has some invalid characters. If you continue editing " #~ "this file you could corrupt it.\n" #~ "You can also choose another character encoding and try again." #~ msgstr "" #~ "Otwarty plik zawiera nieprawidłowe znaki. Jeśli modyfikowanie tego pliku " #~ "zostanie kontynuowane, może on zostać uszkodzony.\n" #~ "Można także wybrać inne kodowanie znaków i spróbować ponownie." #~ msgid "Could not open the file “%s” using the “%s” character encoding." #~ msgstr "Nie można otworzyć pliku „%s” za pomocą kodowania znaków „%s”." #~ msgid "" #~ "Please check that you are not trying to open a binary file.\n" #~ "Select a different character encoding from the menu and try again." #~ msgstr "" #~ "Proszę sprawdzić, czy otwierany plik nie jest binarny.\n" #~ "Można także wybrać inne kodowanie znaków w menu i spróbować ponownie." #~ msgid "Could not open the file “%s”." #~ msgstr "Nie można otworzyć pliku „%s”." 0707010000004B000081A400000000000000000000000166D2F0DB00000457000000000000000000000000000000000000001D00000000libgedit-amtk-5.9.0/po/pt.po# Portuguese translation for amtk. # Copyright (C) 2020 amtk's COPYRIGHT HOLDER # This file is distributed under the same license as the amtk package. # mansil <mmsrs@sky.com>, 2020. # msgid "" msgstr "" "Project-Id-Version: amtk master\n" "Report-Msgid-Bugs-To: https://gitlab.gnome.org/GNOME/amtk/issues\n" "POT-Creation-Date: 2020-05-29 12:15+0000\n" "PO-Revision-Date: 2020-06-23 19:16+0100\n" "Language-Team: Portuguese <gnome_pt@yahoogroups.com>\n" "Language: pt\n" "MIME-Version: 1.0\n" "Content-Type: text/plain; charset=UTF-8\n" "Content-Transfer-Encoding: 8bit\n" "Plural-Forms: nplurals=2; plural=(n != 1);\n" "Last-Translator: Manuela Silva <mmsrs@sky.com>\n" "X-Generator: Poedit 2.3.1\n" #. Translators: %s is a filename. #: amtk/amtk-application-window.c:374 #, c-format msgid "Open “%s”" msgstr "Abrir “%s”" #: amtk/amtk-application-window.c:630 msgid "Open _Recent" msgstr "Abrir _Recente" #. Translators: %s is the application name. #: amtk/amtk-application-window.c:633 #, c-format msgid "Open a file recently used with %s" msgstr "Abrir um ficheiro utilizado recentemente com %s" 0707010000004C000081A400000000000000000000000166D2F0DB00003969000000000000000000000000000000000000002000000000libgedit-amtk-5.9.0/po/pt_BR.po# Brazilian Portuguese translation for tepl. # Copyright (C) 2017 tepl's COPYRIGHT HOLDER # This file is distributed under the same license as the tepl package. # Rafael Fontenelle <rafaelff@gnome.org>, 2017. msgid "" msgstr "" "Project-Id-Version: tepl master\n" "Report-Msgid-Bugs-To: https://bugzilla.gnome.org/enter_bug.cgi?product=tepl&k" "eywords=I18N+L10N&component=general\n" "POT-Creation-Date: 2017-12-01 09:23+0000\n" "PO-Revision-Date: 2017-12-12 06:28-0200\n" "Last-Translator: Rafael Fontenelle <rafaelff@gnome.org>\n" "Language-Team: Brazilian Portuguese <gnome-pt_br-list@gnome.org>\n" "Language: pt_BR\n" "MIME-Version: 1.0\n" "Content-Type: text/plain; charset=UTF-8\n" "Content-Transfer-Encoding: 8bit\n" "Plural-Forms: nplurals=2; plural=(n > 1);\n" "X-Generator: Virtaal 1.0.0-beta1\n" "X-Project-Style: gnome\n" #. Translators: %s is a filename. #: amtk/amtk-application-window.c:374 #, c-format msgid "Open “%s”" msgstr "Abrir “%s”" #: amtk/amtk-application-window.c:630 msgid "Open _Recent" msgstr "Abrir _recente" #. Translators: %s is the application name. #: amtk/amtk-application-window.c:633 #, c-format msgid "Open a file recently used with %s" msgstr "Abre um arquivo recentemente usado com %s" #. action, icon, label, accel, tooltip #. File menu #. Why "file" and not "document"? "Document" is not the best #. word because the action is not always to create a new #. document. For example a LaTeX document can be composed of #. several _files_. Or for source code we do not really create a #. new "document". #: tepl/tepl-application.c:92 msgid "_New" msgstr "_Novo" #: tepl/tepl-application.c:93 msgid "New file" msgstr "Novo arquivo" #: tepl/tepl-application.c:95 msgid "New _Window" msgstr "Nova _janela" #: tepl/tepl-application.c:96 msgid "Create a new window" msgstr "Cria uma nova janela" #: tepl/tepl-application.c:98 tepl/tepl-application-window.c:178 msgid "_Open" msgstr "_Abrir" #: tepl/tepl-application.c:99 #| msgid "New file" msgid "Open a file" msgstr "Abre um arquivo" #: tepl/tepl-application.c:101 tepl/tepl-close-confirm-dialog-single.c:144 #: tepl/tepl-tab.c:752 msgid "_Save" msgstr "_Salvar" #: tepl/tepl-application.c:102 msgid "Save the current file" msgstr "Salva o arquivo atual" #: tepl/tepl-application.c:104 msgid "Save _As" msgstr "Salvar _como" #: tepl/tepl-application.c:105 msgid "Save the current file to a different location" msgstr "Salva o arquivo atual em um local diferente" #. Edit menu #: tepl/tepl-application.c:109 msgid "_Undo" msgstr "_Desfazer" #: tepl/tepl-application.c:110 #| msgid "Copy the selection" msgid "Undo the last action" msgstr "Desfaz a última ação" #: tepl/tepl-application.c:112 msgid "_Redo" msgstr "_Refazer" #: tepl/tepl-application.c:113 msgid "Redo the last undone action" msgstr "Refaz a última ação desfeita" #: tepl/tepl-application.c:115 msgid "Cu_t" msgstr "Recor_tar" #: tepl/tepl-application.c:116 msgid "Cut the selection" msgstr "Recorta a seleção" #: tepl/tepl-application.c:118 msgid "_Copy" msgstr "_Copiar" #: tepl/tepl-application.c:119 msgid "Copy the selection" msgstr "Copia a seleção" #: tepl/tepl-application.c:121 msgid "_Paste" msgstr "C_olar" #: tepl/tepl-application.c:122 msgid "Paste the clipboard" msgstr "Cola conteúdo da área de transferência" #: tepl/tepl-application.c:124 msgid "_Delete" msgstr "E_xcluir" #: tepl/tepl-application.c:125 msgid "Delete the selected text" msgstr "Exclui o texto selecionado" #: tepl/tepl-application.c:127 msgid "Select _All" msgstr "Selecionar _tudo" #: tepl/tepl-application.c:128 msgid "Select all the text" msgstr "Seleciona todo o texto" #: tepl/tepl-application.c:130 msgid "_Indent" msgstr "_Recuar" #: tepl/tepl-application.c:131 #| msgid "Delete the selected text" msgid "Indent the selected lines" msgstr "Recua as linhas selecionadas" #: tepl/tepl-application.c:133 msgid "_Unindent" msgstr "Re_tirar recuo" #: tepl/tepl-application.c:134 #| msgid "Delete the selected text" msgid "Unindent the selected lines" msgstr "Retira recuo das linhas selecionadas" #. Create a GtkFileChooserDialog, not a GtkFileChooserNative, because #. * with GtkFileChooserNative the GFile that we obtain (in flatpak) #. * doesn't have the real path to the file, so it would screw up some #. * features for text editors: #. * - showing the directory in parentheses in the window title, or in the #. * tab tooltip; #. * - opening a recent file. #. * Basically everywhere where the directory is shown. #. #: tepl/tepl-application-window.c:174 msgid "Open File" msgstr "Abrir arquivo" #: tepl/tepl-application-window.c:177 #: tepl/tepl-close-confirm-dialog-single.c:138 tepl/tepl-tab.c:751 msgid "_Cancel" msgstr "_Cancelar" #: tepl/tepl-application-window.c:708 msgid "Read-Only" msgstr "Apenas leitura" #: tepl/tepl-close-confirm-dialog-single.c:133 #, c-format msgid "Save changes to file “%s” before closing?" msgstr "Salvar alterações ao arquivo “%s” antes de fechar?" #: tepl/tepl-close-confirm-dialog-single.c:137 msgid "Close _without Saving" msgstr "_Fechar sem salvar" #: tepl/tepl-close-confirm-dialog-single.c:150 msgid "_Save As…" msgstr "_Salvar como…" #. UTF-8 first, so that it's the first encoding returned by #. * tepl_encoding_get_all(). #. #: tepl/tepl-encoding.c:115 tepl/tepl-encoding.c:132 tepl/tepl-encoding.c:133 #: tepl/tepl-encoding.c:134 tepl/tepl-encoding.c:135 tepl/tepl-encoding.c:136 #: tepl/tepl-encoding.c:137 tepl/tepl-encoding.c:138 msgid "Unicode" msgstr "Unicode" #. FIXME GEOSTD8 ? #: tepl/tepl-encoding.c:117 tepl/tepl-encoding.c:129 tepl/tepl-encoding.c:157 #: tepl/tepl-encoding.c:180 msgid "Western" msgstr "Ocidental" #: tepl/tepl-encoding.c:118 tepl/tepl-encoding.c:158 tepl/tepl-encoding.c:178 msgid "Central European" msgstr "Europeu central" #: tepl/tepl-encoding.c:119 msgid "South European" msgstr "Europeu meridional" #: tepl/tepl-encoding.c:120 tepl/tepl-encoding.c:127 tepl/tepl-encoding.c:185 msgid "Baltic" msgstr "Báltico" #: tepl/tepl-encoding.c:121 tepl/tepl-encoding.c:159 tepl/tepl-encoding.c:166 #: tepl/tepl-encoding.c:168 tepl/tepl-encoding.c:169 tepl/tepl-encoding.c:179 msgid "Cyrillic" msgstr "Cirílico" #: tepl/tepl-encoding.c:122 tepl/tepl-encoding.c:162 tepl/tepl-encoding.c:184 msgid "Arabic" msgstr "Arábico" #: tepl/tepl-encoding.c:123 tepl/tepl-encoding.c:181 msgid "Greek" msgstr "Grego" #: tepl/tepl-encoding.c:124 msgid "Hebrew Visual" msgstr "Hebraico visual" #: tepl/tepl-encoding.c:125 tepl/tepl-encoding.c:160 tepl/tepl-encoding.c:182 msgid "Turkish" msgstr "Turco" #: tepl/tepl-encoding.c:126 msgid "Nordic" msgstr "Nórdico" #: tepl/tepl-encoding.c:128 msgid "Celtic" msgstr "Celta" #: tepl/tepl-encoding.c:130 msgid "Romanian" msgstr "Romeno" #: tepl/tepl-encoding.c:140 msgid "Armenian" msgstr "Armênio" #: tepl/tepl-encoding.c:141 tepl/tepl-encoding.c:142 tepl/tepl-encoding.c:150 msgid "Chinese Traditional" msgstr "Chinês tradicional" #: tepl/tepl-encoding.c:143 msgid "Cyrillic/Russian" msgstr "Cirílico/Russo" #: tepl/tepl-encoding.c:145 tepl/tepl-encoding.c:146 tepl/tepl-encoding.c:147 #: tepl/tepl-encoding.c:164 tepl/tepl-encoding.c:172 msgid "Japanese" msgstr "Japonês" #: tepl/tepl-encoding.c:149 tepl/tepl-encoding.c:165 tepl/tepl-encoding.c:167 #: tepl/tepl-encoding.c:175 msgid "Korean" msgstr "Coreano" #: tepl/tepl-encoding.c:152 tepl/tepl-encoding.c:153 tepl/tepl-encoding.c:154 msgid "Chinese Simplified" msgstr "Chinês simplificado" #: tepl/tepl-encoding.c:155 msgid "Georgian" msgstr "Georgiano" #: tepl/tepl-encoding.c:161 tepl/tepl-encoding.c:183 msgid "Hebrew" msgstr "Hebraico" #: tepl/tepl-encoding.c:170 msgid "Cyrillic/Ukrainian" msgstr "Cirílico/Ucraniano" #: tepl/tepl-encoding.c:173 tepl/tepl-encoding.c:176 tepl/tepl-encoding.c:186 msgid "Vietnamese" msgstr "Vietnamita" #: tepl/tepl-encoding.c:174 msgid "Thai" msgstr "Tailandês" #: tepl/tepl-encoding.c:370 msgid "Unknown" msgstr "Desconhecido" #. Translators: This is the sorted list of encodings used by Tepl for #. * automatic detection of the file encoding. You may want to customize #. * it adding encodings that are common in your country, for instance the #. * GB18030 encoding for the Chinese translation. You may also want to #. * remove the ISO-8859-15 encoding (covering English and most Western #. * European languages) if you think people in your country will rarely #. * use it. 'CURRENT' is a magic value used by Tepl and it represents #. * the encoding for the current locale, so please don't translate the #. * 'CURRENT' term. Keep the same format: square brackets, single quotes, #. * commas. #. #: tepl/tepl-encoding.c:695 msgid "['UTF-8', 'CURRENT', 'ISO-8859-15', 'UTF-16']" msgstr "['UTF-8', 'CURRENT', 'ISO-8859-15', 'UTF-16']" #: tepl/tepl-encoding-converter.c:302 #, c-format msgid "Conversion from character set “%s” to “%s” is not supported." msgstr "Não há suporte a conversão de conjunto de caracteres “%s” para “%s”." #: tepl/tepl-encoding-converter.c:311 #, c-format msgid "Could not open converter from “%s” to “%s”: %s" msgstr "Não foi possível abrir o conversor de “%s” para “%s”: %s" #: tepl/tepl-encoding-converter.c:368 msgid "The input data contains an invalid sequence." msgstr "Os dados de entrada contêm uma sequência inválida." #: tepl/tepl-encoding-converter.c:377 #, c-format msgid "Error when converting data: %s" msgstr "Erro ao converter dados: %s" #: tepl/tepl-encoding-converter.c:556 msgid "The input data ends with an incomplete multi-byte sequence." msgstr "Os dados de entrada terminam com uma sequência multibyte incompleta." #: tepl/tepl-encoding-converter.c:579 msgid "The input content ends with incomplete data." msgstr "O conteúdo de entrada termina com dados incompletos." #: tepl/tepl-file.c:413 #, c-format msgid "Untitled File %d" msgstr "Arquivo sem título %d" #: tepl/tepl-file-content-loader.c:331 #, c-format msgid "The file is too big. Maximum %s can be loaded." msgstr "O arquivo é grande demais. No máximo %s pode ser carregado." #: tepl/tepl-file-loader.c:872 msgid "It is not possible to detect the character encoding automatically." msgstr "Não foi possível detectar a codificação de caracteres automaticamente." #: tepl/tepl-file-saver.c:784 msgid "The file is externally modified." msgstr "O arquivo foi modificado externamente." #: tepl/tepl-file-saver.c:1318 msgid "The buffer contains invalid characters." msgstr "O buffer contém caracteres inválidos." #: tepl/tepl-tab.c:534 #| msgid "Error when converting data: %s" msgid "Error when loading the file." msgstr "Erro ao carregar o arquivo." #: tepl/tepl-tab.c:748 msgid "Save File" msgstr "Salvar arquivo" #. Translators: location of a file. #: tepl/tepl-tab-label.c:273 msgid "Location:" msgstr "Localização:" #: tepl/tepl-tab-label.c:342 msgid "Close file" msgstr "Fecha o arquivo" #: tepl/tepl-tab-saving.c:64 #| msgid "Error when converting data: %s" msgid "Error when saving the file." msgstr "Erro ao salvar o arquivo." #~ msgid "Could not find the file “%s”." #~ msgstr "Não foi possível localizar o arquivo “%s”." #~ msgid "Please check that you typed the location correctly and try again." #~ msgstr "" #~ "Por favor, verifique se você digitou a localização correta e tente " #~ "novamente." #~ msgid "Unable to handle “%s:” locations." #~ msgstr "Não é possível tratar de localizações “%s:”." #~ msgid "The location of the file cannot be accessed." #~ msgstr "A localização do arquivo não pode ser acessada." #~ msgid "“%s” is a directory." #~ msgstr "“%s” é um diretório." #~ msgid "“%s” is not a valid location." #~ msgstr "“%s” não é uma localização válida." #~ msgid "" #~ "Host “%s” could not be found. Please check that your proxy settings are " #~ "correct and try again." #~ msgstr "" #~ "O host “%s” não pôde ser localizado. Por favor, verifique suas " #~ "configurações de proxy e tente novamente." #~ msgid "" #~ "Hostname was invalid. Please check that you typed the location correctly " #~ "and try again." #~ msgstr "" #~ "Nome de máquina inválido. Por favor, verifique se você digitou a " #~ "localização corretamente e tente novamente." #~ msgid "“%s” is not a regular file." #~ msgstr "“%s” não é uma arquivo comum." #~ msgid "Connection timed out. Please try again." #~ msgstr "Tempo expirada. Por favor, tente novamente." #~ msgid "Unexpected error: %s" #~ msgstr "Erro inesperado: %s" #~ msgid "_Retry" #~ msgstr "_Tentar novamente" #~ msgid "Edit Any_way" #~ msgstr "_Editar assim mesmo" #~ msgid "" #~ "The number of followed links is limited and the actual file could not be " #~ "found within this limit." #~ msgstr "" #~ "O número de links seguidos é limitado e o arquivo não pôde ser localizado " #~ "dentro deste limite." #~ msgid "You do not have the permissions necessary to open the file." #~ msgstr "Você não possui as permissões necessárias para abrir o arquivo." #~ msgid "" #~ "Unable to detect the character encoding.\n" #~ "Please check that you are not trying to open a binary file.\n" #~ "Select a character encoding from the menu and try again." #~ msgstr "" #~ "Não foi possível detectar a codificação de caracteres.\n" #~ "Por favor, certifique-se de que você não está tentando abrir um arquivo " #~ "binário.\n" #~ "Selecione uma codificação de caracteres do menu e tente novamente." #~ msgid "There was a problem opening the file “%s”." #~ msgstr "Houve um problema ao abrir o arquivo “%s”." #~ msgid "" #~ "The file you opened has some invalid characters. If you continue editing " #~ "this file you could corrupt it.\n" #~ "You can also choose another character encoding and try again." #~ msgstr "" #~ "O arquivo que você abrir possui alguns caracteres inválidos. Se você " #~ "continuar a editar esse arquivo, você pode corrompê-lo.\n" #~ "Você também pode escolher uma outra codificação de caracteres e tentar " #~ "novamente." #~ msgid "Could not open the file “%s” using the “%s” character encoding." #~ msgstr "" #~ "Não foi possível abrir o arquivo “%s” usando a codificação de caracteres " #~ "“%s”." #~ msgid "" #~ "Please check that you are not trying to open a binary file.\n" #~ "Select a different character encoding from the menu and try again." #~ msgstr "" #~ "Por favor, certifique-se de que você não está tentando abrir um arquivo " #~ "binário.\n" #~ "Selecione uma codificação de caracteres diferente do menu e tente " #~ "novamente." #~ msgid "Could not open the file “%s”." #~ msgstr "Não foi possível abrir o arquivo “%s”." 0707010000004D000081A400000000000000000000000166D2F0DB0000049F000000000000000000000000000000000000001D00000000libgedit-amtk-5.9.0/po/ro.po# Romanian translation for amtk. # Copyright (C) 2018 amtk's COPYRIGHT HOLDER # This file is distributed under the same license as the amtk package. # Floren <>, 2018. # msgid "" msgstr "" "Project-Id-Version: amtk master\n" "Report-Msgid-Bugs-To: https://gitlab.gnome.org/GNOME/amtk/issues\n" "POT-Creation-Date: 2018-06-12 18:03+0000\n" "PO-Revision-Date: 2018-06-19 00:23+0300\n" "Language-Team: Romanian <gnomero-list@lists.sourceforge.net>\n" "Language: ro\n" "MIME-Version: 1.0\n" "Content-Type: text/plain; charset=UTF-8\n" "Content-Transfer-Encoding: 8bit\n" "Plural-Forms: nplurals=3; plural=(n==1 ? 0 : (n==0 || (n%100 > 0 && n%100 < 20)) ? 1 : 2);;\n" "Last-Translator: Florentina Mușat <florentina.musat.28 [at] gmail [dot] com>\n" "X-Generator: Poedit 2.0.8\n" #. Translators: %s is a filename. #: amtk/amtk-application-window.c:374 #, c-format msgid "Open “%s”" msgstr "Deschide „%s”" #: amtk/amtk-application-window.c:630 msgid "Open _Recent" msgstr "Deschide _recent" #. Translators: %s is the application name. #: amtk/amtk-application-window.c:633 #, c-format msgid "Open a file recently used with %s" msgstr "Deschide un fișier utilizat recent cu %s" 0707010000004E000081A400000000000000000000000166D2F0DB00001C7D000000000000000000000000000000000000001D00000000libgedit-amtk-5.9.0/po/ru.po# Russian translation for tepl. # Copyright (C) 2017 tepl's COPYRIGHT HOLDER # This file is distributed under the same license as the tepl package. # FIRST AUTHOR <EMAIL@ADDRESS>, YEAR. # msgid "" msgstr "" "Project-Id-Version: tepl master\n" "Report-Msgid-Bugs-To: \n" "POT-Creation-Date: 2017-03-19 11:57+0000\n" "PO-Revision-Date: 2017-03-25 22:57+0500\n" "Language-Team: Russian <gnome-cyr@gnome.org>\n" "Language: ru\n" "MIME-Version: 1.0\n" "Content-Type: text/plain; charset=UTF-8\n" "Content-Transfer-Encoding: 8bit\n" "Plural-Forms: nplurals=3; plural=(n%10==1 && n%100!=11 ? 0 : n%10>=2 && n%10<=4 && (n%100<10 || n%100>=20) ? 1 : 2);\n" "Last-Translator: Pavel Elizaryev <gonleef@tuta.io>\n" "X-Generator: Poedit 1.8.11\n" #. Translators: %s is a filename. #: tepl/tepl-application-window.c:356 #, c-format msgid "Open “%s”" msgstr "Открыть «%s»" #: tepl/tepl-application-window.c:575 msgid "Open _Recent" msgstr "Открыть _недавние" #. Translators: %s is the application name. #: tepl/tepl-application-window.c:578 #, c-format msgid "Open a file recently used with %s" msgstr "Открыть файл, который недавно использовался с «%s»" #. UTF-8 first, so that it's the first encoding returned by #. * tepl_encoding_get_all(). #. #: tepl/tepl-encoding.c:115 tepl/tepl-encoding.c:132 tepl/tepl-encoding.c:133 #: tepl/tepl-encoding.c:134 tepl/tepl-encoding.c:135 tepl/tepl-encoding.c:136 #: tepl/tepl-encoding.c:137 tepl/tepl-encoding.c:138 msgid "Unicode" msgstr "Юникод" #. FIXME GEOSTD8 ? #: tepl/tepl-encoding.c:117 tepl/tepl-encoding.c:129 tepl/tepl-encoding.c:157 #: tepl/tepl-encoding.c:180 msgid "Western" msgstr "Западная" #: tepl/tepl-encoding.c:118 tepl/tepl-encoding.c:158 tepl/tepl-encoding.c:178 msgid "Central European" msgstr "Центральноевропейская" #: tepl/tepl-encoding.c:119 msgid "South European" msgstr "Южноевропейская" #: tepl/tepl-encoding.c:120 tepl/tepl-encoding.c:127 tepl/tepl-encoding.c:185 msgid "Baltic" msgstr "Балтийская" #: tepl/tepl-encoding.c:121 tepl/tepl-encoding.c:159 tepl/tepl-encoding.c:166 #: tepl/tepl-encoding.c:168 tepl/tepl-encoding.c:169 tepl/tepl-encoding.c:179 msgid "Cyrillic" msgstr "Кириллица" #: tepl/tepl-encoding.c:122 tepl/tepl-encoding.c:162 tepl/tepl-encoding.c:184 msgid "Arabic" msgstr "Арабская" #: tepl/tepl-encoding.c:123 tepl/tepl-encoding.c:181 msgid "Greek" msgstr "Греческая" #: tepl/tepl-encoding.c:124 msgid "Hebrew Visual" msgstr "Еврейская отображаемая" #: tepl/tepl-encoding.c:125 tepl/tepl-encoding.c:160 tepl/tepl-encoding.c:182 msgid "Turkish" msgstr "Турецкая" #: tepl/tepl-encoding.c:126 msgid "Nordic" msgstr "Северная" #: tepl/tepl-encoding.c:128 msgid "Celtic" msgstr "Кельтская" #: tepl/tepl-encoding.c:130 msgid "Romanian" msgstr "Римская" #: tepl/tepl-encoding.c:140 msgid "Armenian" msgstr "Армянская" #: tepl/tepl-encoding.c:141 tepl/tepl-encoding.c:142 tepl/tepl-encoding.c:150 msgid "Chinese Traditional" msgstr "Китайская традиционная" #: tepl/tepl-encoding.c:143 msgid "Cyrillic/Russian" msgstr "Кириллица (российская)" #: tepl/tepl-encoding.c:145 tepl/tepl-encoding.c:146 tepl/tepl-encoding.c:147 #: tepl/tepl-encoding.c:164 tepl/tepl-encoding.c:172 msgid "Japanese" msgstr "Японская" #: tepl/tepl-encoding.c:149 tepl/tepl-encoding.c:165 tepl/tepl-encoding.c:167 #: tepl/tepl-encoding.c:175 msgid "Korean" msgstr "Корейская" #: tepl/tepl-encoding.c:152 tepl/tepl-encoding.c:153 tepl/tepl-encoding.c:154 msgid "Chinese Simplified" msgstr "Китайская упрощённая" #: tepl/tepl-encoding.c:155 msgid "Georgian" msgstr "Грузинская" #: tepl/tepl-encoding.c:161 tepl/tepl-encoding.c:183 msgid "Hebrew" msgstr "Еврейская" #: tepl/tepl-encoding.c:170 msgid "Cyrillic/Ukrainian" msgstr "Кириллица (украинская)" #: tepl/tepl-encoding.c:173 tepl/tepl-encoding.c:176 tepl/tepl-encoding.c:186 msgid "Vietnamese" msgstr "Вьетнамская" #: tepl/tepl-encoding.c:174 msgid "Thai" msgstr "Тайская" #: tepl/tepl-encoding.c:365 msgid "Unknown" msgstr "Неизвестная" #. Translators: This is the sorted list of encodings used by Tepl for #. * automatic detection of the file encoding. You may want to customize #. * it adding encodings that are common in your country, for instance the #. * GB18030 encoding for the Chinese translation. You may also want to #. * remove the ISO-8859-15 encoding (covering English and most Western #. * European languages) if you think people in your country will rarely #. * use it. 'CURRENT' is a magic value used by Tepl and it represents #. * the encoding for the current locale, so please don't translate the #. * 'CURRENT' term. Keep the same format: square brackets, single quotes, #. * commas. #. #: tepl/tepl-encoding.c:640 msgid "['UTF-8', 'CURRENT', 'ISO-8859-15', 'UTF-16']" msgstr "['UTF-8', 'CURRENT', 'ISO-8859-5', 'UTF-16', ' KOI8-R']" #: tepl/tepl-encoding-converter.c:302 #, c-format msgid "Conversion from character set “%s” to “%s” is not supported." msgstr "Преобразование из набора символов «%s» в «%s» не поддерживается." #: tepl/tepl-encoding-converter.c:311 #, c-format msgid "Could not open converter from “%s” to “%s”: %s" msgstr "Не удалось открыть конвертер из «%s» в «%s»: «%s»" #: tepl/tepl-encoding-converter.c:368 msgid "The input data contains an invalid sequence." msgstr "Входные данные содержат недопустимую последовательность." #: tepl/tepl-encoding-converter.c:377 #, c-format msgid "Error when converting data: %s" msgstr "Ошибка при конвертировании данных: «%s»" #: tepl/tepl-encoding-converter.c:556 msgid "The input data ends with an incomplete multi-byte sequence." msgstr "Входные данные заканчиваются незавершенной многобайтовой последовательностью." #: tepl/tepl-encoding-converter.c:579 msgid "The input content ends with incomplete data." msgstr "Содержимое ввода заканчивается незавершенными данными." #: tepl/tepl-file.c:413 #, c-format msgid "Untitled File %d" msgstr "Безымянный файл %d" #: tepl/tepl-file-content-loader.c:334 #, c-format msgid "The file is too big. Maximum %s can be loaded." msgstr "Файл слишком большой. Максимальный размер загрузки «%s»." #: tepl/tepl-file-loader.c:925 msgid "It is not possible to detect the character encoding automatically." msgstr "Не удалось автоматически определить кодировку." #: tepl/tepl-file-saver.c:784 msgid "The file is externally modified." msgstr "Файл был модифицирован внешней программой." #: tepl/tepl-file-saver.c:1318 msgid "The buffer contains invalid characters." msgstr "Буфер содержит недопустимые символы." 0707010000004F000081A400000000000000000000000166D2F0DB00000D98000000000000000000000000000000000000001D00000000libgedit-amtk-5.9.0/po/sl.po# Slovenian translation for amtk. # Copyright (C) 2017 amtk's COPYRIGHT HOLDER # This file is distributed under the same license as the amtk package. # # Matej Urbančič <mateju@svn.gnome.org>, + 2017–2018. # msgid "" msgstr "" "Project-Id-Version: amtk master\n" "Report-Msgid-Bugs-To: https://gitlab.gnome.org/GNOME/amtk/issues\n" "POT-Creation-Date: 2018-07-16 10:30+0000\n" "PO-Revision-Date: 2018-08-10 20:07+0200\n" "Last-Translator: Matej Urbančič <mateju@svn.gnome.org>\n" "Language-Team: Slovenian GNOME Translation Team <gnome-si@googlegroups.com>\n" "Language: sl_SI\n" "MIME-Version: 1.0\n" "Content-Type: text/plain; charset=UTF-8\n" "Content-Transfer-Encoding: 8bit\n" "Plural-Forms: nplurals=4; plural=(n%100==1 ? 1 : n%100==2 ? 2 : n%100==3 || n" "%100==4 ? 3 : 0);\n" "X-Poedit-SourceCharset: UTF-8\n" "X-Generator: Poedit 2.0.6\n" #. Translators: %s is a filename. #: amtk/amtk-application-window.c:374 #, c-format msgid "Open “%s”" msgstr "Odpri »%s«" #: amtk/amtk-application-window.c:630 msgid "Open _Recent" msgstr "Odpri _nedavno" #. Translators: %s is the application name. #: amtk/amtk-application-window.c:633 #, c-format msgid "Open a file recently used with %s" msgstr "Odpri datoteko, nazadnje uporabljeno s programom %s" #~ msgid "Unicode" #~ msgstr "Unicode" #~ msgid "Western" #~ msgstr "Zahodnjaški" #~ msgid "Central European" #~ msgstr "Srednjeevropski" #~ msgid "South European" #~ msgstr "Južnoevropski" #~ msgid "Baltic" #~ msgstr "Baltski" #~ msgid "Cyrillic" #~ msgstr "Cirilično" #~ msgid "Arabic" #~ msgstr "Arabski" #~ msgid "Greek" #~ msgstr "Grški" #~ msgid "Hebrew Visual" #~ msgstr "Hebrejski predočeni" #~ msgid "Turkish" #~ msgstr "Turški" #~ msgid "Nordic" #~ msgstr "Nordijski" #~ msgid "Celtic" #~ msgstr "Keltski" #~ msgid "Romanian" #~ msgstr "Romunski" #~ msgid "Armenian" #~ msgstr "Armenski" #~ msgid "Chinese Traditional" #~ msgstr "Kitajski tradicionalen" #~ msgid "Cyrillic/Russian" #~ msgstr "Cirilica/Ruski" #~ msgid "Japanese" #~ msgstr "Japonski" #~ msgid "Korean" #~ msgstr "Korejski" #~ msgid "Chinese Simplified" #~ msgstr "Kitajski poenostavljen" #~ msgid "Georgian" #~ msgstr "Gruzijski" #~ msgid "Hebrew" #~ msgstr "Hebrejski" #~ msgid "Cyrillic/Ukrainian" #~ msgstr "Cirilica/Ukrajinski" #~ msgid "Vietnamese" #~ msgstr "Vietnamski" #~ msgid "Thai" #~ msgstr "Tajski" #~ msgid "Unknown" #~ msgstr "Neznano" #~ msgid "['UTF-8', 'CURRENT', 'ISO-8859-15', 'UTF-16']" #~ msgstr "['UTF-8', 'TRENUTNI', 'ISO-8859-15', 'UTF-16']" #, fuzzy #~ msgid "Conversion from character set “%s” to “%s” is not supported." #~ msgstr "Pretvorba iz nabora znakov »%s« v »%s« ni podprta" #, fuzzy #~ msgid "Could not open converter from “%s” to “%s”: %s" #~ msgstr "Ni mogoče odpreti pretvornika iz »%s« v »%s«: %s" #, fuzzy #~ msgid "The input data contains an invalid sequence." #~ msgstr "Neveljavno zaporedje bajtov na vhodu pretvorbe" #, fuzzy #~ msgid "Error when converting data: %s" #~ msgstr "Napaka med pretvarjanjem podatkov: %s" #, fuzzy #~ msgid "Untitled File %d" #~ msgstr "Nepoimenovana datoteka %d" #, fuzzy #~ msgid "It is not possible to detect the character encoding automatically." #~ msgstr "Ni mogoče določiti nabora znakov v datoteki." #~ msgid "The file is externally modified." #~ msgstr "Datoteka je močno spremenjena." #~ msgid "The buffer contains invalid characters." #~ msgstr "Medpomnilnik vsebuje neveljavne znake." 07070100000050000081A400000000000000000000000166D2F0DB000040BE000000000000000000000000000000000000001D00000000libgedit-amtk-5.9.0/po/sr.po# Serbian translation for tepl. # Copyright © 2017 tepl's COPYRIGHT HOLDER # This file is distributed under the same license as the tepl package. # Мирослав Николић <miroslavnikolic@rocketmail.com>, 2017–2018. msgid "" msgstr "" "Project-Id-Version: tepl master\n" "Report-Msgid-Bugs-To: https://bugzilla.gnome.org/enter_bug.cgi?product=tepl&k" "eywords=I18N+L10N&component=general\n" "POT-Creation-Date: 2017-12-01 09:23+0000\n" "PO-Revision-Date: 2018-02-23 00:49+0200\n" "Last-Translator: Мирослав Николић <miroslavnikolic@rocketmail.com>\n" "Language-Team: српски <gnome-sr@googlegroups.org>\n" "Language: sr\n" "MIME-Version: 1.0\n" "Content-Type: text/plain; charset=UTF-8\n" "Content-Transfer-Encoding: 8bit\n" "Plural-Forms: nplurals=4; plural=n==1? 3 : n%10==1 && n%100!=11 ? 0 : " "n%10>=2 && n%10<=4 && (n%100<10 || n%100>=20) ? 1 : 2;\n" "X-Project-Style: gnome\n" #. Translators: %s is a filename. #: amtk/amtk-application-window.c:374 #, c-format msgid "Open “%s”" msgstr "Отварам „%s“" #: amtk/amtk-application-window.c:630 msgid "Open _Recent" msgstr "Отвори _скорашње" #. Translators: %s is the application name. #: amtk/amtk-application-window.c:633 #, c-format msgid "Open a file recently used with %s" msgstr "Отворите датотеку коју је недавно користио „%s“" #. action, icon, label, accel, tooltip #. File menu #. Why "file" and not "document"? "Document" is not the best #. word because the action is not always to create a new #. document. For example a LaTeX document can be composed of #. several _files_. Or for source code we do not really create a #. new "document". #: tepl/tepl-application.c:92 msgid "_New" msgstr "_Нова" #: tepl/tepl-application.c:93 msgid "New file" msgstr "Нова датотека" #: tepl/tepl-application.c:95 msgid "New _Window" msgstr "Нови _прозор" #: tepl/tepl-application.c:96 msgid "Create a new window" msgstr "Направите нови прозор" #: tepl/tepl-application.c:98 tepl/tepl-application-window.c:178 msgid "_Open" msgstr "_Отвори" #: tepl/tepl-application.c:99 #| msgid "New file" msgid "Open a file" msgstr "Отворите датотеку" #: tepl/tepl-application.c:101 tepl/tepl-close-confirm-dialog-single.c:144 #: tepl/tepl-tab.c:752 msgid "_Save" msgstr "_Сачувај" #: tepl/tepl-application.c:102 msgid "Save the current file" msgstr "Сачувајте текућу датотеку" #: tepl/tepl-application.c:104 msgid "Save _As" msgstr "Сачувај _као" #: tepl/tepl-application.c:105 msgid "Save the current file to a different location" msgstr "Сачувајте текућу датотеку на другом месту" #. Edit menu #: tepl/tepl-application.c:109 msgid "_Undo" msgstr "_Опозови" #: tepl/tepl-application.c:110 #| msgid "Copy the selection" msgid "Undo the last action" msgstr "Опозовите последњу радњу" #: tepl/tepl-application.c:112 msgid "_Redo" msgstr "_Понови" #: tepl/tepl-application.c:113 msgid "Redo the last undone action" msgstr "Поништите последњу раду опозива" #: tepl/tepl-application.c:115 msgid "Cu_t" msgstr "_Исеци" #: tepl/tepl-application.c:116 msgid "Cut the selection" msgstr "Исеците избор" #: tepl/tepl-application.c:118 msgid "_Copy" msgstr "У_множи" #: tepl/tepl-application.c:119 msgid "Copy the selection" msgstr "Умножите избор" #: tepl/tepl-application.c:121 msgid "_Paste" msgstr "У_баци" #: tepl/tepl-application.c:122 msgid "Paste the clipboard" msgstr "Убаците из оставе" #: tepl/tepl-application.c:124 msgid "_Delete" msgstr "_Обриши" #: tepl/tepl-application.c:125 msgid "Delete the selected text" msgstr "Обришите изабрани текст" #: tepl/tepl-application.c:127 msgid "Select _All" msgstr "Изабери _све" #: tepl/tepl-application.c:128 msgid "Select all the text" msgstr "Изаберите сав текст" #: tepl/tepl-application.c:130 msgid "_Indent" msgstr "_Увуци" #: tepl/tepl-application.c:131 #| msgid "Delete the selected text" msgid "Indent the selected lines" msgstr "Увуците изабране редове" #: tepl/tepl-application.c:133 msgid "_Unindent" msgstr "_Поништи увлачење" #: tepl/tepl-application.c:134 #| msgid "Delete the selected text" msgid "Unindent the selected lines" msgstr "Поништите увлачење изабраних редова" #. Create a GtkFileChooserDialog, not a GtkFileChooserNative, because #. * with GtkFileChooserNative the GFile that we obtain (in flatpak) #. * doesn't have the real path to the file, so it would screw up some #. * features for text editors: #. * - showing the directory in parentheses in the window title, or in the #. * tab tooltip; #. * - opening a recent file. #. * Basically everywhere where the directory is shown. #. #: tepl/tepl-application-window.c:174 msgid "Open File" msgstr "Отвори датотеку" #: tepl/tepl-application-window.c:177 #: tepl/tepl-close-confirm-dialog-single.c:138 tepl/tepl-tab.c:751 msgid "_Cancel" msgstr "_Откажи" #: tepl/tepl-application-window.c:708 msgid "Read-Only" msgstr "Само за читање" #: tepl/tepl-close-confirm-dialog-single.c:133 #, c-format msgid "Save changes to file “%s” before closing?" msgstr "Да сачувам измене у датотеку „%s“ пре затварања?" #: tepl/tepl-close-confirm-dialog-single.c:137 msgid "Close _without Saving" msgstr "Затвори _без чувања" #: tepl/tepl-close-confirm-dialog-single.c:150 msgid "_Save As…" msgstr "_Сачувај као…" #. UTF-8 first, so that it's the first encoding returned by #. * tepl_encoding_get_all(). #. #: tepl/tepl-encoding.c:115 tepl/tepl-encoding.c:132 tepl/tepl-encoding.c:133 #: tepl/tepl-encoding.c:134 tepl/tepl-encoding.c:135 tepl/tepl-encoding.c:136 #: tepl/tepl-encoding.c:137 tepl/tepl-encoding.c:138 msgid "Unicode" msgstr "Уникод" #. FIXME GEOSTD8 ? #: tepl/tepl-encoding.c:117 tepl/tepl-encoding.c:129 tepl/tepl-encoding.c:157 #: tepl/tepl-encoding.c:180 msgid "Western" msgstr "Западни" #: tepl/tepl-encoding.c:118 tepl/tepl-encoding.c:158 tepl/tepl-encoding.c:178 msgid "Central European" msgstr "Централноевропски" #: tepl/tepl-encoding.c:119 msgid "South European" msgstr "Јужноевропски" #: tepl/tepl-encoding.c:120 tepl/tepl-encoding.c:127 tepl/tepl-encoding.c:185 msgid "Baltic" msgstr "Балтички" #: tepl/tepl-encoding.c:121 tepl/tepl-encoding.c:159 tepl/tepl-encoding.c:166 #: tepl/tepl-encoding.c:168 tepl/tepl-encoding.c:169 tepl/tepl-encoding.c:179 msgid "Cyrillic" msgstr "Ћирилични" #: tepl/tepl-encoding.c:122 tepl/tepl-encoding.c:162 tepl/tepl-encoding.c:184 msgid "Arabic" msgstr "Арапски" #: tepl/tepl-encoding.c:123 tepl/tepl-encoding.c:181 msgid "Greek" msgstr "Грчки" #: tepl/tepl-encoding.c:124 msgid "Hebrew Visual" msgstr "Хебрејски визуелни" #: tepl/tepl-encoding.c:125 tepl/tepl-encoding.c:160 tepl/tepl-encoding.c:182 msgid "Turkish" msgstr "Турски" #: tepl/tepl-encoding.c:126 msgid "Nordic" msgstr "Нордијски" #: tepl/tepl-encoding.c:128 msgid "Celtic" msgstr "Келтски" #: tepl/tepl-encoding.c:130 msgid "Romanian" msgstr "Румунски" #: tepl/tepl-encoding.c:140 msgid "Armenian" msgstr "Јерменски" #: tepl/tepl-encoding.c:141 tepl/tepl-encoding.c:142 tepl/tepl-encoding.c:150 msgid "Chinese Traditional" msgstr "Кинески традиционални" #: tepl/tepl-encoding.c:143 msgid "Cyrillic/Russian" msgstr "Ћирилични/Руски" #: tepl/tepl-encoding.c:145 tepl/tepl-encoding.c:146 tepl/tepl-encoding.c:147 #: tepl/tepl-encoding.c:164 tepl/tepl-encoding.c:172 msgid "Japanese" msgstr "Јапански" #: tepl/tepl-encoding.c:149 tepl/tepl-encoding.c:165 tepl/tepl-encoding.c:167 #: tepl/tepl-encoding.c:175 msgid "Korean" msgstr "Корејски" #: tepl/tepl-encoding.c:152 tepl/tepl-encoding.c:153 tepl/tepl-encoding.c:154 msgid "Chinese Simplified" msgstr "Кинески поједностављени" #: tepl/tepl-encoding.c:155 msgid "Georgian" msgstr "Грузијски" #: tepl/tepl-encoding.c:161 tepl/tepl-encoding.c:183 msgid "Hebrew" msgstr "Хебрејски" #: tepl/tepl-encoding.c:170 msgid "Cyrillic/Ukrainian" msgstr "Ћирилични/Украјински" #: tepl/tepl-encoding.c:173 tepl/tepl-encoding.c:176 tepl/tepl-encoding.c:186 msgid "Vietnamese" msgstr "Вијетнамски" #: tepl/tepl-encoding.c:174 msgid "Thai" msgstr "Тајландски" #: tepl/tepl-encoding.c:370 msgid "Unknown" msgstr "Непознат" #. Translators: This is the sorted list of encodings used by Tepl for #. * automatic detection of the file encoding. You may want to customize #. * it adding encodings that are common in your country, for instance the #. * GB18030 encoding for the Chinese translation. You may also want to #. * remove the ISO-8859-15 encoding (covering English and most Western #. * European languages) if you think people in your country will rarely #. * use it. 'CURRENT' is a magic value used by Tepl and it represents #. * the encoding for the current locale, so please don't translate the #. * 'CURRENT' term. Keep the same format: square brackets, single quotes, #. * commas. #. #: tepl/tepl-encoding.c:695 msgid "['UTF-8', 'CURRENT', 'ISO-8859-15', 'UTF-16']" msgstr "['UTF-8', 'CURRENT', 'ISO-8859-15', 'UTF-16']" #: tepl/tepl-encoding-converter.c:302 #, c-format msgid "Conversion from character set “%s” to “%s” is not supported." msgstr "Претварање из скупа знакова „%s“ у „%s“ још није подржано." #: tepl/tepl-encoding-converter.c:311 #, c-format msgid "Could not open converter from “%s” to “%s”: %s" msgstr "Не могу да отворим претварач из „%s“ у „%s“: %s" #: tepl/tepl-encoding-converter.c:368 msgid "The input data contains an invalid sequence." msgstr "Улазни подаци садрже неисправан низ." #: tepl/tepl-encoding-converter.c:377 #, c-format msgid "Error when converting data: %s" msgstr "Грешка приликом претварања података: %s" #: tepl/tepl-encoding-converter.c:556 msgid "The input data ends with an incomplete multi-byte sequence." msgstr "Улазни подаци се завршавају непотпуним вишебајтним низом." #: tepl/tepl-encoding-converter.c:579 msgid "The input content ends with incomplete data." msgstr "Улаз садржи крај са непотпуним подацима." #: tepl/tepl-file.c:413 #, c-format msgid "Untitled File %d" msgstr "Неименована датотека %d" #: tepl/tepl-file-content-loader.c:331 #, c-format msgid "The file is too big. Maximum %s can be loaded." msgstr "Датотека је превелика. Највише %s може бити учитано." #: tepl/tepl-file-loader.c:872 msgid "It is not possible to detect the character encoding automatically." msgstr "Не могу аутоматски да одредим кодирање знакова." #: tepl/tepl-file-saver.c:784 msgid "The file is externally modified." msgstr "Датотека је измењена споља." #: tepl/tepl-file-saver.c:1318 msgid "The buffer contains invalid characters." msgstr "Међумеморија садржи неисправне знаке." #: tepl/tepl-tab.c:534 #| msgid "Error when converting data: %s" msgid "Error when loading the file." msgstr "Грешка приликом учитавања датотеке." #: tepl/tepl-tab.c:748 msgid "Save File" msgstr "Сачувај датотеку" #. Translators: location of a file. #: tepl/tepl-tab-label.c:273 msgid "Location:" msgstr "Место:" #: tepl/tepl-tab-label.c:342 msgid "Close file" msgstr "Затвори датотеку" #: tepl/tepl-tab-saving.c:64 #| msgid "Error when converting data: %s" msgid "Error when saving the file." msgstr "Грешка приликом чувања датотеке." #~ msgid "Could not find the file “%s”." #~ msgstr "Не могу да нађем датотеку „%s“." #~ msgid "Please check that you typed the location correctly and try again." #~ msgstr "Проверите да ли сте исправно укуцали место и пробајте поново." #~ msgid "Unable to handle “%s:” locations." #~ msgstr "Не могу да радим са „%s:“ местима." #~ msgid "The location of the file cannot be accessed." #~ msgstr "Не могу да приступим месту датотеке." #~ msgid "“%s” is a directory." #~ msgstr "„%s“ је директоријум." #~ msgid "“%s” is not a valid location." #~ msgstr "„%s“ није исправно место." #~ msgid "" #~ "Host “%s” could not be found. Please check that your proxy settings are " #~ "correct and try again." #~ msgstr "" #~ "Не могу да нађем домаћина „%s“. Проверите да ли су ваша подешавања " #~ "посредника исправна и пробајте поново." #~ msgid "" #~ "Hostname was invalid. Please check that you typed the location correctly " #~ "and try again." #~ msgstr "" #~ "Назив домаћина беше неисправан. Проверите да ли сте исправно укуцали " #~ "место и пробајте поново." #~ msgid "“%s” is not a regular file." #~ msgstr "„%s“ није обична датотека." #~ msgid "Connection timed out. Please try again." #~ msgstr "Истекло је време за везу. Пробајте поново." #~ msgid "Unexpected error: %s" #~ msgstr "Неочекивана грешка: %s" #~ msgid "_Retry" #~ msgstr "_Покушај поново" #~ msgid "Edit Any_way" #~ msgstr "Уреди _ипак" #~ msgid "" #~ "The number of followed links is limited and the actual file could not be " #~ "found within this limit." #~ msgstr "" #~ "Број праћених веза је ограничен, а стварну датотеку не могу пронаћи у " #~ "овом опсегу." #~ msgid "You do not have the permissions necessary to open the file." #~ msgstr "Немате потребна овлашћења да отворите датотеку." #~ msgid "" #~ "Unable to detect the character encoding.\n" #~ "Please check that you are not trying to open a binary file.\n" #~ "Select a character encoding from the menu and try again." #~ msgstr "" #~ "Не могу да откријем кодирање знакова.\n" #~ "Проверите да не покушавате да отворите бинарну датотеку.\n" #~ "Изабери кодирање знакова из изборника и покушајте поново." #~ msgid "There was a problem opening the file “%s”." #~ msgstr "Дошло је до проблема при отварању датотеке „%s“." #~ msgid "" #~ "The file you opened has some invalid characters. If you continue editing " #~ "this file you could corrupt it.\n" #~ "You can also choose another character encoding and try again." #~ msgstr "" #~ "Датотека коју сте отворили има неке неисправне знакове. Ако наставите да " #~ "је уређујете можете да је оштетите.\n" #~ "Такође можете да изаберете други кодни распоред и да покушате поново." #~ msgid "Could not open the file “%s” using the “%s” character encoding." #~ msgstr "Не могу да отворим датотеку „%s“ користећи „%s“ кодирање знакова." #~ msgid "" #~ "Please check that you are not trying to open a binary file.\n" #~ "Select a different character encoding from the menu and try again." #~ msgstr "" #~ "Проверите да не покушавате да отворите бинарну датотеку.\n" #~ "Изабери други кодни распоред из изборника и покушајте поново." #~ msgid "Could not open the file “%s”." #~ msgstr "Не могу да отворим датотеку „%s“." 07070100000051000081A400000000000000000000000166D2F0DB00003646000000000000000000000000000000000000001D00000000libgedit-amtk-5.9.0/po/sv.po# Swedish translation for tepl. # Copyright © 2017, 2018 tepl's COPYRIGHT HOLDER # This file is distributed under the same license as the tepl package. # Anders Jonsson <anders.jonsson@norsjovallen.se>, 2017, 2018. # Josef Andersson <l10nl18nsweja@gmail.com>, 2017. # msgid "" msgstr "" "Project-Id-Version: tepl master\n" "Report-Msgid-Bugs-To: https://gitlab.gnome.org/GNOME/amtk/issues\n" "POT-Creation-Date: 2018-02-27 19:31+0000\n" "PO-Revision-Date: 2018-03-11 22:01+0100\n" "Last-Translator: Anders Jonsson <anders.jonsson@norsjovallen.se>\n" "Language-Team: Swedish <tp-sv@listor.tp-sv.se>\n" "Language: sv\n" "MIME-Version: 1.0\n" "Content-Type: text/plain; charset=UTF-8\n" "Content-Transfer-Encoding: 8bit\n" "Plural-Forms: nplurals=2; plural=(n != 1);\n" "X-Generator: Poedit 2.0.6\n" #. Translators: %s is a filename. #: amtk/amtk-application-window.c:374 #, c-format msgid "Open “%s”" msgstr "Öppna ”%s”" #: amtk/amtk-application-window.c:630 msgid "Open _Recent" msgstr "Öppna _senaste" #. Translators: %s is the application name. #: amtk/amtk-application-window.c:633 #, c-format msgid "Open a file recently used with %s" msgstr "Öppna en fil som tidigare använts med %s" #. action, icon, label, accel, tooltip #. File menu #. Why "file" and not "document"? "Document" is not the best #. word because the action is not always to create a new #. document. For example a LaTeX document can be composed of #. several _files_. Or for source code we do not really create a #. new "document". #: tepl/tepl-application.c:92 msgid "_New" msgstr "_Ny" #: tepl/tepl-application.c:93 msgid "New file" msgstr "Ny fil" #: tepl/tepl-application.c:95 msgid "New _Window" msgstr "Nytt _fönster" #: tepl/tepl-application.c:96 msgid "Create a new window" msgstr "Skapa ett nytt fönster" #: tepl/tepl-application.c:98 tepl/tepl-application-window.c:178 msgid "_Open" msgstr "Ö_ppna" #: tepl/tepl-application.c:99 msgid "Open a file" msgstr "Öppna en fil" #: tepl/tepl-application.c:101 tepl/tepl-close-confirm-dialog-single.c:144 #: tepl/tepl-tab.c:752 msgid "_Save" msgstr "_Spara" #: tepl/tepl-application.c:102 msgid "Save the current file" msgstr "Spara aktuell fil" #: tepl/tepl-application.c:104 msgid "Save _As" msgstr "S_para som" #: tepl/tepl-application.c:105 msgid "Save the current file to a different location" msgstr "Spara den aktuella filen till en annan plats" #. Edit menu #: tepl/tepl-application.c:109 msgid "_Undo" msgstr "Å_ngra" #: tepl/tepl-application.c:110 msgid "Undo the last action" msgstr "Ångra den senaste åtgärden" #: tepl/tepl-application.c:112 msgid "_Redo" msgstr "_Gör om" #: tepl/tepl-application.c:113 msgid "Redo the last undone action" msgstr "Gör om senaste ångrade åtgärden" #: tepl/tepl-application.c:115 msgid "Cu_t" msgstr "Klipp _ut" #: tepl/tepl-application.c:116 msgid "Cut the selection" msgstr "Klipp ut markering" #: tepl/tepl-application.c:118 msgid "_Copy" msgstr "_Kopiera" #: tepl/tepl-application.c:119 msgid "Copy the selection" msgstr "Kopiera markeringen" #: tepl/tepl-application.c:121 msgid "_Paste" msgstr "K_listra in" #: tepl/tepl-application.c:122 msgid "Paste the clipboard" msgstr "Klistra in urklipp" #: tepl/tepl-application.c:124 msgid "_Delete" msgstr "_Ta bort" #: tepl/tepl-application.c:125 msgid "Delete the selected text" msgstr "Ta bort den markerade texten" #: tepl/tepl-application.c:127 msgid "Select _All" msgstr "Markera _allt" #: tepl/tepl-application.c:128 msgid "Select all the text" msgstr "Markera all text" #: tepl/tepl-application.c:130 msgid "_Indent" msgstr "_Indentera" #: tepl/tepl-application.c:131 msgid "Indent the selected lines" msgstr "Indentera de markerade raderna" #: tepl/tepl-application.c:133 msgid "_Unindent" msgstr "_Avindentera" #: tepl/tepl-application.c:134 msgid "Unindent the selected lines" msgstr "Avindentera de markerade raderna" #. Create a GtkFileChooserDialog, not a GtkFileChooserNative, because #. * with GtkFileChooserNative the GFile that we obtain (in flatpak) #. * doesn't have the real path to the file, so it would screw up some #. * features for text editors: #. * - showing the directory in parentheses in the window title, or in the #. * tab tooltip; #. * - opening a recent file. #. * Basically everywhere where the directory is shown. #. #: tepl/tepl-application-window.c:174 msgid "Open File" msgstr "Öppna fil" #: tepl/tepl-application-window.c:177 #: tepl/tepl-close-confirm-dialog-single.c:138 tepl/tepl-tab.c:751 msgid "_Cancel" msgstr "A_vbryt" #: tepl/tepl-application-window.c:708 msgid "Read-Only" msgstr "Skrivskyddad" #: tepl/tepl-close-confirm-dialog-single.c:133 #, c-format msgid "Save changes to file “%s” before closing?" msgstr "Spara ändringar till filen ”%s” innan du stänger?" #: tepl/tepl-close-confirm-dialog-single.c:137 msgid "Close _without Saving" msgstr "Stäng _utan att spara" #: tepl/tepl-close-confirm-dialog-single.c:150 msgid "_Save As…" msgstr "_Spara som…" #. UTF-8 first, so that it's the first encoding returned by #. * tepl_encoding_get_all(). #. #: tepl/tepl-encoding.c:115 tepl/tepl-encoding.c:132 tepl/tepl-encoding.c:133 #: tepl/tepl-encoding.c:134 tepl/tepl-encoding.c:135 tepl/tepl-encoding.c:136 #: tepl/tepl-encoding.c:137 tepl/tepl-encoding.c:138 msgid "Unicode" msgstr "Unicode" #. FIXME GEOSTD8 ? #: tepl/tepl-encoding.c:117 tepl/tepl-encoding.c:129 tepl/tepl-encoding.c:157 #: tepl/tepl-encoding.c:180 msgid "Western" msgstr "Västerländsk" #: tepl/tepl-encoding.c:118 tepl/tepl-encoding.c:158 tepl/tepl-encoding.c:178 msgid "Central European" msgstr "Centraleuropeisk" #: tepl/tepl-encoding.c:119 msgid "South European" msgstr "Sydeuropeisk" #: tepl/tepl-encoding.c:120 tepl/tepl-encoding.c:127 tepl/tepl-encoding.c:185 msgid "Baltic" msgstr "Baltisk" #: tepl/tepl-encoding.c:121 tepl/tepl-encoding.c:159 tepl/tepl-encoding.c:166 #: tepl/tepl-encoding.c:168 tepl/tepl-encoding.c:169 tepl/tepl-encoding.c:179 msgid "Cyrillic" msgstr "Kyrillisk" #: tepl/tepl-encoding.c:122 tepl/tepl-encoding.c:162 tepl/tepl-encoding.c:184 msgid "Arabic" msgstr "Arabisk" #: tepl/tepl-encoding.c:123 tepl/tepl-encoding.c:181 msgid "Greek" msgstr "Grekisk" #: tepl/tepl-encoding.c:124 msgid "Hebrew Visual" msgstr "Hebreisk visuell" #: tepl/tepl-encoding.c:125 tepl/tepl-encoding.c:160 tepl/tepl-encoding.c:182 msgid "Turkish" msgstr "Turkisk" #: tepl/tepl-encoding.c:126 msgid "Nordic" msgstr "Nordisk" #: tepl/tepl-encoding.c:128 msgid "Celtic" msgstr "Keltisk" #: tepl/tepl-encoding.c:130 msgid "Romanian" msgstr "Rumänsk" #: tepl/tepl-encoding.c:140 msgid "Armenian" msgstr "Armenisk" #: tepl/tepl-encoding.c:141 tepl/tepl-encoding.c:142 tepl/tepl-encoding.c:150 msgid "Chinese Traditional" msgstr "Kinesisk (traditionell)" #: tepl/tepl-encoding.c:143 msgid "Cyrillic/Russian" msgstr "Kyrillisk/Rysk" #: tepl/tepl-encoding.c:145 tepl/tepl-encoding.c:146 tepl/tepl-encoding.c:147 #: tepl/tepl-encoding.c:164 tepl/tepl-encoding.c:172 msgid "Japanese" msgstr "Japansk" #: tepl/tepl-encoding.c:149 tepl/tepl-encoding.c:165 tepl/tepl-encoding.c:167 #: tepl/tepl-encoding.c:175 msgid "Korean" msgstr "Koreansk" #: tepl/tepl-encoding.c:152 tepl/tepl-encoding.c:153 tepl/tepl-encoding.c:154 msgid "Chinese Simplified" msgstr "Kinesisk (förenklad)" #: tepl/tepl-encoding.c:155 msgid "Georgian" msgstr "Georgisk" #: tepl/tepl-encoding.c:161 tepl/tepl-encoding.c:183 msgid "Hebrew" msgstr "Hebreisk" #: tepl/tepl-encoding.c:170 msgid "Cyrillic/Ukrainian" msgstr "Kyrillisk/Ukrainsk" #: tepl/tepl-encoding.c:173 tepl/tepl-encoding.c:176 tepl/tepl-encoding.c:186 msgid "Vietnamese" msgstr "Vietnamesisk" #: tepl/tepl-encoding.c:174 msgid "Thai" msgstr "Thailändsk" #: tepl/tepl-encoding.c:370 msgid "Unknown" msgstr "Okänd" #. Translators: This is the sorted list of encodings used by Tepl for #. * automatic detection of the file encoding. You may want to customize #. * it adding encodings that are common in your country, for instance the #. * GB18030 encoding for the Chinese translation. You may also want to #. * remove the ISO-8859-15 encoding (covering English and most Western #. * European languages) if you think people in your country will rarely #. * use it. 'CURRENT' is a magic value used by Tepl and it represents #. * the encoding for the current locale, so please don't translate the #. * 'CURRENT' term. Keep the same format: square brackets, single quotes, #. * commas. #. #: tepl/tepl-encoding.c:695 msgid "['UTF-8', 'CURRENT', 'ISO-8859-15', 'UTF-16']" msgstr "['UTF-8', 'CURRENT', 'ISO-8859-15', 'UTF-16']" #: tepl/tepl-encoding-converter.c:302 #, c-format msgid "Conversion from character set “%s” to “%s” is not supported." msgstr "Konvertering från teckentabellen ”%s” till ”%s” stöds inte." #: tepl/tepl-encoding-converter.c:311 #, c-format msgid "Could not open converter from “%s” to “%s”: %s" msgstr "Kunde inte öppna konverteraren från ”%s” till ”%s”: %s" #: tepl/tepl-encoding-converter.c:368 msgid "The input data contains an invalid sequence." msgstr "Indata innehåller en ogiltig sekvens." #: tepl/tepl-encoding-converter.c:377 #, c-format msgid "Error when converting data: %s" msgstr "Fel vid konvertering av data: %s" #: tepl/tepl-encoding-converter.c:556 msgid "The input data ends with an incomplete multi-byte sequence." msgstr "Indata avslutas med en ofullständig flerbytesekvens." #: tepl/tepl-encoding-converter.c:579 msgid "The input content ends with incomplete data." msgstr "Inmatningsinnehållet avslutas med ofullständiga data." #: tepl/tepl-file.c:413 #, c-format msgid "Untitled File %d" msgstr "Namnlös fil %d" #: tepl/tepl-file-content-loader.c:331 #, c-format msgid "The file is too big. Maximum %s can be loaded." msgstr "Filen är för stor. Högst %s kan läsas in." #: tepl/tepl-file-loader.c:872 msgid "It is not possible to detect the character encoding automatically." msgstr "Det går inte att identifiera teckenkodningen automatiskt." #: tepl/tepl-file-saver.c:784 msgid "The file is externally modified." msgstr "Filen har ändrats externt." #: tepl/tepl-file-saver.c:1318 msgid "The buffer contains invalid characters." msgstr "Bufferten innehåller ogiltiga tecken." #: tepl/tepl-tab.c:534 msgid "Error when loading the file." msgstr "Fel vid inläsning av filen." #: tepl/tepl-tab.c:748 msgid "Save File" msgstr "Spara fil" #. Translators: location of a file. #: tepl/tepl-tab-label.c:273 msgid "Location:" msgstr "Plats:" #: tepl/tepl-tab-label.c:342 msgid "Close file" msgstr "Stäng fil" #: tepl/tepl-tab-saving.c:64 msgid "Error when saving the file." msgstr "Fel vid sparande av filen." #~ msgid "Could not find the file “%s”." #~ msgstr "Kunde inte hitta filen ”%s”." #~ msgid "Please check that you typed the location correctly and try again." #~ msgstr "Kontrollera att du angav platsen korrekt och försök igen." #~ msgid "Unable to handle “%s:” locations." #~ msgstr "Kan inte hantera ”%s:”-platser." #~ msgid "The location of the file cannot be accessed." #~ msgstr "Platsen för filen kan inte kommas åt." #~ msgid "“%s” is a directory." #~ msgstr "”%s” är en katalog." #~ msgid "“%s” is not a valid location." #~ msgstr "”%s” är inte en giltig plats." #~ msgid "Host “%s” could not be found. Please check that your proxy settings are correct and try again." #~ msgstr "Värden ”%s” kunde inte hittas. Kontrollera att dina proxyinställningar är korrekta och försök igen." #~ msgid "Hostname was invalid. Please check that you typed the location correctly and try again." #~ msgstr "Värdnamnet var ogiltigt. Kontrollera att du angav platsen korrekt och försök igen." #~ msgid "“%s” is not a regular file." #~ msgstr "”%s” är inte en vanlig fil." #~ msgid "Connection timed out. Please try again." #~ msgstr "Anslutningens tidsgräns överskreds. Försök igen." #~ msgid "Unexpected error: %s" #~ msgstr "Oväntat fel: %s" #~ msgid "_Retry" #~ msgstr "_Försök igen" #~ msgid "Edit Any_way" #~ msgstr "Redigera än_då" #~ msgid "The number of followed links is limited and the actual file could not be found within this limit." #~ msgstr "Antalet följda länkar är begränsat och den faktiska filen kunde inte hittas inom denna gräns." #~ msgid "You do not have the permissions necessary to open the file." #~ msgstr "Du har inte de rättigheter som krävs för att öppna filen." #~ msgid "" #~ "Unable to detect the character encoding.\n" #~ "Please check that you are not trying to open a binary file.\n" #~ "Select a character encoding from the menu and try again." #~ msgstr "" #~ "Kan inte identifiera teckenkodningen.\n" #~ "Kontrollera att du inte försöker öppna en binär fil.\n" #~ "Välj en teckenkodning från menyn och försök igen." #~ msgid "There was a problem opening the file “%s”." #~ msgstr "Det uppstod ett problem vid öppnandet av filen ”%s”." #~ msgid "" #~ "The file you opened has some invalid characters. If you continue editing this file you could corrupt it.\n" #~ "You can also choose another character encoding and try again." #~ msgstr "" #~ "Filen du öppnade innehåller ogiltiga tecken. Om du fortsätter redigera denna fil kan du förstöra den.\n" #~ "Du kan också välja en annan teckenkodning och försöka igen." #~ msgid "Could not open the file “%s” using the “%s” character encoding." #~ msgstr "Kunde inte öppna filen ”%s” med teckenkodningen ”%s”." #~ msgid "" #~ "Please check that you are not trying to open a binary file.\n" #~ "Select a different character encoding from the menu and try again." #~ msgstr "" #~ "Kontrollera att du inte försöker öppna en binär fil.\n" #~ "Välj en annan teckenkodning från menyn och försök igen." #~ msgid "Could not open the file “%s”." #~ msgstr "Kunde inte öppna filen ”%s”." 07070100000052000081A400000000000000000000000166D2F0DB0000046A000000000000000000000000000000000000001D00000000libgedit-amtk-5.9.0/po/tr.po# Turkish translation for amtk. # Copyright (C) 2018 amtk's COPYRIGHT HOLDER # This file is distributed under the same license as the amtk package. # Emin Tufan Çetin <etcetin@gmail.com>, 2018. # msgid "" msgstr "" "Project-Id-Version: amtk master\n" "Report-Msgid-Bugs-To: https://gitlab.gnome.org/GNOME/amtk/issues\n" "POT-Creation-Date: 2018-08-12 10:49+0000\n" "PO-Revision-Date: 2018-08-12 14:11+0300\n" "Last-Translator: Emin Tufan Çetin <etcetin@gmail.com>\n" "Language-Team: Türkçe <gnome-turk@gnome.org>\n" "Language: tr\n" "MIME-Version: 1.0\n" "Content-Type: text/plain; charset=UTF-8\n" "Content-Transfer-Encoding: 8bit\n" "Plural-Forms: nplurals=1; plural=0;\n" "X-Generator: Gtranslator 2.91.7\n" #. Translators: %s is a filename. #: amtk/amtk-application-window.c:374 #, c-format msgid "Open “%s”" msgstr "“%s” dosyasını aç" #: amtk/amtk-application-window.c:630 msgid "Open _Recent" msgstr "Son _Kullanılanı Aç" #. Translators: %s is the application name. #: amtk/amtk-application-window.c:633 #, c-format msgid "Open a file recently used with %s" msgstr "%s ile kullanılan son dosyayı aç" 07070100000053000081A400000000000000000000000166D2F0DB0000327B000000000000000000000000000000000000001D00000000libgedit-amtk-5.9.0/po/uk.po# Ukrainian translation for tepl. # Copyright (C) 2017 tepl's COPYRIGHT HOLDER # This file is distributed under the same license as the tepl package. # # yurchor <yurchor@ukr.net>, 2017. msgid "" msgstr "" "Project-Id-Version: tepl master\n" "Report-Msgid-Bugs-To: \n" "POT-Creation-Date: 2017-03-12 11:25+0000\n" "PO-Revision-Date: 2017-03-12 15:32+0200\n" "Last-Translator: Yuri Chornoivan <yurchor@ukr.net>\n" "Language-Team: Ukrainian <trans-uk@lists.fedoraproject.org>\n" "Language: uk\n" "MIME-Version: 1.0\n" "Content-Type: text/plain; charset=UTF-8\n" "Content-Transfer-Encoding: 8bit\n" "Plural-Forms: nplurals=4; plural=n==1 ? 3 : n%10==1 && n%100!=11 ? 0 : n%" "10>=2 && n%10<=4 && (n%100<10 || n%100>=20) ? 1 : 2;\n" "X-Generator: Lokalize 1.5\n" #. Translators: %s is a filename. #: tepl/tepl-application-window.c:356 #, c-format msgid "Open “%s”" msgstr "Відкрити «%s»" #: tepl/tepl-application-window.c:575 msgid "Open _Recent" msgstr "Відкрити не_давній" #. Translators: %s is the application name. #: tepl/tepl-application-window.c:578 #, c-format msgid "Open a file recently used with %s" msgstr "Відкрити нещодавно використаний файл за допомогою %s" #. UTF-8 first, so that it's the first encoding returned by #. * tepl_encoding_get_all(). #. #: tepl/tepl-encoding.c:115 tepl/tepl-encoding.c:132 tepl/tepl-encoding.c:133 #: tepl/tepl-encoding.c:134 tepl/tepl-encoding.c:135 tepl/tepl-encoding.c:136 #: tepl/tepl-encoding.c:137 tepl/tepl-encoding.c:138 msgid "Unicode" msgstr "Unicode" #. FIXME GEOSTD8 ? #: tepl/tepl-encoding.c:117 tepl/tepl-encoding.c:129 tepl/tepl-encoding.c:157 #: tepl/tepl-encoding.c:180 msgid "Western" msgstr "Західна" #: tepl/tepl-encoding.c:118 tepl/tepl-encoding.c:158 tepl/tepl-encoding.c:178 msgid "Central European" msgstr "Центральноєвропейська" #: tepl/tepl-encoding.c:119 msgid "South European" msgstr "Південноєвропейська" #: tepl/tepl-encoding.c:120 tepl/tepl-encoding.c:127 tepl/tepl-encoding.c:185 msgid "Baltic" msgstr "Балтійська" #: tepl/tepl-encoding.c:121 tepl/tepl-encoding.c:159 tepl/tepl-encoding.c:166 #: tepl/tepl-encoding.c:168 tepl/tepl-encoding.c:169 tepl/tepl-encoding.c:179 msgid "Cyrillic" msgstr "Кирилиця" #: tepl/tepl-encoding.c:122 tepl/tepl-encoding.c:162 tepl/tepl-encoding.c:184 msgid "Arabic" msgstr "Арабська" #: tepl/tepl-encoding.c:123 tepl/tepl-encoding.c:181 msgid "Greek" msgstr "Грецька" #: tepl/tepl-encoding.c:124 msgid "Hebrew Visual" msgstr "Іврит (візуальний)" #: tepl/tepl-encoding.c:125 tepl/tepl-encoding.c:160 tepl/tepl-encoding.c:182 msgid "Turkish" msgstr "Турецька" #: tepl/tepl-encoding.c:126 msgid "Nordic" msgstr "Скандинавська" #: tepl/tepl-encoding.c:128 msgid "Celtic" msgstr "Кельтська" #: tepl/tepl-encoding.c:130 msgid "Romanian" msgstr "Румунська" #: tepl/tepl-encoding.c:140 msgid "Armenian" msgstr "Вірменська" #: tepl/tepl-encoding.c:141 tepl/tepl-encoding.c:142 tepl/tepl-encoding.c:150 msgid "Chinese Traditional" msgstr "Китайська (традиційна)" #: tepl/tepl-encoding.c:143 msgid "Cyrillic/Russian" msgstr "Кирилиця/Російська" #: tepl/tepl-encoding.c:145 tepl/tepl-encoding.c:146 tepl/tepl-encoding.c:147 #: tepl/tepl-encoding.c:164 tepl/tepl-encoding.c:172 msgid "Japanese" msgstr "Японська" #: tepl/tepl-encoding.c:149 tepl/tepl-encoding.c:165 tepl/tepl-encoding.c:167 #: tepl/tepl-encoding.c:175 msgid "Korean" msgstr "Корейська" #: tepl/tepl-encoding.c:152 tepl/tepl-encoding.c:153 tepl/tepl-encoding.c:154 msgid "Chinese Simplified" msgstr "Китайська (спрощена)" #: tepl/tepl-encoding.c:155 msgid "Georgian" msgstr "Грузинська" #: tepl/tepl-encoding.c:161 tepl/tepl-encoding.c:183 msgid "Hebrew" msgstr "Іврит" #: tepl/tepl-encoding.c:170 msgid "Cyrillic/Ukrainian" msgstr "Кирилиця/Українська" #: tepl/tepl-encoding.c:173 tepl/tepl-encoding.c:176 tepl/tepl-encoding.c:186 msgid "Vietnamese" msgstr "В’єтнамська" #: tepl/tepl-encoding.c:174 msgid "Thai" msgstr "Тайська" #: tepl/tepl-encoding.c:365 msgid "Unknown" msgstr "Невідоме" #. Translators: This is the sorted list of encodings used by Tepl for #. * automatic detection of the file encoding. You may want to customize #. * it adding encodings that are common in your country, for instance the #. * GB18030 encoding for the Chinese translation. You may also want to #. * remove the ISO-8859-15 encoding (covering English and most Western #. * European languages) if you think people in your country will rarely #. * use it. 'CURRENT' is a magic value used by Tepl and it represents #. * the encoding for the current locale, so please don't translate the #. * 'CURRENT' term. Keep the same format: square brackets, single quotes, #. * commas. #. #: tepl/tepl-encoding.c:640 msgid "['UTF-8', 'CURRENT', 'ISO-8859-15', 'UTF-16']" msgstr "['UTF-8', 'CURRENT', 'CP1251', 'KOI8U', 'UTF-16']" #: tepl/tepl-encoding-converter.c:302 #, c-format msgid "Conversion from character set “%s” to “%s” is not supported." msgstr "" "Підтримки перетворення з кодування «%s» на кодування «%s» не передбачено." #: tepl/tepl-encoding-converter.c:311 #, c-format msgid "Could not open converter from “%s” to “%s”: %s" msgstr "Не вдалося відкрити засіб перетворення з «%s» на «%s»: %s" #: tepl/tepl-encoding-converter.c:368 msgid "The input data contains an invalid sequence." msgstr "У вхідних даних міститься некоректна послідовність символів." #: tepl/tepl-encoding-converter.c:377 #, c-format msgid "Error when converting data: %s" msgstr "Помилка під час спроби перетворити дані: %s" #: tepl/tepl-encoding-converter.c:556 msgid "The input data ends with an incomplete multi-byte sequence." msgstr "Вхідні дані закінчилися на незавершеній багатобайтовій послідовності." #: tepl/tepl-encoding-converter.c:579 msgid "The input content ends with incomplete data." msgstr "Вхідні дані виявилися незавершеними." #: tepl/tepl-file.c:413 #, c-format msgid "Untitled File %d" msgstr "Файл без назви %d" #: tepl/tepl-file-content-loader.c:334 #, c-format msgid "The file is too big. Maximum %s can be loaded." msgstr "" "Файл є надто великим. Можна завантажувати файли, розмір яких не перевищує %s." #: tepl/tepl-file-loader.c:925 msgid "It is not possible to detect the character encoding automatically." msgstr "Неможливо визначити кодування символів у автоматичному режимі." #: tepl/tepl-file-saver.c:776 msgid "The file is externally modified." msgstr "Файл змінено ззовні." #: tepl/tepl-file-saver.c:1310 msgid "The buffer contains invalid characters." msgstr "У буфері містяться некоректні символи." #: tepl/tepl-io-error-info-bar.c:74 #, c-format msgid "Could not find the file “%s”." msgstr "Не вдалося знайти файл «%s»." #: tepl/tepl-io-error-info-bar.c:77 tepl/tepl-io-error-info-bar.c:104 #: tepl/tepl-io-error-info-bar.c:111 msgid "Please check that you typed the location correctly and try again." msgstr "" "Будь ласка, перевірте, чи правильно вказано адресу місця, і повторіть спробу." #. Translators: %s is a URI scheme (like for example #. * http:, ftp:, etc.). #. #: tepl/tepl-io-error-info-bar.c:90 #, c-format msgid "Unable to handle “%s:” locations." msgstr "Обробки місць «%s:» не передбачено." #: tepl/tepl-io-error-info-bar.c:98 msgid "The location of the file cannot be accessed." msgstr "Не вдалося отримати доступ до місця зберігання файла." #: tepl/tepl-io-error-info-bar.c:102 #, c-format msgid "“%s” is a directory." msgstr "«%s» є каталогом." #: tepl/tepl-io-error-info-bar.c:109 #, c-format msgid "“%s” is not a valid location." msgstr "«%s» не є коректним записом місця." #. Translators: %s is a hostname. #: tepl/tepl-io-error-info-bar.c:141 #, c-format msgid "" "Host “%s” could not be found. Please check that your proxy settings are " "correct and try again." msgstr "" "Не вдалося знайти вузол «%s». Будь ласка, перевірте, чи правильно вказано " "параметри проксі-сервера, і повторіть спробу." #. Use the same string as INVALID_HOST. #: tepl/tepl-io-error-info-bar.c:150 msgid "" "Hostname was invalid. Please check that you typed the location correctly and " "try again." msgstr "" "Некоректна назва вузла. Будь ласка, перевірте, чи правильно її вказано, і " "повторіть спробу." #: tepl/tepl-io-error-info-bar.c:159 #, c-format msgid "“%s” is not a regular file." msgstr "«%s» не є звичайним файлом." #: tepl/tepl-io-error-info-bar.c:164 msgid "Connection timed out. Please try again." msgstr "Перевищено час очікування на з’єднання. Будь ласка, повторіть спробу." #: tepl/tepl-io-error-info-bar.c:168 #, c-format msgid "Unexpected error: %s" msgstr "Неочікувана помилка: %s" #: tepl/tepl-io-error-info-bar.c:179 tepl/tepl-io-error-info-bar.c:212 #: tepl/tepl-progress-info-bar.c:53 msgid "_Cancel" msgstr "_Скасувати" #: tepl/tepl-io-error-info-bar.c:185 tepl/tepl-io-error-info-bar.c:195 msgid "_Retry" msgstr "П_овторити" #: tepl/tepl-io-error-info-bar.c:201 msgid "Edit Any_way" msgstr "Редагувати _попри все" #: tepl/tepl-io-error-info-bar.c:270 msgid "" "The number of followed links is limited and the actual file could not be " "found within this limit." msgstr "" "Кількість посилань для переходів є обмеженою. Сам файл не вкладається у ці " "обмеження." #: tepl/tepl-io-error-info-bar.c:275 msgid "You do not have the permissions necessary to open the file." msgstr "У вас немає достатніх прав доступу для відкриття файла." #: tepl/tepl-io-error-info-bar.c:285 msgid "" "Unable to detect the character encoding.\n" "Please check that you are not trying to open a binary file.\n" "Select a character encoding from the menu and try again." msgstr "" "Не вдалося визначити кодування символів.\n" "Будь ласка, перевірте, чи не намагаєтеся ви відкрити бінарний файл.\n" "Виберіть кодування у меню і повторіть спробу." #: tepl/tepl-io-error-info-bar.c:294 #, c-format msgid "There was a problem opening the file “%s”." msgstr "Під час спроби відкрити файл «%s» виникли проблеми." #: tepl/tepl-io-error-info-bar.c:296 msgid "" "The file you opened has some invalid characters. If you continue editing " "this file you could corrupt it.\n" "You can also choose another character encoding and try again." msgstr "" "У відкритому вами файлі було виявлено некоректні символи. Подальше " "редагування цього файла може призвести до пошкодження даних у ньому.\n" "Ви можете вибрати інше кодування символів і повторити спробу відкриття." #: tepl/tepl-io-error-info-bar.c:312 #, c-format msgid "Could not open the file “%s” using the “%s” character encoding." msgstr "Не вдалося відкрити файл «%s» з використанням кодування символів «%s»." #: tepl/tepl-io-error-info-bar.c:316 msgid "" "Please check that you are not trying to open a binary file.\n" "Select a different character encoding from the menu and try again." msgstr "" "Будь ласка, перевірте, чи не намагаєтеся ви відкрити бінарний файл.\n" "Виберіть інше кодування у меню і повторіть спробу." #: tepl/tepl-io-error-info-bar.c:329 #, c-format msgid "Could not open the file “%s”." msgstr "Не вдалося відкрити файл «%s»." 07070100000054000081A400000000000000000000000166D2F0DB00000414000000000000000000000000000000000000002000000000libgedit-amtk-5.9.0/po/zh_CN.po# Chinese (China) translation for amtk. # Copyright (C) 2018 amtk's COPYRIGHT HOLDER # This file is distributed under the same license as the amtk package. # zhanshime <zhanshime@gmail.com>, 2018. # msgid "" msgstr "" "Project-Id-Version: amtk master\n" "Report-Msgid-Bugs-To: https://gitlab.gnome.org/GNOME/amtk/issues\n" "POT-Creation-Date: 2018-08-12 11:12+0000\n" "PO-Revision-Date: 2018-08-16 14:12+0800\n" "Last-Translator: \n" "Language-Team: Chinese (China) <i18n-zh@googlegroups.com>\n" "Language: zh_CN\n" "MIME-Version: 1.0\n" "Content-Type: text/plain; charset=UTF-8\n" "Content-Transfer-Encoding: 8bit\n" "X-Generator: Poedit 2.1.1\n" #. Translators: %s is a filename. #: amtk/amtk-application-window.c:374 #, c-format msgid "Open “%s”" msgstr "打开 “%s”" #: amtk/amtk-application-window.c:630 msgid "Open _Recent" msgstr "打开最近(_R)" #. Translators: %s is the application name. #: amtk/amtk-application-window.c:633 #, c-format msgid "Open a file recently used with %s" msgstr "打开最近 %s 使用的文件" 07070100000055000041ED00000000000000000000000266D2F0DB00000000000000000000000000000000000000000000001A00000000libgedit-amtk-5.9.0/tests07070100000056000041ED00000000000000000000000266D2F0DB00000000000000000000000000000000000000000000002C00000000libgedit-amtk-5.9.0/tests/interactive-tests07070100000057000081A400000000000000000000000166D2F0DB0000010A000000000000000000000000000000000000003800000000libgedit-amtk-5.9.0/tests/interactive-tests/meson.buildinteractive_tests = [ # executable name, sources ['test-headerbar', 'test-headerbar.c'], ['test-traditional-ui', 'test-traditional-ui.c'], ] foreach test : interactive_tests executable( test[0], test[1], dependencies: AMTK_STATIC_DEP ) endforeach 07070100000058000081A400000000000000000000000166D2F0DB000015BB000000000000000000000000000000000000003D00000000libgedit-amtk-5.9.0/tests/interactive-tests/test-headerbar.c/* SPDX-FileCopyrightText: 2018 - Sébastien Wilmet <swilmet@gnome.org> * SPDX-License-Identifier: LGPL-3.0-or-later */ #include <amtk/amtk.h> /* This should be stored instead in the Private struct of the app GtkApplication * subclass. But here to not make the code too complicated there is no * GtkApplication subclass. */ static AmtkActionInfoStore *action_info_store = NULL; static void add_action_info_entries (void) { const gchar *accels[] = {NULL, NULL, NULL}; AmtkActionInfo *action_info; const AmtkActionInfoEntry entries[] = { /* action, icon, label, accel, tooltip */ { "win.show-side-panel", NULL, "_Side Panel", "F9", "Toggle side panel visibility" }, { "win.print", NULL, "_Print", "<Control>p" }, { "win.shortcuts-window", NULL, "_Keyboard Shortcuts" }, { NULL } }; g_assert (action_info_store == NULL); action_info_store = amtk_action_info_store_new (); amtk_action_info_store_add_entries (action_info_store, entries, -1, NULL); accels[0] = "<Control>F1"; accels[1] = "<Control>question"; action_info = amtk_action_info_store_lookup (action_info_store, "win.shortcuts-window"); amtk_action_info_set_accels (action_info, accels); } static void startup_cb (GApplication *g_app, gpointer user_data) { add_action_info_entries (); } static void print_activate_cb (GSimpleAction *action, GVariant *parameter, gpointer user_data) { g_print ("Print\n"); } static void shortcuts_window_activate_cb (GSimpleAction *action, GVariant *parameter, gpointer user_data) { GtkApplicationWindow *app_window = GTK_APPLICATION_WINDOW (user_data); GtkShortcutsWindow *shortcuts_window; GtkContainer *section; GtkContainer *group; AmtkFactory *factory; /* Create group */ group = amtk_shortcuts_group_new ("General"); factory = amtk_factory_new (NULL); amtk_factory_set_default_flags (factory, AMTK_FACTORY_IGNORE_GACTION); gtk_container_add (group, amtk_factory_create_shortcut (factory, "win.show-side-panel")); gtk_container_add (group, amtk_factory_create_shortcut (factory, "win.print")); g_object_unref (factory); /* Create section and window */ section = amtk_shortcuts_section_new (NULL); gtk_container_add (section, GTK_WIDGET (group)); shortcuts_window = amtk_shortcuts_window_new (GTK_WINDOW (app_window)); gtk_container_add (GTK_CONTAINER (shortcuts_window), GTK_WIDGET (section)); gtk_widget_show_all (GTK_WIDGET (shortcuts_window)); } static void add_win_actions (GtkApplicationWindow *window, GtkWidget *side_panel) { GPropertyAction *side_panel_action; const GActionEntry entries[] = { { "print", print_activate_cb }, { "shortcuts-window", shortcuts_window_activate_cb }, { NULL } }; amtk_action_map_add_action_entries_check_dups (G_ACTION_MAP (window), entries, -1, window); side_panel_action = g_property_action_new ("show-side-panel", side_panel, "visible"); g_action_map_add_action (G_ACTION_MAP (window), G_ACTION (side_panel_action)); g_object_unref (side_panel_action); } static GMenuModel * create_window_menu (void) { GMenu *menu; AmtkFactory *factory; menu = g_menu_new (); factory = amtk_factory_new_with_default_application (); amtk_gmenu_append_item (menu, amtk_factory_create_gmenu_item (factory, "win.show-side-panel")); amtk_gmenu_append_item (menu, amtk_factory_create_gmenu_item (factory, "win.print")); amtk_gmenu_append_item (menu, amtk_factory_create_gmenu_item (factory, "win.shortcuts-window")); g_object_unref (factory); g_menu_freeze (menu); return G_MENU_MODEL (menu); } static GtkWidget * create_header_bar (void) { GtkHeaderBar *header_bar; GMenuModel *window_menu; GtkMenuButton *menu_button; header_bar = GTK_HEADER_BAR (gtk_header_bar_new ()); gtk_header_bar_set_title (header_bar, "Amtk test headerbar"); gtk_header_bar_set_show_close_button (header_bar, TRUE); /* Menu */ menu_button = GTK_MENU_BUTTON (gtk_menu_button_new ()); gtk_menu_button_set_direction (menu_button, GTK_ARROW_NONE); window_menu = create_window_menu (); gtk_menu_button_set_menu_model (menu_button, window_menu); g_object_unref (window_menu); gtk_header_bar_pack_end (header_bar, GTK_WIDGET (menu_button)); return GTK_WIDGET (header_bar); } static void activate_cb (GApplication *g_app, gpointer user_data) { GtkWidget *window; GtkWidget *hgrid; GtkWidget *side_panel; window = gtk_application_window_new (GTK_APPLICATION (g_app)); gtk_window_set_default_size (GTK_WINDOW (window), 800, 600); gtk_window_set_titlebar (GTK_WINDOW (window), create_header_bar ()); hgrid = gtk_grid_new (); side_panel = gtk_label_new ("Side panel"); gtk_container_add (GTK_CONTAINER (hgrid), side_panel); gtk_container_add (GTK_CONTAINER (hgrid), gtk_label_new ("Text view")); add_win_actions (GTK_APPLICATION_WINDOW (window), side_panel); gtk_container_add (GTK_CONTAINER (window), hgrid); gtk_widget_show_all (window); amtk_action_info_store_check_all_used (action_info_store); } int main (int argc, char **argv) { GtkApplication *app; int status; amtk_init (); app = gtk_application_new ("org.gnome.amtk.test-headerbar", G_APPLICATION_DEFAULT_FLAGS); g_signal_connect (app, "startup", G_CALLBACK (startup_cb), NULL); g_signal_connect (app, "activate", G_CALLBACK (activate_cb), NULL); status = g_application_run (G_APPLICATION (app), argc, argv); amtk_finalize (); g_object_unref (app); g_clear_object (&action_info_store); return status; } 07070100000059000081A400000000000000000000000166D2F0DB00001604000000000000000000000000000000000000004200000000libgedit-amtk-5.9.0/tests/interactive-tests/test-traditional-ui.c/* SPDX-FileCopyrightText: 2017, 2018 - Sébastien Wilmet <swilmet@gnome.org> * SPDX-License-Identifier: LGPL-3.0-or-later */ #include <amtk/amtk.h> /* This should be stored instead in the Private struct of the app GtkApplication * subclass. But here to not make the code too complicated there is no * GtkApplication subclass. */ static AmtkActionInfoStore *action_info_store = NULL; static AmtkActionInfoEntry file_action_info_entries[] = { { "win.open", "document-open", "_Open", "<Control>o", "Open a file" }, { "app.quit", "application-exit", "_Quit", "<Control>q", "Quit the application" }, { NULL } }; static void add_action_info_entries (void) { const AmtkActionInfoEntry entries[] = { /* action, icon, label, accel, tooltip */ { "app.about", "help-about", "_About", NULL, "About this application" }, { "win.show-side-panel", NULL, "_Side Panel", "F9", "Toggle side panel visibility" }, }; g_assert (action_info_store == NULL); action_info_store = amtk_action_info_store_new (); amtk_action_info_store_add_entries (action_info_store, entries, G_N_ELEMENTS (entries), NULL); amtk_action_info_store_add_entries (action_info_store, file_action_info_entries, -1, NULL); } static void quit_activate_cb (GSimpleAction *action, GVariant *parameter, gpointer user_data) { g_application_quit (G_APPLICATION (user_data)); } static void about_activate_cb (GSimpleAction *action, GVariant *parameter, gpointer user_data) { g_print ("About\n"); } static void add_app_action_entries (GApplication *app) { const GActionEntry entries[] = { { "quit", quit_activate_cb }, { "about", about_activate_cb }, }; amtk_action_map_add_action_entries_check_dups (G_ACTION_MAP (app), entries, G_N_ELEMENTS (entries), app); } static void startup_cb (GApplication *g_app, gpointer user_data) { add_action_info_entries (); add_app_action_entries (g_app); } static GtkWidget * create_view_submenu (void) { GtkMenuShell *view_submenu; AmtkFactory *factory; view_submenu = GTK_MENU_SHELL (gtk_menu_new ()); factory = amtk_factory_new_with_default_application (); gtk_menu_shell_append (view_submenu, amtk_factory_create_check_menu_item (factory, "win.show-side-panel")); g_object_unref (factory); return GTK_WIDGET (view_submenu); } static GtkWidget * create_help_submenu (void) { GtkMenuShell *help_submenu; AmtkFactory *factory; help_submenu = GTK_MENU_SHELL (gtk_menu_new ()); factory = amtk_factory_new_with_default_application (); gtk_menu_shell_append (help_submenu, amtk_factory_create_menu_item (factory, "app.about")); g_object_unref (factory); return GTK_WIDGET (help_submenu); } static GtkMenuBar * create_menu_bar (void) { AmtkFactory *factory; GtkWidget *file_menu_item; GtkWidget *view_menu_item; GtkWidget *help_menu_item; GtkMenuBar *menu_bar; factory = amtk_factory_new_with_default_application (); file_menu_item = gtk_menu_item_new_with_mnemonic ("_File"); gtk_menu_item_set_submenu (GTK_MENU_ITEM (file_menu_item), amtk_factory_create_simple_menu (factory, file_action_info_entries, -1)); view_menu_item = gtk_menu_item_new_with_mnemonic ("_View"); gtk_menu_item_set_submenu (GTK_MENU_ITEM (view_menu_item), create_view_submenu ()); help_menu_item = gtk_menu_item_new_with_mnemonic ("_Help"); gtk_menu_item_set_submenu (GTK_MENU_ITEM (help_menu_item), create_help_submenu ()); menu_bar = GTK_MENU_BAR (gtk_menu_bar_new ()); gtk_menu_shell_append (GTK_MENU_SHELL (menu_bar), file_menu_item); gtk_menu_shell_append (GTK_MENU_SHELL (menu_bar), view_menu_item); gtk_menu_shell_append (GTK_MENU_SHELL (menu_bar), help_menu_item); amtk_action_info_store_check_all_used (action_info_store); g_object_unref (factory); return menu_bar; } static void add_win_actions (GtkApplicationWindow *window, GtkWidget *side_panel) { GPropertyAction *side_panel_action; side_panel_action = g_property_action_new ("show-side-panel", side_panel, "visible"); g_action_map_add_action (G_ACTION_MAP (window), G_ACTION (side_panel_action)); g_object_unref (side_panel_action); } static void activate_cb (GApplication *g_app, gpointer user_data) { GtkWidget *window; GtkWidget *vgrid; GtkWidget *hgrid; GtkWidget *side_panel; window = gtk_application_window_new (GTK_APPLICATION (g_app)); gtk_window_set_default_size (GTK_WINDOW (window), 800, 600); vgrid = gtk_grid_new (); gtk_orientable_set_orientation (GTK_ORIENTABLE (vgrid), GTK_ORIENTATION_VERTICAL); gtk_container_add (GTK_CONTAINER (vgrid), GTK_WIDGET (create_menu_bar ())); hgrid = gtk_grid_new (); side_panel = gtk_label_new ("Side panel"); gtk_container_add (GTK_CONTAINER (hgrid), side_panel); gtk_container_add (GTK_CONTAINER (hgrid), gtk_label_new ("Text view")); gtk_container_add (GTK_CONTAINER (vgrid), hgrid); add_win_actions (GTK_APPLICATION_WINDOW (window), side_panel); gtk_container_add (GTK_CONTAINER (window), vgrid); gtk_widget_show_all (window); } int main (int argc, char **argv) { GtkApplication *app; int status; amtk_init (); app = gtk_application_new ("org.gnome.amtk.test-traditional-ui", G_APPLICATION_DEFAULT_FLAGS); g_signal_connect (app, "startup", G_CALLBACK (startup_cb), NULL); g_signal_connect (app, "activate", G_CALLBACK (activate_cb), NULL); status = g_application_run (G_APPLICATION (app), argc, argv); amtk_finalize (); g_object_unref (app); g_clear_object (&action_info_store); return status; } 0707010000005A000081A400000000000000000000000166D2F0DB00000031000000000000000000000000000000000000002600000000libgedit-amtk-5.9.0/tests/meson.buildsubdir('interactive-tests') subdir('unit-tests') 0707010000005B000041ED00000000000000000000000266D2F0DB00000000000000000000000000000000000000000000002500000000libgedit-amtk-5.9.0/tests/unit-tests0707010000005C000081A400000000000000000000000166D2F0DB000000FD000000000000000000000000000000000000003100000000libgedit-amtk-5.9.0/tests/unit-tests/meson.buildunit_tests = [ 'test-action-info-store', 'test-action-map', 'test-utils', ] foreach test_name : unit_tests test_exe = executable( test_name, test_name + '.c', dependencies: AMTK_STATIC_DEP ) test(test_name, test_exe) endforeach 0707010000005D000081A400000000000000000000000166D2F0DB000005AC000000000000000000000000000000000000003E00000000libgedit-amtk-5.9.0/tests/unit-tests/test-action-info-store.c/* SPDX-FileCopyrightText: 2017 - Sébastien Wilmet <swilmet@gnome.org> * SPDX-License-Identifier: LGPL-3.0-or-later */ #include <amtk/amtk.h> static void test_add_entries (void) { AmtkActionInfoStore *store; AmtkActionInfoCentralStore *central_store; AmtkActionInfo *info1; AmtkActionInfo *info2; const AmtkActionInfoEntry entries[] = { /* action, icon, label, accel, tooltip */ { "app.quit", "application-exit", "_Quit", "<Control>q", "Quit the application" }, /* Tooltip field missing, must be NULL. */ { "win.open", "document-open", "_Open", "<Control>o" }, }; store = amtk_action_info_store_new (); amtk_action_info_store_add_entries (store, entries, G_N_ELEMENTS (entries), NULL); info1 = amtk_action_info_store_lookup (store, "win.open"); g_assert_true (info1 != NULL); g_assert_cmpstr (amtk_action_info_get_icon_name (info1), ==, "document-open"); g_assert_true (amtk_action_info_get_tooltip (info1) == NULL); central_store = amtk_action_info_central_store_get_singleton (); info2 = amtk_action_info_central_store_lookup (central_store, "win.open"); g_assert_true (info1 == info2); info1 = amtk_action_info_store_lookup (store, "plouf"); g_assert_true (info1 == NULL); g_object_unref (store); } int main (int argc, char **argv) { g_test_init (&argc, &argv, NULL); g_test_add_func ("/action-info-store/add-entries", test_add_entries); return g_test_run (); } 0707010000005E000081A400000000000000000000000166D2F0DB0000094B000000000000000000000000000000000000003700000000libgedit-amtk-5.9.0/tests/unit-tests/test-action-map.c/* SPDX-FileCopyrightText: 2017 - Sébastien Wilmet <swilmet@gnome.org> * SPDX-License-Identifier: LGPL-3.0-or-later */ #include <amtk/amtk.h> static void test_add_action_entries_check_dups (void) { GSimpleActionGroup *group; const GActionEntry entries[] = { { "quit" }, { "about" } }; group = g_simple_action_group_new (); amtk_action_map_add_action_entries_check_dups (G_ACTION_MAP (group), entries, G_N_ELEMENTS (entries), NULL); g_object_unref (group); g_test_trap_subprocess ("/action-map/add-action-entries-check-dups/subprocess/add-two-times", 0, 0); g_test_trap_assert_failed (); g_test_trap_assert_stderr ("*the GActionMap already contains a GAction with the name*"); g_test_trap_subprocess ("/action-map/add-action-entries-check-dups/subprocess/dups-in-array", 0, 0); g_test_trap_assert_failed (); g_test_trap_assert_stderr ("*the GActionEntry array contains duplicated entries for the action name*"); } static void test_add_action_entries_check_dups__add_two_times (void) { GSimpleActionGroup *group; const GActionEntry entries[] = { { "quit" } }; group = g_simple_action_group_new (); amtk_action_map_add_action_entries_check_dups (G_ACTION_MAP (group), entries, G_N_ELEMENTS (entries), NULL); amtk_action_map_add_action_entries_check_dups (G_ACTION_MAP (group), entries, G_N_ELEMENTS (entries), NULL); g_object_unref (group); } static void test_add_action_entries_check_dups__dups_in_array (void) { GSimpleActionGroup *group; const GActionEntry entries[] = { { "quit" }, { "quit" } }; group = g_simple_action_group_new (); amtk_action_map_add_action_entries_check_dups (G_ACTION_MAP (group), entries, G_N_ELEMENTS (entries), NULL); g_object_unref (group); } int main (int argc, char **argv) { g_test_init (&argc, &argv, NULL); g_test_add_func ("/action-map/add-action-entries-check-dups", test_add_action_entries_check_dups); g_test_add_func ("/action-map/add-action-entries-check-dups/subprocess/add-two-times", test_add_action_entries_check_dups__add_two_times); g_test_add_func ("/action-map/add-action-entries-check-dups/subprocess/dups-in-array", test_add_action_entries_check_dups__dups_in_array); return g_test_run (); } 0707010000005F000081A400000000000000000000000166D2F0DB0000046D000000000000000000000000000000000000003200000000libgedit-amtk-5.9.0/tests/unit-tests/test-utils.c/* SPDX-FileCopyrightText: 2017 - Sébastien Wilmet <swilmet@gnome.org> * SPDX-License-Identifier: LGPL-3.0-or-later */ #include <amtk/amtk.h> static void check_remove_mnemonic (const gchar *str_with_mnemonic, const gchar *expected_str_without_mnemonic) { gchar *str_without_mnemonic; str_without_mnemonic = amtk_utils_remove_mnemonic (str_with_mnemonic); g_assert_cmpstr (str_without_mnemonic, ==, expected_str_without_mnemonic); g_free (str_without_mnemonic); } static void test_remove_mnemonic (void) { check_remove_mnemonic ("", ""); check_remove_mnemonic ("a", "a"); check_remove_mnemonic ("_a", "a"); check_remove_mnemonic ("__a", "_a"); check_remove_mnemonic ("___a", "_a"); check_remove_mnemonic ("S_maller Text", "Smaller Text"); /* With multi-byte UTF-8 chars. */ check_remove_mnemonic ("___ß_é__c____d", "_ßé_c__d"); /* Not valid mnemonic, but the function must not crash. */ check_remove_mnemonic ("a_", "a"); } int main (int argc, char **argv) { g_test_init (&argc, &argv, NULL); g_test_add_func ("/utils/remove-mnemonic", test_remove_mnemonic); return g_test_run (); } 07070100000000000000000000000000000000000000010000000000000000000000000000000000000000000000000000000B00000000TRAILER!!!752 blocks
Locations
Projects
Search
Status Monitor
Help
OpenBuildService.org
Documentation
API Documentation
Code of Conduct
Contact
Support
@OBShq
Terms
openSUSE Build Service is sponsored by
The Open Build Service is an
openSUSE project
.
Sign Up
Log In
Places
Places
All Projects
Status Monitor