Merge branch '3265_cleanup'

* 3265_cleanup: (26 commits)
  Update po/*.po files.
  Ticket #3333: fix g_error_new_valist().
  lib/glibcompat.h: add missing include of stdarg.h.
  src/filemanager/boxes.c: move static functions to the matched section.
  (sel_skin_button): simplify.
  (format_file): remove unused arguments.
  mceditor: syntax: reimplement context list using GPtrArray.
  mceditor: syntax: remove syntax_keyword_t::first member.
  mceditor: syntax: reimplement keyword list using GPtrArray.
  (edit_read_syntax_rules): minor refactoring of keyword first chars collect.
  (edit_read_syntax_rules): fix pointer tests.
  mceditor: reimplement syntax name list using GPtrArray.
  Ticket #3277: Info panel can't obtain file system statistics on Solaris.
  Recognize "Java archive data (JAR)" as zip archive.
  (mcview_offset_doz): use more.
  Sync with gnulib 2768ceb7994506e2cfba88be3b6bd13ef5440a90.
  Sync with gnulib 3ea43e02541ece750ffc6cd1dfe34195421b4ef3.
  (mcview_dimen_min): remove. Use min() macro instead.
  (mcview_get_byte_string): minor optimization.
  mcviewer: clarify support of UTF-8 codeset.
  ...
This commit is contained in:
Andrew Borodin 2014-12-10 13:14:14 +03:00
commit b7b78319f0
83 changed files with 1287 additions and 1093 deletions

View File

@ -153,9 +153,7 @@ g_error_new_valist (GQuark domain, gint code, const gchar * format, va_list args
char *message;
GError *ret_value;
va_start (ap, format);
message = g_strdup_vprintf (format, ap);
va_end (ap);
message = g_strdup_vprintf (format, args);
ret_value = g_error_new_literal (domain, code, message);
g_free (message);

View File

@ -1,6 +1,10 @@
#ifndef MC_GLIBCOMPAT_H
#define MC_GLIBCOMPAT_H
#if ! GLIB_CHECK_VERSION (2, 22, 0)
#include <stdarg.h> /* for g_error_new_valist() */
#endif /* ! GLIB_CHECK_VERSION (2, 22, 0) */
/*** typedefs(not structures) and defined constants **********************************************/
/*** enums ***************************************************************************************/

View File

