Hello community, here is the log from the commit of package pdfchain for openSUSE:Factory checked in at 2016-03-11 12:29:46 ++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++ Comparing /work/SRC/openSUSE:Factory/pdfchain (Old) and /work/SRC/openSUSE:Factory/.pdfchain.new (New) ++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
Package is "pdfchain" Changes: -------- --- /work/SRC/openSUSE:Factory/pdfchain/pdfchain.changes 2015-09-24 06:15:12.000000000 +0200 +++ /work/SRC/openSUSE:Factory/.pdfchain.new/pdfchain.changes 2016-03-11 12:29:48.000000000 +0100 @@ -1,0 +2,28 @@ +Thu Mar 10 11:55:38 UTC 2016 - fcro...@suse.com + +- Add 0003-Fix-crash-because-the-RadioButtonGroup-was-contructe.patch: + fix crash (and some warnings) when starting the application. + Patch by Hubert Figuière [boo#970530]. + +------------------------------------------------------------------- +Wed Mar 9 17:04:18 UTC 2016 - fcro...@suse.com + +- Version 0.4.4.2: + * Quoting passwords: $ sign in passoword is now possible + * Disabled rubber banding in the treeviews of catenate and + attachment. + * Replaced switch() statements with boolean variables with if() + statements. + * Solved problem with the Gtk::CellrendererText + * Added Help Button and MenuItem which links to the documentation + page. + * Adjusted the year in the copyright message in the about dialog. + * Corrected required version of GTKmm for C++11 from 3.12 to 3.18 + in configure.ac (was wrong). +- Changes from version 0.4.4.1: + * Added check for gtkmm >= 3.12 in configure.ac. gtkmm >= 3.12 + depends on c++11. If check is true the compiler flag -std=c++0x + will be set.. +- Update BuildRequires to pkgconfig(gtkmm-3.0) >= 3.12 + +------------------------------------------------------------------- Old: ---- pdfchain-0.4.4.tar.gz New: ---- 0003-Fix-crash-because-the-RadioButtonGroup-was-contructe.patch pdfchain-0.4.4.2.tar.gz ++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++ Other differences: ------------------ ++++++ pdfchain.spec ++++++ --- /var/tmp/diff_new_pack.Rlb02z/_old 2016-03-11 12:29:48.000000000 +0100 +++ /var/tmp/diff_new_pack.Rlb02z/_new 2016-03-11 12:29:48.000000000 +0100 @@ -1,7 +1,7 @@ # # spec file for package pdfchain # -# Copyright (c) 2015 SUSE LINUX GmbH, Nuernberg, Germany. +# Copyright (c) 2016 SUSE LINUX GmbH, Nuernberg, Germany. # Copyright (c) 2012-2013 B1 Systems GmbH, Vohburg, Germany. # # All modifications and additions to the file contributed by third parties @@ -18,7 +18,7 @@ Name: pdfchain -Version: 0.4.4 +Version: 0.4.4.2 Release: 0 Summary: A GUI for pdftk License: GPL-3.0 @@ -26,13 +26,14 @@ Url: http://sourceforge.net/projects/pdfchain/ Source0: http://sourceforge.net/projects/pdfchain/files/pdfchain-%{version}/pdfchain-%{version}.tar.gz Patch0: pdfchain-desktop.patch +# PATCH-FIX-UPSTREAM fix-crash-and-warnings.patch fcro...@suse.com -- fix crash at startup +Patch1: 0003-Fix-crash-because-the-RadioButtonGroup-was-contructe.patch BuildRequires: fdupes BuildRequires: gcc-c++ -BuildRequires: gtkmm3-devel BuildRequires: hicolor-icon-theme BuildRequires: intltool >= 0.35.0 -BuildRequires: pkg-config BuildRequires: update-desktop-files +BuildRequires: pkgconfig(gtkmm-3.0) >= 3.12.0 Requires: hicolor-icon-theme Requires: pdftk >= 2.0 BuildRoot: %{_tmppath}/%{name}-%{version}-build @@ -50,6 +51,7 @@ %prep %setup -q %patch0 +%patch1 -p1 %build %configure ++++++ 0003-Fix-crash-because-the-RadioButtonGroup-was-contructe.patch ++++++ >From cc25d6e662d93d82addb67967c346052a7e54b36 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Hubert=20Figui=C3=A8re?= <h...@figuiere.net> Date: Wed, 9 Mar 2016 14:49:58 -0500 Subject: [PATCH 3/3] Fix crash because the RadioButtonGroup was contructed AFTER the RadioButton. --- src/window_main_bgst.cc | 1 - src/window_main_bgst.h | 8 ++++---- src/window_main_burst.cc | 3 --- src/window_main_burst.h | 10 +++++----- src/window_main_tool.cc | 1 - src/window_main_tool.h | 6 +++--- 6 files changed, 12 insertions(+), 17 deletions(-) Index: pdfchain-0.4.4.2/src/window_main_bgst.cc =================================================================== --- pdfchain-0.4.4.2.orig/src/window_main_bgst.cc 2016-03-10 16:50:02.204879217 +0100 +++ pdfchain-0.4.4.2/src/window_main_bgst.cc 2016-03-10 16:51:25.555854265 +0100 @@ -37,7 +37,6 @@ mLabel_SourceFile( _("Document:") , Gtk::ALIGN_END , Gtk::ALIGN_CENTER , false ) , // label , xalign , yalign , mnemonic mLabel_BgStFile( _("Layer (PDF):") , Gtk::ALIGN_END , Gtk::ALIGN_CENTER , false ) , - mRBGroup_BgSt( mRButton_Background.get_group() ) , mRButton_Background( mRBGroup_BgSt , _("Background") , false ) , // group , label , mnemonic mRButton_Stamp( mRBGroup_BgSt , _("Stamp") , false ) , Index: pdfchain-0.4.4.2/src/window_main_bgst.h =================================================================== --- pdfchain-0.4.4.2.orig/src/window_main_bgst.h 2013-07-04 19:40:30.000000000 +0200 +++ pdfchain-0.4.4.2/src/window_main_bgst.h 2016-03-10 16:50:02.204879217 +0100 @@ -64,13 +64,13 @@ Gtk::CheckButton mCButton_Multiple; - Gtk::RadioButton // Declaration of Gtk::RadioButton before Gtk::RadioButtonGroup!!! + Gtk::RadioButtonGroup + mRBGroup_BgSt; + + Gtk::RadioButton mRButton_Background , mRButton_Stamp; - Gtk::RadioButtonGroup // Declaration of Gtk::RadioButtonGroup behind Gtk::RadioButton!!! - mRBGroup_BgSt; - // Derived Widgets cFCButton_Pdf mFCButton_SourceFile , Index: pdfchain-0.4.4.2/src/window_main_burst.cc =================================================================== --- pdfchain-0.4.4.2.orig/src/window_main_burst.cc 2016-03-10 16:50:02.204879217 +0100 +++ pdfchain-0.4.4.2/src/window_main_burst.cc 2016-03-10 16:52:07.923334335 +0100 @@ -62,7 +62,6 @@ mLabel_Digits( _("Digits:") , Gtk::ALIGN_END , Gtk::ALIGN_CENTER , false ), mLabel_Suffix( _("Suffix:") , Gtk::ALIGN_END , Gtk::ALIGN_CENTER , false ), - mRBGroup_CounterDigits( mRButton_Auto.get_group() ), mRButton_Auto( mRBGroup_CounterDigits , _("Auto") , false ), // group , label , mnemonic mRButton_Manual( mRBGroup_CounterDigits , _("Manual:") , false ), Index: pdfchain-0.4.4.2/src/window_main_burst.h =================================================================== --- pdfchain-0.4.4.2.orig/src/window_main_burst.h 2013-07-04 19:18:21.000000000 +0200 +++ pdfchain-0.4.4.2/src/window_main_burst.h 2016-03-10 16:50:02.204879217 +0100 @@ -118,13 +118,13 @@ Gtk::SpinButton // Declaration of Gtk::SpinButton behind Glib::RefPtr<Gtk::Adjustment>!!! mSButton_Digits; - Gtk::RadioButton // Declaration of Gtk::RadioButton before Gtk::RadioButtonGroup!!! + Gtk::RadioButtonGroup + mRBGroup_CounterDigits; + + Gtk::RadioButton mRButton_Auto , mRButton_Manual; - Gtk::RadioButtonGroup // Declaration of Gtk::RadioButtonGroup behind Gtk::RadioButton!!! - mRBGroup_CounterDigits; - Gtk::CheckButton mCButton_Extension; Index: pdfchain-0.4.4.2/src/window_main_tool.cc =================================================================== --- pdfchain-0.4.4.2.orig/src/window_main_tool.cc 2016-03-10 16:50:02.204879217 +0100 +++ pdfchain-0.4.4.2/src/window_main_tool.cc 2016-03-10 16:52:41.274925543 +0100 @@ -50,8 +50,6 @@ mCButton_FillForm_Flatten( _("Flatten") , false ), mCButton_FillForm_Appearance( _("Need appearances") , false ), -mRBGroup_Tool( mRButton_UnpackFiles.get_group() ), - mRButton_Repair( mRBGroup_Tool , _("Repair docu_ment") , true ), // group , label , mnemonic mRButton_UnpackFiles( mRBGroup_Tool , _("Un_pack attached files from document") , true ), mRButton_Uncompress( mRBGroup_Tool , _("_Uncompress document") , true ), Index: pdfchain-0.4.4.2/src/window_main_tool.h =================================================================== --- pdfchain-0.4.4.2.orig/src/window_main_tool.h 2013-07-02 00:22:33.000000000 +0200 +++ pdfchain-0.4.4.2/src/window_main_tool.h 2016-03-10 16:50:02.204879217 +0100 @@ -57,6 +57,9 @@ mLabel_DumpDataFile , mLabel_FdfFile; + Gtk::RadioButtonGroup + mRBGroup_Tool; + Gtk::RadioButton mRButton_Repair , mRButton_UnpackFiles , @@ -71,9 +74,6 @@ mRButton_Flatten , mRButton_DropXfa; - Gtk::RadioButtonGroup - mRBGroup_Tool; - Gtk::CheckButton mCButton_DumpDataFields_Utf8 , mCButton_DumpData_Utf8 , ++++++ pdfchain-0.4.4.tar.gz -> pdfchain-0.4.4.2.tar.gz ++++++ ++++ 4437 lines of diff (skipped) ++++ retrying with extended exclude list diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' --exclude Makefile.in --exclude configure --exclude config.guess --exclude '*.pot' --exclude mkinstalldirs --exclude aclocal.m4 --exclude config.sub --exclude depcomp --exclude install-sh --exclude ltmain.sh old/pdfchain-0.4.4/ChangeLog new/pdfchain-0.4.4.2/ChangeLog --- old/pdfchain-0.4.4/ChangeLog 2013-07-10 11:35:28.000000000 +0200 +++ new/pdfchain-0.4.4.2/ChangeLog 2015-12-17 17:32:55.000000000 +0100 @@ -274,3 +274,34 @@ * Added a clear function to all FileChoosers * All FileChooser show the "current folder" not the "history" * Changed the clear function for the FileChooser in the sections + + +2015-10-15 Martin Singer <m_pow...@users.sourceforge.net> + + Version 0.4.4.1 (alpha) + + * Added check for gtkmm >= 3.12 in configure.ac + gtkmm >= 3.12 depends on c++11. If check is true the + compiler flag -std=c++0x will be set. + + http://www.murrayc.com/permalink/2015/07/31/gtkmm-now-uses-c11/ + + +2015-12-17 Martin Singer <m_pow...@users.sourceforge.net> + + Version 0.4.4.2 (alpha) + + * Quoting passwords + Solves problem with $ sign in passwords + Thanks Robert! + * Disabled rubber banding in the treeviews of catenate and attachment + Solves some critical messages of GTK + * Replaced switch() statements with boolean variables with if() statements + Removes compiler warnings + * Solved problem with the Gtk::CellrendererText + Added a separate column for the even/odd filter + * Added Help Button and MenuItem wich links to the documentation page + * Adjusted the year in the copyright message in the about dialog + * Changed requred version of GTKmm from 3.12 to 3.18 (was wrong) + http://www.murrayc.com/permalink/2015/09/25/gtkmm-3-18-and-glibmm-2-46/ + diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' --exclude Makefile.in --exclude configure --exclude config.guess --exclude '*.pot' --exclude mkinstalldirs --exclude aclocal.m4 --exclude config.sub --exclude depcomp --exclude install-sh --exclude ltmain.sh old/pdfchain-0.4.4/compile new/pdfchain-0.4.4.2/compile --- old/pdfchain-0.4.4/compile 1970-01-01 01:00:00.000000000 +0100 +++ new/pdfchain-0.4.4.2/compile 2015-10-15 16:39:34.000000000 +0200 @@ -0,0 +1,347 @@ +#! /bin/sh +# Wrapper for compilers which do not understand '-c -o'. + +scriptversion=2012-10-14.11; # UTC + +# Copyright (C) 1999-2014 Free Software Foundation, Inc. +# Written by Tom Tromey <tro...@cygnus.com>. +# +# This program is free software; you can redistribute it and/or modify +# it under the terms of the GNU General Public License as published by +# the Free Software Foundation; either version 2, or (at your option) +# any later version. +# +# This program is distributed in the hope that it will be useful, +# but WITHOUT ANY WARRANTY; without even the implied warranty of +# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the +# GNU General Public License for more details. +# +# You should have received a copy of the GNU General Public License +# along with this program. If not, see <http://www.gnu.org/licenses/>. + +# As a special exception to the GNU General Public License, if you +# distribute this file as part of a program that contains a +# configuration script generated by Autoconf, you may include it under +# the same distribution terms that you use for the rest of that program. + +# This file is maintained in Automake, please report +# bugs to <bug-autom...@gnu.org> or send patches to +# <automake-patc...@gnu.org>. + +nl=' +' + +# We need space, tab and new line, in precisely that order. Quoting is +# there to prevent tools from complaining about whitespace usage. +IFS=" "" $nl" + +file_conv= + +# func_file_conv build_file lazy +# Convert a $build file to $host form and store it in $file +# Currently only supports Windows hosts. If the determined conversion +# type is listed in (the comma separated) LAZY, no conversion will +# take place. +func_file_conv () +{ + file=$1 + case $file in + / | /[!/]*) # absolute file, and not a UNC file + if test -z "$file_conv"; then + # lazily determine how to convert abs files + case `uname -s` in + MINGW*) + file_conv=mingw + ;; + CYGWIN*) + file_conv=cygwin + ;; + *) + file_conv=wine + ;; + esac + fi + case $file_conv/,$2, in + *,$file_conv,*) + ;; + mingw/*) + file=`cmd //C echo "$file " | sed -e 's/"\(.*\) " *$/\1/'` + ;; + cygwin/*) + file=`cygpath -m "$file" || echo "$file"` + ;; + wine/*) + file=`winepath -w "$file" || echo "$file"` + ;; + esac + ;; + esac +} + +# func_cl_dashL linkdir +# Make cl look for libraries in LINKDIR +func_cl_dashL () +{ + func_file_conv "$1" + if test -z "$lib_path"; then + lib_path=$file + else + lib_path="$lib_path;$file" + fi + linker_opts="$linker_opts -LIBPATH:$file" +} + +# func_cl_dashl library +# Do a library search-path lookup for cl +func_cl_dashl () +{ + lib=$1 + found=no + save_IFS=$IFS + IFS=';' + for dir in $lib_path $LIB + do + IFS=$save_IFS + if $shared && test -f "$dir/$lib.dll.lib"; then + found=yes + lib=$dir/$lib.dll.lib + break + fi + if test -f "$dir/$lib.lib"; then + found=yes + lib=$dir/$lib.lib + break + fi + if test -f "$dir/lib$lib.a"; then + found=yes + lib=$dir/lib$lib.a + break + fi + done + IFS=$save_IFS + + if test "$found" != yes; then + lib=$lib.lib + fi +} + +# func_cl_wrapper cl arg... +# Adjust compile command to suit cl +func_cl_wrapper () +{ + # Assume a capable shell + lib_path= + shared=: + linker_opts= + for arg + do + if test -n "$eat"; then + eat= + else + case $1 in + -o) + # configure might choose to run compile as 'compile cc -o foo foo.c'. + eat=1 + case $2 in + *.o | *.[oO][bB][jJ]) + func_file_conv "$2" + set x "$@" -Fo"$file" + shift + ;; + *) + func_file_conv "$2" + set x "$@" -Fe"$file" + shift + ;; + esac + ;; + -I) + eat=1 + func_file_conv "$2" mingw + set x "$@" -I"$file" + shift + ;; + -I*) + func_file_conv "${1#-I}" mingw + set x "$@" -I"$file" + shift + ;; + -l) + eat=1 + func_cl_dashl "$2" + set x "$@" "$lib" + shift + ;; + -l*) + func_cl_dashl "${1#-l}" + set x "$@" "$lib" + shift + ;; + -L) + eat=1 + func_cl_dashL "$2" + ;; + -L*) + func_cl_dashL "${1#-L}" + ;; + -static) + shared=false + ;; + -Wl,*) + arg=${1#-Wl,} + save_ifs="$IFS"; IFS=',' + for flag in $arg; do + IFS="$save_ifs" + linker_opts="$linker_opts $flag" + done + IFS="$save_ifs" + ;; + -Xlinker) + eat=1 + linker_opts="$linker_opts $2" + ;; + -*) + set x "$@" "$1" + shift + ;; + *.cc | *.CC | *.cxx | *.CXX | *.[cC]++) + func_file_conv "$1" + set x "$@" -Tp"$file" + shift + ;; + *.c | *.cpp | *.CPP | *.lib | *.LIB | *.Lib | *.OBJ | *.obj | *.[oO]) + func_file_conv "$1" mingw + set x "$@" "$file" + shift + ;; + *) + set x "$@" "$1" + shift + ;; + esac + fi + shift + done + if test -n "$linker_opts"; then + linker_opts="-link$linker_opts" + fi + exec "$@" $linker_opts + exit 1 +} + +eat= + +case $1 in + '') + echo "$0: No command. Try '$0 --help' for more information." 1>&2 + exit 1; + ;; + -h | --h*) + cat <<\EOF +Usage: compile [--help] [--version] PROGRAM [ARGS] + +Wrapper for compilers which do not understand '-c -o'. +Remove '-o dest.o' from ARGS, run PROGRAM with the remaining +arguments, and rename the output as expected. + +If you are trying to build a whole package this is not the +right script to run: please start by reading the file 'INSTALL'. + +Report bugs to <bug-autom...@gnu.org>. +EOF + exit $? + ;; + -v | --v*) + echo "compile $scriptversion" + exit $? + ;; + cl | *[/\\]cl | cl.exe | *[/\\]cl.exe ) + func_cl_wrapper "$@" # Doesn't return... + ;; +esac + +ofile= +cfile= + +for arg +do + if test -n "$eat"; then + eat= + else + case $1 in + -o) + # configure might choose to run compile as 'compile cc -o foo foo.c'. + # So we strip '-o arg' only if arg is an object. + eat=1 + case $2 in + *.o | *.obj) + ofile=$2 + ;; + *) + set x "$@" -o "$2" + shift + ;; + esac + ;; + *.c) + cfile=$1 + set x "$@" "$1" + shift + ;; + *) + set x "$@" "$1" + shift + ;; + esac + fi + shift +done + +if test -z "$ofile" || test -z "$cfile"; then + # If no '-o' option was seen then we might have been invoked from a + # pattern rule where we don't need one. That is ok -- this is a + # normal compilation that the losing compiler can handle. If no + # '.c' file was seen then we are probably linking. That is also + # ok. + exec "$@" +fi + +# Name of file we expect compiler to create. +cofile=`echo "$cfile" | sed 's|^.*[\\/]||; s|^[a-zA-Z]:||; s/\.c$/.o/'` + +# Create the lock directory. +# Note: use '[/\\:.-]' here to ensure that we don't use the same name +# that we are using for the .o file. Also, base the name on the expected +# object file name, since that is what matters with a parallel build. +lockdir=`echo "$cofile" | sed -e 's|[/\\:.-]|_|g'`.d +while true; do + if mkdir "$lockdir" >/dev/null 2>&1; then + break + fi + sleep 1 +done +# FIXME: race condition here if user kills between mkdir and trap. +trap "rmdir '$lockdir'; exit 1" 1 2 15 + +# Run the compile. +"$@" +ret=$? + +if test -f "$cofile"; then + test "$cofile" = "$ofile" || mv "$cofile" "$ofile" +elif test -f "${cofile}bj"; then + test "${cofile}bj" = "$ofile" || mv "${cofile}bj" "$ofile" +fi + +rmdir "$lockdir" +exit $ret + +# 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: diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' --exclude Makefile.in --exclude configure --exclude config.guess --exclude '*.pot' --exclude mkinstalldirs --exclude aclocal.m4 --exclude config.sub --exclude depcomp --exclude install-sh --exclude ltmain.sh old/pdfchain-0.4.4/configure.ac new/pdfchain-0.4.4.2/configure.ac --- old/pdfchain-0.4.4/configure.ac 2013-07-10 11:58:30.000000000 +0200 +++ new/pdfchain-0.4.4.2/configure.ac 2015-12-17 17:28:17.000000000 +0100 @@ -1,4 +1,4 @@ -AC_INIT([pdfchain], [0.4.4], [m_pow...@users.sourceforge.net]) +AC_INIT([pdfchain], [0.4.4.2], [m_pow...@users.sourceforge.net]) AM_INIT_AUTOMAKE([-Wall -Werror]) AC_PROG_CXX @@ -18,6 +18,14 @@ )] )] ) +PKG_CHECK_MODULES( + [GTKMM], + [GTKMM-3.0 >= 3.18.0], + [AX_CHECK_COMPILE_FLAG( + [-std=c++0x], + [CXXFLAGS="$CXXFLAGS -std=c++0x"] + )] +) AC_CONFIG_HEADERS([config.h]) AC_CONFIG_FILES([ diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' --exclude Makefile.in --exclude configure --exclude config.guess --exclude '*.pot' --exclude mkinstalldirs --exclude aclocal.m4 --exclude config.sub --exclude depcomp --exclude install-sh --exclude ltmain.sh old/pdfchain-0.4.4/src/dialog.cc new/pdfchain-0.4.4.2/src/dialog.cc --- old/pdfchain-0.4.4/src/dialog.cc 2013-07-03 12:36:20.000000000 +0200 +++ new/pdfchain-0.4.4.2/src/dialog.cc 2015-12-17 15:56:13.000000000 +0100 @@ -51,7 +51,7 @@ //set_documenters( vet_documenters ); //set_artists( vet_artists ); //set_translator_credits( str_translators ); - set_copyright( "Copyright " + Pdfchain::String::COPYRIGHT + " 2009-2013 Martin Singer" ); + set_copyright( "Copyright " + Pdfchain::String::COPYRIGHT + " 2009-2015 Martin Singer" ); set_license_type( Gtk::LICENSE_GPL_3_0 ); set_website( Pdfchain::About::PROJECT_URL ); set_website_label( Pdfchain::About::PROJECT_URL ); diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' --exclude Makefile.in --exclude configure --exclude config.guess --exclude '*.pot' --exclude mkinstalldirs --exclude aclocal.m4 --exclude config.sub --exclude depcomp --exclude install-sh --exclude ltmain.sh old/pdfchain-0.4.4/src/dialog_filechooser.cc new/pdfchain-0.4.4.2/src/dialog_filechooser.cc --- old/pdfchain-0.4.4/src/dialog_filechooser.cc 2013-07-09 16:43:19.000000000 +0200 +++ new/pdfchain-0.4.4.2/src/dialog_filechooser.cc 2015-12-17 10:01:04.000000000 +0100 @@ -182,11 +182,9 @@ { std::string str_filename = Gtk::FileChooser::get_filename(); - switch ( mCButton_AddExtension.get_active() ) + if ( true == mCButton_AddExtension.get_active() ) { - case true: - addExtension( str_filename ); - break; + addExtension( str_filename ); } if ( Gio::File::create_for_path( str_filename )->query_exists() ) diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' --exclude Makefile.in --exclude configure --exclude config.guess --exclude '*.pot' --exclude mkinstalldirs --exclude aclocal.m4 --exclude config.sub --exclude depcomp --exclude install-sh --exclude ltmain.sh old/pdfchain-0.4.4/src/store_cat.cc new/pdfchain-0.4.4.2/src/store_cat.cc --- old/pdfchain-0.4.4/src/store_cat.cc 2013-07-09 16:16:00.000000000 +0200 +++ new/pdfchain-0.4.4.2/src/store_cat.cc 2015-12-17 09:57:47.000000000 +0100 @@ -870,17 +870,15 @@ iter->set_value( pTMCRecord->mTMColumn_Pages , str_pages ); - switch ( validateTMColumn_Pages( iter ) ) { - case true: - iter->set_value( - pTMCRecord->mTMColumn_Color_Pages , - Pdfchain::Color::RGBA_VALID ); - break; - default: - iter->set_value( - pTMCRecord->mTMColumn_Color_Pages , - Pdfchain::Color::RGBA_INVALID ); - break; + if ( true == validateTMColumn_Pages( iter ) ) { + iter->set_value( + pTMCRecord->mTMColumn_Color_Pages , + Pdfchain::Color::RGBA_VALID ); + } + else { + iter->set_value( + pTMCRecord->mTMColumn_Color_Pages , + Pdfchain::Color::RGBA_INVALID ); } return; @@ -999,13 +997,11 @@ // Select Cat or Shuffle str_command.append( " " ); - switch ( shuffle ) { - case true: - str_command.append( Pdfchain::Cmd::SHUFFLE ); - break; - default: - str_command.append( Pdfchain::Cmd::CAT ); - break; + if ( true == shuffle ) { + str_command.append( Pdfchain::Cmd::SHUFFLE ); + } + else { + str_command.append( Pdfchain::Cmd::CAT ); } // Assign Pages, EvenOdd, Rotation on each handle @@ -1013,48 +1009,42 @@ if ( G_MAXUINT > ( file_id = iter_row->get_value( pTMCRecord->mTMColumn_Id ) ) ) { // Create command - switch ( validateTMColumn_Pages( iter_row ) ) { + if ( true != validateTMColumn_Pages( iter_row ) ) { + return ""; + } + else { + std::string::size_type + pos_a = 0, + pos_b = 0; + + std::string + str_pages = Glib::filename_from_utf8( + iter_row->get_value( pTMCRecord->mTMColumn_Pages ) ); + + while ( str_pages.length() > pos_a + && str_pages.length() > pos_b ) { + + // Find begin and end of an argument (arguments are separated by ' ') + for ( pos_a = pos_b ; + str_pages.length() > pos_a && 0 == str_pages.compare( pos_a , 1 , " " ) ; + pos_a++ ); // Skips all ' ' + + for ( pos_b = pos_a ; + str_pages.length() > pos_b && 0 != str_pages.compare( pos_b , 1 , " " ) ; + pos_b++ ); // Skips all characters, without ' ' + + // Append argument + str_command.append( " " ); + str_command.append( getHandle( file_id ) ); + str_command.append( str_pages.substr( pos_a , pos_b - pos_a ) ); + + // EvenOdd (only it there is a page range sign "-" at pages string) + if ( std::string::npos != ( str_pages.substr( pos_a , pos_b - pos_a )).find( "-" ) ) + str_command.append( iter_row->get_value( pTMCRecord->mTMColumn_Cmd_EvenOdd ) ); - case false: - return ""; - break; - - case true: { - - std::string::size_type - pos_a = 0, - pos_b = 0; - - std::string - str_pages = Glib::filename_from_utf8( - iter_row->get_value( pTMCRecord->mTMColumn_Pages ) ); - - while ( str_pages.length() > pos_a - && str_pages.length() > pos_b ) { - - // Find begin and end of an argument (arguments are separated by ' ') - for ( pos_a = pos_b ; - str_pages.length() > pos_a && 0 == str_pages.compare( pos_a , 1 , " " ) ; - pos_a++ ); // Skips all ' ' - - for ( pos_b = pos_a ; - str_pages.length() > pos_b && 0 != str_pages.compare( pos_b , 1 , " " ) ; - pos_b++ ); // Skips all characters, without ' ' - - // Append argument - str_command.append( " " ); - str_command.append( getHandle( file_id ) ); - str_command.append( str_pages.substr( pos_a , pos_b - pos_a ) ); - - // EvenOdd (only it there is a page range sign "-" at pages string) - if ( std::string::npos != ( str_pages.substr( pos_a , pos_b - pos_a )).find( "-" ) ) - str_command.append( iter_row->get_value( pTMCRecord->mTMColumn_Cmd_EvenOdd ) ); - - // Rotation - str_command.append( iter_row->get_value( pTMCRecord->mTMColumn_Cmd_Rotation ) ); - } + // Rotation + str_command.append( iter_row->get_value( pTMCRecord->mTMColumn_Cmd_Rotation ) ); } - break; } } } diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' --exclude Makefile.in --exclude configure --exclude config.guess --exclude '*.pot' --exclude mkinstalldirs --exclude aclocal.m4 --exclude config.sub --exclude depcomp --exclude install-sh --exclude ltmain.sh old/pdfchain-0.4.4/src/window_main.cc new/pdfchain-0.4.4.2/src/window_main.cc --- old/pdfchain-0.4.4/src/window_main.cc 2013-07-10 11:53:40.000000000 +0200 +++ new/pdfchain-0.4.4.2/src/window_main.cc 2015-12-17 15:37:10.000000000 +0100 @@ -95,9 +95,11 @@ Gtk::HBox( false , Pdfchain::SPACING ) , // homogenous , spacing #ifndef PDFCHAIN_GTKMM_OLD mIMItem_About( Gtk::Stock::ABOUT ) , + mIMItem_Help( Gtk::Stock::HELP ) , mIMItem_Clear( Gtk::Stock::CLEAR ) , #else mImg_About( Gtk::Stock::ABOUT , Gtk::ICON_SIZE_BUTTON ) , // stock id , size + mImg_Help ( Gtk::Stock::HELP , Gtk::ICON_SIZE_BUTTON ) , mImg_Clear( Gtk::Stock::CLEAR , Gtk::ICON_SIZE_BUTTON ) , #endif mTButton_Permission( _("_Permissions") , true ) , // label, mnemonic @@ -109,6 +111,7 @@ _("Sets passwords, encryption and restrictions for the output document") ); #ifndef PDFCHAIN_GTKMM_OLD mMenu.append( mIMItem_About ); + mMenu.append( mIMItem_Help ); mMenu.append( mMISeparator_A ); mMenu.append( mIMItem_Clear ); mMenu.show_all_children(); @@ -118,12 +121,15 @@ pack_start( mMButton , false , false , 0 ); // widget , expand , fill , padding #else mButton_About.set_image( mImg_About ); + mButton_Help.set_image( mImg_Help ); mButton_Clear.set_image( mImg_Clear ); mButton_About.set_tooltip_text( _("About") ); + mButton_About.set_tooltip_text( _("Online Help") ); mButton_Clear.set_tooltip_text( _("Clear") ); pack_start( mButton_About , false , false , 0 ); + pack_start( mButton_Help , false , false , 0 ); pack_start( mButton_Clear , false , false , 0 ); #endif pack_start( mTButton_Permission , false , false , 0 ); // widget , expand , fill , padding @@ -194,13 +200,19 @@ #ifndef PDFCHAIN_GTKMM_OLD mHBox_Execute.mIMItem_About.signal_activate().connect( sigc::mem_fun( *this , &cWindow_Main::onIMItem_About_activated ) ); - + + mHBox_Execute.mIMItem_Help.signal_activate().connect( + sigc::mem_fun( *this , &cWindow_Main::onIMItem_Help_activated ) ); + mHBox_Execute.mIMItem_Clear.signal_activate().connect( sigc::mem_fun( *this , &cWindow_Main::onIMItem_Clear_activated ) ); #else mHBox_Execute.mButton_About.signal_clicked().connect( sigc::mem_fun( *this , &cWindow_Main::onIMItem_About_activated ) ); + mHBox_Execute.mButton_Help.signal_clicked().connect( + sigc::mem_fun( *this , &cWindow_Main::onIMItem_Help_activated ) ); + mHBox_Execute.mButton_Clear.signal_clicked().connect( sigc::mem_fun( *this , &cWindow_Main::onIMItem_Clear_activated ) ); #endif @@ -329,6 +341,15 @@ } +// Signal Handler (protected) : on Button Help clicked +void +cWindow_Main::onIMItem_Help_activated() +{ + system( "xdg-open http://pdfchain.sourceforge.net/documentation.html" ); + return; +} + + // Signal Handler (protected) : on Button Clear clicked void cWindow_Main::onIMItem_Clear_activated() @@ -342,15 +363,10 @@ void cWindow_Main::onTButton_Permission_toggled() { - switch ( mHBox_Execute.mTButton_Permission.get_active() ) { - - case false: - mSection_Permission.hide(); - break; - - default: - mSection_Permission.show(); - break; + if ( true != mHBox_Execute.mTButton_Permission.get_active() ) { + mSection_Permission.hide(); + } else { + mSection_Permission.show(); } return; diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' --exclude Makefile.in --exclude configure --exclude config.guess --exclude '*.pot' --exclude mkinstalldirs --exclude aclocal.m4 --exclude config.sub --exclude depcomp --exclude install-sh --exclude ltmain.sh old/pdfchain-0.4.4/src/window_main.h new/pdfchain-0.4.4.2/src/window_main.h --- old/pdfchain-0.4.4/src/window_main.h 2013-07-10 11:01:15.000000000 +0200 +++ new/pdfchain-0.4.4.2/src/window_main.h 2015-12-17 15:36:32.000000000 +0100 @@ -109,6 +109,7 @@ Gtk::ImageMenuItem mIMItem_About , + mIMItem_Help , mIMItem_Clear; Gtk::SeparatorMenuItem @@ -116,10 +117,12 @@ #else Gtk::Image mImg_About , + mImg_Help , mImg_Clear; Gtk::Button mButton_About , + mButton_Help , mButton_Clear; #endif }; @@ -150,6 +153,7 @@ // Signal Handler inline void onNotebook_Sections_switch_page( const Widget* , const guint ); inline void onIMItem_About_activated(); + inline void onIMItem_Help_activated(); inline void onIMItem_Clear_activated(); inline void onTButton_Permission_toggled(); inline void onButton_Execute_clicked(); diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' --exclude Makefile.in --exclude configure --exclude config.guess --exclude '*.pot' --exclude mkinstalldirs --exclude aclocal.m4 --exclude config.sub --exclude depcomp --exclude install-sh --exclude ltmain.sh old/pdfchain-0.4.4/src/window_main_attachment.cc new/pdfchain-0.4.4.2/src/window_main_attachment.cc --- old/pdfchain-0.4.4/src/window_main_attachment.cc 2013-07-09 16:45:20.000000000 +0200 +++ new/pdfchain-0.4.4.2/src/window_main_attachment.cc 2015-12-17 09:32:16.000000000 +0100 @@ -43,7 +43,8 @@ set_model( rLStore_Attach ); set_reorderable( true ); set_rules_hint( true ); - set_rubber_banding( true ); +// set_rubber_banding( true ); + set_rubber_banding( false ); set_enable_search( true ); set_search_column( pTMCRecord_Attach->mTMColumn_AttachFile ); set_tooltip_column( get_search_column() + 2 ); diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' --exclude Makefile.in --exclude configure --exclude config.guess --exclude '*.pot' --exclude mkinstalldirs --exclude aclocal.m4 --exclude config.sub --exclude depcomp --exclude install-sh --exclude ltmain.sh old/pdfchain-0.4.4/src/window_main_bgst.cc new/pdfchain-0.4.4.2/src/window_main_bgst.cc --- old/pdfchain-0.4.4/src/window_main_bgst.cc 2013-07-09 16:52:21.000000000 +0200 +++ new/pdfchain-0.4.4.2/src/window_main_bgst.cc 2015-12-17 10:11:08.000000000 +0100 @@ -126,33 +126,18 @@ if ( "" != ( str_targetfile = mFCDialog_SaveAs.get_filename() ) ) { str_command = " " + Pdfchain::quote_path( str_sourcefile ); - switch ( mRButton_Background.get_active() ) { - - case true: - switch ( mCButton_Multiple.get_active() ) { - - case true: - str_command += " " + Pdfchain::Cmd::BACKGROUND_MULTI; - break; - - case false: - str_command += " " + Pdfchain::Cmd::BACKGROUND; - break; - } - break; - - case false: - switch ( mCButton_Multiple.get_active() ) { - - case true: - str_command += " " + Pdfchain::Cmd::STAMP_MULTI; - break; - - case false: - str_command += " " + Pdfchain::Cmd::STAMP; - break; - } - break; + if ( true == mRButton_Background.get_active() ) { + if ( true == mCButton_Multiple.get_active() ) { + str_command += " " + Pdfchain::Cmd::BACKGROUND_MULTI; + } else { + str_command += " " + Pdfchain::Cmd::BACKGROUND; + } + } else { + if ( true == mCButton_Multiple.get_active() ) { + str_command += " " + Pdfchain::Cmd::STAMP_MULTI; + } else { + str_command += " " + Pdfchain::Cmd::STAMP; + } } str_command += " " + Pdfchain::quote_path( str_bgstfile ); diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' --exclude Makefile.in --exclude configure --exclude config.guess --exclude '*.pot' --exclude mkinstalldirs --exclude aclocal.m4 --exclude config.sub --exclude depcomp --exclude install-sh --exclude ltmain.sh old/pdfchain-0.4.4/src/window_main_burst.cc new/pdfchain-0.4.4.2/src/window_main_burst.cc --- old/pdfchain-0.4.4/src/window_main_burst.cc 2013-07-09 16:49:55.000000000 +0200 +++ new/pdfchain-0.4.4.2/src/window_main_burst.cc 2015-12-17 10:13:42.000000000 +0100 @@ -214,25 +214,20 @@ str_bursttemplate += str_prefix; str_bursttemplate += Pdfchain::Cmd::TEMPLATE; - switch( mRButton_Auto.get_active() ) { - case true: - - switch ( (*iter)[pt_record->mTMColumn_ID] ) { - case Pdfchain::Id::COUNT_OCT : - str_bursttemplate += Pdfchain::convert_guint_to_string( vDigits_Oct ); - break; - case Pdfchain::Id::COUNT_DEC : - str_bursttemplate += Pdfchain::convert_guint_to_string( vDigits_Dec ); - break; - case Pdfchain::Id::COUNT_HEX : - str_bursttemplate += Pdfchain::convert_guint_to_string( vDigits_Hex ); - break; - } - - break; - case false: - str_bursttemplate += mSButton_Digits.get_text(); - break; + if ( true == mRButton_Auto.get_active() ) { + switch ( (*iter)[pt_record->mTMColumn_ID] ) { + case Pdfchain::Id::COUNT_OCT : + str_bursttemplate += Pdfchain::convert_guint_to_string( vDigits_Oct ); + break; + case Pdfchain::Id::COUNT_DEC : + str_bursttemplate += Pdfchain::convert_guint_to_string( vDigits_Dec ); + break; + case Pdfchain::Id::COUNT_HEX : + str_bursttemplate += Pdfchain::convert_guint_to_string( vDigits_Hex ); + break; + } + } else { + str_bursttemplate += mSButton_Digits.get_text(); } str_bursttemplate += iter->get_value( pt_record->mTMColumn_Command ); diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' --exclude Makefile.in --exclude configure --exclude config.guess --exclude '*.pot' --exclude mkinstalldirs --exclude aclocal.m4 --exclude config.sub --exclude depcomp --exclude install-sh --exclude ltmain.sh old/pdfchain-0.4.4/src/window_main_cat.cc new/pdfchain-0.4.4.2/src/window_main_cat.cc --- old/pdfchain-0.4.4/src/window_main_cat.cc 2013-07-09 16:46:38.000000000 +0200 +++ new/pdfchain-0.4.4.2/src/window_main_cat.cc 2015-12-17 18:31:26.000000000 +0100 @@ -155,7 +155,7 @@ cPMenu_Cat::~cPMenu_Cat() { #ifdef PDFCHAIN_TEST - std::cout << std::endl << "cPMenu_Cat::~cPMenu_Cat()"); //TEST + std::cout << std::endl << "cPMenu_Cat::~cPMenu_Cat()"; //TEST #endif } @@ -180,6 +180,7 @@ mLabel_Add( _("Add") , false ), // label , mnemonic mLabel_Pages( _("Page selection") , false ), + mLabel_EvenOdd( _("Page filter") , false ), mLabel_Rotation( _("Rotation") , false ), mLabel_SourceFile( _("Document") , false ), mLabel_Password( _("Password") , false ), @@ -199,7 +200,8 @@ set_model( rLStore_Cat ); set_reorderable( true ); set_rules_hint( true ); - set_rubber_banding( true ); +// set_rubber_banding( true ); + set_rubber_banding( false ); set_enable_search( true ); set_search_column( pTMCRecord_Cat->mTMColumn_SourceFile ); set_tooltip_column( get_search_column() + 2 ); @@ -207,8 +209,9 @@ mLabel_Add.set_tooltip_text( _("Add entry for processing") ); mLabel_Pages.set_tooltip_text( _("Select and filter pages" "\nE.g.: '1-3 5 7-end' or '1 r5 r3-end' or 'end-3 3 3 3-end'" - "\n'r' means 'reverse' (e.g. 'r2' is the second last page)." - "\nThe 'even' and 'odd' filters only affect to page ranges (not to single pages)!") ); + "\n'r' means 'reverse' (e.g. 'r2' is the second last page).") ); + mLabel_EvenOdd.set_tooltip_text( _("Filters pages with an AND logic to the page selection." + "\nThe 'even' and 'odd' filters only affect to page ranges (not to single selected pages)!") ); /* mLabel_Pages.set_tooltip_text( _("Select and filter pages\n" "Single pages and page ranges are separated by the space sign (e.g.: '3 5 4-6'). " @@ -225,6 +228,7 @@ mTVColumn_Add.set_widget( mLabel_Add ); mTVColumn_Pages.set_widget( mLabel_Pages ); + mTVColumn_EvenOdd.set_widget( mLabel_EvenOdd ); mTVColumn_Rotation.set_widget( mLabel_Rotation ); mTVColumn_SourceFile.set_widget( mLabel_SourceFile ); mTVColumn_SourcePath.set_widget( mLabel_SourcePath ); @@ -233,6 +237,7 @@ mLabel_Add.show(); mLabel_Pages.show(); + mLabel_EvenOdd.show(); mLabel_Rotation.show(); mLabel_SourceFile.show(); mLabel_SourcePath.show(); @@ -242,6 +247,7 @@ mTVColumn_Add.set_resizable( false ); mTVColumn_Pages.set_expand( true ); mTVColumn_Pages.set_resizable( true ); + mTVColumn_EvenOdd.set_resizable( false ); mTVColumn_Rotation.set_resizable( false ); mTVColumn_SourceFile.set_expand( true ); mTVColumn_SourceFile.set_resizable( true ); @@ -274,12 +280,12 @@ mTVColumn_Add.pack_start( mCRToggle_Add , false ); // cell renderer , expand mTVColumn_Pages.pack_start( mCRText_Pages , true ); - mTVColumn_Pages.pack_start( mCRCombo_EvenOdd , false ); + mTVColumn_EvenOdd.pack_start( mCRCombo_EvenOdd , false ); mTVColumn_Rotation.pack_start( mCRCombo_Rotation , false ); mTVColumn_SourceFile.pack_start( mCRText_SourceFile , true ); mTVColumn_Password.pack_start( mCRText_Password , true ); mTVColumn_PageNumbers.pack_start( mCRText_PageNumbers , true ); - + #ifdef PDFCHAIN_TEMP mTVColumn_Id.pack_start( mCRText_Id , true ); //TEMP mTVColumn_SourcePath.pack_start( mCRText_SourcePath , true ); //TEMP @@ -303,7 +309,7 @@ mCRText_Pages.property_foreground_rgba() , pTMCRecord_Cat->mTMColumn_Color_Pages ); - mTVColumn_Pages.add_attribute( + mTVColumn_EvenOdd.add_attribute( mCRCombo_EvenOdd.property_text() , pTMCRecord_Cat->mTMColumn_EvenOdd ); @@ -359,6 +365,7 @@ append_column( mTVColumn_Add ); append_column( mTVColumn_Pages ); + append_column( mTVColumn_EvenOdd ); append_column( mTVColumn_Rotation ); append_column( mTVColumn_SourceFile ); append_column( mTVColumn_Password ); diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' --exclude Makefile.in --exclude configure --exclude config.guess --exclude '*.pot' --exclude mkinstalldirs --exclude aclocal.m4 --exclude config.sub --exclude depcomp --exclude install-sh --exclude ltmain.sh old/pdfchain-0.4.4/src/window_main_cat.h new/pdfchain-0.4.4.2/src/window_main_cat.h --- old/pdfchain-0.4.4/src/window_main_cat.h 2013-07-01 15:24:20.000000000 +0200 +++ new/pdfchain-0.4.4.2/src/window_main_cat.h 2015-12-17 13:38:58.000000000 +0100 @@ -172,6 +172,7 @@ Gtk::Label mLabel_Add , mLabel_Pages , + mLabel_EvenOdd , mLabel_Rotation , mLabel_SourceFile , mLabel_SourcePath , @@ -181,6 +182,7 @@ Gtk::TreeViewColumn mTVColumn_Add, mTVColumn_Pages, + mTVColumn_EvenOdd, mTVColumn_Rotation, mTVColumn_SourceFile, mTVColumn_SourcePath, diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' --exclude Makefile.in --exclude configure --exclude config.guess --exclude '*.pot' --exclude mkinstalldirs --exclude aclocal.m4 --exclude config.sub --exclude depcomp --exclude install-sh --exclude ltmain.sh old/pdfchain-0.4.4/src/window_main_permission.cc new/pdfchain-0.4.4.2/src/window_main_permission.cc --- old/pdfchain-0.4.4/src/window_main_permission.cc 2013-07-03 14:50:44.000000000 +0200 +++ new/pdfchain-0.4.4.2/src/window_main_permission.cc 2015-12-17 08:27:29.000000000 +0100 @@ -203,12 +203,12 @@ if ( mEntry_PasswordUser.get_text_length() ) { str_command += " " + Pdfchain::Cmd::PASSWORD_USER - + " " + mEntry_PasswordUser.get_text(); + + " " + Pdfchain::quote_path( mEntry_PasswordUser.get_text() ); } if ( mEntry_PasswordOwner.get_text_length() ) { str_command += " " + Pdfchain::Cmd::PASSWORD_OWNER - + " " + mEntry_PasswordOwner.get_text(); + + " " + Pdfchain::quote_path( mEntry_PasswordOwner.get_text() ); } } } diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' --exclude Makefile.in --exclude configure --exclude config.guess --exclude '*.pot' --exclude mkinstalldirs --exclude aclocal.m4 --exclude config.sub --exclude depcomp --exclude install-sh --exclude ltmain.sh old/pdfchain-0.4.4/src/window_main_tool.cc new/pdfchain-0.4.4.2/src/window_main_tool.cc --- old/pdfchain-0.4.4/src/window_main_tool.cc 2013-07-09 16:58:13.000000000 +0200 +++ new/pdfchain-0.4.4.2/src/window_main_tool.cc 2015-12-17 10:07:15.000000000 +0100 @@ -315,9 +315,10 @@ else if ( mRButton_DumpDataFields.get_active() ) { str_command = " " + Pdfchain::quote_path( str_sourcefile ); - switch ( mCButton_DumpDataFields_Utf8.get_active() ) { - case true: str_command += " " + Pdfchain::Cmd::DUMP_DATA_FIELDS_UTF8; break; - default: str_command += " " + Pdfchain::Cmd::DUMP_DATA_FIELDS; break; + if ( true == mCButton_DumpDataFields_Utf8.get_active() ) { + str_command += " " + Pdfchain::Cmd::DUMP_DATA_FIELDS_UTF8; + } else { + str_command += " " + Pdfchain::Cmd::DUMP_DATA_FIELDS; } str_command += " " + Pdfchain::Cmd::OUTPUT; str_command += " " + Pdfchain::quote_path( str_output ); @@ -325,9 +326,10 @@ else if ( mRButton_DumpData.get_active() ) { str_command = " " + Pdfchain::quote_path( str_sourcefile ); - switch ( mCButton_DumpData_Utf8.get_active() ) { - case true: str_command += " " + Pdfchain::Cmd::DUMP_DATA_UTF8; break; - default: str_command += " " + Pdfchain::Cmd::DUMP_DATA; break; + if ( true == mCButton_DumpData_Utf8.get_active() ) { + str_command += " " + Pdfchain::Cmd::DUMP_DATA_UTF8; + } else { + str_command += " " + Pdfchain::Cmd::DUMP_DATA; } str_command += " " + Pdfchain::Cmd::OUTPUT; str_command += " " + Pdfchain::quote_path( str_output ); @@ -335,9 +337,10 @@ else if ( mRButton_UpdateInfo.get_active() ) { str_command = " " + Pdfchain::quote_path( str_sourcefile ); - switch ( mCButton_UpdateInfo_Utf8.get_active() ) { - case true: str_command += " " + Pdfchain::Cmd::UPDATE_INFO_UTF8; break; - default: str_command += " " + Pdfchain::Cmd::UPDATE_INFO; break; + if ( true == mCButton_UpdateInfo_Utf8.get_active() ) { + str_command += " " + Pdfchain::Cmd::UPDATE_INFO_UTF8; + } else { + str_command += " " + Pdfchain::Cmd::UPDATE_INFO; } str_command += " " + Pdfchain::quote_path( str_dumpfile ); str_command += " " + Pdfchain::Cmd::OUTPUT;