diff --git a/.gitignore b/.gitignore index b313d2b00c9713c21f0cc9c7c8c7b2f802b84a6a..44c77939c71e3026427cda3a3fc4466bd106bafa 100644 --- a/.gitignore +++ b/.gitignore @@ -1,4 +1,5 @@ # Autotools files generated into srcdir +/ABOUT-NLS /INSTALL *.tar.bz2 *.tar.gz @@ -13,10 +14,17 @@ Makefile.in /depcomp /install-sh /install-sh~ -/intltool-*.in /ltmain.sh /missing /po/Makefile.in.in +/po/Makevars.template +/po/Rules-quot +/po/boldquot.sed +/po/en@boldquot.header +/po/en@quot.header +/po/insert-header.sin +/po/quot.sed +/po/remove-potcdate.sin /configure.ac /m4/ /mkinstalldirs @@ -33,10 +41,11 @@ Makefile /libtool /panel-plugin/.dirstamp /panel-plugin/screenshooter.desktop -/po/.intltool-merge-cache* /po/POTFILES /po/*.gmo -/po/stamp-it +/po/remove-potcdate.sed +/po/stamp-po +/po/xfce4-screenshooter.pot /src/.dirstamp *.o /src/xfce4-screenshooter diff --git a/Makefile.am b/Makefile.am index 409b4dede893bd3f0723eecc1bb9107928270b6e..752dbdb785a83bd03e9296c3b4c83d438b3c728c 100644 --- a/Makefile.am +++ b/Makefile.am @@ -221,7 +221,6 @@ app_desktopdir = $(datadir)/applications app_desktop_in_in_files = src/xfce4-screenshooter.desktop.in.in app_desktop_in_files = $(app_desktop_in_in_files:.desktop.in.in=.desktop.in) app_desktop_DATA = $(app_desktop_in_files:.desktop.in=.desktop) -@INTLTOOL_DESKTOP_RULE@ src/xfce4-screenshooter.desktop.in: src/xfce4-screenshooter.desktop.in.in $(AM_V_GEN) ( \ @@ -230,6 +229,9 @@ src/xfce4-screenshooter.desktop.in: src/xfce4-screenshooter.desktop.in.in $< > $@ \ ) +src/xfce4-screenshooter.desktop: src/xfce4-screenshooter.desktop.in + $(AM_V_GEN)$(MSGFMT) --desktop --template $< -d $(top_srcdir)/po -o $@ + # Panel plugin plugindir = $(libdir)/xfce4/panel/plugins plugin_LTLIBRARIES = panel-plugin/libscreenshooterplugin.la @@ -274,14 +276,17 @@ panel_plugin_libscreenshooterplugin_la_SOURCES = \ panel_desktopdir = $(datadir)/xfce4/panel/plugins panel_desktop_in_files = panel-plugin/screenshooter.desktop.in panel_desktop_DATA = $(panel_desktop_in_files:.desktop.in=.desktop) -@INTLTOOL_DESKTOP_RULE@ + +panel-plugin/screenshooter.desktop: panel-plugin/screenshooter.desktop.in + $(AM_V_GEN)$(MSGFMT) --desktop --template $< -d $(top_srcdir)/po -o $@ # appdata file for the application -@INTLTOOL_XML_RULE@ appdatadir = $(datadir)/metainfo appdata_DATA = $(appdata_in_files:.xml.in=.xml) appdata_in_files = src/xfce4-screenshooter.appdata.xml.in +src/xfce4-screenshooter.appdata.xml: src/xfce4-screenshooter.appdata.xml.in + $(AM_V_GEN)$(MSGFMT) --xml --template $< -d $(top_srcdir)/po -o $@ # App icons @@ -334,10 +339,6 @@ dist-hook: ChangeLog # Extra dist and distclean rules EXTRA_DIST += \ - README.md \ - intltool-extract.in \ - intltool-merge.in \ - intltool-update.in \ lib/screenshooter-marshal.list \ lib/screenshooter-imgur-dialog.ui \ $(app_desktop_in_in_files) \ @@ -352,17 +353,13 @@ EXTRA_DIST += \ $(script_DATA) DISTCLEANFILES += \ - intltool-extract \ - intltool-merge \ - intltool-update \ stamp-screenshooter-marshal.h \ $(lib_libscreenshooter_built_sources) \ lib/stamp-screenshooter-marshal.h \ $(app_desktop_DATA) $(app_desktop_in_files) \ $(panel_desktop_DATA) \ $(appdata_DATA) \ - xfce4-screenshooter.1 \ - po/.intltool-merge-cache.lock + xfce4-screenshooter.1 # Man pages dist_man_MANS = xfce4-screenshooter.1 diff --git a/autogen.sh b/autogen.sh index 956cc9374580ddad3a2e4019e627ff08583a2e26..c59f2581df9bba38f7a6f756e76498161563059f 100755 --- a/autogen.sh +++ b/autogen.sh @@ -5,8 +5,6 @@ # # Written for Xfce by Benedikt Meurer <benny@xfce.org>. -export XDT_AUTOGEN_REQUIRED_VERSION="4.14.0" - (type xdt-autogen) >/dev/null 2>&1 || { cat >&2 <<EOF autogen.sh: You don't seem to have the Xfce development tools installed on @@ -17,4 +15,4 @@ EOF exit 1 } -xdt-autogen $@ +XDT_AUTOGEN_REQUIRED_VERSION="4.17.0" xdt-autogen $@ diff --git a/configure.ac.in b/configure.ac.in index 95764ddc5938eacc2aa2d5bf63eb44cf15f3ad11..116b25f87a50ec2e1116ea7b70fa4e4e2604df36 100644 --- a/configure.ac.in +++ b/configure.ac.in @@ -28,7 +28,6 @@ AC_PROG_CC() AC_PROG_CC_C_O() AC_PROG_LD() AC_PROG_INSTALL() -IT_PROG_INTLTOOL([0.35.0]) AM_PROG_CC_C_O() dnl ************************** @@ -114,7 +113,12 @@ fi dnl ****************************** dnl *** Check for i18n support *** dnl ****************************** -XDT_I18N([@LINGUAS@]) +GETTEXT_PACKAGE="$PACKAGE" +AC_DEFINE_UNQUOTED([GETTEXT_PACKAGE], ["$GETTEXT_PACKAGE"], [Name of default gettext domain]) +AC_SUBST([GETTEXT_PACKAGE]) + +AM_GNU_GETTEXT([external]) +AM_GNU_GETTEXT_VERSION([0.19.8]) dnl ************************** dnl *** Check for help2man *** diff --git a/panel-plugin/screenshooter.desktop.in b/panel-plugin/screenshooter.desktop.in index 50adb915bcd578aa89e47f9ef3d648113a9363a4..3c0e605cf77ed1d6496d6b38e16c5f2ff6fe10b3 100644 --- a/panel-plugin/screenshooter.desktop.in +++ b/panel-plugin/screenshooter.desktop.in @@ -1,7 +1,7 @@ [Xfce Panel] Type=X-XFCE-PanelPlugin -_Name=Screenshot -_Comment=Take screenshots of the entire screen, of the active window or of a region +Name=Screenshot +Comment=Take screenshots of the entire screen, of the active window or of a region Icon=org.xfce.screenshooter X-XFCE-Internal=FALSE X-XFCE-Module=screenshooterplugin diff --git a/po/LINGUAS b/po/LINGUAS new file mode 100644 index 0000000000000000000000000000000000000000..d86da3890af8ab428e8bf64ec9738cc7015f61d7 --- /dev/null +++ b/po/LINGUAS @@ -0,0 +1,60 @@ +ar +ast +be +bg +ca +cs +da +de +el +en_AU +en_GB +es +et +eu +fa_IR +fi +fr +gl +he +hr +hu +hy_AM +hye +id +ie +is +it +ja +ka +kk +ko +lt +lv +ms +nb +nl +nn +oc +pa +pl +pt_BR +pt +ro +ru +si +sk +sl +sq +sr +sv +te +th +tr +ug +uk +ur_PK +ur +vi +zh_CN +zh_TW diff --git a/po/Makevars b/po/Makevars new file mode 100644 index 0000000000000000000000000000000000000000..6a5044a263901ccaa019b10bd56ec191fc0dbe91 --- /dev/null +++ b/po/Makevars @@ -0,0 +1,80 @@ +# Makefile variables for PO directory in any package using GNU gettext. + +# Usually the message domain is the same as the package name. +DOMAIN = $(PACKAGE) + +# These two variables depend on the location of this directory. +subdir = po +top_builddir = .. + +# These options get passed to xgettext. +XGETTEXT_OPTIONS = --from-code=UTF-8 --keyword=_ --keyword=N_ \ + --keyword=C_:1c,2 --keyword=NC_:1c,2 --keyword=g_dngettext:2,3 \ + --add-comments + +# This is the copyright holder that gets inserted into the header of the +# $(DOMAIN).pot file. Set this to the copyright holder of the surrounding +# package. (Note that the msgstr strings, extracted from the package's +# sources, belong to the copyright holder of the package.) Translators are +# expected to transfer the copyright for their translations to this person +# or entity, or to disclaim their copyright. The empty string stands for +# the public domain; in this case the translators are expected to disclaim +# their copyright. +COPYRIGHT_HOLDER = The Xfce development team. + +# This tells whether or not to prepend "GNU " prefix to the package +# name that gets inserted into the header of the $(DOMAIN).pot file. +# Possible values are "yes", "no", or empty. If it is empty, try to +# detect it automatically by scanning the files in $(top_srcdir) for +# "GNU packagename" string. +PACKAGE_GNU = no + +# This is the email address or URL to which the translators shall report +# bugs in the untranslated strings: +# - Strings which are not entire sentences, see the maintainer guidelines +# in the GNU gettext documentation, section 'Preparing Strings'. +# - Strings which use unclear terms or require additional context to be +# understood. +# - Strings which make invalid assumptions about notation of date, time or +# money. +# - Pluralisation problems. +# - Incorrect English spelling. +# - Incorrect formatting. +# It can be your email address, or a mailing list address where translators +# can write to without being subscribed, or the URL of a web page through +# which the translators can contact you. +MSGID_BUGS_ADDRESS = + +# This is the list of locale categories, beyond LC_MESSAGES, for which the +# message catalogs shall be used. It is usually empty. +EXTRA_LOCALE_CATEGORIES = + +# This tells whether the $(DOMAIN).pot file contains messages with an 'msgctxt' +# context. Possible values are "yes" and "no". Set this to yes if the +# package uses functions taking also a message context, like pgettext(), or +# if in $(XGETTEXT_OPTIONS) you define keywords with a context argument. +USE_MSGCTXT = no + +# These options get passed to msgmerge. +# Useful options are in particular: +# --previous to keep previous msgids of translated messages, +# --quiet to reduce the verbosity. +MSGMERGE_OPTIONS = + +# These options get passed to msginit. +# If you want to disable line wrapping when writing PO files, add +# --no-wrap to MSGMERGE_OPTIONS, XGETTEXT_OPTIONS, and +# MSGINIT_OPTIONS. +MSGINIT_OPTIONS = + +# This tells whether or not to regenerate a PO file when $(DOMAIN).pot +# has changed. Possible values are "yes" and "no". Set this to no if +# the POT file is checked in the repository and the version control +# program ignores timestamps. +PO_DEPENDS_ON_POT = no + +# This tells whether or not to forcibly update $(DOMAIN).pot and +# regenerate PO files on "make dist". Possible values are "yes" and +# "no". Set this to no if the POT file and PO files are maintained +# externally. +DIST_DEPENDS_ON_UPDATE_PO = no diff --git a/po/POTFILES.in b/po/POTFILES.in index d2eb89d6ef2603e77f3bfa9270e5c570362d64ce..2db462425538625ea749fde6668d814bcd59e84c 100644 --- a/po/POTFILES.in +++ b/po/POTFILES.in @@ -5,7 +5,7 @@ lib/screenshooter-utils.c lib/screenshooter-imgur.c lib/screenshooter-imgur-dialog.c lib/screenshooter-capture-wayland.c -[type: gettext/glade]lib/screenshooter-imgur-dialog.ui +lib/screenshooter-imgur-dialog.ui lib/screenshooter-job-callbacks.c src/main.c src/xfce4-screenshooter.desktop.in.in diff --git a/src/xfce4-screenshooter.appdata.xml.in b/src/xfce4-screenshooter.appdata.xml.in index 79977a28041f9a1d6cb65b2f4ed3129e5b494e87..b520e12b0a3fa10290626ee5ac06e5e9eed6ac2c 100644 --- a/src/xfce4-screenshooter.appdata.xml.in +++ b/src/xfce4-screenshooter.appdata.xml.in @@ -11,12 +11,12 @@ <summary>Application and panel plugin to take screenshots</summary> <description> - <_p>Allows you to capture the entire screen, the active window + <p>Allows you to capture the entire screen, the active window or a selected region. You can set the delay that elapses before the screenshot is taken and the action that will be done with the screenshot: save it to a PNG or JPG file, copy it to the clipboard, open it using another application, or host it on imgur, a free online image hosting service. - </_p> + </p> </description> <screenshots> diff --git a/src/xfce4-screenshooter.desktop.in.in b/src/xfce4-screenshooter.desktop.in.in index 609674e287c029ca211ff38794ca6a65536cd830..aeeee8fe83b9d0b8ec47689001d14c87681a43d1 100644 --- a/src/xfce4-screenshooter.desktop.in.in +++ b/src/xfce4-screenshooter.desktop.in.in @@ -1,7 +1,7 @@ [Desktop Entry] Version=1.0 -_Name=Screenshot -_Comment=Take screenshots of the entire screen, of the active window or of a region +Name=Screenshot +Comment=Take screenshots of the entire screen, of the active window or of a region Icon=org.xfce.screenshooter Exec=xfce4-screenshooter Type=Application