@ -174,6 +174,7 @@ const key_code_name_t key_name_conv_tab[] = {
{(int) ',', "comma", N_("Comma"), ","},
{(int) '\'', "apostrophe", N_("Apostrophe"), "\'"},
{(int) ':', "colon", N_("Colon"), ":"},
{(int) ';', "semicolon", N_("Semicolon"), ";"},
{(int) '!', "exclamation", N_("Exclamation mark"), "!"},
{(int) '?', "question", N_("Question mark"), "?"},
{(int) '&', "ampersand", N_("Ampersand"), "&"},

View File

@ -245,28 +245,26 @@ is_printable (int c)
/* --------------------------------------------------------------------------------------------- */
/**
* Quote the filename for the purpose of inserting it into the command
* line. If quote_percent is 1, replace "%" with "%%" - the percent is
* line. If quote_percent is TRUE, replace "%" with "%%" - the percent is
* processed by the mc command line.
*/
char *
name_quote (const char *s, int quote_percent)
name_quote (const char *s, gboolean quote_percent)
{
char *ret, *d;
GString *ret;
ret = g_string_sized_new (64);
d = ret = g_malloc (strlen (s) * 2 + 2 + 1);
if (*s == '-')
{
*d++ = '.';
*d++ = '/';
}
g_string_append (ret, "." PATH_SEP_STR);
for (; *s; s++, d++)
for (; *s != '\0'; s++)
{
switch (*s)
{
case '%':
if (quote_percent)
*d++ = '%';
g_string_append_c (ret, '%');
break;
case '\'':
case '\\':
@ -291,24 +289,24 @@ name_quote (const char *s, int quote_percent)
case '*':
case '(':
case ')':
*d++ = '\\';
g_string_append_c (ret, '\\');
break;
case '~':
case '#':
if (d == ret)
*d++ = '\\';
if (ret->len == 0)
g_string_append_c (ret, '\\');
break;
}
*d = *s;
g_string_append_c (ret, *s);
}
*d = '\0';
return ret;
return g_string_free (ret, FALSE);
}
/* --------------------------------------------------------------------------------------------- */
char *
fake_name_quote (const char *s, int quote_percent)
fake_name_quote (const char *s, gboolean quote_percent)
{
(void) quote_percent;
return g_strdup (s);

View File

@ -124,10 +124,10 @@ int is_printable (int c);
/* Quote the filename for the purpose of inserting it into the command
* line. If quote_percent is 1, replace "%" with "%%" - the percent is
* processed by the mc command line. */
char *name_quote (const char *c, int quote_percent);
char *name_quote (const char *c, gboolean quote_percent);
/* returns a duplicate of c. */
char *fake_name_quote (const char *c, int quote_percent);
char *fake_name_quote (const char *c, gboolean quote_percent);
/* path_trunc() is the same as str_trunc() but
* it deletes possible password from path for security

View File

@ -152,6 +152,19 @@ if test $ac_cv_func_getmntent = yes; then
of mounted file systems, and that function takes a single argument.
(4.3BSD, SunOS, HP-UX, Dynix, Irix)])
AC_CHECK_FUNCS([hasmntopt])
# Check for libmount to support /proc/self/mountinfo on Linux
AC_CACHE_VAL([ac_cv_lib_libmount_mnt_table_parse_stream],
[AC_CHECK_LIB([mount], [mnt_new_table_from_file],
ac_cv_lib_mount_mnt_table_parse_stream=yes,
ac_cv_lib_mount_mnt_table_parse_stream=no)])
if test $ac_cv_lib_mount_mnt_table_parse_stream = yes; then
AC_DEFINE([MOUNTED_PROC_MOUNTINFO], [1],
[Define if want to use /proc/self/mountinfo on Linux.])
LIBS="-lmount $LIBS"
elif test -f /proc/self/mountinfo; then
AC_MSG_WARN([/proc/self/mountinfo present but libmount is missing.])
fi
fi
fi

View File

@ -691,7 +691,7 @@ type/i/^zip\ archive
View=%view{ascii} @EXTHELPERSDIR@/archive.sh view zip
# jar(zip)
type/i/^Java\ Jar\ file\ data\ \(zip\)
type/i/^Java\ (Jar\ file|archive)\ data\ \((zip|JAR)\)
Open=%cd %p/uzip://
View=%view{ascii} @EXTHELPERSDIR@/archive.sh view zip

View File

@ -8,7 +8,7 @@ msgid ""
msgstr ""
"Project-Id-Version: Midnight Commander\n"
"Report-Msgid-Bugs-To: http://www.midnight-commander.org/\n"
"POT-Creation-Date: 2014-09-27 20:13+0400\n"
"POT-Creation-Date: 2014-12-10 13:09+0300\n"
"PO-Revision-Date: 2014-09-04 10:10+0000\n"
"Last-Translator: Piotr Drąg <piotrdrag@gmail.com>\n"
"Language-Team: Azerbaijani (http://www.transifex.com/projects/p/mc/language/"
@ -333,6 +333,9 @@ msgstr ""
msgid "Colon"
msgstr ""
msgid "Semicolon"
msgstr ""
msgid "Exclamation mark"
msgstr ""
@ -1682,6 +1685,12 @@ msgid ""
"%s"
msgstr ""
msgid "< Default >"
msgstr ""
msgid "Skins"
msgstr ""
msgid "Other 8 bit"
msgstr "Başqa 8 bit"
@ -1766,12 +1775,6 @@ msgstr ""
msgid "Configure options"
msgstr "Seçənəkləri quraşdır"
msgid "< Default >"
msgstr ""
msgid "Skins"
msgstr ""
msgid "Skin:"
msgstr ""

View File

@ -8,7 +8,7 @@ msgid ""
msgstr ""
"Project-Id-Version: Midnight Commander\n"
"Report-Msgid-Bugs-To: http://www.midnight-commander.org/\n"
"POT-Creation-Date: 2014-09-27 20:13+0400\n"
"POT-Creation-Date: 2014-12-10 13:09+0300\n"
"PO-Revision-Date: 2014-09-04 10:10+0000\n"
"Last-Translator: Piotr Drąg <piotrdrag@gmail.com>\n"
"Language-Team: Belarusian (http://www.transifex.com/projects/p/mc/language/"
@ -351,6 +351,9 @@ msgstr "Апостраф"
msgid "Colon"
msgstr "Двухкроп’е"
msgid "Semicolon"
msgstr ""
msgid "Exclamation mark"
msgstr "Клічнік"
@ -1744,6 +1747,12 @@ msgstr ""
"Немагчыма зьмяніць уладальніка «%s»\n"
"%s"
msgid "< Default >"
msgstr ""
msgid "Skins"
msgstr ""
msgid "Other 8 bit"
msgstr "Іншая 8-бітная"
@ -1828,12 +1837,6 @@ msgstr "Самарушна захоўваць &налады"
msgid "Configure options"
msgstr "Наставіць налады"
msgid "< Default >"
msgstr ""
msgid "Skins"
msgstr ""
msgid "Skin:"
msgstr ""

View File

@ -9,7 +9,7 @@ msgid ""
msgstr ""
"Project-Id-Version: Midnight Commander\n"
"Report-Msgid-Bugs-To: http://www.midnight-commander.org/\n"
"POT-Creation-Date: 2014-09-27 20:13+0400\n"
"POT-Creation-Date: 2014-12-10 13:09+0300\n"
"PO-Revision-Date: 2014-09-04 10:10+0000\n"
"Last-Translator: Piotr Drąg <piotrdrag@gmail.com>\n"
"Language-Team: Bulgarian (http://www.transifex.com/projects/p/mc/language/"
@ -334,6 +334,9 @@ msgstr "Апостроф"
msgid "Colon"
msgstr "Двоеточие"
msgid "Semicolon"
msgstr ""
msgid "Exclamation mark"
msgstr "Удивителна"
@ -1683,6 +1686,12 @@ msgid ""
"%s"
msgstr ""
msgid "< Default >"
msgstr ""
msgid "Skins"
msgstr ""
msgid "Other 8 bit"
msgstr "Други 8 бита"
@ -1767,12 +1776,6 @@ msgstr ""
msgid "Configure options"
msgstr "Опции на конфигурацията"
msgid "< Default >"
msgstr ""
msgid "Skins"
msgstr ""
msgid "Skin:"
msgstr ""

View File

@ -11,7 +11,7 @@ msgid ""
msgstr ""
"Project-Id-Version: Midnight Commander\n"
"Report-Msgid-Bugs-To: http://www.midnight-commander.org/\n"
"POT-Creation-Date: 2014-09-27 20:13+0400\n"
"POT-Creation-Date: 2014-12-10 13:09+0300\n"
"PO-Revision-Date: 2014-09-04 10:10+0000\n"
"Last-Translator: Piotr Drąg <piotrdrag@gmail.com>\n"
"Language-Team: Catalan (http://www.transifex.com/projects/p/mc/language/"
@ -339,6 +339,9 @@ msgstr "Apòstrof"
msgid "Colon"
msgstr "Punt i Coma"
msgid "Semicolon"
msgstr ""
msgid "Exclamation mark"
msgstr "Signe d'exclamació"
@ -1690,6 +1693,12 @@ msgid ""
"%s"
msgstr ""
msgid "< Default >"
msgstr ""
msgid "Skins"
msgstr ""
msgid "Other 8 bit"
msgstr "Altres 8 bits"
@ -1774,12 +1783,6 @@ msgstr ""
msgid "Configure options"
msgstr "Opcions de configuració"
msgid "< Default >"
msgstr ""
msgid "Skins"
msgstr ""
msgid "Skin:"
msgstr ""

View File

@ -9,7 +9,7 @@ msgid ""
msgstr ""
"Project-Id-Version: Midnight Commander\n"
"Report-Msgid-Bugs-To: http://www.midnight-commander.org/\n"
"POT-Creation-Date: 2014-09-27 20:13+0400\n"
"POT-Creation-Date: 2014-12-10 13:09+0300\n"
"PO-Revision-Date: 2014-09-04 10:10+0000\n"
"Last-Translator: Piotr Drąg <piotrdrag@gmail.com>\n"
"Language-Team: Czech (http://www.transifex.com/projects/p/mc/language/cs/)\n"
@ -347,6 +347,9 @@ msgstr "Apostrof"
msgid "Colon"
msgstr "Dvojtečka"
msgid "Semicolon"
msgstr ""
msgid "Exclamation mark"
msgstr "Vykřičník"
@ -1733,6 +1736,12 @@ msgstr ""
"Nelze změnit vlastníka souboru „%s“\n"
"%s"
msgid "< Default >"
msgstr ""
msgid "Skins"
msgstr ""
msgid "Other 8 bit"
msgstr "Ostatní 8 bitů"
@ -1817,12 +1826,6 @@ msgstr "&Automatické ukládání parametrů"
msgid "Configure options"
msgstr "Změna nastavení"
msgid "< Default >"
msgstr ""
msgid "Skins"
msgstr ""
msgid "Skin:"
msgstr ""

View File

@ -8,7 +8,7 @@ msgid ""
msgstr ""
"Project-Id-Version: Midnight Commander\n"
"Report-Msgid-Bugs-To: http://www.midnight-commander.org/\n"
"POT-Creation-Date: 2014-09-27 20:13+0400\n"
"POT-Creation-Date: 2014-12-10 13:09+0300\n"
"PO-Revision-Date: 2014-09-04 10:10+0000\n"
"Last-Translator: Piotr Drąg <piotrdrag@gmail.com>\n"
"Language-Team: Danish (http://www.transifex.com/projects/p/mc/language/da/)\n"
@ -339,6 +339,9 @@ msgstr "Apostrof"
msgid "Colon"
msgstr "Kolon"
msgid "Semicolon"
msgstr ""
msgid "Exclamation mark"
msgstr "Udråbstegn"
@ -1715,6 +1718,12 @@ msgstr ""
"Kan ikke chown »%s«\n"
"%s"
msgid "< Default >"
msgstr ""
msgid "Skins"
msgstr ""
msgid "Other 8 bit"
msgstr "Andre 8-bit"
@ -1799,12 +1808,6 @@ msgstr "Opsætning for a&utomatisk gemning"
msgid "Configure options"
msgstr "Konfigurer indstillinger"
msgid "< Default >"
msgstr ""
msgid "Skins"
msgstr ""
msgid "Skin:"
msgstr ""

View File

@ -10,7 +10,7 @@ msgid ""
msgstr ""
"Project-Id-Version: Midnight Commander\n"
"Report-Msgid-Bugs-To: http://www.midnight-commander.org/\n"
"POT-Creation-Date: 2014-09-27 20:13+0400\n"
"POT-Creation-Date: 2014-12-10 13:09+0300\n"
"PO-Revision-Date: 2014-09-04 10:10+0000\n"
"Last-Translator: Piotr Drąg <piotrdrag@gmail.com>\n"
"Language-Team: German (http://www.transifex.com/projects/p/mc/language/de/)\n"
@ -343,6 +343,9 @@ msgstr "Hochkomma"
msgid "Colon"
msgstr "Doppelpunkt"
msgid "Semicolon"
msgstr ""
msgid "Exclamation mark"
msgstr "Ausrufezeichen"
@ -1722,6 +1725,12 @@ msgstr ""
"Kann chown für \"%s\" nicht durchführen\n"
"%s"
msgid "< Default >"
msgstr ""
msgid "Skins"
msgstr ""
msgid "Other 8 bit"
msgstr "Andere 8 bit"
@ -1806,12 +1815,6 @@ msgstr "Einstellungen auto&m. speichern"
msgid "Configure options"
msgstr "Einstellungen"
msgid "< Default >"
msgstr ""
msgid "Skins"
msgstr ""
msgid "Skin:"
msgstr ""

View File

@ -7,7 +7,7 @@ msgid ""
msgstr ""
"Project-Id-Version: Midnight Commander\n"
"Report-Msgid-Bugs-To: http://www.midnight-commander.org/\n"
"POT-Creation-Date: 2014-09-27 20:13+0400\n"
"POT-Creation-Date: 2014-12-10 13:09+0300\n"
"PO-Revision-Date: 2014-09-04 10:10+0000\n"
"Last-Translator: Piotr Drąg <piotrdrag@gmail.com>\n"
"Language-Team: German (Switzerland) (http://www.transifex.com/projects/p/mc/"
@ -332,6 +332,9 @@ msgstr ""
msgid "Colon"
msgstr ""
msgid "Semicolon"
msgstr ""
msgid "Exclamation mark"
msgstr ""
@ -1674,6 +1677,12 @@ msgid ""
"%s"
msgstr ""
msgid "< Default >"
msgstr ""
msgid "Skins"
msgstr ""
msgid "Other 8 bit"
msgstr ""
@ -1758,12 +1767,6 @@ msgstr ""
msgid "Configure options"
msgstr ""
msgid "< Default >"
msgstr ""
msgid "Skins"
msgstr ""
msgid "Skin:"
msgstr ""

View File

@ -9,7 +9,7 @@ msgid ""
msgstr ""
"Project-Id-Version: Midnight Commander\n"
"Report-Msgid-Bugs-To: http://www.midnight-commander.org/\n"
"POT-Creation-Date: 2014-09-27 20:13+0400\n"
"POT-Creation-Date: 2014-12-10 13:09+0300\n"
"PO-Revision-Date: 2014-09-04 10:10+0000\n"
"Last-Translator: Piotr Drąg <piotrdrag@gmail.com>\n"
"Language-Team: Greek (http://www.transifex.com/projects/p/mc/language/el/)\n"
@ -346,6 +346,9 @@ msgstr "Απόστροφος"
msgid "Colon"
msgstr ""
msgid "Semicolon"
msgstr ""
msgid "Exclamation mark"
msgstr "Θαυμαστικό"
@ -1714,6 +1717,12 @@ msgstr ""
"Αδυναμία chown \"%s\"\n"
"%s"
msgid "< Default >"
msgstr ""
msgid "Skins"
msgstr ""
msgid "Other 8 bit"
msgstr ""
@ -1798,12 +1807,6 @@ msgstr ""
msgid "Configure options"
msgstr ""
msgid "< Default >"
msgstr ""
msgid "Skins"
msgstr ""
msgid "Skin:"
msgstr ""

View File

@ -7,7 +7,7 @@ msgid ""
msgstr ""
"Project-Id-Version: Midnight Commander\n"
"Report-Msgid-Bugs-To: http://www.midnight-commander.org/\n"
"POT-Creation-Date: 2014-09-27 20:13+0400\n"
"POT-Creation-Date: 2014-12-10 13:09+0300\n"
"PO-Revision-Date: 2014-09-04 10:10+0000\n"
"Last-Translator: Piotr Drąg <piotrdrag@gmail.com>\n"
"Language-Team: English (United Kingdom) (http://www.transifex.com/projects/p/"
@ -332,6 +332,9 @@ msgstr ""
msgid "Colon"
msgstr ""
msgid "Semicolon"
msgstr ""
msgid "Exclamation mark"
msgstr ""
@ -1674,6 +1677,12 @@ msgid ""
"%s"
msgstr ""
msgid "< Default >"
msgstr ""
msgid "Skins"
msgstr ""
msgid "Other 8 bit"
msgstr ""
@ -1758,12 +1767,6 @@ msgstr ""
msgid "Configure options"
msgstr ""
msgid "< Default >"
msgstr ""
msgid "Skins"
msgstr ""
msgid "Skin:"
msgstr ""

View File

@ -8,7 +8,7 @@ msgid ""
msgstr ""
"Project-Id-Version: Midnight Commander\n"
"Report-Msgid-Bugs-To: http://www.midnight-commander.org/\n"
"POT-Creation-Date: 2014-09-27 20:13+0400\n"
"POT-Creation-Date: 2014-12-10 13:09+0300\n"
"PO-Revision-Date: 2014-09-04 10:10+0000\n"
"Last-Translator: Piotr Drąg <piotrdrag@gmail.com>\n"
"Language-Team: Esperanto (http://www.transifex.com/projects/p/mc/language/"
@ -349,6 +349,9 @@ msgstr "Apostrofo"
msgid "Colon"
msgstr "Dupunkto"
msgid "Semicolon"
msgstr ""
msgid "Exclamation mark"
msgstr "Krisigno"
@ -1769,6 +1772,12 @@ msgstr ""
"Ne eblas ŝanĝi estrecon de \"%s\"\n"
"%s"
msgid "< Default >"
msgstr "< Apriora >"
msgid "Skins"
msgstr "Etosoj"
msgid "Other 8 bit"
msgstr "Alia 8-bita"
@ -1853,12 +1862,6 @@ msgstr "Aŭtomate konservi agor&don"
msgid "Configure options"
msgstr "Agordaĵoj"
msgid "< Default >"
msgstr "< Apriora >"
msgid "Skins"
msgstr "Etosoj"
msgid "Skin:"
msgstr "Etoso:"

View File

@ -13,7 +13,7 @@ msgid ""
msgstr ""
"Project-Id-Version: Midnight Commander\n"
"Report-Msgid-Bugs-To: http://www.midnight-commander.org/\n"
"POT-Creation-Date: 2014-09-27 20:13+0400\n"
"POT-Creation-Date: 2014-12-10 13:09+0300\n"
"PO-Revision-Date: 2014-09-04 10:10+0000\n"
"Last-Translator: Piotr Drąg <piotrdrag@gmail.com>\n"
"Language-Team: Spanish (http://www.transifex.com/projects/p/mc/language/"
@ -354,6 +354,9 @@ msgstr "Apóstrofo"
msgid "Colon"
msgstr "Dos puntos"
msgid "Semicolon"
msgstr ""
msgid "Exclamation mark"
msgstr "Exclamación"
@ -1776,6 +1779,12 @@ msgstr ""
"Imposible cambiar el dueño de «%s»\n"
"%s"
msgid "< Default >"
msgstr "< Por defecto >"
msgid "Skins"
msgstr "Skins"
msgid "Other 8 bit"
msgstr "Otro (8 bit)"
@ -1860,12 +1869,6 @@ msgstr "auto-guarda con&Figuración"
msgid "Configure options"
msgstr "Configuración"
msgid "< Default >"
msgstr "< Por defecto >"
msgid "Skins"
msgstr "Skins"
msgid "Skin:"
msgstr "Skin:"

View File

@ -8,7 +8,7 @@ msgid ""
msgstr ""
"Project-Id-Version: Midnight Commander\n"
"Report-Msgid-Bugs-To: http://www.midnight-commander.org/\n"
"POT-Creation-Date: 2014-09-27 20:13+0400\n"
"POT-Creation-Date: 2014-12-10 13:09+0300\n"
"PO-Revision-Date: 2014-09-04 10:10+0000\n"
"Last-Translator: Piotr Drąg <piotrdrag@gmail.com>\n"
"Language-Team: Estonian (http://www.transifex.com/projects/p/mc/language/"
@ -349,6 +349,9 @@ msgstr "Ülakoma '"
msgid "Colon"
msgstr "Koolon :"
msgid "Semicolon"
msgstr ""
msgid "Exclamation mark"
msgstr "Hüüumärk !"
@ -1766,6 +1769,12 @@ msgstr ""
"\"%s\" omaniku vahetus nurjus:\n"
"%s"
msgid "< Default >"
msgstr "< Vaikimisi >"
msgid "Skins"
msgstr "Nahad"
msgid "Other 8 bit"
msgstr "Muu 8-bitine"
@ -1850,12 +1859,6 @@ msgstr "Seadete a&utomaatsalvestus"
msgid "Configure options"
msgstr "Valikute seadistamine"
msgid "< Default >"
msgstr "< Vaikimisi >"
msgid "Skins"
msgstr "Nahad"
msgid "Skin:"
msgstr "Nahk:"

View File

@ -9,7 +9,7 @@ msgid ""
msgstr ""
"Project-Id-Version: Midnight Commander\n"
"Report-Msgid-Bugs-To: http://www.midnight-commander.org/\n"
"POT-Creation-Date: 2014-09-27 20:13+0400\n"
"POT-Creation-Date: 2014-12-10 13:09+0300\n"
"PO-Revision-Date: 2014-09-04 10:10+0000\n"
"Last-Translator: Piotr Drąg <piotrdrag@gmail.com>\n"
"Language-Team: Basque (http://www.transifex.com/projects/p/mc/language/eu/)\n"
@ -349,6 +349,9 @@ msgstr "Apostrofe"
msgid "Colon"
msgstr "Bi puntu"
msgid "Semicolon"
msgstr ""
msgid "Exclamation mark"
msgstr "Harridura marka"
@ -1738,6 +1741,12 @@ msgstr ""
"\"%s\"-ren jabea ezin aldatu (\"chown\")\n"
"%s"
msgid "< Default >"
msgstr ""
msgid "Skins"
msgstr ""
msgid "Other 8 bit"
msgstr "Beste 8 bit"
@ -1822,12 +1831,6 @@ msgstr "A&uto gorde ezarpena"
msgid "Configure options"
msgstr "Konfiguratu aukerak"
msgid "< Default >"
msgstr ""
msgid "Skins"
msgstr ""
msgid "Skin:"
msgstr ""

View File

@ -11,7 +11,7 @@ msgid ""
msgstr ""
"Project-Id-Version: Midnight Commander\n"
"Report-Msgid-Bugs-To: http://www.midnight-commander.org/\n"
"POT-Creation-Date: 2014-09-27 20:13+0400\n"
"POT-Creation-Date: 2014-12-10 13:09+0300\n"
"PO-Revision-Date: 2014-09-04 10:10+0000\n"
"Last-Translator: Piotr Drąg <piotrdrag@gmail.com>\n"
"Language-Team: Persian (http://www.transifex.com/projects/p/mc/language/"
@ -336,6 +336,9 @@ msgstr ""
msgid "Colon"
msgstr "دونقطه"
msgid "Semicolon"
msgstr ""
msgid "Exclamation mark"
msgstr "علامت تعجب"
@ -1680,6 +1683,12 @@ msgid ""
"%s"
msgstr ""
msgid "< Default >"
msgstr ""
msgid "Skins"
msgstr ""
msgid "Other 8 bit"
msgstr ""
@ -1764,12 +1773,6 @@ msgstr ""
msgid "Configure options"
msgstr "تنظیمات پیکربندی"
msgid "< Default >"
msgstr ""
msgid "Skins"
msgstr ""
msgid "Skin:"
msgstr ""

View File

@ -8,7 +8,7 @@ msgid ""
msgstr ""
"Project-Id-Version: Midnight Commander\n"
"Report-Msgid-Bugs-To: http://www.midnight-commander.org/\n"
"POT-Creation-Date: 2014-09-27 20:13+0400\n"
"POT-Creation-Date: 2014-12-10 13:09+0300\n"
"PO-Revision-Date: 2014-09-04 10:10+0000\n"
"Last-Translator: Piotr Drąg <piotrdrag@gmail.com>\n"
"Language-Team: Finnish (http://www.transifex.com/projects/p/mc/language/"
@ -340,6 +340,9 @@ msgstr ""
msgid "Colon"
msgstr ""
msgid "Semicolon"
msgstr ""
msgid "Exclamation mark"
msgstr "Varoitus-merkki"
@ -1686,6 +1689,12 @@ msgid ""
"%s"
msgstr ""
msgid "< Default >"
msgstr ""
msgid "Skins"
msgstr ""
msgid "Other 8 bit"
msgstr ""
@ -1770,12 +1779,6 @@ msgstr ""
msgid "Configure options"
msgstr ""
msgid "< Default >"
msgstr ""
msgid "Skins"
msgstr ""
msgid "Skin:"
msgstr ""

View File

@ -8,7 +8,7 @@ msgid ""
msgstr ""
"Project-Id-Version: Midnight Commander\n"
"Report-Msgid-Bugs-To: http://www.midnight-commander.org/\n"
"POT-Creation-Date: 2014-09-27 20:13+0400\n"
"POT-Creation-Date: 2014-12-10 13:09+0300\n"
"PO-Revision-Date: 2013-03-13 08:51+0000\n"
"Last-Translator: Slava Zanko <slavazanko@gmail.com>\n"
"Language-Team: LANGUAGE <LL@li.org>\n"
@ -350,6 +350,9 @@ msgstr ""
msgid "Colon"
msgstr ""
msgid "Semicolon"
msgstr ""
msgid "Exclamation mark"
msgstr "Varoitus-merkki"
@ -1696,6 +1699,12 @@ msgid ""
"%s"
msgstr ""
msgid "< Default >"
msgstr ""
msgid "Skins"
msgstr ""
msgid "Other 8 bit"
msgstr ""
@ -1780,12 +1789,6 @@ msgstr ""
msgid "Configure options"
msgstr ""
msgid "< Default >"
msgstr ""
msgid "Skins"
msgstr ""
msgid "Skin:"
msgstr ""

View File

@ -10,7 +10,7 @@ msgid ""
msgstr ""
"Project-Id-Version: Midnight Commander\n"
"Report-Msgid-Bugs-To: http://www.midnight-commander.org/\n"
"POT-Creation-Date: 2014-09-27 20:13+0400\n"
"POT-Creation-Date: 2014-12-10 13:09+0300\n"
"PO-Revision-Date: 2014-09-04 10:10+0000\n"
"Last-Translator: Piotr Drąg <piotrdrag@gmail.com>\n"
"Language-Team: French (http://www.transifex.com/projects/p/mc/language/fr/)\n"
@ -343,6 +343,9 @@ msgstr "Apostrophe"
msgid "Colon"
msgstr "Deux points"
msgid "Semicolon"
msgstr ""
msgid "Exclamation mark"
msgstr "Point d'exclamation"
@ -1714,6 +1717,12 @@ msgstr ""
"Ne peut changer l'appartenance de \"%s\"\n"
"%s"
msgid "< Default >"
msgstr ""
msgid "Skins"
msgstr ""
msgid "Other 8 bit"
msgstr "Autre 8 bits"
@ -1798,12 +1807,6 @@ msgstr "Enregistrement a&utomatique de la configuration"
msgid "Configure options"
msgstr "Configurer les options"
msgid "< Default >"
msgstr ""
msgid "Skins"
msgstr ""
msgid "Skin:"
msgstr ""

View File

@ -12,7 +12,7 @@ msgid ""
msgstr ""
"Project-Id-Version: Midnight Commander\n"
"Report-Msgid-Bugs-To: http://www.midnight-commander.org/\n"
"POT-Creation-Date: 2014-09-27 20:13+0400\n"
"POT-Creation-Date: 2014-12-10 13:09+0300\n"
"PO-Revision-Date: 2014-09-04 10:10+0000\n"
"Last-Translator: Piotr Drąg <piotrdrag@gmail.com>\n"
"Language-Team: Galician (http://www.transifex.com/projects/p/mc/language/"
@ -355,6 +355,9 @@ msgstr "Apostrofo"
msgid "Colon"
msgstr "Dous puntos"
msgid "Semicolon"
msgstr ""
msgid "Exclamation mark"
msgstr "Signo de exclamación"
@ -1754,6 +1757,12 @@ msgstr ""
"Non é posíbel cambiar o propietario de «%s»\n"
"%s"
msgid "< Default >"
msgstr "< Predeterminado >"
msgid "Skins"
msgstr "Temas"
msgid "Other 8 bit"
msgstr "Outro (8 bit)"
@ -1838,12 +1847,6 @@ msgstr "Configuración do &Auto-gardado"
msgid "Configure options"
msgstr "Configuración"
msgid "< Default >"
msgstr "< Predeterminado >"
msgid "Skins"
msgstr "Temas"
msgid "Skin:"
msgstr "Tema:"

View File

@ -7,7 +7,7 @@ msgid ""
msgstr ""
"Project-Id-Version: Midnight Commander\n"
"Report-Msgid-Bugs-To: http://www.midnight-commander.org/\n"
"POT-Creation-Date: 2014-09-27 20:13+0400\n"
"POT-Creation-Date: 2014-12-10 13:09+0300\n"
"PO-Revision-Date: 2014-09-04 10:10+0000\n"
"Last-Translator: Piotr Drąg <piotrdrag@gmail.com>\n"
"Language-Team: Croatian (http://www.transifex.com/projects/p/mc/language/"
@ -333,6 +333,9 @@ msgstr ""
msgid "Colon"
msgstr ""
msgid "Semicolon"
msgstr ""
msgid "Exclamation mark"
msgstr ""
@ -1675,6 +1678,12 @@ msgid ""
"%s"
msgstr ""
msgid "< Default >"
msgstr ""
msgid "Skins"
msgstr ""
msgid "Other 8 bit"
msgstr ""
@ -1759,12 +1768,6 @@ msgstr ""
msgid "Configure options"
msgstr ""
msgid "< Default >"
msgstr ""
msgid "Skins"
msgstr ""
msgid "Skin:"
msgstr ""

View File

@ -11,7 +11,7 @@ msgid ""
msgstr ""
"Project-Id-Version: Midnight Commander\n"
"Report-Msgid-Bugs-To: http://www.midnight-commander.org/\n"
"POT-Creation-Date: 2014-09-27 20:13+0400\n"
"POT-Creation-Date: 2014-12-10 13:09+0300\n"
"PO-Revision-Date: 2014-09-04 10:10+0000\n"
"Last-Translator: Piotr Drąg <piotrdrag@gmail.com>\n"
"Language-Team: Hungarian (http://www.transifex.com/projects/p/mc/language/"
@ -352,6 +352,9 @@ msgstr "Aposztróf"
msgid "Colon"
msgstr "Kettőspont"
msgid "Semicolon"
msgstr ""
msgid "Exclamation mark"
msgstr "Felkiáltójel"
@ -1755,6 +1758,12 @@ msgstr ""
"\"%s\" tulaja nem állítható\n"
"%s"
msgid "< Default >"
msgstr ""
msgid "Skins"
msgstr ""
msgid "Other 8 bit"
msgstr "Egyéb 8 bites"
@ -1839,12 +1848,6 @@ msgstr "Auto &Beállításmentés"
msgid "Configure options"
msgstr "Alapbeállítások"
msgid "< Default >"
msgstr ""
msgid "Skins"
msgstr ""
msgid "Skin:"
msgstr ""

View File

@ -9,7 +9,7 @@ msgid ""
msgstr ""
"Project-Id-Version: Midnight Commander\n"
"Report-Msgid-Bugs-To: http://www.midnight-commander.org/\n"
"POT-Creation-Date: 2014-09-27 20:13+0400\n"
"POT-Creation-Date: 2014-12-10 13:09+0300\n"
"PO-Revision-Date: 2014-09-04 10:10+0000\n"
"Last-Translator: Piotr Drąg <piotrdrag@gmail.com>\n"
"Language-Team: Interlingua (http://www.transifex.com/projects/p/mc/language/"
@ -341,6 +341,9 @@ msgstr "Apostrophe"
msgid "Colon"
msgstr "Duo punctos"
msgid "Semicolon"
msgstr ""
msgid "Exclamation mark"
msgstr "Signo de exclamation"
@ -1702,6 +1705,12 @@ msgid ""
"%s"
msgstr ""
msgid "< Default >"
msgstr ""
msgid "Skins"
msgstr ""
msgid "Other 8 bit"
msgstr ""
@ -1786,12 +1795,6 @@ msgstr ""
msgid "Configure options"
msgstr "Configurar optiones"
msgid "< Default >"
msgstr ""
msgid "Skins"
msgstr ""
msgid "Skin:"
msgstr ""

View File

@ -8,7 +8,7 @@ msgid ""
msgstr ""
"Project-Id-Version: Midnight Commander\n"
"Report-Msgid-Bugs-To: http://www.midnight-commander.org/\n"
"POT-Creation-Date: 2014-09-27 20:13+0400\n"
"POT-Creation-Date: 2014-12-10 13:09+0300\n"
"PO-Revision-Date: 2014-09-04 10:10+0000\n"
"Last-Translator: Piotr Drąg <piotrdrag@gmail.com>\n"
"Language-Team: Indonesian (http://www.transifex.com/projects/p/mc/language/"
@ -340,6 +340,9 @@ msgstr "Apostrof"
msgid "Colon"
msgstr "Titik dua"
msgid "Semicolon"
msgstr ""
msgid "Exclamation mark"
msgstr "Tanda seru"
@ -1685,6 +1688,12 @@ msgid ""
"%s"
msgstr ""
msgid "< Default >"
msgstr ""
msgid "Skins"
msgstr ""
msgid "Other 8 bit"
msgstr ""
@ -1769,12 +1778,6 @@ msgstr ""
msgid "Configure options"
msgstr ""
msgid "< Default >"
msgstr ""
msgid "Skins"
msgstr ""
msgid "Skin:"
msgstr ""

View File

@ -11,7 +11,7 @@ msgid ""
msgstr ""
"Project-Id-Version: Midnight Commander\n"
"Report-Msgid-Bugs-To: http://www.midnight-commander.org/\n"
"POT-Creation-Date: 2014-11-15 20:23+0100\n"
"POT-Creation-Date: 2014-12-10 13:09+0300\n"
"PO-Revision-Date: 2014-11-15 20:24+0100\n"
"Last-Translator: Marco Ciampa <ciampix@libero.it>\n"
"Language-Team: Italian (http://www.transifex.com/projects/p/mc/language/"
@ -351,6 +351,9 @@ msgstr "Apostrofo"
msgid "Colon"
msgstr "Duepunti"
msgid "Semicolon"
msgstr ""
msgid "Exclamation mark"
msgstr "Punto esclamativo"
@ -1767,6 +1770,12 @@ msgstr ""
"Impossibile eseguire chown su \"%s\"\n"
"%s"
msgid "< Default >"
msgstr "< predefinito >"
msgid "Skins"
msgstr "Skin"
msgid "Other 8 bit"
msgstr "Altre a 8 bit"
@ -1851,12 +1860,6 @@ msgstr "Autosalva &configurazione"
msgid "Configure options"
msgstr "Configura opzioni"
msgid "< Default >"
msgstr "< predefinito >"
msgid "Skins"
msgstr "Skin"
msgid "Skin:"
msgstr "Skin:"

View File

@ -11,7 +11,7 @@ msgid ""
msgstr ""
"Project-Id-Version: Midnight Commander\n"
"Report-Msgid-Bugs-To: http://www.midnight-commander.org/\n"
"POT-Creation-Date: 2014-09-27 20:13+0400\n"
"POT-Creation-Date: 2014-12-10 13:09+0300\n"
"PO-Revision-Date: 2014-09-04 10:10+0000\n"
"Last-Translator: Piotr Drąg <piotrdrag@gmail.com>\n"
"Language-Team: Japanese (http://www.transifex.com/projects/p/mc/language/"
@ -343,6 +343,9 @@ msgstr "アポストロフィ"
msgid "Colon"
msgstr "コロン"
msgid "Semicolon"
msgstr ""
msgid "Exclamation mark"
msgstr "感嘆符(!)"
@ -1696,6 +1699,12 @@ msgid ""
"%s"
msgstr ""
msgid "< Default >"
msgstr ""
msgid "Skins"
msgstr ""
msgid "Other 8 bit"
msgstr "別の 8bit"
@ -1780,12 +1789,6 @@ msgstr "自動保存の設定(&U)"
msgid "Configure options"
msgstr "設定オプション"
msgid "< Default >"
msgstr ""
msgid "Skins"
msgstr ""
msgid "Skin:"
msgstr ""

View File

@ -8,7 +8,7 @@ msgid ""
msgstr ""
"Project-Id-Version: Midnight Commander\n"
"Report-Msgid-Bugs-To: http://www.midnight-commander.org/\n"
"POT-Creation-Date: 2014-09-27 20:13+0400\n"
"POT-Creation-Date: 2014-12-10 13:09+0300\n"
"PO-Revision-Date: 2014-09-04 10:10+0000\n"
"Last-Translator: Piotr Drąg <piotrdrag@gmail.com>\n"
"Language-Team: Georgian (http://www.transifex.com/projects/p/mc/language/"
@ -333,6 +333,9 @@ msgstr "აპოსტროფი"
msgid "Colon"
msgstr "ორი წერტილი"
msgid "Semicolon"
msgstr ""
msgid "Exclamation mark"
msgstr "ძახილის ნიშანი"
@ -1678,6 +1681,12 @@ msgid ""
"%s"
msgstr ""
msgid "< Default >"
msgstr ""
msgid "Skins"
msgstr ""
msgid "Other 8 bit"
msgstr ""
@ -1762,12 +1771,6 @@ msgstr ""
msgid "Configure options"
msgstr ""
msgid "< Default >"
msgstr ""
msgid "Skins"
msgstr ""
msgid "Skin:"
msgstr ""

View File

@ -7,7 +7,7 @@ msgid ""
msgstr ""
"Project-Id-Version: Midnight Commander\n"
"Report-Msgid-Bugs-To: http://www.midnight-commander.org/\n"
"POT-Creation-Date: 2014-09-27 20:13+0400\n"
"POT-Creation-Date: 2014-12-10 13:09+0300\n"
"PO-Revision-Date: 2014-09-04 10:10+0000\n"
"Last-Translator: Piotr Drąg <piotrdrag@gmail.com>\n"
"Language-Team: Kazakh (http://www.transifex.com/projects/p/mc/language/kk/)\n"
@ -331,6 +331,9 @@ msgstr ""
msgid "Colon"
msgstr ""
msgid "Semicolon"
msgstr ""
msgid "Exclamation mark"
msgstr ""
@ -1673,6 +1676,12 @@ msgid ""
"%s"
msgstr ""
msgid "< Default >"
msgstr ""
msgid "Skins"
msgstr ""
msgid "Other 8 bit"
msgstr ""
@ -1757,12 +1766,6 @@ msgstr ""
msgid "Configure options"
msgstr ""
msgid "< Default >"
msgstr ""
msgid "Skins"
msgstr ""
msgid "Skin:"
msgstr ""

View File

@ -8,7 +8,7 @@ msgid ""
msgstr ""
"Project-Id-Version: Midnight Commander\n"
"Report-Msgid-Bugs-To: http://www.midnight-commander.org/\n"
"POT-Creation-Date: 2014-09-27 20:13+0400\n"
"POT-Creation-Date: 2014-12-10 13:09+0300\n"
"PO-Revision-Date: 2014-09-04 10:10+0000\n"
"Last-Translator: Piotr Drąg <piotrdrag@gmail.com>\n"
"Language-Team: Korean (http://www.transifex.com/projects/p/mc/language/ko/)\n"
@ -336,6 +336,9 @@ msgstr "아포스트로피"
msgid "Colon"
msgstr "콜론"
msgid "Semicolon"
msgstr ""
msgid "Exclamation mark"
msgstr "느낌표"
@ -1685,6 +1688,12 @@ msgid ""
"%s"
msgstr ""
msgid "< Default >"
msgstr ""
msgid "Skins"
msgstr ""
msgid "Other 8 bit"
msgstr "다른 8 비트"
@ -1769,12 +1778,6 @@ msgstr ""
msgid "Configure options"
msgstr "환경설정 선택항목"
msgid "< Default >"
msgstr ""
msgid "Skins"
msgstr ""
msgid "Skin:"
msgstr ""

View File

@ -9,7 +9,7 @@ msgid ""
msgstr ""
"Project-Id-Version: Midnight Commander\n"
"Report-Msgid-Bugs-To: http://www.midnight-commander.org/\n"
"POT-Creation-Date: 2014-09-27 20:13+0400\n"
"POT-Creation-Date: 2014-12-10 13:09+0300\n"
"PO-Revision-Date: 2014-09-04 10:10+0000\n"
"Last-Translator: Piotr Drąg <piotrdrag@gmail.com>\n"
"Language-Team: Lithuanian (http://www.transifex.com/projects/p/mc/language/"
@ -335,6 +335,9 @@ msgstr ""
msgid "Colon"
msgstr ""
msgid "Semicolon"
msgstr ""
msgid "Exclamation mark"
msgstr ""
@ -1684,6 +1687,12 @@ msgid ""
"%s"
msgstr ""
msgid "< Default >"
msgstr ""
msgid "Skins"
msgstr ""
msgid "Other 8 bit"
msgstr "Kita 8 bitų"
@ -1768,12 +1777,6 @@ msgstr ""
msgid "Configure options"
msgstr "Nustatymai"
msgid "< Default >"
msgstr ""
msgid "Skins"
msgstr ""
msgid "Skin:"
msgstr ""

View File

@ -8,7 +8,7 @@ msgid ""
msgstr ""
"Project-Id-Version: Midnight Commander\n"
"Report-Msgid-Bugs-To: http://www.midnight-commander.org/\n"
"POT-Creation-Date: 2014-09-27 20:13+0400\n"
"POT-Creation-Date: 2014-12-10 13:09+0300\n"
"PO-Revision-Date: 2014-09-04 10:10+0000\n"
"Last-Translator: Piotr Drąg <piotrdrag@gmail.com>\n"
"Language-Team: Latvian (http://www.transifex.com/projects/p/mc/language/"
@ -334,6 +334,9 @@ msgstr ""
msgid "Colon"
msgstr ""
msgid "Semicolon"
msgstr ""
msgid "Exclamation mark"
msgstr ""
@ -1683,6 +1686,12 @@ msgid ""
"%s"
msgstr ""
msgid "< Default >"
msgstr ""
msgid "Skins"
msgstr ""
msgid "Other 8 bit"
msgstr "Citi 8 bitu"
@ -1767,12 +1776,6 @@ msgstr ""
msgid "Configure options"
msgstr "Konfigurēt opcijas"
msgid "< Default >"
msgstr ""
msgid "Skins"
msgstr ""
msgid "Skin:"
msgstr ""

562
po/mc.pot

File diff suppressed because it is too large Load Diff

View File

@ -8,7 +8,7 @@ msgid ""
msgstr ""
"Project-Id-Version: Midnight Commander\n"
"Report-Msgid-Bugs-To: http://www.midnight-commander.org/\n"
"POT-Creation-Date: 2014-09-27 20:13+0400\n"
"POT-Creation-Date: 2014-12-10 13:09+0300\n"
"PO-Revision-Date: 2014-09-04 10:10+0000\n"
"Last-Translator: Piotr Drąg <piotrdrag@gmail.com>\n"
"Language-Team: Mongolian (http://www.transifex.com/projects/p/mc/language/"
@ -333,6 +333,9 @@ msgstr ""
msgid "Colon"
msgstr ""
msgid "Semicolon"
msgstr ""
msgid "Exclamation mark"
msgstr ""
@ -1682,6 +1685,12 @@ msgid ""
"%s"
msgstr ""
msgid "< Default >"
msgstr ""
msgid "Skins"
msgstr ""
msgid "Other 8 bit"
msgstr "Бусад 8-бит"
@ -1766,12 +1775,6 @@ msgstr ""
msgid "Configure options"
msgstr "Тохиргуулгын параметрүүд"
msgid "< Default >"
msgstr ""
msgid "Skins"
msgstr ""
msgid "Skin:"
msgstr ""

View File

@ -8,7 +8,7 @@ msgid ""
msgstr ""
"Project-Id-Version: Midnight Commander\n"
"Report-Msgid-Bugs-To: http://www.midnight-commander.org/\n"
"POT-Creation-Date: 2014-09-27 20:13+0400\n"
"POT-Creation-Date: 2014-12-10 13:09+0300\n"
"PO-Revision-Date: 2014-09-04 10:10+0000\n"
"Last-Translator: Piotr Drąg <piotrdrag@gmail.com>\n"
"Language-Team: Norwegian Bokmål (http://www.transifex.com/projects/p/mc/"
@ -333,6 +333,9 @@ msgstr ""
msgid "Colon"
msgstr ""
msgid "Semicolon"
msgstr ""
msgid "Exclamation mark"
msgstr ""
@ -1682,6 +1685,12 @@ msgid ""
"%s"
msgstr ""
msgid "< Default >"
msgstr ""
msgid "Skins"
msgstr ""
msgid "Other 8 bit"
msgstr "Andre 8-bit"
@ -1766,12 +1775,6 @@ msgstr ""
msgid "Configure options"
msgstr "Alternativer for konfigurasjon"
msgid "< Default >"
msgstr ""
msgid "Skins"
msgstr ""
msgid "Skin:"
msgstr ""

View File

@ -13,7 +13,7 @@ msgid ""
msgstr ""
"Project-Id-Version: Midnight Commander\n"
"Report-Msgid-Bugs-To: http://www.midnight-commander.org/\n"
"POT-Creation-Date: 2014-09-27 20:13+0400\n"
"POT-Creation-Date: 2014-12-10 13:09+0300\n"
"PO-Revision-Date: 2014-09-04 10:10+0000\n"
"Last-Translator: Piotr Drąg <piotrdrag@gmail.com>\n"
"Language-Team: Dutch (http://www.transifex.com/projects/p/mc/language/nl/)\n"
@ -351,6 +351,9 @@ msgstr "Apostrof"
msgid "Colon"
msgstr "Dubbele punt"
msgid "Semicolon"
msgstr ""
msgid "Exclamation mark"
msgstr "Uitroepteken"
@ -1747,6 +1750,12 @@ msgstr ""
"chown voor \"%s\" mislukt \n"
"%s"
msgid "< Default >"
msgstr ""
msgid "Skins"
msgstr ""
msgid "Other 8 bit"
msgstr "Andere 8 bits"
@ -1831,12 +1840,6 @@ msgstr "A&utomatisch instellingen opslaan"
msgid "Configure options"
msgstr "Instellingen"
msgid "< Default >"
msgstr ""
msgid "Skins"
msgstr ""
msgid "Skin:"
msgstr ""

View File

@ -9,7 +9,7 @@ msgid ""
msgstr ""
"Project-Id-Version: Midnight Commander\n"
"Report-Msgid-Bugs-To: http://www.midnight-commander.org/\n"
"POT-Creation-Date: 2014-09-27 20:13+0400\n"
"POT-Creation-Date: 2014-12-10 13:09+0300\n"
"PO-Revision-Date: 2014-09-04 10:10+0000\n"
"Last-Translator: Piotr Drąg <piotrdrag@gmail.com>\n"
"Language-Team: Polish (http://www.transifex.com/projects/p/mc/language/pl/)\n"
@ -351,6 +351,9 @@ msgstr "Apostrof"
msgid "Colon"
msgstr "Dwukropek"
msgid "Semicolon"
msgstr ""
msgid "Exclamation mark"
msgstr "Wykrzyknik"
@ -1772,6 +1775,12 @@ msgstr ""
"Nie można wykonać chown na \"%s\"\n"
"%s"
msgid "< Default >"
msgstr "< Domyślne >"
msgid "Skins"
msgstr "Skórki"
msgid "Other 8 bit"
msgstr "Inne 8 bitowe"
@ -1856,12 +1865,6 @@ msgstr "Auto&matyczny zapis ustawień"
msgid "Configure options"
msgstr "Konfiguracja opcji"
msgid "< Default >"
msgstr "< Domyślne >"
msgid "Skins"
msgstr "Skórki"
msgid "Skin:"
msgstr "Skórka:"

View File

@ -11,7 +11,7 @@ msgid ""
msgstr ""
"Project-Id-Version: Midnight Commander\n"
"Report-Msgid-Bugs-To: http://www.midnight-commander.org/\n"
"POT-Creation-Date: 2014-09-27 20:13+0400\n"
"POT-Creation-Date: 2014-12-10 13:09+0300\n"
"PO-Revision-Date: 2014-09-04 12:38+0000\n"
"Last-Translator: Gilberto Jorge <gmj125@gmail.com>\n"
"Language-Team: Portuguese (http://www.transifex.com/projects/p/mc/language/"
@ -352,6 +352,9 @@ msgstr "Apóstrofe"
msgid "Colon"
msgstr "Dois pontos"
msgid "Semicolon"
msgstr ""
msgid "Exclamation mark"
msgstr "Ponto de exclamação"
@ -1774,6 +1777,12 @@ msgstr ""
"Não é possível efetuar chown \"%s\"\n"
"%s"
msgid "< Default >"
msgstr "< Default >"
msgid "Skins"
msgstr "Skins"
msgid "Other 8 bit"
msgstr "Outros 8 bit"
@ -1858,12 +1867,6 @@ msgstr "Guardar setup a&uto"
msgid "Configure options"
msgstr "Opções de configuração"
msgid "< Default >"
msgstr "< Default >"
msgid "Skins"
msgstr "Skins"
msgid "Skin:"
msgstr "Skin:"

View File

@ -11,7 +11,7 @@ msgid ""
msgstr ""
"Project-Id-Version: Midnight Commander\n"
"Report-Msgid-Bugs-To: http://www.midnight-commander.org/\n"
"POT-Creation-Date: 2014-09-27 20:13+0400\n"
"POT-Creation-Date: 2014-12-10 13:09+0300\n"
"PO-Revision-Date: 2014-09-04 10:10+0000\n"
"Last-Translator: Piotr Drąg <piotrdrag@gmail.com>\n"
"Language-Team: Portuguese (Brazil) (http://www.transifex.com/projects/p/mc/"
@ -343,6 +343,9 @@ msgstr "Apóstrofo"
msgid "Colon"
msgstr "Dois pontos"
msgid "Semicolon"
msgstr ""
msgid "Exclamation mark"
msgstr "Ponto de exclamação"
@ -1718,6 +1721,12 @@ msgstr ""
"Não foi possível executar chown \"%s\"\n"
"%s"
msgid "< Default >"
msgstr ""
msgid "Skins"
msgstr ""
msgid "Other 8 bit"
msgstr "Outro 8 bit"
@ -1802,12 +1811,6 @@ msgstr ""
msgid "Configure options"
msgstr "Configurar Opções"
msgid "< Default >"
msgstr ""
msgid "Skins"
msgstr ""
msgid "Skin:"
msgstr ""

View File

@ -10,7 +10,7 @@ msgid ""
msgstr ""
"Project-Id-Version: Midnight Commander\n"
"Report-Msgid-Bugs-To: http://www.midnight-commander.org/\n"
"POT-Creation-Date: 2014-09-27 20:13+0400\n"
"POT-Creation-Date: 2014-12-10 13:09+0300\n"
"PO-Revision-Date: 2014-09-04 10:10+0000\n"
"Last-Translator: Piotr Drąg <piotrdrag@gmail.com>\n"
"Language-Team: Romanian (http://www.transifex.com/projects/p/mc/language/"
@ -352,6 +352,9 @@ msgstr "Apostrof"
msgid "Colon"
msgstr "Punct și virgulă"
msgid "Semicolon"
msgstr ""
msgid "Exclamation mark"
msgstr "Semn de exclamare"
@ -1755,6 +1758,12 @@ msgstr ""
"Nu se poate aplica chown \"%s\"\n"
"%s"
msgid "< Default >"
msgstr "< Implicit >"
msgid "Skins"
msgstr "Tematici"
msgid "Other 8 bit"
msgstr "Alt 8 biți"
@ -1839,12 +1848,6 @@ msgstr "Auto-salvare a configurației"
msgid "Configure options"
msgstr "Opțiuni de configurare"
msgid "< Default >"
msgstr "< Implicit >"
msgid "Skins"
msgstr "Tematici"
msgid "Skin:"
msgstr "Tematică:"

View File

@ -17,8 +17,8 @@ msgid ""
msgstr ""
"Project-Id-Version: Midnight Commander\n"
"Report-Msgid-Bugs-To: http://www.midnight-commander.org/\n"
"POT-Creation-Date: 2014-09-27 20:13+0400\n"
"PO-Revision-Date: 2014-09-09 14:43+0300\n"
"POT-Creation-Date: 2014-12-10 13:09+0300\n"
"PO-Revision-Date: 2014-12-10 13:12+0300\n"
"Last-Translator: Andrew Borodin <aborodin@vmail.ru>\n"
"Language-Team: Russian (http://www.transifex.com/projects/p/mc/language/"
"ru/)\n"
@ -359,6 +359,9 @@ msgstr "Апостроф"
msgid "Colon"
msgstr "Двоеточие"
msgid "Semicolon"
msgstr ""
msgid "Exclamation mark"
msgstr "Exclamation mark"
@ -1775,6 +1778,12 @@ msgstr ""
"Невозможно изменить владельца \"%s\"\n"
"%s"
msgid "< Default >"
msgstr "< По умолчанию >"
msgid "Skins"
msgstr "Скины"
msgid "Other 8 bit"
msgstr "Другая 8-битная"
@ -1859,12 +1868,6 @@ msgstr "&Автосохранение настроек"
msgid "Configure options"
msgstr "Параметры конфигурации"
msgid "< Default >"
msgstr "< По умолчанию >"
msgid "Skins"
msgstr "Скины"
msgid "Skin:"
msgstr "Скин:"
@ -3519,7 +3522,7 @@ msgid "&Case sensitive"
msgstr "Учет ре&гистра"
msgid "Select"
msgstr "отметить группу"
msgstr "Отметить группу"
msgid "Unselect"
msgstr "Снять отметку"

View File

@ -11,7 +11,7 @@ msgid ""
msgstr ""
"Project-Id-Version: Midnight Commander\n"
"Report-Msgid-Bugs-To: http://www.midnight-commander.org/\n"
"POT-Creation-Date: 2014-09-27 20:13+0400\n"
"POT-Creation-Date: 2014-12-10 13:09+0300\n"
"PO-Revision-Date: 2014-09-04 10:10+0000\n"
"Last-Translator: Piotr Drąg <piotrdrag@gmail.com>\n"
"Language-Team: Slovak (http://www.transifex.com/projects/p/mc/language/sk/)\n"
@ -343,6 +343,9 @@ msgstr "Apostrof"
msgid "Colon"
msgstr "Dvojbodka"
msgid "Semicolon"
msgstr ""
msgid "Exclamation mark"
msgstr "Výkričník"
@ -1692,6 +1695,12 @@ msgid ""
"%s"
msgstr ""
msgid "< Default >"
msgstr ""
msgid "Skins"
msgstr ""
msgid "Other 8 bit"
msgstr "Iné 8-bitové"
@ -1776,12 +1785,6 @@ msgstr ""
msgid "Configure options"
msgstr "Nastavovateľne voľby"
msgid "< Default >"
msgstr ""
msgid "Skins"
msgstr ""
msgid "Skin:"
msgstr ""

View File

@ -10,7 +10,7 @@ msgid ""
msgstr ""
"Project-Id-Version: Midnight Commander\n"
"Report-Msgid-Bugs-To: http://www.midnight-commander.org/\n"
"POT-Creation-Date: 2014-09-27 20:13+0400\n"
"POT-Creation-Date: 2014-12-10 13:09+0300\n"
"PO-Revision-Date: 2014-09-04 10:10+0000\n"
"Last-Translator: Piotr Drąg <piotrdrag@gmail.com>\n"
"Language-Team: Slovenian (http://www.transifex.com/projects/p/mc/language/"
@ -343,6 +343,9 @@ msgstr "Narekovaj"
msgid "Colon"
msgstr "Podpičje"
msgid "Semicolon"
msgstr ""
msgid "Exclamation mark"
msgstr "Klicaj"
@ -1692,6 +1695,12 @@ msgid ""
"%s"
msgstr ""
msgid "< Default >"
msgstr ""
msgid "Skins"
msgstr ""
msgid "Other 8 bit"
msgstr "Drugo 8 bitno"
@ -1776,12 +1785,6 @@ msgstr ""
msgid "Configure options"
msgstr "Nastavi"
msgid "< Default >"
msgstr ""
msgid "Skins"
msgstr ""
msgid "Skin:"
msgstr ""

View File

@ -8,7 +8,7 @@ msgid ""
msgstr ""
"Project-Id-Version: Midnight Commander\n"
"Report-Msgid-Bugs-To: http://www.midnight-commander.org/\n"
"POT-Creation-Date: 2014-09-27 20:13+0400\n"
"POT-Creation-Date: 2014-12-10 13:09+0300\n"
"PO-Revision-Date: 2014-09-04 10:10+0000\n"
"Last-Translator: Piotr Drąg <piotrdrag@gmail.com>\n"
"Language-Team: Serbian (http://www.transifex.com/projects/p/mc/language/"
@ -334,6 +334,9 @@ msgstr ""
msgid "Colon"
msgstr ""
msgid "Semicolon"
msgstr ""
msgid "Exclamation mark"
msgstr ""
@ -1683,6 +1686,12 @@ msgid ""
"%s"
msgstr ""
msgid "< Default >"
msgstr ""
msgid "Skins"
msgstr ""
msgid "Other 8 bit"
msgstr "Другa, осмобитнa"
@ -1767,12 +1776,6 @@ msgstr ""
msgid "Configure options"
msgstr "Подеси изборе"
msgid "< Default >"
msgstr ""
msgid "Skins"
msgstr ""
msgid "Skin:"
msgstr ""

View File

@ -9,7 +9,7 @@ msgid ""
msgstr ""
"Project-Id-Version: Midnight Commander\n"
"Report-Msgid-Bugs-To: http://www.midnight-commander.org/\n"
"POT-Creation-Date: 2014-09-27 20:13+0400\n"
"POT-Creation-Date: 2014-12-10 13:09+0300\n"
"PO-Revision-Date: 2014-09-04 10:10+0000\n"
"Last-Translator: Piotr Drąg <piotrdrag@gmail.com>\n"
"Language-Team: Swedish (http://www.transifex.com/projects/p/mc/language/"
@ -334,6 +334,9 @@ msgstr ""
msgid "Colon"
msgstr ""
msgid "Semicolon"
msgstr ""
msgid "Exclamation mark"
msgstr ""
@ -1683,6 +1686,12 @@ msgid ""
"%s"
msgstr ""
msgid "< Default >"
msgstr ""
msgid "Skins"
msgstr ""
msgid "Other 8 bit"
msgstr "Annan 8-bitars"
@ -1767,12 +1776,6 @@ msgstr ""
msgid "Configure options"
msgstr "Inställningar"
msgid "< Default >"
msgstr ""
msgid "Skins"
msgstr ""
msgid "Skin:"
msgstr ""

View File

@ -7,7 +7,7 @@ msgid ""
msgstr ""
"Project-Id-Version: Midnight Commander\n"
"Report-Msgid-Bugs-To: http://www.midnight-commander.org/\n"
"POT-Creation-Date: 2014-09-27 20:13+0400\n"
"POT-Creation-Date: 2014-12-10 13:09+0300\n"
"PO-Revision-Date: 2011-12-07 11:21+0000\n"
"Last-Translator: slavazanko <slavazanko@gmail.com>\n"
"Language-Team: Swedish (Sweden) (http://www.transifex.net/projects/p/mc/team/"
@ -331,6 +331,9 @@ msgstr ""
msgid "Colon"
msgstr ""
msgid "Semicolon"
msgstr ""
msgid "Exclamation mark"
msgstr ""
@ -1673,6 +1676,12 @@ msgid ""
"%s"
msgstr ""
msgid "< Default >"
msgstr ""
msgid "Skins"
msgstr ""
msgid "Other 8 bit"
msgstr ""
@ -1757,12 +1766,6 @@ msgstr ""
msgid "Configure options"
msgstr ""
msgid "< Default >"
msgstr ""
msgid "Skins"
msgstr ""
msgid "Skin:"
msgstr ""

View File

@ -7,7 +7,7 @@ msgid ""
msgstr ""
"Project-Id-Version: Midnight Commander\n"
"Report-Msgid-Bugs-To: http://www.midnight-commander.org/\n"
"POT-Creation-Date: 2014-09-27 20:13+0400\n"
"POT-Creation-Date: 2014-12-10 13:09+0300\n"
"PO-Revision-Date: 2014-09-04 10:10+0000\n"
"Last-Translator: Piotr Drąg <piotrdrag@gmail.com>\n"
"Language-Team: Silesian (http://www.transifex.com/projects/p/mc/language/"
@ -333,6 +333,9 @@ msgstr ""
msgid "Colon"
msgstr ""
msgid "Semicolon"
msgstr ""
msgid "Exclamation mark"
msgstr ""
@ -1675,6 +1678,12 @@ msgid ""
"%s"
msgstr ""
msgid "< Default >"
msgstr ""
msgid "Skins"
msgstr ""
msgid "Other 8 bit"
msgstr ""
@ -1759,12 +1768,6 @@ msgstr ""
msgid "Configure options"
msgstr ""
msgid "< Default >"
msgstr ""
msgid "Skins"
msgstr ""
msgid "Skin:"
msgstr ""

View File

@ -8,7 +8,7 @@ msgid ""
msgstr ""
"Project-Id-Version: Midnight Commander\n"
"Report-Msgid-Bugs-To: http://www.midnight-commander.org/\n"
"POT-Creation-Date: 2014-09-27 20:13+0400\n"
"POT-Creation-Date: 2014-12-10 13:09+0300\n"
"PO-Revision-Date: 2014-09-04 10:10+0000\n"
"Last-Translator: Piotr Drąg <piotrdrag@gmail.com>\n"
"Language-Team: Tamil (http://www.transifex.com/projects/p/mc/language/ta/)\n"
@ -332,6 +332,9 @@ msgstr ""
msgid "Colon"
msgstr ""
msgid "Semicolon"
msgstr ""
msgid "Exclamation mark"
msgstr ""
@ -1674,6 +1677,12 @@ msgid ""
"%s"
msgstr ""
msgid "< Default >"
msgstr ""
msgid "Skins"
msgstr ""
msgid "Other 8 bit"
msgstr ""
@ -1758,12 +1767,6 @@ msgstr ""
msgid "Configure options"
msgstr ""
msgid "< Default >"
msgstr ""
msgid "Skins"
msgstr ""
msgid "Skin:"
msgstr ""

View File

@ -9,7 +9,7 @@ msgid ""
msgstr ""
"Project-Id-Version: Midnight Commander\n"
"Report-Msgid-Bugs-To: http://www.midnight-commander.org/\n"
"POT-Creation-Date: 2014-09-27 20:13+0400\n"
"POT-Creation-Date: 2014-12-10 13:09+0300\n"
"PO-Revision-Date: 2014-09-04 10:10+0000\n"
"Last-Translator: Piotr Drąg <piotrdrag@gmail.com>\n"
"Language-Team: Turkish (http://www.transifex.com/projects/p/mc/language/"
@ -334,6 +334,9 @@ msgstr ""
msgid "Colon"
msgstr ""
msgid "Semicolon"
msgstr ""
msgid "Exclamation mark"
msgstr "Ünlem İşareti"
@ -1683,6 +1686,12 @@ msgid ""
"%s"
msgstr ""
msgid "< Default >"
msgstr ""
msgid "Skins"
msgstr ""
msgid "Other 8 bit"
msgstr "Diğer 8 bit"
@ -1767,12 +1776,6 @@ msgstr ""
msgid "Configure options"
msgstr "Yapılandırma seçenekleri"
msgid "< Default >"
msgstr ""
msgid "Skins"
msgstr ""
msgid "Skin:"
msgstr ""

View File

@ -10,7 +10,7 @@ msgid ""
msgstr ""
"Project-Id-Version: Midnight Commander\n"
"Report-Msgid-Bugs-To: http://www.midnight-commander.org/\n"
"POT-Creation-Date: 2014-09-27 20:13+0400\n"
"POT-Creation-Date: 2014-12-10 13:09+0300\n"
"PO-Revision-Date: 2014-09-04 10:10+0000\n"
"Last-Translator: Piotr Drąg <piotrdrag@gmail.com>\n"
"Language-Team: Ukrainian (http://www.transifex.com/projects/p/mc/language/"
@ -353,6 +353,9 @@ msgstr "'"
msgid "Colon"
msgstr ":"
msgid "Semicolon"
msgstr ""
msgid "Exclamation mark"
msgstr "!"
@ -954,7 +957,8 @@ msgstr "«%s» не є звичайним файлом"
msgid ""
"File \"%s\" is too large.\n"
"Open it anyway?"
msgstr "Файл «%s» занадто великий.\n"
msgstr ""
"Файл «%s» занадто великий.\n"
"Відкрити його будь що?"
#, c-format
@ -1749,6 +1753,12 @@ msgstr ""
"Не вдалося змінити власника «%s» \n"
"%s"
msgid "< Default >"
msgstr ""
msgid "Skins"
msgstr ""
msgid "Other 8 bit"
msgstr "Інше 8-розрядне"
@ -1833,12 +1843,6 @@ msgstr "&Автозбереження параметрів"
msgid "Configure options"
msgstr "Параметри конфігурації"
msgid "< Default >"
msgstr ""
msgid "Skins"
msgstr ""
msgid "Skin:"
msgstr ""
@ -4159,8 +4163,7 @@ msgstr "sftp: Створення списку завершено."
#, c-format
msgid "reconnect to %s failed"
msgstr ""
"сталася помилка повторного з’єднання з %s"
msgstr "сталася помилка повторного з’єднання з %s"
msgid "Authentication failed"
msgstr "Сталася помилка авторизації "

View File

@ -8,7 +8,7 @@ msgid ""
msgstr ""
"Project-Id-Version: Midnight Commander\n"
"Report-Msgid-Bugs-To: http://www.midnight-commander.org/\n"
"POT-Creation-Date: 2014-09-27 20:13+0400\n"
"POT-Creation-Date: 2014-12-10 13:09+0300\n"
"PO-Revision-Date: 2014-09-04 10:10+0000\n"
"Last-Translator: Piotr Drąg <piotrdrag@gmail.com>\n"
"Language-Team: Vietnamese (http://www.transifex.com/projects/p/mc/language/"
@ -333,6 +333,9 @@ msgstr ""
msgid "Colon"
msgstr ""
msgid "Semicolon"
msgstr ""
msgid "Exclamation mark"
msgstr ""
@ -1682,6 +1685,12 @@ msgid ""
"%s"
msgstr ""
msgid "< Default >"
msgstr ""
msgid "Skins"
msgstr ""
msgid "Other 8 bit"
msgstr "8 bit khác"
@ -1766,12 +1775,6 @@ msgstr ""
msgid "Configure options"
msgstr "Tùy chọn cấu hình"
msgid "< Default >"
msgstr ""
msgid "Skins"
msgstr ""
msgid "Skin:"
msgstr ""

View File

@ -8,7 +8,7 @@ msgid ""
msgstr ""
"Project-Id-Version: Midnight Commander\n"
"Report-Msgid-Bugs-To: http://www.midnight-commander.org/\n"
"POT-Creation-Date: 2014-09-27 20:13+0400\n"
"POT-Creation-Date: 2014-12-10 13:09+0300\n"
"PO-Revision-Date: 2014-09-04 10:10+0000\n"
"Last-Translator: Piotr Drąg <piotrdrag@gmail.com>\n"
"Language-Team: Walloon (http://www.transifex.com/projects/p/mc/language/"
@ -333,6 +333,9 @@ msgstr ""
msgid "Colon"
msgstr ""
msgid "Semicolon"
msgstr ""
msgid "Exclamation mark"
msgstr ""
@ -1678,6 +1681,12 @@ msgid ""
"%s"
msgstr ""
msgid "< Default >"
msgstr ""
msgid "Skins"
msgstr ""
msgid "Other 8 bit"
msgstr "Ôte 8 bit"
@ -1762,12 +1771,6 @@ msgstr ""
msgid "Configure options"
msgstr "Apontyî les tchûzes"
msgid "< Default >"
msgstr ""
msgid "Skins"
msgstr ""
msgid "Skin:"
msgstr ""

View File

@ -13,7 +13,7 @@ msgid ""
msgstr ""
"Project-Id-Version: Midnight Commander\n"
"Report-Msgid-Bugs-To: http://www.midnight-commander.org/\n"
"POT-Creation-Date: 2014-09-27 20:13+0400\n"
"POT-Creation-Date: 2014-12-10 13:09+0300\n"
"PO-Revision-Date: 2014-09-04 10:10+0000\n"
"Last-Translator: Piotr Drąg <piotrdrag@gmail.com>\n"
"Language-Team: Chinese (China) (http://www.transifex.com/projects/p/mc/"
@ -354,6 +354,9 @@ msgstr "撇号"
msgid "Colon"
msgstr "冒号"
msgid "Semicolon"
msgstr ""
msgid "Exclamation mark"
msgstr "感叹号"
@ -1752,6 +1755,12 @@ msgstr ""
"无法 chown“%s”\n"
"%s"
msgid "< Default >"
msgstr ""
msgid "Skins"
msgstr ""
msgid "Other 8 bit"
msgstr "其它 8 位"
@ -1836,12 +1845,6 @@ msgstr "自动保存设置(&U)"
msgid "Configure options"
msgstr "配置选项"
msgid "< Default >"
msgstr ""
msgid "Skins"
msgstr ""
msgid "Skin:"
msgstr ""

View File

@ -8,7 +8,7 @@ msgid ""
msgstr ""
"Project-Id-Version: Midnight Commander\n"
"Report-Msgid-Bugs-To: http://www.midnight-commander.org/\n"
"POT-Creation-Date: 2014-09-27 20:13+0400\n"
"POT-Creation-Date: 2014-12-10 13:09+0300\n"
"PO-Revision-Date: 2014-09-04 10:10+0000\n"
"Last-Translator: Piotr Drąg <piotrdrag@gmail.com>\n"
"Language-Team: Chinese (Taiwan) (http://www.transifex.com/projects/p/mc/"
@ -333,6 +333,9 @@ msgstr ""
msgid "Colon"
msgstr ""
msgid "Semicolon"
msgstr ""
msgid "Exclamation mark"
msgstr ""
@ -1682,6 +1685,12 @@ msgid ""
"%s"
msgstr ""
msgid "< Default >"
msgstr ""
msgid "Skins"
msgstr ""
msgid "Other 8 bit"
msgstr "其它八位元"
@ -1766,12 +1775,6 @@ msgstr ""
msgid "Configure options"
msgstr "設定選項"
msgid "< Default >"
msgstr ""
msgid "Skins"
msgstr ""
msgid "Skin:"
msgstr ""

View File

@ -35,7 +35,7 @@
#include <config.h>
#include <stdlib.h>
#include <sys/types.h>
#include <string.h> /* strcmp() */
#include "lib/global.h"
#include "lib/widget.h" /* Listbox */
@ -67,19 +67,23 @@ pstrcmp (const void *p1, const void *p2)
/* --------------------------------------------------------------------------------------------- */
static int
exec_edit_syntax_dialog (const char **names, const char *current_syntax)
exec_edit_syntax_dialog (const GPtrArray * names, const char *current_syntax)
{
size_t i;
Listbox *syntaxlist;
Listbox *syntaxlist = create_listbox_window (LIST_LINES, MAX_ENTRY_LEN,
_("Choose syntax highlighting"), NULL);
syntaxlist = create_listbox_window (LIST_LINES, MAX_ENTRY_LEN,
_("Choose syntax highlighting"), NULL);
LISTBOX_APPEND_TEXT (syntaxlist, 'A', _("< Auto >"), NULL);
LISTBOX_APPEND_TEXT (syntaxlist, 'R', _("< Reload Current Syntax >"), NULL);
for (i = 0; names[i] != NULL; i++)
for (i = 0; i < names->len; i++)
{
LISTBOX_APPEND_TEXT (syntaxlist, 0, names[i], NULL);
if ((current_syntax != NULL) && (strcmp (names[i], current_syntax) == 0))
const char *name;
name = g_ptr_array_index (names, i);
LISTBOX_APPEND_TEXT (syntaxlist, 0, name, NULL);
if (current_syntax != NULL && strcmp (name, current_syntax) == 0)
listbox_select_entry (syntaxlist->list, i + N_DFLT_ENTRIES);
}
@ -93,27 +97,27 @@ exec_edit_syntax_dialog (const char **names, const char *current_syntax)
void
edit_syntax_dialog (WEdit * edit)
{
char *current_syntax;
int old_auto_syntax, syntax;
char **names;
gboolean force_reload = FALSE;
size_t count;
GPtrArray *names;
int syntax;
current_syntax = g_strdup (edit->syntax_type);
old_auto_syntax = option_auto_syntax;
names = g_new0 (char *, 1);
names = g_ptr_array_new ();
/* We fill the list of syntax files every time the editor is invoked.
Instead we could save the list to a file and update it once the syntax
file gets updated (either by testing or by explicit user command). */
edit_load_syntax (NULL, &names, NULL);
count = g_strv_length (names);
qsort (names, count, sizeof (char *), pstrcmp);
edit_load_syntax (NULL, names, NULL);
g_ptr_array_sort (names, pstrcmp);
syntax = exec_edit_syntax_dialog ((const char **) names, current_syntax);
syntax = exec_edit_syntax_dialog (names, edit->syntax_type);
if (syntax >= 0)
{
gboolean force_reload = FALSE;
char *current_syntax;
int old_auto_syntax;
current_syntax = g_strdup (edit->syntax_type);
old_auto_syntax = option_auto_syntax;
switch (syntax)
{
case 0: /* auto syntax */
@ -125,19 +129,20 @@ edit_syntax_dialog (WEdit * edit)
default:
option_auto_syntax = 0;
g_free (edit->syntax_type);
edit->syntax_type = g_strdup (names[syntax - N_DFLT_ENTRIES]);
edit->syntax_type = g_strdup (g_ptr_array_index (names, syntax - N_DFLT_ENTRIES));
}
/* Load or unload syntax rules if the option has changed */
if ((option_auto_syntax && !old_auto_syntax) || old_auto_syntax ||
(current_syntax && edit->syntax_type &&
(strcmp (current_syntax, edit->syntax_type) != 0)) || force_reload)
if (force_reload || (option_auto_syntax && !old_auto_syntax) || old_auto_syntax ||
(current_syntax != NULL && edit->syntax_type != NULL &&
strcmp (current_syntax, edit->syntax_type) != 0))
edit_load_syntax (edit, NULL, edit->syntax_type);
g_free (current_syntax);
}
g_strfreev (names);
g_ptr_array_foreach (names, (GFunc) g_free, NULL);
g_ptr_array_free (names, TRUE);
}
/* --------------------------------------------------------------------------------------------- */

View File

@ -264,7 +264,7 @@ void edit_paste_from_history (WEdit * edit);
void edit_set_filename (WEdit * edit, const vfs_path_t * name_vpath);
void edit_load_syntax (WEdit * edit, char ***pnames, const char *type);
void edit_load_syntax (WEdit * edit, GPtrArray * pnames, const char *type);
void edit_free_syntax_rules (WEdit * edit);
int edit_get_syntax_color (WEdit * edit, off_t byte_index);

View File

@ -256,7 +256,7 @@ edit_get_filter (const vfs_path_t * filename_vpath)
if (i < 0)
return NULL;
quoted_name = name_quote (vfs_path_as_str (filename_vpath), 0);
quoted_name = name_quote (vfs_path_as_str (filename_vpath), FALSE);
p = g_strdup_printf (all_filters[i].read, quoted_name);
g_free (quoted_name);
return p;
@ -1810,7 +1810,7 @@ edit_get_write_filter (const vfs_path_t * write_name_vpath, const vfs_path_t * f
return NULL;
path_element = vfs_path_get_by_index (write_name_vpath, -1);
writename = name_quote (path_element->path, 0);
writename = name_quote (path_element->path, FALSE);
p = g_strdup_printf (all_filters[i].write, writename);
g_free (writename);
return p;

View File

@ -1109,9 +1109,9 @@ pipe_mail (const edit_buffer_t * buf, char *to, char *subject, char *cc)
FILE *p = 0;
char *s;
to = name_quote (to, 0);
subject = name_quote (subject, 0);
cc = name_quote (cc, 0);
to = name_quote (to, FALSE);
subject = name_quote (subject, FALSE);
cc = name_quote (cc, FALSE);
s = g_strconcat ("mail -s ", subject, *cc ? " -c " : "", cc, " ", to, (char *) NULL);
g_free (to);
g_free (subject);

View File

@ -153,7 +153,7 @@ struct WEdit
/* syntax higlighting */
GSList *syntax_marker;
struct context_rule **rules;
GPtrArray *rules;
off_t last_get_rule;
edit_syntax_rule_t rule;
char *syntax_type; /* description of syntax highlighting type being used */

View File

@ -8,7 +8,7 @@
Paul Sheer, 1998
Egmont Koblinger <egmont@gmail.com>, 2010
Slava Zanko <slavazanko@gmail.com>, 2013
Andrew Borodin <aborodin@vmail.ru>, 2013
Andrew Borodin <aborodin@vmail.ru>, 2013, 2014
This file is part of the Midnight Commander.
@ -95,19 +95,21 @@ int option_auto_syntax = 1;
#define check_a {if(!*a){result=line;break;}}
#define check_not_a {if(*a){result=line;break;}}
#define SYNTAX_KEYWORD(x) ((syntax_keyword_t *) (x))
#define CONTEXT_RULE(x) ((context_rule_t *) (x))
/*** file scope type declarations ****************************************************************/
struct key_word
typedef struct
{
char *keyword;
unsigned char first;
char *whole_word_chars_left;
char *whole_word_chars_right;
long line_start;
int color;
};
} syntax_keyword_t;
struct context_rule
typedef struct
{
char *left;
unsigned char first_left;
@ -121,8 +123,8 @@ struct context_rule
char *keyword_first_chars;
gboolean spelling;
/* first word is word[1] */
struct key_word **keyword;
};
GPtrArray *keyword;
} context_rule_t;
typedef struct
{
@ -134,9 +136,45 @@ typedef struct
static char *error_file_name = NULL;
/* --------------------------------------------------------------------------------------------- */
/*** file scope functions ************************************************************************/
/* --------------------------------------------------------------------------------------------- */
static void
syntax_keyword_free (gpointer keyword)
{
syntax_keyword_t *k = SYNTAX_KEYWORD (keyword);
g_free (k->keyword);
g_free (k->whole_word_chars_left);
g_free (k->whole_word_chars_right);
g_free (k);
}
/* --------------------------------------------------------------------------------------------- */
static void
context_rule_free (gpointer rule)
{
context_rule_t *r = CONTEXT_RULE (rule);
g_free (r->left);
g_free (r->right);
g_free (r->whole_word_chars_left);
g_free (r->whole_word_chars_right);
g_free (r->keyword_first_chars);
if (r->keyword != NULL)
{
g_ptr_array_foreach (r->keyword, (GFunc) syntax_keyword_free, NULL);
g_ptr_array_free (r->keyword, TRUE);
}
g_free (r);
}
/* --------------------------------------------------------------------------------------------- */
static gint
mc_defines_destroy (gpointer key, gpointer value, gpointer data)
{
@ -336,7 +374,7 @@ xx_strchr (const WEdit * edit, const unsigned char *s, int char_byte)
static void
apply_rules_going_right (WEdit * edit, off_t i)
{
struct context_rule *r;
context_rule_t *r;
int c;
gboolean contextchanged = FALSE;
gboolean found_left = FALSE, found_right = FALSE;
@ -368,7 +406,7 @@ apply_rules_going_right (WEdit * edit, off_t i)
{
off_t e;
r = edit->rules[_rule.context];
r = CONTEXT_RULE (g_ptr_array_index (edit->rules, _rule.context));
if (r->first_right == c && (edit->rule.border & RULE_ON_RIGHT_BORDER) == 0
&& (e =
compare_word_to_right (edit, i, r->right, r->whole_word_chars_left,
@ -401,18 +439,18 @@ apply_rules_going_right (WEdit * edit, off_t i)
{
const char *p;
r = edit->rules[_rule.context];
r = CONTEXT_RULE (g_ptr_array_index (edit->rules, _rule.context));
p = r->keyword_first_chars;
if (p != NULL)
while (*(p = xx_strchr (edit, (unsigned char *) p + 1, c)) != '\0')
{
struct key_word *k;
syntax_keyword_t *k;
int count;
off_t e;
count = p - r->keyword_first_chars;
k = r->keyword[count];
k = SYNTAX_KEYWORD (g_ptr_array_index (r->keyword, count));
e = compare_word_to_right (edit, i, k->keyword, k->whole_word_chars_left,
k->whole_word_chars_right, k->line_start);
if (e > 0)
@ -441,7 +479,7 @@ apply_rules_going_right (WEdit * edit, off_t i)
}
else if ((edit->rule.border & RULE_ON_LEFT_BORDER) != 0)
{
r = edit->rules[_rule._context];
r = CONTEXT_RULE (g_ptr_array_index (edit->rules, _rule._context));
_rule.border = 0;
if (r->between_delimiters)
{
@ -469,12 +507,11 @@ apply_rules_going_right (WEdit * edit, off_t i)
if (!found_right)
{
int count;
struct context_rule **rules = edit->rules;
size_t count;
for (count = 1; rules[count] != NULL; count++)
for (count = 1; count < edit->rules->len; count++)
{
r = rules[count];
r = CONTEXT_RULE (g_ptr_array_index (edit->rules, count));
if (r->first_left == c)
{
off_t e;
@ -504,17 +541,17 @@ apply_rules_going_right (WEdit * edit, off_t i)
{
const char *p;
r = edit->rules[_rule.context];
r = CONTEXT_RULE (g_ptr_array_index (edit->rules, _rule.context));
p = r->keyword_first_chars;
while (*(p = xx_strchr (edit, (unsigned char *) p + 1, c)) != '\0')
{
struct key_word *k;
syntax_keyword_t *k;
int count;
off_t e;
count = p - r->keyword_first_chars;
k = r->keyword[count];
k = SYNTAX_KEYWORD (g_ptr_array_index (r->keyword, count));
e = compare_word_to_right (edit, i, k->keyword, k->whole_word_chars_left,
k->whole_word_chars_right, k->line_start);
if (e > 0)
@ -591,10 +628,16 @@ edit_get_rule (WEdit * edit, off_t byte_index)
/* --------------------------------------------------------------------------------------------- */
static inline int
static int
translate_rule_to_color (const WEdit * edit, const edit_syntax_rule_t * rule)
{
return edit->rules[rule->context]->keyword[rule->keyword]->color;
syntax_keyword_t *k;
context_rule_t *r;
r = CONTEXT_RULE (g_ptr_array_index (edit->rules, rule->context));
k = SYNTAX_KEYWORD (g_ptr_array_index (r->keyword, rule->keyword));
return k->color;
}
/* --------------------------------------------------------------------------------------------- */
@ -884,12 +927,9 @@ edit_read_syntax_rules (WEdit * edit, FILE * f, char **args, int args_size)
char whole_left[512];
char *l = 0;
int save_line = 0, line = 0;
struct context_rule **r, *c = NULL;
int num_words = -1, num_contexts = -1;
context_rule_t *c = NULL;
gboolean no_words = TRUE;
int result = 0;
int alloc_contexts = MAX_CONTEXTS,
alloc_words_per_context = MAX_WORDS_PER_CONTEXT,
max_alloc_words_per_context = MAX_WORDS_PER_CONTEXT;
args[0] = NULL;
edit->is_case_insensitive = FALSE;
@ -897,7 +937,7 @@ edit_read_syntax_rules (WEdit * edit, FILE * f, char **args, int args_size)
strcpy (whole_left, "abcdefghijklmnopqrstuvwxyzABCDEFGHIJKLMNOPQRSTUVWXYZ_01234567890");
strcpy (whole_right, "abcdefghijklmnopqrstuvwxyzABCDEFGHIJKLMNOPQRSTUVWXYZ_01234567890");
r = edit->rules = g_malloc0 (alloc_contexts * sizeof (struct context_rule *));
edit->rules = g_ptr_array_new ();
if (!edit->defines)
edit->defines = g_tree_new ((GCompareFunc) strcmp);
@ -982,24 +1022,26 @@ edit_read_syntax_rules (WEdit * edit, FILE * f, char **args, int args_size)
}
else if (strcmp (args[0], "context") == 0)
{
syntax_keyword_t *k;
check_a;
if (num_contexts == -1)
if (edit->rules->len == 0)
{
/* first context is the default */
if (strcmp (*a, "default") != 0)
{ /* first context is the default */
break_a;
}
a++;
c = r[0] = g_malloc0 (sizeof (struct context_rule));
c = g_new0 (context_rule_t, 1);
g_ptr_array_add (edit->rules, c);
c->left = g_strdup (" ");
c->right = g_strdup (" ");
num_contexts = 0;
}
else
{
/* Terminate previous context. */
r[num_contexts - 1]->keyword[num_words] = NULL;
c = r[num_contexts] = g_malloc0 (sizeof (struct context_rule));
/* Start new context. */
c = g_new0 (context_rule_t, 1);
g_ptr_array_add (edit->rules, c);
if (strcmp (*a, "exclusive") == 0)
{
a++;
@ -1041,35 +1083,26 @@ edit_read_syntax_rules (WEdit * edit, FILE * f, char **args, int args_size)
c->first_left = *c->left;
c->first_right = *c->right;
}
c->keyword = g_malloc (alloc_words_per_context * sizeof (struct key_word *));
num_words = 1;
c->keyword[0] = g_malloc0 (sizeof (struct key_word));
c->keyword = g_ptr_array_new ();
k = g_new0 (syntax_keyword_t, 1);
g_ptr_array_add (c->keyword, k);
no_words = FALSE;
subst_defines (edit->defines, a, &args[1024]);
fg = *a;
if (*a != '\0')
if (*a != NULL)
a++;
bg = *a;
if (*a != '\0')
if (*a != NULL)
a++;
attrs = *a;
if (*a != '\0')
if (*a != NULL)
a++;
g_strlcpy (last_fg, fg != NULL ? fg : "", sizeof (last_fg));
g_strlcpy (last_bg, bg != NULL ? bg : "", sizeof (last_bg));
g_strlcpy (last_attrs, attrs != NULL ? attrs : "", sizeof (last_attrs));
c->keyword[0]->color = this_try_alloc_color_pair (fg, bg, attrs);
c->keyword[0]->keyword = g_strdup (" ");
k->color = this_try_alloc_color_pair (fg, bg, attrs);
k->keyword = g_strdup (" ");
check_not_a;
alloc_words_per_context = MAX_WORDS_PER_CONTEXT;
if (++num_contexts >= alloc_contexts)
{
struct context_rule **tmp;
alloc_contexts += 128;
tmp = g_realloc (r, alloc_contexts * sizeof (struct context_rule *));
r = tmp;
}
}
else if (strcmp (args[0], "spellcheck") == 0)
{
@ -1082,12 +1115,15 @@ edit_read_syntax_rules (WEdit * edit, FILE * f, char **args, int args_size)
}
else if (strcmp (args[0], "keyword") == 0)
{
struct key_word *k;
context_rule_t *last_rule;
syntax_keyword_t *k;
if (num_words == -1)
if (no_words)
break_a;
check_a;
k = r[num_contexts - 1]->keyword[num_words] = g_malloc0 (sizeof (struct key_word));
last_rule = CONTEXT_RULE (g_ptr_array_index (edit->rules, edit->rules->len - 1));
k = g_new0 (syntax_keyword_t, 1);
g_ptr_array_add (last_rule->keyword, k);
if (strcmp (*a, "whole") == 0)
{
a++;
@ -1116,16 +1152,15 @@ edit_read_syntax_rules (WEdit * edit, FILE * f, char **args, int args_size)
break_a;
}
k->keyword = g_strdup (*a++);
k->first = *k->keyword;
subst_defines (edit->defines, a, &args[1024]);
fg = *a;
if (*a != '\0')
if (*a != NULL)
a++;
bg = *a;
if (*a != '\0')
if (*a != NULL)
a++;
attrs = *a;
if (*a != '\0')
if (*a != NULL)
a++;
if (fg == NULL)
fg = last_fg;
@ -1135,19 +1170,6 @@ edit_read_syntax_rules (WEdit * edit, FILE * f, char **args, int args_size)
attrs = last_attrs;
k->color = this_try_alloc_color_pair (fg, bg, attrs);
check_not_a;
if (++num_words >= alloc_words_per_context)
{
struct key_word **tmp;
alloc_words_per_context += 1024;
if (alloc_words_per_context > max_alloc_words_per_context)
max_alloc_words_per_context = alloc_words_per_context;
tmp = g_realloc (c->keyword, alloc_words_per_context * sizeof (struct key_word *));
c->keyword = tmp;
}
}
else if (*(args[0]) == '#')
{
@ -1186,41 +1208,43 @@ edit_read_syntax_rules (WEdit * edit, FILE * f, char **args, int args_size)
free_args (args);
MC_PTR_FREE (l);
/* Terminate context array. */
if (num_contexts > 0)
if (edit->rules->len == 0)
{
r[num_contexts - 1]->keyword[num_words] = NULL;
r[num_contexts] = NULL;
g_ptr_array_free (edit->rules, TRUE);
edit->rules = NULL;
}
if (edit->rules[0] == NULL)
MC_PTR_FREE (edit->rules);
if (result == 0)
{
int i;
char *first_chars;
size_t i;
GString *first_chars;
if (num_contexts == -1)
if (edit->rules == NULL)
return line;
first_chars = g_malloc0 (max_alloc_words_per_context + 2);
first_chars = g_string_sized_new (32);
for (i = 0; edit->rules[i] != NULL; i++)
/* collect first character of keywords */
for (i = 0; i < edit->rules->len; i++)
{
char *p;
int j;
size_t j;
c = edit->rules[i];
p = first_chars;
*p++ = (char) 1;
for (j = 1; c->keyword[j] != NULL; j++)
*p++ = c->keyword[j]->first;
*p = '\0';
c->keyword_first_chars = g_strdup (first_chars);
g_string_set_size (first_chars, 0);
c = CONTEXT_RULE (g_ptr_array_index (edit->rules, i));
g_string_append_c (first_chars, (char) 1);
for (j = 1; j < c->keyword->len; j++)
{
syntax_keyword_t *k;
k = SYNTAX_KEYWORD (g_ptr_array_index (c->keyword, j));
g_string_append_c (first_chars, k->keyword[0]);
}
c->keyword_first_chars = g_strndup (first_chars->str, first_chars->len);
}
g_free (first_chars);
g_string_free (first_chars, TRUE);
}
return result;
@ -1230,18 +1254,15 @@ edit_read_syntax_rules (WEdit * edit, FILE * f, char **args, int args_size)
/* returns -1 on file error, line number on error in file syntax */
static int
edit_read_syntax_file (WEdit * edit, char ***pnames, const char *syntax_file,
edit_read_syntax_file (WEdit * edit, GPtrArray * pnames, const char *syntax_file,
const char *editor_file, const char *first_line, const char *type)
{
#define NENTRIES 30
FILE *f, *g = NULL;
char *args[1024], *l = NULL;
long line = 0;
int result = 0;
int count = 0;
char *lib_file;
gboolean found = FALSE;
char **tmpnames = NULL;
f = fopen (syntax_file, "r");
if (f == NULL)
@ -1290,20 +1311,11 @@ edit_read_syntax_file (WEdit * edit, char ***pnames, const char *syntax_file,
result = line;
break;
}
if (pnames && *pnames)
if (pnames != NULL)
{
/* 1: just collecting a list of names of rule sets */
/* Reallocate the list if required */
if (count % NENTRIES == 0)
{
tmpnames =
(char **) g_try_realloc (*pnames, (count + NENTRIES + 1) * sizeof (char *));
if (tmpnames == NULL)
break;
*pnames = tmpnames;
}
(*pnames)[count++] = g_strdup (args[2]);
(*pnames)[count] = NULL;
g_ptr_array_add (pnames, g_strdup (args[2]));
}
else if (type)
{
@ -1342,12 +1354,17 @@ edit_read_syntax_file (WEdit * edit, char ***pnames, const char *syntax_file,
g_free (edit->syntax_type);
edit->syntax_type = g_strdup (syntax_type);
/* if there are no rules then turn off syntax highlighting for speed */
if (!g && !edit->rules[1])
if (!edit->rules[0]->keyword[1] && !edit->rules[0]->spelling)
if (g == NULL && edit->rules->len == 1)
{
context_rule_t *r0;
r0 = CONTEXT_RULE (g_ptr_array_index (edit->rules, 0));
if (r0->keyword->len == 1 && !r0->spelling)
{
edit_free_syntax_rules (edit);
break;
}
}
}
if (g == NULL)
@ -1416,42 +1433,23 @@ edit_get_syntax_color (WEdit * edit, off_t byte_index)
void
edit_free_syntax_rules (WEdit * edit)
{
size_t i, j;
if (!edit)
if (edit == NULL)
return;
if (edit->defines)
if (edit->defines != NULL)
destroy_defines (&edit->defines);
if (!edit->rules)
if (edit->rules == NULL)
return;
edit_get_rule (edit, -1);
MC_PTR_FREE (edit->syntax_type);
for (i = 0; edit->rules[i]; i++)
{
if (edit->rules[i]->keyword)
{
for (j = 0; edit->rules[i]->keyword[j]; j++)
{
MC_PTR_FREE (edit->rules[i]->keyword[j]->keyword);
MC_PTR_FREE (edit->rules[i]->keyword[j]->whole_word_chars_left);
MC_PTR_FREE (edit->rules[i]->keyword[j]->whole_word_chars_right);
MC_PTR_FREE (edit->rules[i]->keyword[j]);
}
}
MC_PTR_FREE (edit->rules[i]->left);
MC_PTR_FREE (edit->rules[i]->right);
MC_PTR_FREE (edit->rules[i]->whole_word_chars_left);
MC_PTR_FREE (edit->rules[i]->whole_word_chars_right);
MC_PTR_FREE (edit->rules[i]->keyword);
MC_PTR_FREE (edit->rules[i]->keyword_first_chars);
MC_PTR_FREE (edit->rules[i]);
}
g_ptr_array_foreach (edit->rules, (GFunc) context_rule_free, NULL);
g_ptr_array_free (edit->rules, TRUE);
edit->rules = NULL;
g_slist_free_full (edit->syntax_marker, g_free);
edit->syntax_marker = NULL;
MC_PTR_FREE (edit->rules);
tty_color_free_all_tmp ();
}
@ -1463,7 +1461,7 @@ edit_free_syntax_rules (WEdit * edit)
* type must be edit->syntax_type or NULL
*/
void
edit_load_syntax (WEdit * edit, char ***pnames, const char *type)
edit_load_syntax (WEdit * edit, GPtrArray * pnames, const char *type)
{
int r;
char *f = NULL;
@ -1483,7 +1481,7 @@ edit_load_syntax (WEdit * edit, char ***pnames, const char *type)
if (!tty_use_colors ())
return;
if (!option_syntax_highlighting && (!pnames || !*pnames))
if (!option_syntax_highlighting && (pnames == NULL || pnames->len == 0))
return;
if (edit != NULL && edit->filename_vpath == NULL)

View File

@ -103,8 +103,6 @@ static int listing_user_hotkey = 'u';
static unsigned long panel_listing_types_id, panel_user_format_id;
static unsigned long mini_user_status_id, mini_user_format_id;
static unsigned long skin_name_id;
#ifdef HAVE_CHARSET
static int new_display_codepage;
#endif /* HAVE_CHARSET */
@ -151,6 +149,99 @@ configure_callback (Widget * w, Widget * sender, widget_msg_t msg, int parm, voi
/* --------------------------------------------------------------------------------------------- */
static void
skin_apply (const gchar * skin_override)
{
GError *mcerror = NULL;
mc_skin_deinit ();
mc_skin_init (skin_override, &mcerror);
mc_fhl_free (&mc_filehighlight);
mc_filehighlight = mc_fhl_new (TRUE);
dlg_set_default_colors ();
input_set_default_colors ();
if (mc_global.mc_run_mode == MC_RUN_FULL)
command_set_default_colors ();
panel_deinit ();
panel_init ();
repaint_screen ();
mc_error_message (&mcerror);
}
/* --------------------------------------------------------------------------------------------- */
static const gchar *
skin_name_to_label (const gchar * name)
{
if (strcmp (name, "default") == 0)
return _("< Default >");
return name;
}
/* --------------------------------------------------------------------------------------------- */
static int
sel_skin_button (WButton * button, int action)
{
int result;
WListbox *skin_list;
WDialog *skin_dlg;
const gchar *skin_name;
int lxx, lyy;
unsigned int i;
unsigned int pos = 1;
(void) action;
lxx = COLS / 2;
lyy = (LINES - 13) / 2;
skin_dlg =
dlg_create (TRUE, lyy, lxx, 13, 24, dialog_colors, NULL, NULL, "[Appearance]", _("Skins"),
DLG_COMPACT);
skin_list = listbox_new (1, 1, 11, 22, FALSE, NULL);
skin_name = "default";
listbox_add_item (skin_list, LISTBOX_APPEND_AT_END, 0, skin_name_to_label (skin_name),
(void *) skin_name);
if (strcmp (skin_name, current_skin_name) == 0)
listbox_select_entry (skin_list, 0);
for (i = 0; i < skin_names->len; i++)
{
skin_name = g_ptr_array_index (skin_names, i);
if (strcmp (skin_name, "default") != 0)
{
listbox_add_item (skin_list, LISTBOX_APPEND_AT_END, 0, skin_name_to_label (skin_name),
(void *) skin_name);
if (strcmp (skin_name, current_skin_name) == 0)
listbox_select_entry (skin_list, pos);
pos++;
}
}
add_widget (skin_dlg, skin_list);
result = dlg_run (skin_dlg);
if (result == B_ENTER)
{
gchar *skin_label;
listbox_get_current (skin_list, &skin_label, (void **) &skin_name);
g_free (current_skin_name);
current_skin_name = g_strdup (skin_name);
skin_apply (skin_name);
button_set_text (button, str_fit_to_term (skin_label, 20, J_LEFT_FIT));
}
dlg_destroy (skin_dlg);
return 0;
}
/* --------------------------------------------------------------------------------------------- */
static cb_ret_t
panel_listing_callback (Widget * w, Widget * sender, widget_msg_t msg, int parm, void *data)
{
@ -518,101 +609,6 @@ configure_box (void)
/* --------------------------------------------------------------------------------------------- */
static void
skin_apply (const gchar * skin_override)
{
GError *mcerror = NULL;
mc_skin_deinit ();
mc_skin_init (skin_override, &mcerror);
mc_fhl_free (&mc_filehighlight);
mc_filehighlight = mc_fhl_new (TRUE);
dlg_set_default_colors ();
input_set_default_colors ();
if (mc_global.mc_run_mode == MC_RUN_FULL)
command_set_default_colors ();
panel_deinit ();
panel_init ();
repaint_screen ();
mc_error_message (&mcerror);
}
/* --------------------------------------------------------------------------------------------- */
static const gchar *
skin_name_to_label (const gchar * name)
{
if (strcmp (name, "default") == 0)
return _("< Default >");
return name;
}
/* --------------------------------------------------------------------------------------------- */
static int
sel_skin_button (WButton * button, int action)
{
int result;
WListbox *skin_list;
WDialog *skin_dlg;
const gchar *skin_name;
int lxx, lyy;
unsigned int i;
unsigned int pos = 1;
(void) action;
lxx = COLS / 2;
lyy = (LINES - 13) / 2;
skin_dlg =
dlg_create (TRUE, lyy, lxx, 13, 24, dialog_colors, NULL, NULL, "[Appearance]", _("Skins"),
DLG_COMPACT);
skin_list = listbox_new (1, 1, 11, 22, FALSE, NULL);
skin_name = "default";
listbox_add_item (skin_list, LISTBOX_APPEND_AT_END, 0, skin_name_to_label (skin_name),
(void *) skin_name);
if (strcmp (skin_name, current_skin_name) == 0)
listbox_select_entry (skin_list, 0);
for (i = 0; i < skin_names->len; i++)
{
skin_name = g_ptr_array_index (skin_names, i);
if (strcmp (skin_name, "default") != 0)
{
listbox_add_item (skin_list, LISTBOX_APPEND_AT_END, 0, skin_name_to_label (skin_name),
(void *) skin_name);
if (strcmp (skin_name, current_skin_name) == 0)
listbox_select_entry (skin_list, pos);
pos++;
}
}
add_widget (skin_dlg, skin_list);
result = dlg_run (skin_dlg);
if (result == B_ENTER)
{
Widget *w;
gchar *skin_label;
listbox_get_current (skin_list, &skin_label, (void **) &skin_name);
g_free (current_skin_name);
current_skin_name = g_strdup (skin_name);
skin_apply (skin_name);
w = dlg_find_by_id (WIDGET (button)->owner, skin_name_id);
button_set_text (BUTTON (w), str_fit_to_term (skin_label, 20, J_LEFT_FIT));
}
dlg_destroy (skin_dlg);
return 0;
}
/* --------------------------------------------------------------------------------------------- */
void
appearance_box (void)
{
@ -626,7 +622,7 @@ appearance_box (void)
QUICK_LABEL (N_("Skin:"), NULL),
QUICK_NEXT_COLUMN,
QUICK_BUTTON (str_fit_to_term (skin_name_to_label (current_skin_name), 20, J_LEFT_FIT),
B_USER, sel_skin_button, &skin_name_id),
B_USER, sel_skin_button, NULL),
QUICK_STOP_COLUMNS,
QUICK_BUTTONS_OK_CANCEL,
QUICK_END

View File

@ -508,7 +508,7 @@ command_insert (WInput * in, const char *text, gboolean insert_extra_space)
{
char *quoted_text;
quoted_text = name_quote (text, 1);
quoted_text = name_quote (text, TRUE);
input_insert (in, quoted_text, insert_extra_space);
g_free (quoted_text);
}

View File

@ -78,7 +78,7 @@
/*** file scope type declarations ****************************************************************/
typedef char *(*quote_func_t) (const char *name, int quote_percent);
typedef char *(*quote_func_t) (const char *name, gboolean quote_percent);
/*** file scope variables ************************************************************************/
@ -138,7 +138,7 @@ static char *
exec_get_file_name (const vfs_path_t * filename_vpath)
{
if (!do_local_copy)
return quote_func (vfs_path_get_last_path_str (filename_vpath), 0);
return quote_func (vfs_path_get_last_path_str (filename_vpath), FALSE);
if (localfilecopy_vpath == NULL)
{
@ -151,7 +151,7 @@ exec_get_file_name (const vfs_path_t * filename_vpath)
localmtime = mystat.st_mtime;
}
return quote_func (vfs_path_get_last_path_str (localfilecopy_vpath), 0);
return quote_func (vfs_path_get_last_path_str (localfilecopy_vpath), FALSE);
}
/* --------------------------------------------------------------------------------------------- */
@ -574,7 +574,7 @@ get_file_type_local (const vfs_path_t * filename_vpath, char *buf, int buflen)
char *tmp;
int ret;
tmp = name_quote (vfs_path_get_last_path_str (filename_vpath), 0);
tmp = name_quote (vfs_path_get_last_path_str (filename_vpath), FALSE);
ret = get_popen_information (FILE_CMD, tmp, buf, buflen);
g_free (tmp);
@ -594,8 +594,8 @@ get_file_encoding_local (const vfs_path_t * filename_vpath, char *buf, int bufle
char *tmp, *lang, *args;
int ret;
tmp = name_quote (vfs_path_get_last_path_str (filename_vpath), 0);
lang = name_quote (autodetect_codeset, 0);
tmp = name_quote (vfs_path_get_last_path_str (filename_vpath), FALSE);
lang = name_quote (autodetect_codeset, FALSE);
args = g_strconcat (" -L", lang, " -i ", tmp, (char *) NULL);
ret = get_popen_information ("enca", args, buf, buflen);

View File

@ -249,8 +249,7 @@ parse_ignore_dirs (const char *ignore_dirs)
if (find_ignore_dirs[r][0] == '\0')
{
/* empty entry -- skip it */
g_free (find_ignore_dirs[r]);
find_ignore_dirs[r] = NULL;
MC_PTR_FREE (find_ignore_dirs[r]);
continue;
}

View File

@ -157,6 +157,12 @@
#include <sys/mntent.h>
#endif
#ifdef MOUNTED_PROC_MOUNTINFO
/* Use /proc/self/mountinfo instead of /proc/self/mounts (/etc/mtab)
* on Linux, if available */
#include <libmount/libmount.h>
#endif
#ifndef HAVE_HASMNTOPT
#define hasmntopt(mnt, opt) ((char *) 0)
#endif
@ -227,10 +233,9 @@
we grant an exception to any with "bind" in its list of mount options.
I.e., those are *not* dummy entries. */
#ifdef MOUNTED_GETMNTENT1
#define ME_DUMMY(Fs_name, Fs_type, Fs_ent) \
#define ME_DUMMY(Fs_name, Fs_type, Bind) \
(ME_DUMMY_0 (Fs_name, Fs_type) \
|| (strcmp (Fs_type, "none") == 0 \
&& !hasmntopt (Fs_ent, "bind")))
|| (strcmp (Fs_type, "none") == 0 && !Bind))
#else
#define ME_DUMMY(Fs_name, Fs_type) \
(ME_DUMMY_0 (Fs_name, Fs_type) || strcmp (Fs_type, "none") == 0)
@ -653,32 +658,79 @@ read_file_system_list (int need_fs_type)
#ifdef MOUNTED_GETMNTENT1 /* GNU/Linux, 4.3BSD, SunOS, HP-UX, Dynix, Irix. */
{
struct mntent *mnt;
const char *table = MOUNTED;
FILE *fp;
#ifdef MOUNTED_PROC_MOUNTINFO
struct libmnt_table *fstable = NULL;
fp = setmntent (table, "r");
if (fp == NULL)
return NULL;
fstable = mnt_new_table_from_file ("/proc/self/mountinfo");
while ((mnt = getmntent (fp)))
if (fstable != NULL)
{
me = g_malloc (sizeof (*me));
me->me_devname = g_strdup (mnt->mnt_fsname);
me->me_mountdir = g_strdup (mnt->mnt_dir);
me->me_type = g_strdup (mnt->mnt_type);
me->me_type_malloced = 1;
me->me_dummy = ME_DUMMY (me->me_devname, me->me_type, mnt);
me->me_remote = ME_REMOTE (me->me_devname, me->me_type);
me->me_dev = dev_from_mount_options (mnt->mnt_opts);
struct libmnt_fs *fs;
struct libmnt_iter *iter;
iter = mnt_new_iter (MNT_ITER_FORWARD);
while (iter && mnt_table_next_fs (fstable, iter, &fs) == 0)
{
me = g_malloc (sizeof *me);
me->me_devname = g_strdup (mnt_fs_get_source (fs));
me->me_mountdir = g_strdup (mnt_fs_get_target (fs));
me->me_type = g_strdup (mnt_fs_get_fstype (fs));
me->me_type_malloced = 1;
me->me_dev = mnt_fs_get_devno (fs);
/* Note we don't use mnt_fs_is_pseudofs() or mnt_fs_is_netfs() here
as libmount's classification is non-compatible currently.
Also we pass "false" for the "Bind" option as that's only
significant when the Fs_type is "none" which will not be
the case when parsing "/proc/self/mountinfo", and only
applies for static /etc/mtab files. */
me->me_dummy = ME_DUMMY (me->me_devname, me->me_type, FALSE);
me->me_remote = ME_REMOTE (me->me_devname, me->me_type);
/* Add to the linked list. */
*mtail = me;
mtail = &me->me_next;
}
mnt_free_iter (iter);
mnt_free_table (fstable);
/* Add to the linked list. */
*mtail = me;
mtail = &me->me_next;
}
else /* fallback to /proc/self/mounts (/etc/mtab) if anything failed */
#endif /* MOUNTED_PROC_MOUNTINFO */
{
FILE *fp;
struct mntent *mnt;
const char *table = MOUNTED;
if (endmntent (fp) == 0)
goto free_then_fail;
fp = setmntent (table, "r");
if (fp == NULL)
return NULL;
while ((mnt = getmntent (fp)) != NULL)
{
gboolean bind;
bind = hasmntopt (mnt, "bind") != NULL;
me = g_malloc (sizeof (*me));
me->me_devname = g_strdup (mnt->mnt_fsname);
me->me_mountdir = g_strdup (mnt->mnt_dir);
me->me_type = g_strdup (mnt->mnt_type);
me->me_type_malloced = 1;
me->me_dummy = ME_DUMMY (me->me_devname, me->me_type, bind);
me->me_remote = ME_REMOTE (me->me_devname, me->me_type);
me->me_dev = dev_from_mount_options (mnt->mnt_opts);
/* Add to the linked list. */
*mtail = me;
mtail = &me->me_next;
}
if (endmntent (fp) == 0)
goto free_then_fail;
}
}
#endif /* MOUNTED_GETMNTENT1. */
@ -999,7 +1051,7 @@ read_file_system_list (int need_fs_type)
char *table = MNTTAB;
FILE *fp;
int ret;
int lockfd;
int lockfd = -1;
#if defined F_RDLCK && defined F_SETLKW
/* MNTTAB_LOCK is a macro name of our own invention; it's not present in

View File

@ -771,17 +771,14 @@ file_compute_color (int attr, file_entry_t * fe)
/** Formats the file number file_index of panel in the buffer dest */
static filename_scroll_flag_t
format_file (char *dest, int limit, WPanel * panel, int file_index, int width, int attr,
gboolean isstatus, int *field_length)
format_file (WPanel * panel, int file_index, int width, int attr, gboolean isstatus,
int *field_length)
{
int color, length = 0, empty_line;
format_e *format, *home;
file_entry_t *fe;
filename_scroll_flag_t res = FILENAME_NOSCROLL;
(void) dest;
(void) limit;
empty_line = (file_index >= panel->dir.len);
home = isstatus ? panel->status_format : panel->format;
fe = &panel->dir.list[file_index];
@ -893,7 +890,6 @@ repaint_file (WPanel * panel, int file_index, gboolean mv, int attr, gboolean is
int second_column = 0;
int width;
int offset = 0;
char buffer[BUF_MEDIUM];
filename_scroll_flag_t ret_frm;
int ypos = 0;
gboolean panel_is_split = !isstatus && panel->split;
@ -930,7 +926,7 @@ repaint_file (WPanel * panel, int file_index, gboolean mv, int attr, gboolean is
widget_move (w, ypos, offset + 1);
}
ret_frm = format_file (buffer, sizeof (buffer), panel, file_index, width, attr, isstatus, &fln);
ret_frm = format_file (panel, file_index, width, attr, isstatus, &fln);
if (panel_is_split)
{
@ -2784,8 +2780,10 @@ do_enter_on_file_entry (file_entry_t * fe)
}
{
char *tmp = name_quote (fe->fname, 0);
char *cmd = g_strconcat (".", PATH_SEP_STR, tmp, (char *) NULL);
char *tmp, *cmd;
tmp = name_quote (fe->fname, FALSE);
cmd = g_strconcat (".", PATH_SEP_STR, tmp, (char *) NULL);
g_free (tmp);
shell_execute (cmd, 0);
g_free (cmd);

View File

@ -14,7 +14,7 @@
Norbert Warmuth, 1997
Miguel de Icaza, 1996, 1999
Slava Zanko <slavazanko@gmail.com>, 2013
Andrew Borodin <aborodin@vmail.ru>, 2013
Andrew Borodin <aborodin@vmail.ru>, 2013, 2014
This file is part of the Midnight Commander.
@ -306,7 +306,6 @@ show_tree (WTree * tree)
i = 0;
while (current->prev && i < tree->topdiff)
{
current = current->prev;
if (current->sublevel < tree->selected_ptr->sublevel)
@ -324,15 +323,11 @@ show_tree (WTree * tree)
if (vfs_path_equal_len (current->name, tree->selected_ptr->name, j))
i++;
}
else
else if (current->sublevel == tree->selected_ptr->sublevel + 1)
{
if (current->sublevel == tree->selected_ptr->sublevel + 1
&& vfs_path_len (tree->selected_ptr->name) > 1)
{
if (vfs_path_equal_len (current->name, tree->selected_ptr->name,
vfs_path_len (tree->selected_ptr->name)))
i++;
}
j = vfs_path_len (tree->selected_ptr->name);
if (j > 1 && vfs_path_equal_len (current->name, tree->selected_ptr->name, j))
i++;
}
}
tree->topdiff = i;

View File

@ -491,7 +491,7 @@ execute_menu_command (WEdit * edit_widget, const char *commands, gboolean show_p
{
char *tmp;
tmp = name_quote (parameter, 0);
tmp = name_quote (parameter, FALSE);
fputs (tmp, cmd_file);
g_free (tmp);
}
@ -737,7 +737,7 @@ char *
expand_format (struct WEdit *edit_widget, char c, gboolean do_quote)
{
WPanel *panel = NULL;
char *(*quote_func) (const char *, int);
char *(*quote_func) (const char *, gboolean);
char *fname = NULL;
char *result;
char c_lc;
@ -785,10 +785,10 @@ expand_format (struct WEdit *edit_widget, char c, gboolean do_quote)
{
case 'f':
case 'p':
result = (*quote_func) (fname, 0);
result = quote_func (fname, FALSE);
goto ret;
case 'x':
result = (*quote_func) (extension (fname), 0);
result = quote_func (extension (fname), FALSE);
goto ret;
case 'd':
{
@ -800,7 +800,7 @@ expand_format (struct WEdit *edit_widget, char c, gboolean do_quote)
else
cwd = vfs_get_current_dir ();
qstr = (*quote_func) (cwd, 0);
qstr = quote_func (cwd, FALSE);
g_free (cwd);
@ -838,14 +838,14 @@ expand_format (struct WEdit *edit_widget, char c, gboolean do_quote)
char *file;
file = mc_config_get_full_path (EDIT_BLOCK_FILE);
result = (*quote_func) (file, 0);
result = quote_func (file, FALSE);
g_free (file);
goto ret;
}
#endif
if (c_lc == 'b')
{
result = strip_ext ((*quote_func) (fname, 0));
result = strip_ext (quote_func (fname, FALSE));
goto ret;
}
break;
@ -854,7 +854,7 @@ expand_format (struct WEdit *edit_widget, char c, gboolean do_quote)
#ifdef USE_INTERNAL_EDIT
if (edit_widget)
{
result = strip_ext ((*quote_func) (fname, 0));
result = strip_ext (quote_func (fname, FALSE));
goto ret;
}
#endif
@ -862,14 +862,14 @@ expand_format (struct WEdit *edit_widget, char c, gboolean do_quote)
case 'm': /* menu file name */
if (menu)
{
result = (*quote_func) (menu, 0);
result = quote_func (menu, FALSE);
goto ret;
}
break;
case 's':
if (!panel || !panel->marked)
{
result = (*quote_func) (fname, 0);
result = quote_func (fname, FALSE);
goto ret;
}
@ -894,7 +894,7 @@ expand_format (struct WEdit *edit_widget, char c, gboolean do_quote)
{
char *tmp;
tmp = (*quote_func) (panel->dir.list[i].fname, 0);
tmp = quote_func (panel->dir.list[i].fname, FALSE);
g_string_append (block, tmp);
g_string_append_c (block, ' ');
g_free (tmp);

View File

@ -420,7 +420,7 @@ extfs_open_archive (int fstype, const char *name, struct archive **pparc)
goto ret;
}
tmp = name_quote (vfs_path_get_last_path_str (name_vpath), 0);
tmp = name_quote (vfs_path_get_last_path_str (name_vpath), FALSE);
}
cmd = g_strconcat (info->path, info->prefix, " list ",
@ -834,13 +834,13 @@ extfs_cmd (const char *str_extfs_cmd, struct archive *archive,
int retval;
file = extfs_get_path_from_entry (entry);
quoted_file = name_quote (file, 0);
quoted_file = name_quote (file, FALSE);
g_free (file);
archive_name = extfs_get_archive_name (archive);
quoted_archive_name = name_quote (archive_name, 0);
quoted_archive_name = name_quote (archive_name, FALSE);
g_free (archive_name);
quoted_localname = name_quote (localname, 0);
quoted_localname = name_quote (localname, FALSE);
info = &g_array_index (extfs_plugins, extfs_plugin_info_t, archive->fstype);
cmd = g_strconcat (info->path, info->prefix, str_extfs_cmd,
quoted_archive_name, " ", quoted_file, " ", quoted_localname, (char *) NULL);
@ -868,11 +868,11 @@ extfs_run (const vfs_path_t * vpath)
p = extfs_get_path (vpath, &archive, FALSE);
if (p == NULL)
return;
q = name_quote (p, 0);
q = name_quote (p, FALSE);
g_free (p);
archive_name = extfs_get_archive_name (archive);
quoted_archive_name = name_quote (archive_name, 0);
quoted_archive_name = name_quote (archive_name, FALSE);
g_free (archive_name);
info = &g_array_index (extfs_plugins, extfs_plugin_info_t, archive->fstype);
cmd =

View File

@ -157,11 +157,11 @@ sfs_vfmake (const vfs_path_t * vpath, vfs_path_t * cache_vpath)
vfs_path_free (pname);
return -1;
}
pqname = name_quote (vfs_path_get_last_path_str (s), 0);
pqname = name_quote (vfs_path_get_last_path_str (s), FALSE);
vfs_path_free (s);
}
else
pqname = name_quote (vfs_path_as_str (pname), 0);
pqname = name_quote (vfs_path_as_str (pname), FALSE);
vfs_path_free (pname);

View File

@ -151,19 +151,6 @@ mcview_get_ptr_file (mcview_t * view, off_t byte_index)
/* --------------------------------------------------------------------------------------------- */
char *
mcview_get_ptr_string (mcview_t * view, off_t byte_index)
{
#ifdef HAVE_ASSERT_H
assert (view->datasource == DS_STRING);
#endif
if (byte_index < (off_t) view->ds_string_len)
return (char *) (view->ds_string_data + byte_index);
return NULL;
}
/* --------------------------------------------------------------------------------------------- */
int
mcview_get_utf (mcview_t * view, off_t byte_index, int *char_width, gboolean * result)
{
@ -237,21 +224,34 @@ mcview_get_utf (mcview_t * view, off_t byte_index, int *char_width, gboolean * r
/* --------------------------------------------------------------------------------------------- */
gboolean
mcview_get_byte_string (mcview_t * view, off_t byte_index, int *retval)
char *
mcview_get_ptr_string (mcview_t * view, off_t byte_index)
{
#ifdef HAVE_ASSERT_H
assert (view->datasource == DS_STRING);
#endif
if (byte_index < (off_t) view->ds_string_len)
{
if (retval)
*retval = view->ds_string_data[byte_index];
return TRUE;
}
if (retval)
if (byte_index >= 0 && byte_index < (off_t) view->ds_string_len)
return (char *) (view->ds_string_data + byte_index);
return NULL;
}
/* --------------------------------------------------------------------------------------------- */
gboolean
mcview_get_byte_string (mcview_t * view, off_t byte_index, int *retval)
{
char *p;
if (retval != NULL)
*retval = -1;
return FALSE;
p = mcview_get_ptr_string (view, byte_index);
if (p == NULL)
return FALSE;
if (retval != NULL)
*retval = *p;
return TRUE;
}
/* --------------------------------------------------------------------------------------------- */

View File

@ -288,11 +288,12 @@ mcview_compute_areas (mcview_t * view)
/* Compute the heights of the areas */
rest = view_area.height;
height = mcview_dimen_min (rest, 1);
height = min (rest, 1);
view->status_area.height = height;
rest -= height;
height = mcview_dimen_min (rest, (ruler == RULER_NONE || view->hex_mode) ? 0 : 2);
height = (ruler == RULER_NONE || view->hex_mode) ? 0 : 2;
height = min (rest, height);
view->ruler_area.height = height;
rest -= height;

View File

@ -242,39 +242,26 @@ mcview_growbuf_read_until (mcview_t * view, off_t ofs)
gboolean
mcview_get_byte_growing_buffer (mcview_t * view, off_t byte_index, int *retval)
{
off_t pageno;
off_t pageindex;
if (retval != NULL)
*retval = -1;
pageno = byte_index / VIEW_PAGE_SIZE;
pageindex = byte_index % VIEW_PAGE_SIZE;
char *p;
#ifdef HAVE_ASSERT_H
assert (view->growbuf_in_use);
#endif
if (pageno < 0)
if (retval != NULL)
*retval = -1;
if (byte_index < 0)
return FALSE;
mcview_growbuf_read_until (view, byte_index + 1);
if (view->growbuf_blockptr->len == 0)
p = mcview_get_ptr_growing_buffer (view, byte_index);
if (p == NULL)
return FALSE;
if (pageno < (off_t) view->growbuf_blockptr->len - 1)
{
if (retval != NULL)
*retval = *((byte *) (g_ptr_array_index (view->growbuf_blockptr, pageno) + pageindex));
return TRUE;
}
if (pageno == (off_t) view->growbuf_blockptr->len - 1
&& pageindex < (off_t) view->growbuf_lastindex)
{
if (retval != NULL)
*retval = *((byte *) (g_ptr_array_index (view->growbuf_blockptr, pageno) + pageindex));
return TRUE;
}
return FALSE;
if (retval != NULL)
*retval = *p;
return TRUE;
}
/* --------------------------------------------------------------------------------------------- */
@ -282,16 +269,18 @@ mcview_get_byte_growing_buffer (mcview_t * view, off_t byte_index, int *retval)
char *
mcview_get_ptr_growing_buffer (mcview_t * view, off_t byte_index)
{
off_t pageno = byte_index / VIEW_PAGE_SIZE;
off_t pageindex = byte_index % VIEW_PAGE_SIZE;
off_t pageno, pageindex;
#ifdef HAVE_ASSERT_H
assert (view->growbuf_in_use);
#endif
if (pageno < 0)
if (byte_index < 0)
return NULL;
pageno = byte_index / VIEW_PAGE_SIZE;
pageindex = byte_index % VIEW_PAGE_SIZE;
mcview_growbuf_read_until (view, byte_index + 1);
if (view->growbuf_blockptr->len == 0)
return NULL;

View File

@ -17,6 +17,7 @@
/*** inline functions ****************************************************************************/
/* difference or zero */
static inline off_t
mcview_offset_doz (off_t a, off_t b)
{
@ -45,14 +46,6 @@ mcview_dimen_doz (screen_dimen a, screen_dimen b)
/* --------------------------------------------------------------------------------------------- */
static inline screen_dimen
mcview_dimen_min (screen_dimen a, screen_dimen b)
{
return (a < b) ? a : b;
}
/* --------------------------------------------------------------------------------------------- */
/* {{{ Simple Primitive Functions for mcview_t }}} */
static inline gboolean
mcview_is_in_panel (mcview_t * view)
@ -120,7 +113,7 @@ mcview_get_byte (mcview_t * view, off_t offset, int *retval)
#ifdef HAVE_ASSERT_H
assert (!"Unknown datasource type");
#endif
return -1;
return FALSE;
}
/* --------------------------------------------------------------------------------------------- */

View File

@ -135,7 +135,9 @@ struct mcview_struct
gboolean hexedit_lownibble; /* Are we editing the last significant nibble? */
gboolean locked; /* We hold lock on current file */
#ifdef HAVE_CHARSET
gboolean utf8; /* It's multibyte file codeset */
#endif
coord_cache_t *coord_cache; /* Cache for mapping offsets to cursor positions */

View File

@ -242,8 +242,7 @@ mcview_done (mcview_t * view)
mc_search_free (view->search);
view->search = NULL;
g_free (view->last_search_string);
view->last_search_string = NULL;
MC_PTR_FREE (view->last_search_string);
mcview_nroff_seq_free (&view->search_nroff_seq);
mcview_hexedit_free_change_list (view);

View File

@ -180,10 +180,8 @@ mcview_move_down (mcview_t * view, off_t lines)
{
off_t i, limit;
if (last_byte >= (off_t) view->bytes_per_line)
limit = last_byte - view->bytes_per_line;
else
limit = 0;
limit = mcview_offset_doz (last_byte, (off_t) view->bytes_per_line);
for (i = 0; i < lines && view->hex_cursor < limit; i++)
{
view->hex_cursor += view->bytes_per_line;
@ -258,12 +256,8 @@ mcview_move_left (mcview_t * view, off_t columns)
view->hexedit_lownibble = !view->hexedit_lownibble;
}
else
{
if (view->dpy_text_column >= columns)
view->dpy_text_column -= columns;
else
view->dpy_text_column = 0;
}
view->dpy_text_column = mcview_offset_doz (view->dpy_text_column, columns);
mcview_movement_fixups (view, FALSE);
}
@ -276,6 +270,7 @@ mcview_move_right (mcview_t * view, off_t columns)
{
off_t last_byte;
off_t old_cursor = view->hex_cursor;
last_byte = mcview_offset_doz (mcview_get_filesize (view), 1);
#ifdef HAVE_ASSERT_H
assert (columns == 1);
@ -376,16 +371,15 @@ mcview_moveto_eol (mcview_t * view)
else
{
off_t eol;
bol = mcview_bol (view, view->dpy_start, 0);
eol = mcview_eol (view, view->dpy_start, mcview_get_filesize (view));
if (!view->utf8)
{
if (eol > bol)
view->dpy_text_column = eol - bol;
}
else
#ifdef HAVE_CHARSET
if (view->utf8)
{
char *str = NULL;
switch (view->datasource)
{
case DS_STDIO_PIPE:
@ -406,11 +400,13 @@ mcview_moveto_eol (mcview_t * view)
else
view->dpy_text_column = eol - bol;
}
if (view->dpy_text_column < (off_t) view->data_area.width)
view->dpy_text_column = 0;
else
view->dpy_text_column = view->dpy_text_column - (off_t) view->data_area.width;
#endif /* HAVE_CHARSET */
if (eol > bol)
view->dpy_text_column = eol - bol;
view->dpy_text_column =
mcview_offset_doz (view->dpy_text_column, (off_t) view->data_area.width);
}
mcview_movement_fixups (view, FALSE);
}

View File

@ -48,7 +48,7 @@ static WEdit *test_edit;
/* --------------------------------------------------------------------------------------------- */
/* @Mock */
void
edit_load_syntax (WEdit * _edit, char ***_pnames, const char *_type)
edit_load_syntax (WEdit * _edit, GPtrArray * _pnames, const char *_type)
{
(void) _edit;
(void) _pnames;