From 1858c4feaa24e40cea4b1b5ea39a60fb6670f33b Mon Sep 17 00:00:00 2001 From: auroux Date: Tue, 22 May 2012 22:19:00 +0000 Subject: [PATCH] Fix "1.#J" bug; release 0.4.6. --- AUTHORS | 13 +++--- ChangeLog | 5 ++- NEWS | 4 +- README | 11 ++--- aclocal.m4 | 54 ++++++++++++----------- config.h.in | 3 ++ configure | 2 +- configure.in | 2 +- html-doc/manual.html | 57 ++++++++++++++++-------- mkinstalldirs | 93 +++++++++++++++++++++++++++++++--------- po/ChangeLog | 1 + po/Makefile.in.in | 18 ++++++-- src/TODO | 23 +++++----- src/ttsubset/Makefile.in | 15 ++++++- src/xo-callbacks.c | 4 +- src/xo-file.c | 10 ++++- src/xo-misc.c | 12 ++++-- src/xo-misc.h | 1 + 18 files changed, 227 insertions(+), 101 deletions(-) diff --git a/AUTHORS b/AUTHORS index bf48670..fadb86c 100644 --- a/AUTHORS +++ b/AUTHORS @@ -1,12 +1,13 @@ -Main author: Denis Auroux (auroux@math.mit.edu, auroux@math.berkeley.edu) +Main author: Denis Auroux (auroux@math.berkeley.edu) The source code includes contributions by the following people: -Eduardo de Barros Lima, Mathieu Bouchard, Ole Joergen Broenner, -Vincenzo Ciancia, Luca de Cicco, Michele Codutti, Robert Gerlach, -Lukasz Kaiser, Danny Kukawka, Stefan Lembach, Bob McElrath, Andy Neitzke, -David Planella, Marco Poletti, Alex Ray, Jean-Baptiste Rouquier, -Mike Ter Louw, Uwe Winter, Lu Zhihe. +Alvaro, Kit Barnes, Eduardo de Barros Lima, Mathieu Bouchard, +Ole Joergen Broenner, Robert Buchholz, Vincenzo Ciancia, Luca de Cicco, +Michele Codutti, Robert Gerlach, Daniel German, Dirk Gerrits, +Lukasz Kaiser, Timo Kluck, David Kolibac, Danny Kukawka, Stefan Lembach, +Bob McElrath, Andy Neitzke, David Planella, Marco Poletti, Alex Ray, +Jean-Baptiste Rouquier, Marco Souza, Mike Ter Louw, Uwe Winter, Lu Zhihe. (Let me know if you are missing from this list or if your name is mis-spelled) diff --git a/ChangeLog b/ChangeLog index 05121a3..dd5f70a 100644 --- a/ChangeLog +++ b/ChangeLog @@ -1,4 +1,4 @@ -This version: +Version 0.4.6 (May 22, 2012): - win32 portability code (contributed by Dirk Gerrits) - fix bug in PDF export code on 64-bit systems (patch by Robert Buchholz) - fix hand tool bug when exiting canvas (#2905711) @@ -11,6 +11,9 @@ This version: - option to force PDF background rendering via cairo (slower but nicer) - wrapper for missing GdkPixbuf rendering function in newest poppler - disable GTK+ XInput bugfix by default (#3429416) + - fix linker flags (#3208984); evdev coordinate fix (#3244118) (Timo Kluck) + - specify license version: GPL v2 or later + - fix 1.#J coordinates from win32 xoj files Version 0.4.5 (Oct 2, 2009): - bugfixes for GTK+ 2.16/2.17 issues with xinput events diff --git a/NEWS b/NEWS index a2befc6..ad92faf 100644 --- a/NEWS +++ b/NEWS @@ -1,4 +1,6 @@ -Version 0.4.5 (October 2, 2009) +Version 0.4.6 (May 22, 2012) + +This release catches up with changes accumulated in the cvs repository. Installation: see INSTALL User's manual: see html-doc/manual.html diff --git a/README b/README index 9195954..ad92faf 100644 --- a/README +++ b/README @@ -1,8 +1,9 @@ -Version 0.4.5 (October 2, 2009) +Version 0.4.6 (May 22, 2012) -Installation: see INSTALL -Latest changes: see ChangeLog -User's manual: see html-doc/manual.html -Updates: see http://xournal.sourceforge.net/ +This release catches up with changes accumulated in the cvs repository. + +Installation: see INSTALL +User's manual: see html-doc/manual.html +Updates: see http://xournal.sourceforge.net/ See also: http://sourceforge.net/projects/xournal diff --git a/aclocal.m4 b/aclocal.m4 index f916408..77588d1 100644 --- a/aclocal.m4 +++ b/aclocal.m4 @@ -1,4 +1,4 @@ -# generated automatically by aclocal 1.11 -*- Autoconf -*- +# generated automatically by aclocal 1.11.1 -*- Autoconf -*- # Copyright (C) 1996, 1997, 1998, 1999, 2000, 2001, 2002, 2003, 2004, # 2005, 2006, 2007, 2008, 2009 Free Software Foundation, Inc. @@ -13,8 +13,8 @@ m4_ifndef([AC_AUTOCONF_VERSION], [m4_copy([m4_PACKAGE_VERSION], [AC_AUTOCONF_VERSION])])dnl -m4_if(m4_defn([AC_AUTOCONF_VERSION]), [2.63],, -[m4_warning([this file was generated for autoconf 2.63. +m4_if(m4_defn([AC_AUTOCONF_VERSION]), [2.68],, +[m4_warning([this file was generated for autoconf 2.68. You have another version of autoconf. It may work, but is not guaranteed to. If you have problems, you may need to regenerate the build system entirely. To do so, use the procedure documented by the package, typically `autoreconf'.])]) @@ -260,6 +260,10 @@ msgstr "" [CATOBJEXT=.mo DATADIRNAME=lib]) ;; + *-*-openbsd*) + CATOBJEXT=.mo + DATADIRNAME=share + ;; *) CATOBJEXT=.mo DATADIRNAME=lib @@ -301,7 +305,7 @@ msgstr "" dnl These rules are solely for the distribution goal. While doing this dnl we only have to keep exactly one list of the available catalogs - dnl in configure.in. + dnl in configure.ac. for lang in $ALL_LINGUAS; do GMOFILES="$GMOFILES $lang.gmo" POFILES="$POFILES $lang.po" @@ -430,7 +434,7 @@ AC_DEFINE_UNQUOTED($1, "$localedir", dnl dnl Now the definitions that aclocal will find dnl -ifdef(glib_configure_in,[],[ +ifdef(glib_configure_ac,[],[ AC_DEFUN([AM_GLIB_GNU_GETTEXT],[GLIB_GNU_GETTEXT($@)]) AC_DEFUN([AM_GLIB_DEFINE_LOCALEDIR],[GLIB_DEFINE_LOCALEDIR($@)]) ])dnl @@ -453,6 +457,7 @@ fi]) # pkg.m4 - Macros to locate and utilise pkg-config. -*- Autoconf -*- +# serial 1 (pkg-config-0.24) # # Copyright © 2004 Scott James Remnant . # @@ -480,7 +485,10 @@ fi]) AC_DEFUN([PKG_PROG_PKG_CONFIG], [m4_pattern_forbid([^_?PKG_[A-Z_]+$]) m4_pattern_allow([^PKG_CONFIG(_PATH)?$]) -AC_ARG_VAR([PKG_CONFIG], [path to pkg-config utility])dnl +AC_ARG_VAR([PKG_CONFIG], [path to pkg-config utility]) +AC_ARG_VAR([PKG_CONFIG_PATH], [directories to add to pkg-config's search path]) +AC_ARG_VAR([PKG_CONFIG_LIBDIR], [path overriding pkg-config's built-in search path]) + if test "x$ac_cv_env_PKG_CONFIG_set" != "xset"; then AC_PATH_TOOL([PKG_CONFIG], [pkg-config]) fi @@ -493,7 +501,6 @@ if test -n "$PKG_CONFIG"; then AC_MSG_RESULT([no]) PKG_CONFIG="" fi - fi[]dnl ])# PKG_PROG_PKG_CONFIG @@ -502,21 +509,20 @@ fi[]dnl # Check to see whether a particular set of modules exists. Similar # to PKG_CHECK_MODULES(), but does not set variables or print errors. # -# -# Similar to PKG_CHECK_MODULES, make sure that the first instance of -# this or PKG_CHECK_MODULES is called, or make sure to call -# PKG_CHECK_EXISTS manually +# Please remember that m4 expands AC_REQUIRE([PKG_PROG_PKG_CONFIG]) +# only at the first occurence in configure.ac, so if the first place +# it's called might be skipped (such as if it is within an "if", you +# have to call PKG_CHECK_EXISTS manually # -------------------------------------------------------------- AC_DEFUN([PKG_CHECK_EXISTS], [AC_REQUIRE([PKG_PROG_PKG_CONFIG])dnl if test -n "$PKG_CONFIG" && \ AC_RUN_LOG([$PKG_CONFIG --exists --print-errors "$1"]); then - m4_ifval([$2], [$2], [:]) + m4_default([$2], [:]) m4_ifvaln([$3], [else $3])dnl fi]) - # _PKG_CONFIG([VARIABLE], [COMMAND], [MODULES]) # --------------------------------------------- m4_define([_PKG_CONFIG], @@ -569,6 +575,7 @@ and $1[]_LIBS to avoid the need to call pkg-config. See the pkg-config man page for more details.]) if test $pkg_failed = yes; then + AC_MSG_RESULT([no]) _PKG_SHORT_ERRORS_SUPPORTED if test $_pkg_short_errors_supported = yes; then $1[]_PKG_ERRORS=`$PKG_CONFIG --short-errors --print-errors "$2" 2>&1` @@ -578,7 +585,7 @@ if test $pkg_failed = yes; then # Put the nasty error message in config.log where it belongs echo "$$1[]_PKG_ERRORS" >&AS_MESSAGE_LOG_FD - ifelse([$4], , [AC_MSG_ERROR(dnl + m4_default([$4], [AC_MSG_ERROR( [Package requirements ($2) were not met: $$1_PKG_ERRORS @@ -586,25 +593,24 @@ $$1_PKG_ERRORS Consider adjusting the PKG_CONFIG_PATH environment variable if you installed software in a non-standard prefix. -_PKG_TEXT -])], - [AC_MSG_RESULT([no]) - $4]) +_PKG_TEXT]) + ]) elif test $pkg_failed = untried; then - ifelse([$4], , [AC_MSG_FAILURE(dnl + AC_MSG_RESULT([no]) + m4_default([$4], [AC_MSG_FAILURE( [The pkg-config script could not be found or is too old. Make sure it is in your PATH or set the PKG_CONFIG environment variable to the full path to pkg-config. _PKG_TEXT -To get pkg-config, see .])], - [$4]) +To get pkg-config, see .]) + ]) else $1[]_CFLAGS=$pkg_cv_[]$1[]_CFLAGS $1[]_LIBS=$pkg_cv_[]$1[]_LIBS AC_MSG_RESULT([yes]) - ifelse([$3], , :, [$3]) + $3 fi[]dnl ])# PKG_CHECK_MODULES @@ -623,7 +629,7 @@ AC_DEFUN([AM_AUTOMAKE_VERSION], [am__api_version='1.11' dnl Some users find AM_AUTOMAKE_VERSION and mistake it for a way to dnl require some minimum version. Point them to the right macro. -m4_if([$1], [1.11], [], +m4_if([$1], [1.11.1], [], [AC_FATAL([Do not call $0, use AM_INIT_AUTOMAKE([$1]).])])dnl ]) @@ -639,7 +645,7 @@ m4_define([_AM_AUTOCONF_VERSION], []) # Call AM_AUTOMAKE_VERSION and AM_AUTOMAKE_VERSION so they can be traced. # This function is AC_REQUIREd by AM_INIT_AUTOMAKE. AC_DEFUN([AM_SET_CURRENT_AUTOMAKE_VERSION], -[AM_AUTOMAKE_VERSION([1.11])dnl +[AM_AUTOMAKE_VERSION([1.11.1])dnl m4_ifndef([AC_AUTOCONF_VERSION], [m4_copy([m4_PACKAGE_VERSION], [AC_AUTOCONF_VERSION])])dnl _AM_AUTOCONF_VERSION(m4_defn([AC_AUTOCONF_VERSION]))]) diff --git a/config.h.in b/config.h.in index 99c626f..3b0e4de 100644 --- a/config.h.in +++ b/config.h.in @@ -63,6 +63,9 @@ /* Define to the one symbol short name of this package. */ #undef PACKAGE_TARNAME +/* Define to the home page for this package. */ +#undef PACKAGE_URL + /* Define to the version of this package. */ #undef PACKAGE_VERSION diff --git a/configure b/configure index 9095957..f3c87c8 100755 --- a/configure +++ b/configure @@ -2627,7 +2627,7 @@ fi # Define the identity of the package. PACKAGE=xournal - VERSION=0.4.5 + VERSION=0.4.6 cat >>confdefs.h <<_ACEOF diff --git a/configure.in b/configure.in index 2bae7af..5d4aa09 100644 --- a/configure.in +++ b/configure.in @@ -1,7 +1,7 @@ dnl Process this file with autoconf to produce a configure script. AC_INIT(configure.in) -AM_INIT_AUTOMAKE(xournal, 0.4.5) +AM_INIT_AUTOMAKE(xournal, 0.4.6) AM_CONFIG_HEADER(config.h) AM_MAINTAINER_MODE diff --git a/html-doc/manual.html b/html-doc/manual.html index ab24d51..8a257e6 100644 --- a/html-doc/manual.html +++ b/html-doc/manual.html @@ -24,7 +24,7 @@ Xournal User's Manual

- Version 0.4.5 + Version 0.4.6


@@ -696,21 +696,22 @@ the name and point size of the default text font.

Author information, license, bug-reports

Xournal is written by Denis Auroux -(auroux@math.mit.edu, -auroux@math.berkeley.edu). +(auroux@math.berkeley.edu).

The source code includes contributions by the following people: -Eduardo de Barros Lima, Mathieu Bouchard, Ole Jørgen Brønner, -Vincenzo Ciancia, Luca de Cicco, Michele Codutti, -Robert Gerlach, Lukasz Kaiser, Danny Kukawka, Bob McElrath, -Andy Neitzke, David Planella, Alex Ray, Jean-Baptiste Rouquier, -Mike Ter Louw, Uwe Winter, Lu Zhihe. +Alvaro, Kit Barnes, Eduardo de Barros Lima, Mathieu Bouchard, +Ole Jørgen Brønner, Robert Buchholz, Vincenzo Ciancia, Luca de Cicco, +Michele Codutti, Robert Gerlach, Daniel German, Dirk Gerrits, +Lukasz Kaiser, Timo Kluck, David Kolibac, Danny Kukawka, Stefan Lembach, +Bob McElrath, Andy Neitzke, David Planella, Marco Poletti, Alex Ray, +Jean-Baptiste Rouquier, Marco Souza, Mike Ter Louw, Uwe Winter, Lu Zhihe.

(Let me know if you are missing from this list or if your name is mis-spelled)

-Xournal is distributed under the GNU General Public License. +Xournal is distributed under the GNU General Public License (version 2, or +at your option any later version).

Note: most of the code of version 0.4.2.1 @@ -733,6 +734,27 @@ Bug reports and suggestions can also be submitted on Xournal's

Version history

+Version 0.4.6 (May 22, 2012): +

    +
  • win32 portability code (contributed by Dirk Gerrits) +
  • fix bug in PDF export code on 64-bit systems (patch by Robert Buchholz) +
  • fix hand tool bug when exiting canvas (#2905711) +
  • Italian translation (Marco Poletti), German translation (Stefan Lembach) +
  • Spanish translation (Alvaro), Brazil Portuguese translation (Marco Souza) +
  • fix save bug with text boxes containing > 4095 characters +
  • Czech translation (David Kolibac), Dutch translation (Timo Kluck) +
  • fix crash upon unplugging input devices +
  • change close dialog box default to "save" (patch by Kit Barnes) +
  • option to force PDF background rendering via cairo (slower but nicer) +
  • wrapper for missing GdkPixbuf rendering function in newest poppler +
  • disable GTK+ XInput bugfix by default (#3429416) +
  • fix linker flags (#3208984); evdev coordinate fix (#3244118) (Timo Kluck) +
  • specify license version: GPL v2 or later +
  • fix 1.#J coordinates from win32 xoj files +
  • +
+

+

Version 0.4.5 (Oct 2, 2009):

  • bugfixes for GTK+ 2.16/2.17 issues with xinput events @@ -1094,7 +1116,7 @@ Download the Xournal distribution tar.gz file, and any needed dependencies.

    Compilation and installation in /usr/local:

    -./configure
    +./autogen.sh
     make
     (as root) make install
     (as root) make desktop-install
    @@ -1103,6 +1125,7 @@ make
     

    Compilation and installation in $HOME:

    +./autogen.sh
     ./configure --prefix=$HOME
     make
     make install
    @@ -1278,15 +1301,12 @@ Options menu), at a price of a severe loss of resolution (and the eraser tip
     won't be detected anymore).
     

    -I have also had a report that one of the workarounds used by Xournal to -bypass a calibration bug in GTK+ can actually entirely prevent strokes -from being drawn. If you are being unsuccessful at drawing in Xournal -with XInput enabled, try recompiling after commenting out the line +One of the workarounds used by Xournal to +bypass a calibration bug in old versions of GTK+ seems to be more harmful +than helpful with modern distributions. If you miss the old behavior or +are having XInput issues, try recompiling after uncommenting the line

    #define ENABLE_XINPUT_BUGFIX
    near the beginning of src/xournal.h. -If this modification does improve things for you, and if you have a bit -of spare time to help investigate the causes of this problem, please -contact me.

    On-the-fly display rotation

    @@ -1307,7 +1327,8 @@ To return to landscape mode:

    Note #1: you should not rotate the display while Xournal is running, otherwise the tablet calibration in Xournal may (and most likely will) -become incorrect. +become incorrect. (Less likely to occur with modern distributions and +ENABLE_XINPUT_BUGFIX disabled). Exit Xournal and restart it after the display has been rotated.

    diff --git a/mkinstalldirs b/mkinstalldirs index d2d5f21..4191a45 100755 --- a/mkinstalldirs +++ b/mkinstalldirs @@ -1,21 +1,36 @@ #! /bin/sh # mkinstalldirs --- make directory hierarchy -# Author: Noah Friedman + +scriptversion=2009-04-28.21; # UTC + +# Original author: Noah Friedman # Created: 1993-05-16 -# Public domain +# Public domain. +# +# This file is maintained in Automake, please report +# bugs to or send patches to +# . +nl=' +' +IFS=" "" $nl" errstatus=0 -dirmode="" +dirmode= usage="\ -Usage: mkinstalldirs [-h] [--help] [-m mode] dir ..." +Usage: mkinstalldirs [-h] [--help] [--version] [-m MODE] DIR ... + +Create each directory DIR (with mode MODE, if specified), including all +leading file name components. + +Report bugs to ." # process command line arguments while test $# -gt 0 ; do case $1 in -h | --help | --h*) # -h for help - echo "$usage" 1>&2 - exit 0 + echo "$usage" + exit $? ;; -m) # -m PERM arg shift @@ -23,6 +38,10 @@ while test $# -gt 0 ; do dirmode=$1 shift ;; + --version) + echo "$0 $scriptversion" + exit $? + ;; --) # stop option processing shift break @@ -50,30 +69,58 @@ case $# in 0) exit 0 ;; esac +# Solaris 8's mkdir -p isn't thread-safe. If you mkdir -p a/b and +# mkdir -p a/c at the same time, both will detect that a is missing, +# one will create a, then the other will try to create a and die with +# a "File exists" error. This is a problem when calling mkinstalldirs +# from a parallel make. We use --version in the probe to restrict +# ourselves to GNU mkdir, which is thread-safe. case $dirmode in '') - if mkdir -p -- . 2>/dev/null; then + if mkdir -p --version . >/dev/null 2>&1 && test ! -d ./--version; then echo "mkdir -p -- $*" exec mkdir -p -- "$@" + else + # On NextStep and OpenStep, the `mkdir' command does not + # recognize any option. It will interpret all options as + # directories to create, and then abort because `.' already + # exists. + test -d ./-p && rmdir ./-p + test -d ./--version && rmdir ./--version fi ;; *) - if mkdir -m "$dirmode" -p -- . 2>/dev/null; then + if mkdir -m "$dirmode" -p --version . >/dev/null 2>&1 && + test ! -d ./--version; then echo "mkdir -m $dirmode -p -- $*" exec mkdir -m "$dirmode" -p -- "$@" + else + # Clean up after NextStep and OpenStep mkdir. + for d in ./-m ./-p ./--version "./$dirmode"; + do + test -d $d && rmdir $d + done fi ;; esac for file do - set fnord `echo ":$file" | sed -ne 's/^:\//#/;s/^://;s/\// /g;s/^#/\//;p'` + case $file in + /*) pathcomp=/ ;; + *) pathcomp= ;; + esac + oIFS=$IFS + IFS=/ + set fnord $file shift + IFS=$oIFS - pathcomp= for d do - pathcomp="$pathcomp$d" + test "x$d" = x && continue + + pathcomp=$pathcomp$d case $pathcomp in -*) pathcomp=./$pathcomp ;; esac @@ -84,21 +131,21 @@ do mkdir "$pathcomp" || lasterr=$? if test ! -d "$pathcomp"; then - errstatus=$lasterr + errstatus=$lasterr else - if test ! -z "$dirmode"; then + if test ! -z "$dirmode"; then echo "chmod $dirmode $pathcomp" - lasterr="" - chmod "$dirmode" "$pathcomp" || lasterr=$? + lasterr= + chmod "$dirmode" "$pathcomp" || lasterr=$? - if test ! -z "$lasterr"; then - errstatus=$lasterr - fi - fi + if test ! -z "$lasterr"; then + errstatus=$lasterr + fi + fi fi fi - pathcomp="$pathcomp/" + pathcomp=$pathcomp/ done done @@ -107,5 +154,9 @@ exit $errstatus # Local Variables: # mode: shell-script # sh-indentation: 2 +# eval: (add-hook 'write-file-hooks 'time-stamp) +# time-stamp-start: "scriptversion=" +# time-stamp-format: "%:y-%02m-%02d.%02H" +# time-stamp-time-zone: "UTC" +# time-stamp-end: "; # UTC" # End: -# mkinstalldirs ends here diff --git a/po/ChangeLog b/po/ChangeLog index cfb01a7..421d795 100644 --- a/po/ChangeLog +++ b/po/ChangeLog @@ -1,3 +1,4 @@ +Version 0.4.6: - added Italian translation (by Marco Poletti) - added German translation (by Stefan Lembach) - added Spanish translation (by Alvaro) diff --git a/po/Makefile.in.in b/po/Makefile.in.in index 15d6a20..53b496d 100644 --- a/po/Makefile.in.in +++ b/po/Makefile.in.in @@ -79,7 +79,7 @@ INSTOBJEXT = @INSTOBJEXT@ $(MSGFMT) -o $@ $< .po.gmo: - file=$(srcdir)/`echo $* | sed 's,.*/,,'`.gmo \ + $(AM_V_GEN) file=$(srcdir)/`echo $* | sed 's,.*/,,'`.gmo \ && rm -f $$file && $(GMSGFMT) $(MSGFMT_OPTS) -o $$file $< .po.cat: @@ -93,8 +93,18 @@ all-yes: $(CATALOGS) all-no: $(srcdir)/$(GETTEXT_PACKAGE).pot: $(POTFILES) - $(XGETTEXT) --default-domain=$(GETTEXT_PACKAGE) --directory=$(top_srcdir) \ + $(XGETTEXT) --default-domain=$(GETTEXT_PACKAGE) \ + --msgid-bugs-address='http://bugzilla.gnome.org/enter_bug.cgi?product=glib&keywords=I18N+L10N&component=general' \ --add-comments --keyword=_ --keyword=N_ \ + --keyword=C_:1c,2 \ + --keyword=NC_:1c,2 \ + --keyword=g_dcgettext:2 \ + --keyword=g_dngettext:2,3 \ + --keyword=g_dpgettext2:2c,3 \ + --flag=N_:1:pass-c-format \ + --flag=C_:2:pass-c-format \ + --flag=NC_:2:pass-c-format \ + --flag=g_dngettext:2:pass-c-format \ --flag=g_strdup_printf:1:c-format \ --flag=g_string_printf:2:c-format \ --flag=g_string_append_printf:2:c-format \ @@ -110,7 +120,7 @@ $(srcdir)/$(GETTEXT_PACKAGE).pot: $(POTFILES) --flag=g_snprintf:3:c-format \ --flag=g_scanner_error:2:c-format \ --flag=g_scanner_warn:2:c-format \ - --files-from=$(srcdir)/POTFILES.in \ + $(POTFILES) \ && test ! -f $(GETTEXT_PACKAGE).po \ || ( rm -f $(srcdir)/$(GETTEXT_PACKAGE).pot \ && mv $(GETTEXT_PACKAGE).po $(srcdir)/$(GETTEXT_PACKAGE).pot ) @@ -209,7 +219,7 @@ maintainer-clean: distclean rm -f $(GMOFILES) distdir = ../$(GETTEXT_PACKAGE)-$(VERSION)/$(subdir) -dist distdir: update-po $(DISTFILES) +dist distdir: $(DISTFILES) dists="$(DISTFILES)"; \ for file in $$dists; do \ ln $(srcdir)/$$file $(distdir) 2> /dev/null \ diff --git a/src/TODO b/src/TODO index 57acb3a..e6d19ed 100644 --- a/src/TODO +++ b/src/TODO @@ -12,7 +12,7 @@ List of features to be implemented (not in any particular order) - cleanup of undo history (keep track of refcounts, delete old undo) save-and-clear-undo ? -- RandR / recalibration awareness? +- RandR / recalibration awareness? - NOT NEEDED ANYMORE? (e.g. if xinput events are far away from core events, re-query geometry?) or see if removing the GTK bugfix would help? -- e.g. by recalling an internal gtk init function? @@ -21,32 +21,35 @@ List of features to be implemented (not in any particular order) to X server to query input device geometry and compensate for GTK. BUGS: -** lingering issues with synaptics touchpads? (#2872667) +- lingering issues with synaptics touchpads? (#2872667) (todo) - set device to Absolute mode at startup? (GDK doesn't expose API, cf XSetDeviceMode() in /usr/include/X11/extensions/XInput.h) -** color picker into canvas doesn't work in GTK+ 2.16 (should disable +- color picker into canvas doesn't work in GTK+ 2.16 (should disable xinput first?) -** export to PDF should see cropbox size if smaller, and map the +- export to PDF should see cropbox size if smaller, and map the cropbox -- not the entire page -- to the page area! (2009-11-18 forum) -*** filter out very large coords when loading, not just infinity - WIN32: - test further - write an installer - bug: opening files with accents in name? - bug: cairo-scaled-font in printing? (2009-11-18 bug tracker) - bug: printf() sometimes generates stroke coordinates 1.#J -1.#J (???) + (filter out inf, -inf, nan, very large values when saving ???) PATCHES TO INCORPORATE: -* filter out very large coords when loading, not just infinity; also filter - out 1.#J's +- ezyang e-mail of 11/28/2011: patches in Ubuntu to fix PDF showing up? +http://archive.ubuntu.com/ubuntu/pool/universe/x/xournal/xournal_0.4.5-3.debian.tar.gz +actually not necessary anymore? (ezyang 12/2/2011) + +- tauu e-mail of 12/1/2011: 8 small patches for win32, uploaded on tracker +https://sourceforge.net/tracker/index.php?func=detail&aid=3447356&group_id=163434&atid=827735 - patch: add Alt-Up/Dn accelerators for show/hide layer. See show_hide_layer.patch -***** my own patch noresize_background_v1.patch (also in xournal-working/) +* my own patch noresize_background_v1.patch (also in xournal-working/) ** patch: ortho/snap (revised Apr 13 2009) xournal_ortho_snap_patch_4 (by Josef Pavlicek) @@ -77,8 +80,6 @@ PATCHES TO INCORPORATE: shortcut to increase/decrease text font size by 1 point (?) - acts just as if one had clicked font sel box and resized (affects sel text + cur font) -- make default in ok_to_close() box "cancel" rather than "no". - - make line spacing in text objects customizable: to a fixed scaling factor, a fixed number of units, or the paper ruling (esp. the latter!!) diff --git a/src/ttsubset/Makefile.in b/src/ttsubset/Makefile.in index e091355..58893a5 100644 --- a/src/ttsubset/Makefile.in +++ b/src/ttsubset/Makefile.in @@ -1,4 +1,4 @@ -# Makefile.in generated by automake 1.11 from Makefile.am. +# Makefile.in generated by automake 1.11.1 from Makefile.am. # @configure_input@ # Copyright (C) 1994, 1995, 1996, 1997, 1998, 1999, 2000, 2001, 2002, @@ -32,6 +32,8 @@ POST_INSTALL = : NORMAL_UNINSTALL = : PRE_UNINSTALL = : POST_UNINSTALL = : +build_triplet = @build@ +host_triplet = @host@ subdir = src/ttsubset DIST_COMMON = README $(srcdir)/Makefile.am $(srcdir)/Makefile.in ACLOCAL_M4 = $(top_srcdir)/aclocal.m4 @@ -113,9 +115,12 @@ PACKAGE_LIBS = @PACKAGE_LIBS@ PACKAGE_NAME = @PACKAGE_NAME@ PACKAGE_STRING = @PACKAGE_STRING@ PACKAGE_TARNAME = @PACKAGE_TARNAME@ +PACKAGE_URL = @PACKAGE_URL@ PACKAGE_VERSION = @PACKAGE_VERSION@ PATH_SEPARATOR = @PATH_SEPARATOR@ PKG_CONFIG = @PKG_CONFIG@ +PKG_CONFIG_LIBDIR = @PKG_CONFIG_LIBDIR@ +PKG_CONFIG_PATH = @PKG_CONFIG_PATH@ POFILES = @POFILES@ POSUB = @POSUB@ PO_IN_DATADIR_FALSE = @PO_IN_DATADIR_FALSE@ @@ -138,14 +143,22 @@ am__quote = @am__quote@ am__tar = @am__tar@ am__untar = @am__untar@ bindir = @bindir@ +build = @build@ build_alias = @build_alias@ +build_cpu = @build_cpu@ +build_os = @build_os@ +build_vendor = @build_vendor@ builddir = @builddir@ datadir = @datadir@ datarootdir = @datarootdir@ docdir = @docdir@ dvidir = @dvidir@ exec_prefix = @exec_prefix@ +host = @host@ host_alias = @host_alias@ +host_cpu = @host_cpu@ +host_os = @host_os@ +host_vendor = @host_vendor@ htmldir = @htmldir@ includedir = @includedir@ infodir = @infodir@ diff --git a/src/xo-callbacks.c b/src/xo-callbacks.c index a9fb39c..3b2b319 100644 --- a/src/xo-callbacks.c +++ b/src/xo-callbacks.c @@ -2391,7 +2391,7 @@ on_canvas_button_press_event (GtkWidget *widget, if (!is_core) fix_xinput_coords((GdkEvent *)event); - if (!finite(event->x) || !finite(event->y)) return FALSE; // Xorg 7.3 bug + if (!finite_sized(event->x) || !finite_sized(event->y)) return FALSE; // Xorg 7.3 bug if (ui.cur_item_type == ITEM_TEXT) { if (!is_event_within_textview(event)) end_text(); @@ -2702,7 +2702,7 @@ on_canvas_motion_notify_event (GtkWidget *widget, is_core = (event->device == gdk_device_get_core_pointer()); if (!ui.use_xinput && !is_core) return FALSE; if (!is_core) fix_xinput_coords((GdkEvent *)event); - if (!finite(event->x) || !finite(event->y)) return FALSE; // Xorg 7.3 bug + if (!finite_sized(event->x) || !finite_sized(event->y)) return FALSE; // Xorg 7.3 bug if (ui.selection!=NULL && ui.cur_item_type == ITEM_NONE) { get_pointer_coords((GdkEvent *)event, pt); diff --git a/src/xo-file.c b/src/xo-file.c index b8d5bbb..81ce156 100644 --- a/src/xo-file.c +++ b/src/xo-file.c @@ -252,10 +252,16 @@ gboolean close_journal(void) } // sanitize a string containing floats, in case it may have , instead of . +// also replace Windows-produced 1.#J by inf void cleanup_numeric(char *s) { - while (*s!=0) { if (*s==',') *s='.'; s++; } + while (*s!=0) { + if (*s==',') *s='.'; + if (*s=='1' && s[1]=='.' && s[2]=='#' && s[3]=='J') + { *s='i'; s[1]='n'; s[2]='f'; s[3]=' '; } + s++; + } } // the XML parser functions for open_journal() @@ -650,7 +656,7 @@ void xoj_parser_text(GMarkupParseContext *context, if (ptr == text) break; text_len -= (ptr - text); text = ptr; - if (!finite(ui.cur_path.coords[n])) { + if (!finite_sized(ui.cur_path.coords[n])) { if (n>=2) ui.cur_path.coords[n] = ui.cur_path.coords[n-2]; else ui.cur_path.coords[n] = 0; } diff --git a/src/xo-misc.c b/src/xo-misc.c index 1ec4401..4f51d85 100644 --- a/src/xo-misc.c +++ b/src/xo-misc.c @@ -355,6 +355,12 @@ void refstring_unref(struct Refstring *rs) // some helper functions +int finite_sized(double x) // detect unrealistic coordinate values +{ + return (finite(x) && x<1E6 && x>-1E6); +} + + void get_pointer_coords(GdkEvent *event, gdouble *ret) { double x, y; @@ -388,7 +394,7 @@ void fix_xinput_coords(GdkEvent *event) #ifdef ENABLE_XINPUT_BUGFIX // fix broken events with the core pointer's location - if (!finite(axes[0]) || !finite(axes[1]) || axes[0]==0. || axes[1]==0.) { + if (!finite_sized(axes[0]) || !finite_sized(axes[1]) || axes[0]==0. || axes[1]==0.) { gdk_window_get_pointer(GTK_WIDGET(canvas)->window, &ix, &iy, NULL); *px = ix + sx; *py = iy + sy; @@ -403,7 +409,7 @@ void fix_xinput_coords(GdkEvent *event) *py = (axes[1]/axis_width)*ui.screen_height + sy - wy; } #else - if (!finite(*px) || !finite(*py) || (*px==0. && *py==0.)) { + if (!finite_sized(*px) || !finite_sized(*py) || *px==0. || *py==0.) { gdk_window_get_pointer(GTK_WIDGET(canvas)->window, &ix, &iy, NULL); *px = ix + sx; *py = iy + sy; @@ -445,7 +451,7 @@ double get_pressure_multiplier(GdkEvent *event) || device->num_axes <= 2) return 1.0; rawpressure = axes[2]/(device->axes[2].max - device->axes[2].min); - if (!finite(rawpressure)) return 1.0; + if (!finite_sized(rawpressure)) return 1.0; return ((1-rawpressure)*ui.width_minimum_multiplier + rawpressure*ui.width_maximum_multiplier); } diff --git a/src/xo-misc.h b/src/xo-misc.h index c4342b8..da1433d 100644 --- a/src/xo-misc.h +++ b/src/xo-misc.h @@ -34,6 +34,7 @@ void refstring_unref(struct Refstring *rs); // helper functions +int finite_sized(double x); void get_pointer_coords(GdkEvent *event, double *ret); double get_pressure_multiplier(GdkEvent *event); void fix_xinput_coords(GdkEvent *event); -- 2.39.2