1. 17 Jan, 2007 2 commits
    • Daniel Elstner's avatar
      :filename_short_display_name): Rename from Util::shorten_pathname(). · 80cf78cd
      Daniel Elstner authored
      * src/stringutils.{cc,h} (Util::filename_short_display_name):
      Rename from Util::shorten_pathname().  Return the display name
      of the shortened filename encoded in UTF-8.
      (Util::expand_pathname): Remove as this function is no longer
      being used anywhere.
      * src/mainwindow.cc (MainWindow::set_title_filename): Use
      Util::filename_short_display_name().
      
      svn path=/trunk/; revision=644
      80cf78cd
    • Daniel Elstner's avatar
      New variable that defines the locale directory the same way intltool does. · 276eba50
      Daniel Elstner authored
      * Makefile.am (rxlocaledir): New variable that defines the locale
      directory the same way intltool does.
      (global_defs): Use $(rxlocaledir) instead of $(localedir).  In
      addition to being different from intltool's definition, standard
      $(localedir) also requires at least Autoconf 2.59c.
      
      svn path=/trunk/; revision=643
      276eba50
  2. 16 Jan, 2007 4 commits
    • Daniel Elstner's avatar
      :CounterBox): Change the shadow type to Gtk::SHADOW_ETCHED_IN. Still looks · a99ae6b9
      Daniel Elstner authored
      * src/statusline.cc (CounterBox::CounterBox): Change the shadow
      type to Gtk::SHADOW_ETCHED_IN.  Still looks somewhat ugly though;
      I need to think of something better.  Also enable the single line
      mode property of the numeric labels, in order to avoid resizing if
      the digits in the font have different height.
      (StatusLine::StatusLine): Increase HBox spacing to 3 pixels.
      
      svn path=/trunk/; revision=642
      a99ae6b9
    • Daniel Elstner's avatar
      Prefix function signature with G_MODULE_EXPORT, as this will probably be · 42586130
      Daniel Elstner authored
      * src/filetree.cc (regexxer_create_file_tree): Prefix function
      signature with G_MODULE_EXPORT, as this will probably be required
      on Windows to enable dynamic loading.
      * src/statusline.cc (regexxer_create_status_line): Ditto.
      
      svn path=/trunk/; revision=641
      42586130
    • Daniel Elstner's avatar
      Accept a fourth argument which can be used to generate · 1282b6a1
      Daniel Elstner authored
      * m4/dk-warn.m4 (DK_ARG_ENABLE_WARNINGS): Accept a fourth argument
      which can be used to generate -DMODULE_DISABLE_DEPRECATED defines
      by specifying a list of module prefixes.  These flags are produced
      only in --enable-warnings=fatal mode, in order to avoid breaking
      the default build if new deprecations appear in some module.
      
      * configure.ac (REGEXXER_WARNING_FLAGS): List the module prefixes
      GLIBMM and GTKMM in the fourth argument to DK_ARG_ENABLE_WARNINGS.
      * Makefile.am (global_defs): Remove -D*_DISABLE_DEPRECATED flags,
      since they are now included in $(REGEXXER_WARNING_FLAGS).
      
      svn path=/trunk/; revision=640
      1282b6a1
    • Daniel Elstner's avatar
      Accept backslash '\' as directory separator in filenames, in addition to · 54125c73
      Daniel Elstner authored
      * Makefile.am (ui/stockimages.h): Accept backslash '\' as directory
      separator in filenames, in addition to the forward slash '/'.  You
      can never know.
      
      svn path=/trunk/; revision=639
      54125c73
  3. 15 Jan, 2007 1 commit
  4. 14 Jan, 2007 5 commits
    • Alexander Shopov's avatar
      Updated Bulgarian translation by Yavor Doganov <yavor@doganov.org> · dd343707
      Alexander Shopov authored
      2007-01-14  Alexander Shopov  <ash@contact.bg>
      
      	* bg.po: Updated Bulgarian translation by
      	Yavor Doganov <yavor@doganov.org>
      
      svn path=/trunk/; revision=637
      dd343707
    • Daniel Elstner's avatar
      :compose_argv): New function with the functionality of compose_impl() but · af360b85
      Daniel Elstner authored
      * src/translation.{cc,h} (Util::compose_argv): New function with
      the functionality of compose_impl() but using a format string of
      type const char*.  This implementation operates on bytes instead of
      Unicode code points, and copies the chunks between placeholders in
      one go instead of each character separately.
      (Util::compose): Call compose_argv() instead of compose_impl()
      and change the type of the format argument to const char* because
      the format string really should be a string literal.  Also, inline
      all of these overloads since they just forward their arguments to
      compose_argv() anyway, so that inlining actually reduces code size.
      
      svn path=/trunk/; revision=636
      af360b85
    • Daniel Elstner's avatar
      Replace occurrences of "lhs" and "rhs" with "a" and "b", respectively. · 742206f2
      Daniel Elstner authored
      * src/fileshared.h: Replace occurrences of "lhs" and "rhs" with
      "a" and "b", respectively.
      (BoundState): Remove BOUND_MASK value from enumeration as it is
      nowhere being used.
      
      svn path=/trunk/; revision=635
      742206f2
    • Daniel Elstner's avatar
      Clean up the code a bit. In particular, change occurrences of · 4fa17b0f
      Daniel Elstner authored
      * src/filetree.{cc,h}: Clean up the code a bit.  In particular,
      change occurrences of Gtk::TreePath to Gtk::TreeModel::Path.
      * src/filetreeprivate.{cc,h}: Likewise.
      
      * src/sharedptr.h (Util::SharedPtr::SharedPtr): Inline.
      (Util::SharedPtr::~SharedPtr): Remove assertion and inline.
      * src/sharedptr.cc: Remove now empty file.
      
      * Makefile.am (src_regexxer_SOURCES): Remove src/sharedptr.cc.
      
      svn path=/trunk/; revision=634
      4fa17b0f
    • Daniel Elstner's avatar
      Move function to the global namespace. Putting it inside an anonymous · 1aecc9f9
      Daniel Elstner authored
      * src/filetree.cc (regexxer_create_file_tree): Move function to
      the global namespace.  Putting it inside an anonymous namespace
      just obfuscated the code, as this function is exported for the
      world to see.
      * src/statusline.cc (regexxer_create_status_line): Likewise.
      
      svn path=/trunk/; revision=633
      1aecc9f9
  5. 13 Jan, 2007 3 commits
    • Daniel Elstner's avatar
      Add file for the benefit of sysadmin tools. · 69a07a23
      Daniel Elstner authored
      * MAINTAINERS: Add file for the benefit of sysadmin tools.
      
      svn path=/trunk/; revision=632
      69a07a23
    • Daniel Elstner's avatar
      New string constant defining the directory of regexxer in the GConf · 83eba3dd
      Daniel Elstner authored
      * src/globalstrings.h (conf_dir_application): New string constant
      defining the directory of regexxer in the GConf database.  This
      string literal replaces the REGEXXER_GCONF_DIRECTORY macro which
      used to be defined in the Makefile.  This global macro definition
      was inherently pointless as it was not configurable anyway.
      * src/main.cc (initialize_configuration): Use conf_dir_application
      instead of REGEXXER_GCONF_DIRECTORY.
      * src/prefdialog.cc (PrefDialog::initialize_configuration): ditto.
      
      * configure.ac (REGEXXER_GCONF_DIRECTORY): Remove substitution.
      (PKG_CHECK_MODULES): Add gmodule-export-2.0 to the module list to
      get the -Wl,--export-dynamic flag automatically.
      (DK_LINK_EXPORT_DYNAMIC): Remove macro invocation as it no longer
      necessary.  Also, add comments elaborating about the whole linker
      stuff.
      * Makefile.am (global_defs): Remove -DREGEXXER_GCONF_DIRECTORY.
      (src_regexxer_LDFLAGS): Get rid of $(REGEXXER_EXPORT_DYNAMIC).
      
      * m4/dk-export.m4 (DK_LINK_EXPORT_DYNAMIC): Remove macro.
      
      svn path=/trunk/; revision=631
      83eba3dd
    • Daniel Elstner's avatar
      :find_recursively): Replace uses of Glib::filename_display_name() by · 28d68a4f
      Daniel Elstner authored
      * src/filetree.cc (FileTree::find_recursively): Replace uses of
      Glib::filename_display_name() by Glib::filename_display_basename()
      to enable translation of well-known locations in future.  Store
      the full path in the directory stack.
      (FileTree::find_fill_dirstack): Convert the full path from the
      stack to a displayable name with Glib::filename_display_basename().
      (FileTree::save_file_at_iter): Determine the basename for
      use in the error message with Glib::filename_display_basename().
      
      * src/mainwindow.cc (MainWindow::set_title_filename): Call
      Glib::filename_display_basename() to get the filename to be
      displayed in the window title.
      
      * src/filetreeprivate.{cc,h}: Some early spring cleaning.
      
      svn path=/trunk/; revision=630
      28d68a4f
  6. 12 Jan, 2007 1 commit
  7. 11 Jan, 2007 8 commits
    • Daniel Elstner's avatar
      :initialize): Really minor tweaks. · 879e4271
      Daniel Elstner authored
      * src/mainwindow.cc (MainWindow::initialize): Really minor tweaks.
      
      svn path=/trunk/; revision=628
      879e4271
    • Daniel Elstner's avatar
      Make init_state_ a value member of the class instead creating it · 81753d24
      Daniel Elstner authored
      * src/main.cc (RegexxerOptions): Make init_state_ a value member
      of the class instead creating it dynamically.  This simplification
      is now possible since the RegexxerOptions object will be allocated
      dynamically anyway.
      (RegexxerOptions::init_state): Rename from take_init_state(), and
      make it return a const reference.
      (main): Use new init_state() method when initializing the window.
      
      * src/mainwindow.{cc,h} (MainWindow::initialize): Change init
      parameter type to a const reference.
      
      svn path=/trunk/; revision=627
      81753d24
    • Daniel Elstner's avatar
      Define REGEXXER_LOCALEDIR to the "$(locale)" directory path. Remove define · dddf937a
      Daniel Elstner authored
      * Makefile.am (global_defs): Define REGEXXER_LOCALEDIR to the
      "$(locale)" directory path.  Remove define for REGEXXER_DATADIR
      since it was used only as part of the locale directory.
      * src/main.cc (main): Use REGEXXER_LOCALEDIR.
      (locale_directory): Remove string literal.
      
      svn path=/trunk/; revision=626
      dddf937a
    • Daniel Elstner's avatar
      "): Move accelerator from "g" to "T" in order to make it visible. ("Text · 059341ce
      Daniel Elstner authored
      * de.po ("C_urrent match color:"): Move accelerator from "g" to "T"
      in order to make it visible.
      ("Text view font"): Slightly reword translation.
      
      === Change I forgot to mention in previous commit: ===
      
      * *.po: Globally replace ASCII quotes (") and apostrophes (') with
      the typographically correct variants in Unicode.
      
      svn path=/trunk/; revision=625
      059341ce
    • Daniel Elstner's avatar
      Assign mnemonic widget combo_toolbar_style as GTK+ messes up the automatic · 36867be7
      Daniel Elstner authored
      * ui/prefdialog.glade (label_toolbar_style): Assign mnemonic widget
      combo_toolbar_style as GTK+ messes up the automatic assignment.
      
      svn path=/trunk/; revision=624
      36867be7
    • Daniel Elstner's avatar
      :create_with_error_message): Use UTF-8 encoded typographically correct · ab2411fc
      Daniel Elstner authored
      * src/filebuffer.cc (FileBuffer::create_with_error_message): Use
      UTF-8 encoded typographically correct apostrophe in the title
      string.
      * src/filetree.cc (FileTree::find_recursively): Replace call to
      Util::filename_to_utf8_fallback() by Glib::filename_display_name().
      (FileTree::find_fill_dirstack): Likewise.
      (FileTree::save_file_at_iter): Use UTF-8 encoded typographically
      correct quote characters in the error message string.
      (FileTree::load_file_with_fallback): Likewise.
      
      * src/pcreshell.cc (throw_regex_error): New function to throw a
      Pcre::Error exception with a properly formatted error message.
      (Pcre::Pattern::Pattern): Use throw_regex_error().
      
      * src/prefdialog.cc (PrefDialog::on_entry_fallback_activate):
      Use proper Unicode quotes in error message string.
      
      * src/mainwindow.cc (MainWindow::initialize): Run the search
      automatically only if also a filename pattern has been specified
      on the command line.
      (MainWindow::confirm_quit_request): Use proper Unicode apostrophe
      in the error message.
      (MainWindow::on_find_files): Likewise.  Also remove the code to
      format an error message for regex exceptions, as Pcre::Error now
      already carries a user-friendly message.
      (MainWindow::set_title_filename): Replace calls to
      Util::filename_to_utf8_fallback() by Glib::filename_display_name().
      
      * src/stringutils.{cc,h} (Util::shell_pattern_to_regex): Minor
      optimization twiddling.
      (Util::substitute_references): Likewise.
      (Util::filename_to_utf8_fallback): Remove function, as we can
      now simply use Glib::filename_display_name() instead.
      (Util::convert_to_ascii): Remove; no longer used anywhere.
      (Util::shorten_pathname): Use G_IS_DIR_SEPARATOR() instead of
      comparing against G_DIR_SEPARATOR directly.  Necessary because
      on win32 both '/' and '\' are accepted as directory separators.
      
      * ui/regexxer.schemas.in: Reformat and use proper Unicode quotes
      and apostrophes.
      * ui/prefdialog.glade: Likewise.  Also remove some property
      specifications which assigned default values anyway.
      * ui/mainwindow.glade: As above, strip pointless property settings.
      
      * en.po: Remove English "translation" as proper Unicode quotes and
      apostrophes are now used directly in the untranslated messages.
      * LINGUAS: Remove "en" from list.
      * POTFILES.in: Prepend [encoding: UTF-8] to list of files.
      
      svn path=/trunk/; revision=623
      ab2411fc
    • Daniel Elstner's avatar
      Add comment about assertions and reorganize the code a bit. · 502855e9
      Daniel Elstner authored
      * src/fileio.cc (save_iochannel): Add comment about assertions and
      reorganize the code a bit.
      (Regexxer::save_file): Elaborate on why IOChannel::close() is
      used explicitely.
      
      * src/filetreeprivate.cc (FileTreePrivate::collatekey_sort_func):
      Fix oversight:  Subtracting two unsigned values and converting the
      result to a signed type relies on implementation-defined behavior.
      Explicitely cast the operands to a signed type before substraction.
      
      * src/main.cc (main): Use g_get_prgname() instead of the string
      literal PACKAGE_TARNAME in the error message for Glib::OptionError
      exceptions.
      
      svn path=/trunk/; revision=622
      502855e9
    • Daniel Elstner's avatar
      Add comment about assertions and reorganize the code a bit. · c539cb97
      Daniel Elstner authored
      * src/fileio.cc (save_iochannel): Add comment about assertions and
      reorganize the code a bit.
      (Regexxer::save_file): Elaborate on why IOChannel::close() is
      used explicitely.
      
      * src/filetreeprivate.cc (FileTreePrivate::collatekey_sort_func):
      Fix oversight:  Subtracting two unsigned values and converting the
      result to a signed type relies on implementation-defined behavior.
      Explicitely cast the operands to a signed type before substraction.
      
      * src/main.cc (main): Use g_get_prgname() instead of the string
      literal PACKAGE_TARNAME in the error message for Glib::OptionError
      exceptions.
      
      svn path=/trunk/; revision=621
      c539cb97
  8. 10 Jan, 2007 2 commits
    • Daniel Elstner's avatar
      :create_with_error_message): Get rid of the inappropriate plea to · ec127ebc
      Daniel Elstner authored
      * src/filebuffer.cc (FileBuffer::create_with_error_message): Get
      rid of the inappropriate plea to translators to replace space with
      no-break space in the message title.  Apart from the fact that it
      was a bad idea in the first place to make translators put up with
      this internal issue, the no-break spaces have no point being there
      at all.  A single untranslated no-break space between the error
      icon and the title text is all that is warranted.
      
      svn path=/trunk/; revision=619
      ec127ebc
    • Daniel Elstner's avatar
      Add --add-comments=TRANSLATORS in order to make xgettext only extract · ec1b224d
      Daniel Elstner authored
      * Makevars (XGETTEXT_OPTIONS): Add --add-comments=TRANSLATORS in
      order to make xgettext only extract explicitely tagged comments
      into PO files.  This gets rid of the comment spam due to intltool
      passing --add-comments by default without specifying any tag.
      
      svn path=/trunk/; revision=618
      ec1b224d
  9. 09 Jan, 2007 5 commits
  10. 08 Jan, 2007 4 commits
  11. 07 Jan, 2007 4 commits
    • Daniel Elstner's avatar
      Update translation. Ditto. · 9bdad3ad
      Daniel Elstner authored
      * en.po: Update translation.
      * de.po: Ditto.
      
      svn path=/trunk/; revision=608
      9bdad3ad
    • Daniel Elstner's avatar
      Again remove the tearoff menus and the menubar and toolbar handle boxes. · fcf2d49b
      Daniel Elstner authored
      * ui/mainwindow.glade: Again remove the tearoff menus and the
      menubar and toolbar handle boxes.  This was just superfluous UI
      clutter not actually used by anyone.
      (button_folder): Get rid of the custom button that used to fire
      up the file chooser dialog, plus the accompanying text entry for
      display and editing of the folder name.  Replace this old cruft
      with a fresh and crisp GtkFileChooserButton plus a label.  Yay!
      (combo_pattern_entry): Reactivate commented-out markup that sets
      a tooltip on the internal GtkEntry child of combo_pattern.  As
      this finally supported by libglade it is no longer necessary to
      hack around the limitation in code.
      
      * src/mainwindow.{cc,h} (MainWindow): Adapt the implementation
      to work with the changed UI layout.  Change the folder selection
      handling as necessary.
      (MainWindow::load_xml): Remove the tooltip hack for the pattern
      entry, since libglade now allows for this in the glade file.
      (MainWindow::get_folder_fullname): Remove now unused method.
      (MainWindow::on_select_folder): Likewise.
      
      svn path=/trunk/; revision=607
      fcf2d49b
    • Daniel Elstner's avatar
      #include <memory> for std::auto_ptr<> rather than relying on indirect · 16898c1c
      Daniel Elstner authored
      * src/main.cc: #include <memory> for std::auto_ptr<> rather than
      relying on indirect inclusion by some other header file.
      
      svn path=/trunk/; revision=606
      16898c1c
    • Daniel Elstner's avatar
      Remove <cstdlib> and <cstdio> includes left over from the old libpopt · 03f81039
      Daniel Elstner authored
      * src/main.cc: Remove <cstdlib> and <cstdio> includes left over
      from the old libpopt code.
      
      svn path=/trunk/; revision=605
      03f81039
  12. 06 Jan, 2007 1 commit
    • Daniel Elstner's avatar
      Eeek, as it turns out the flag ANCHORED (and probably others too) are · d5792660
      Daniel Elstner authored
      * src/pcreshell.h ({Compile,Match}Options): Eeek, as it turns out
      the flag ANCHORED (and probably others too) are valid flags at both
      compile time and match time.  Move ANCHORED from CompileOptions to
      MatchOptions as I need it there for the following /g matching fix.
      These enumerations should of course be properly namespaced instead;
      this is just a quick hack for now.
      * src/pcreshell.cc: Rename a couple of variables to improve code
      clarity.
      
      * src/filebuffer.cc (FileBuffer::find_matches): Set the ANCHORED
      flag in addition to the NOT_EMPTY flag if the previous match was
      empty in /g mode.  This matches the algorithm outlined in recent
      versions of the PCRE documentation to mimic the behavior of Perl.
      
      svn path=/trunk/; revision=604
      d5792660