Skip to content
Projects
Groups
Snippets
Help
This project
Loading...
Sign in / Register
Toggle navigation
Y
yad
Project
Project
Details
Activity
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Registry
Registry
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
Vladislav
yad
Commits
ee416fc8
Commit
ee416fc8
authored
Apr 18, 2021
by
Victor Ananjevsky
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
add --file-op option to text-info dialog
parent
6b2d263d
Show whitespace changes
Inline
Side-by-side
Showing
6 changed files
with
503 additions
and
279 deletions
+503
-279
yad.1
data/yad.1
+3
-0
ru.po
po/ru.po
+148
-126
uk.po
po/uk.po
+148
-126
option.c
src/option.c
+3
-0
text.c
src/text.c
+200
-27
yad.h
src/yad.h
+1
-0
No files found.
data/yad.1
View file @
ee416fc8
...
...
@@ -968,6 +968,9 @@ Listen data from stdin even if filename was specified.
.B \-\-in-place
Save file on exit instead of print it content on stdout. This option works only if file was specified from command-line.
.TP
.B \-\-file-op
Enable file operations. This option adds open and save menu items to popup menu, This option works only in editable mode.
.TP
Next options works only if yad builds with GtkSourceView.
.TP
.B \-\-lang=\fILANGUAGE\fP
...
...
po/ru.po
View file @
ee416fc8
...
...
@@ -7,7 +7,7 @@ msgid ""
msgstr ""
"Project-Id-Version: YAD\n"
"Report-Msgid-Bugs-To: \n"
"POT-Creation-Date: 2021-04-1
7 16:19
+0300\n"
"POT-Creation-Date: 2021-04-1
8 09:24
+0300\n"
"PO-Revision-Date: 2009-04-30 16:47+0300\n"
"Last-Translator: Victor Ananjevsky <ananasik@gmail.com>\n"
"Language-Team: \n"
...
...
@@ -45,7 +45,7 @@ msgstr ""
"Собран с поддержкой GtkSpell\n"
"Используется GTK+ %d.%d.%d\n"
#: ../src/calendar.c:39 ../src/text.c:
397
#: ../src/calendar.c:39 ../src/text.c:
585
#, c-format
msgid "Cannot open file '%s': %s\n"
msgstr "Не могу открыть файл %s: %s\n"
...
...
@@ -65,49 +65,51 @@ msgstr "Начальное значение меньше минимальног
msgid "Initial value greater than maximum.\n"
msgstr "Начальное значение больше маскимального.\n"
#: ../src/form.c:45
3
#: ../src/form.c:45
5
msgid "Select files"
msgstr "Выбор файлов"
#: ../src/form.c:456 ../src/form.c:464 ../src/form.c:543 ../src/form.c:551
#: ../src/form.c:602 ../src/html.c:175 ../src/html.c:207 ../src/util.c:40
#: ../src/form.c:458 ../src/form.c:466 ../src/form.c:545 ../src/form.c:553
#: ../src/form.c:604 ../src/html.c:175 ../src/html.c:207 ../src/text.c:160
#: ../src/text.c:225 ../src/util.c:40
msgid "Cancel"
msgstr "Отмена"
#: ../src/form.c:457 ../src/form.c:465 ../src/form.c:544 ../src/form.c:552
#: ../src/form.c:603 ../src/html.c:174 ../src/util.c:46
#: ../src/form.c:459 ../src/form.c:467 ../src/form.c:546 ../src/form.c:554
#: ../src/form.c:605 ../src/html.c:174 ../src/text.c:161 ../src/text.c:226
#: ../src/util.c:46
msgid "OK"
msgstr "OK"
#: ../src/form.c:46
1
#: ../src/form.c:46
3
msgid "Select folders"
msgstr "Выбор каталогов"
#: ../src/form.c:54
0
#: ../src/form.c:54
2
msgid "Select or create file"
msgstr "Выбор или создание файла"
#: ../src/form.c:5
48
#: ../src/form.c:5
50
msgid "Select or create folder"
msgstr "Выбор или создание каталога"
#: ../src/form.c:
599
#: ../src/form.c:
601
msgid "Select date"
msgstr "Выбор даты"
#: ../src/form.c:9
12
#: ../src/form.c:9
60
msgid "Select file"
msgstr "Выбор файла"
#: ../src/form.c:9
42
#: ../src/form.c:9
90
msgid "Select folder"
msgstr "Выбор каталога"
#: ../src/form.c:11
10 ../src/form.c:1112
#: ../src/form.c:11
58 ../src/form.c:1160
msgid "Link"
msgstr "Ссылка"
#: ../src/html.c:171
#: ../src/html.c:171
../src/text.c:157 ../src/text.c:222
msgid "YAD - Select File"
msgstr "YAD - Выбор файла"
...
...
@@ -325,8 +327,8 @@ msgstr "Задать выравнивание текста диалога (left,
#: ../src/option.c:225 ../src/option.c:370 ../src/option.c:397
#: ../src/option.c:453 ../src/option.c:463 ../src/option.c:509
#: ../src/option.c:541 ../src/option.c:553 ../src/option.c:563
#: ../src/option.c:577 ../src/option.c:638 ../src/option.c:68
5
#: ../src/option.c:71
2 ../src/option.c:714
../src/tools.c:80
#: ../src/option.c:577 ../src/option.c:638 ../src/option.c:68
7
#: ../src/option.c:71
4 ../src/option.c:716
../src/tools.c:80
msgid "TYPE"
msgstr "ТИП"
...
...
@@ -342,7 +344,7 @@ msgstr "КАРТИНКА"
msgid "Use specified icon theme instead of default"
msgstr "Использовать указанную тему иконок"
#: ../src/option.c:118 ../src/option.c:66
3
../src/browser.c:217
#: ../src/option.c:118 ../src/option.c:66
5
../src/browser.c:217
#: ../src/tools.c:81
msgid "THEME"
msgstr "ТЕМА"
...
...
@@ -571,8 +573,8 @@ msgstr "Показывать скрытые файлы в диалоге выб
msgid "Set source filename"
msgstr "Имя исходного файла"
#: ../src/option.c:217 ../src/option.c:284 ../src/option.c:71
0
#: ../src/option.c:72
2
#: ../src/option.c:217 ../src/option.c:284 ../src/option.c:71
2
#: ../src/option.c:72
4
msgid "FILENAME"
msgstr "ИМЯ_ФАЙЛА"
...
...
@@ -618,7 +620,7 @@ msgstr "Задать имя приложения"
#: ../src/option.c:243 ../src/option.c:245 ../src/option.c:247
#: ../src/option.c:257 ../src/option.c:401 ../src/option.c:526
#: ../src/option.c:7
08
#: ../src/option.c:7
10
msgid "STRING"
msgstr "СТРОКА"
...
...
@@ -724,7 +726,7 @@ msgid "Set initial color value"
msgstr "Задать начальное значение цвета"
#: ../src/option.c:294 ../src/option.c:642 ../src/option.c:644
#: ../src/option.c:650 ../src/option.c:67
1 ../src/option.c:673
#: ../src/option.c:650 ../src/option.c:67
3 ../src/option.c:675
msgid "COLOR"
msgstr "ЦВЕТ"
...
...
@@ -1272,8 +1274,8 @@ msgid "Set initial value"
msgstr "Задать начальное значение"
#: ../src/option.c:608 ../src/option.c:610 ../src/option.c:612
#: ../src/option.c:614 ../src/option.c:618 ../src/option.c:68
1
#: ../src/option.c:68
3
#: ../src/option.c:614 ../src/option.c:618 ../src/option.c:68
3
#: ../src/option.c:68
5
msgid "VALUE"
msgstr "ЗНАЧЕНИЕ"
...
...
@@ -1365,448 +1367,452 @@ msgstr "Использовать разметку pango"
msgid "Save file instead of print on exit"
msgstr "Сохранять файл вместо вывода на выходе"
#: ../src/option.c:661
#: ../src/option.c:656
msgid "Enable file operations"
msgstr "Разрешить файловые операции"
#: ../src/option.c:663
msgid "Use specified langauge for syntax highlighting"
msgstr "Использовать указанный язык для подсветки синтаксиса"
#: ../src/option.c:66
1
#: ../src/option.c:66
3
msgid "LANG"
msgstr "ЯЗЫК"
#: ../src/option.c:66
3
#: ../src/option.c:66
5
msgid "Use specified theme"
msgstr "Использовать указанную тему"
#: ../src/option.c:66
5
../data/yad.gschema.xml.in.h:17
#: ../src/option.c:66
7
../data/yad.gschema.xml.in.h:17
msgid "Show line numbers"
msgstr "Показывать номера строк"
#: ../src/option.c:66
7
../data/yad.gschema.xml.in.h:18
#: ../src/option.c:66
9
../data/yad.gschema.xml.in.h:18
msgid "Highlight current line"
msgstr "Подсвечивать текущую строку"
#: ../src/option.c:6
69
#: ../src/option.c:6
71
msgid "Enable line marks"
msgstr "Разрешить пометки строк"
#: ../src/option.c:67
1
#: ../src/option.c:67
3
msgid "Set color for first type marks"
msgstr "Задать цвет меток первого типа"
#: ../src/option.c:67
3
#: ../src/option.c:67
5
msgid "Set color for second type marks"
msgstr "Задать цвет меток второго типа"
#: ../src/option.c:67
5
#: ../src/option.c:67
7
msgid "Set position of right margin"
msgstr "Задать положение правой границы"
#: ../src/option.c:67
5
#: ../src/option.c:67
7
msgid "[POS]"
msgstr "[ПОЗИЦИЯ]"
#: ../src/option.c:67
7
../data/yad.gschema.xml.in.h:23
#: ../src/option.c:67
9
../data/yad.gschema.xml.in.h:23
msgid "Highlight matching brackets"
msgstr "Подсвечивать парные скобки"
#: ../src/option.c:6
79
../data/yad.gschema.xml.in.h:24
#: ../src/option.c:6
81
../data/yad.gschema.xml.in.h:24
msgid "Use autoindent"
msgstr "Использовать автовыравнивание"
#: ../src/option.c:68
1
#: ../src/option.c:68
3
msgid "Set tabulation width"
msgstr "Задать ширину табуляции"
#: ../src/option.c:68
3
#: ../src/option.c:68
5
msgid "Set indentation width"
msgstr "Задать ширину выравнивания"
#: ../src/option.c:68
5
#: ../src/option.c:68
7
msgid "Set smart Home/End behavior"
msgstr "Задать поведение умных Home/End"
#: ../src/option.c:68
7
#: ../src/option.c:68
9
msgid "Enable smart backspace"
msgstr "Использовать умный backspace"
#: ../src/option.c:6
89
../data/yad.gschema.xml.in.h:29
#: ../src/option.c:6
91
../data/yad.gschema.xml.in.h:29
msgid "Insert spaces instead of tabs"
msgstr "Вставлять пробелы вместо табуляции"
#: ../src/option.c:69
6
#: ../src/option.c:69
8
msgid "Sets a filename filter"
msgstr "Задать фильтр файлов по маске"
#: ../src/option.c:69
6
#: ../src/option.c:69
8
msgid "NAME | PATTERN1 PATTERN2 ..."
msgstr "ИМЯ | ШАБЛОН1 ШАБЛОН2 ..."
#: ../src/option.c:
698
#: ../src/option.c:
700
msgid "Sets a mime-type filter"
msgstr "Задать фильтр файлов по типу mime"
#: ../src/option.c:
698
#: ../src/option.c:
700
msgid "NAME | MIME1 MIME2 ..."
msgstr "ИМЯ | ТИП1 ТИП2 ..."
#: ../src/option.c:70
0
#: ../src/option.c:70
2
msgid "Add filter for images"
msgstr "Добавить фильтр изображений"
#: ../src/option.c:70
0
#: ../src/option.c:70
2
msgid "[NAME]"
msgstr "[ИМЯ]"
#: ../src/option.c:70
6
../src/tools.c:59
#: ../src/option.c:70
8
../src/tools.c:59
msgid "Print version"
msgstr "Вывести версию"
#: ../src/option.c:7
08
#: ../src/option.c:7
10
msgid "Load additional CSS settings from file or string"
msgstr "Загрузить дополнительные настройки CSS из файла или строки"
#: ../src/option.c:71
0
#: ../src/option.c:71
2
msgid "Load additional CSS settings from file"
msgstr "Загрузить дополнительные настройки CSS из файла"
#: ../src/option.c:71
2
#: ../src/option.c:71
4
msgid "Set policy for horizontal scrollbars (auto, always, never)"
msgstr "Задать тип горизонтальной прокрутки (auto, always, never)"
#: ../src/option.c:71
4
#: ../src/option.c:71
6
msgid "Set policy for vertical scrollbars (auto, always, never)"
msgstr "Задать тип вертикальной прокрутки (auto, always, never)"
#: ../src/option.c:71
6
#: ../src/option.c:71
8
msgid "Add path for search icons by name"
msgstr "Добавить каталог для поиска изображений по имени"
#: ../src/option.c:71
6
#: ../src/option.c:71
8
msgid "PATH"
msgstr "ПУТЬ"
#: ../src/option.c:72
2
#: ../src/option.c:72
4
msgid "Load extra arguments from file"
msgstr "Загрузить дополнительные аргументы из файла"
#: ../src/option.c:9
27
#: ../src/option.c:9
31
#, c-format
msgid "Mark %s doesn't have a value\n"
msgstr "Метке %s не задано значение\n"
#: ../src/option.c:96
4
#: ../src/option.c:96
8
msgid "Images"
msgstr "Изображения"
#: ../src/option.c:10
29
#: ../src/option.c:10
33
#, c-format
msgid "Unknown color mode: %s\n"
msgstr "Неизвестный режим цвета: '%s'\n"
#: ../src/option.c:10
48
#: ../src/option.c:10
52
#, c-format
msgid "Unknown buttons layout type: %s\n"
msgstr "Неизвестный тип расположения кнопок: %s\n"
#: ../src/option.c:106
3
#: ../src/option.c:106
7
#, c-format
msgid "Unknown align type: %s\n"
msgstr "Неизвестный тип выравнивания: %s\n"
#: ../src/option.c:10
87
#: ../src/option.c:10
91
#, c-format
msgid "Unknown justification type: %s\n"
msgstr "Неизвестный тип выравнивания: %s\n"
#: ../src/option.c:110
4
#: ../src/option.c:110
8
#, c-format
msgid "Unknown tab position type: %s\n"
msgstr "Неизвестный тип позиции вкладки: %s\n"
#: ../src/option.c:114
1
#: ../src/option.c:114
5
#, c-format
msgid "Unknown ellipsize type: %s\n"
msgstr "Неизвестный тип усечения: %s\n"
#: ../src/option.c:115
4
#: ../src/option.c:115
8
#, c-format
msgid "Unknown orientation: %s\n"
msgstr "Неизвестная ориентация: %s\n"
#: ../src/option.c:11
69
#: ../src/option.c:11
73
#, c-format
msgid "Unknown source type: %s\n"
msgstr "Неизвестный исходный тип: %s\n"
#: ../src/option.c:118
0
#: ../src/option.c:118
4
msgid "Progress log"
msgstr "Окно журнала"
#: ../src/option.c:119
3
#: ../src/option.c:119
7
#, c-format
msgid "Unknown size type: %s\n"
msgstr "Неизвестный тип размера: %s\n"
#: ../src/option.c:123
5
#: ../src/option.c:123
9
#, c-format
msgid "Unknown completion type: %s\n"
msgstr "Неизвестный тип дополнения: %s\n"
#: ../src/option.c:12
67
#: ../src/option.c:12
71
#, c-format
msgid "Unknown boolean format type: %s\n"
msgstr "Неизвестный тип булевского формата: %s\n"
#: ../src/option.c:128
3
#: ../src/option.c:128
7
#, c-format
msgid "Unknown grid lines type: %s\n"
msgstr "Неизвестный тип разделительных линий: %s\n"
#: ../src/option.c:130
0
#: ../src/option.c:130
4
#, c-format
msgid "Unknown scrollbar policy type: %s\n"
msgstr "Неизвестный тип прокрутки: %s\n"
#: ../src/option.c:135
3
#: ../src/option.c:135
7
#, c-format
msgid "Unknown smart Home/End mode: %s\n"
msgstr "Неизвестный режим умных Home/End: '%s'\n"
#: ../src/option.c:146
3
#: ../src/option.c:146
7
#, c-format
msgid "Unknown signal: %s\n"
msgstr "Неизвестный сигнал: %s\n"
#: ../src/option.c:1
697
#: ../src/option.c:1
701
msgid "File exist. Overwrite?"
msgstr "Файл существует. Перезаписать?"
#: ../src/option.c:18
89
#: ../src/option.c:18
94
msgid "- Yet another dialoging program"
msgstr "- Программа для отображения диалогов"
#. Adds general option entries
#: ../src/option.c:189
3
#: ../src/option.c:189
8
msgid "General options"
msgstr "Основные параметры"
#: ../src/option.c:189
3
#: ../src/option.c:189
8
msgid "Show general options"
msgstr "Показывать основные параметры"
#. Adds common option entries
#: ../src/option.c:1
899
#: ../src/option.c:1
904
msgid "Common options"
msgstr "Общие параметры"
#: ../src/option.c:1
899
#: ../src/option.c:1
904
msgid "Show common options"
msgstr "Показывать общие параметры диалогов"
#. Adds about option entries
#: ../src/option.c:19
05
#: ../src/option.c:19
10
msgid "About dialog options"
msgstr "Параметры диалога о программе"
#: ../src/option.c:19
05
#: ../src/option.c:19
10
msgid "Show custom about dialog options"
msgstr "Показывать параметры диалога о программе"
#. Adds app option entries
#: ../src/option.c:191
1
#: ../src/option.c:191
6
msgid "Application selection options"
msgstr "Параметры диалога выбора приложения"
#: ../src/option.c:191
1
#: ../src/option.c:191
6
msgid "Show application selection options"
msgstr "Показывать параметры диалога выбора приложения"
#. Adds calendar option entries
#: ../src/option.c:19
17
#: ../src/option.c:19
22
msgid "Calendar options"
msgstr "Параметры календаря"
#: ../src/option.c:19
17
#: ../src/option.c:19
22
msgid "Show calendar options"
msgstr "Показывать параметры календаря"
#. Adds color option entries
#: ../src/option.c:192
3
#: ../src/option.c:192
8
msgid "Color selection options"
msgstr "Параметры диалога выбора цвета"
#: ../src/option.c:192
3
#: ../src/option.c:192
8
msgid "Show color selection options"
msgstr "Показывать параметры диалога выбора цвета"
#. Adds dnd option entries
#: ../src/option.c:19
29
#: ../src/option.c:19
34
msgid "DND options"
msgstr "Параметры DND"
#: ../src/option.c:19
29
#: ../src/option.c:19
34
msgid "Show drag-n-drop options"
msgstr "Показывать параметры dnd"
#. Adds entry option entries
#: ../src/option.c:19
35
#: ../src/option.c:19
40
msgid "Text entry options"
msgstr "Параметры ввода текста"
#: ../src/option.c:19
35
#: ../src/option.c:19
40
msgid "Show text entry options"
msgstr "Показывать параметры ввода текста"
#. Adds file selection option entries
#: ../src/option.c:194
1
#: ../src/option.c:194
6
msgid "File selection options"
msgstr "Параметры диалога выбора файла"
#: ../src/option.c:194
1
#: ../src/option.c:194
6
msgid "Show file selection options"
msgstr "Показывать параметры диалога выбора файлов"
#. Add font selection option entries
#: ../src/option.c:19
47
#: ../src/option.c:19
52
msgid "Font selection options"
msgstr "Параметры диалога выбора шрифта"
#: ../src/option.c:19
47
#: ../src/option.c:19
52
msgid "Show font selection options"
msgstr "Показывать параметры диалога выбора шрифта"
#. Add form option entries
#: ../src/option.c:195
3
#: ../src/option.c:195
8
msgid "Form options"
msgstr "Параметры диалога формы"
#: ../src/option.c:195
3
#: ../src/option.c:195
8
msgid "Show form options"
msgstr "Показывать параметры диалога формы"
#. Add html options entries
#: ../src/option.c:196
0
#: ../src/option.c:196
5
msgid "HTML options"
msgstr "Параметры HTML диалога"
#: ../src/option.c:196
0
#: ../src/option.c:196
5
msgid "Show HTML options"
msgstr "Показывать параметры HTML диалога"
#. Add icons option entries
#: ../src/option.c:19
67
#: ../src/option.c:19
72
msgid "Icons box options"
msgstr "Параметры диалога значков"
#: ../src/option.c:19
67
#: ../src/option.c:19
72
msgid "Show icons box options"
msgstr "Показывать параметры диалога значков быстрого доступа"
#. Adds list option entries
#: ../src/option.c:197
3
#: ../src/option.c:197
8
msgid "List options"
msgstr "Параметры списка"
#: ../src/option.c:197
3
#: ../src/option.c:197
8
msgid "Show list options"
msgstr "Показывать параметры списка"
#. Adds notebook option entries
#: ../src/option.c:19
79
#: ../src/option.c:19
84
msgid "Notebook options"
msgstr "Параметры диалога с вкладками"
#: ../src/option.c:19
79
#: ../src/option.c:19
84
msgid "Show notebook dialog options"
msgstr "Показывать параметры диалога с вкладками"
#. Adds notification option entries
#: ../src/option.c:19
86
#: ../src/option.c:19
91
msgid "Notification icon options"
msgstr "Параметры значка уведомления"
#: ../src/option.c:19
87
#: ../src/option.c:19
92
msgid "Show notification icon options"
msgstr "Показывать параметры значка уведомления"
#. Adds paned option entries
#: ../src/option.c:199
4
#: ../src/option.c:199
9
msgid "Paned dialog options"
msgstr "Параметры диалога с панелями"
#: ../src/option.c:199
4
#: ../src/option.c:199
9
msgid "Show paned dialog options"
msgstr "Показывать параметры диалога с панелями"
#. Adds picture option entries
#: ../src/option.c:200
0
#: ../src/option.c:200
5
msgid "Picture dialog options"
msgstr "Параметры диалога показа картинки"
#: ../src/option.c:200
0
#: ../src/option.c:200
5
msgid "Show picture dialog options"
msgstr "Показывать параметры диалога отображения картинки"
#. Adds print option entries
#: ../src/option.c:20
06
#: ../src/option.c:20
11
msgid "Print dialog options"
msgstr "Параметры диалога печати"
#: ../src/option.c:20
06
#: ../src/option.c:20
11
msgid "Show print dialog options"
msgstr "Показывать параметры диалога печати"
#. Adds progress option entries
#: ../src/option.c:201
2
#: ../src/option.c:201
7
msgid "Progress options"
msgstr "Параметры хода процесса"
#: ../src/option.c:201
2
#: ../src/option.c:201
7
msgid "Show progress options"
msgstr "Показывать параметры хода процесса"
#. Adds scale option entries
#: ../src/option.c:20
18
#: ../src/option.c:20
23
msgid "Scale options"
msgstr "Параметры масштаба"
#: ../src/option.c:20
18
#: ../src/option.c:20
23
msgid "Show scale options"
msgstr "Показывать параметры масштаба"
#. Adds text option entries
#: ../src/option.c:202
4
#: ../src/option.c:202
9
msgid "Text information options"
msgstr "Параметры текстовой информации"
#: ../src/option.c:202
4
#: ../src/option.c:202
9
msgid "Show text information options"
msgstr "Показывать параметры текстовой информации"
#. Adds sourceview option entries
#: ../src/option.c:203
1
#: ../src/option.c:203
6
msgid "SourceView options"
msgstr "Параметры SourceView"
#: ../src/option.c:203
1
#: ../src/option.c:203
6
msgid "Show SourceView options"
msgstr "Показывать параметры SourceView"
#. Adds file filters option entries
#: ../src/option.c:20
38
#: ../src/option.c:20
43
msgid "File filter options"
msgstr "Параметры фильтров диалога выбора файла"
#: ../src/option.c:20
38
#: ../src/option.c:20
43
msgid "Show file filter options"
msgstr "Показывать параметры фильтров диалога выбора файлов"
#. Adds miscellaneous option entries
#: ../src/option.c:204
4
#: ../src/option.c:204
9
msgid "Miscellaneous options"
msgstr "Дополнительные параметры"
#: ../src/option.c:204
4
#: ../src/option.c:204
9
msgid "Show miscellaneous options"
msgstr "Показывать дополнительные параметры"
...
...
@@ -1909,7 +1915,23 @@ msgstr "Цвет"
msgid "Name"
msgstr "Название"
#: ../src/text.c:535
#: ../src/text.c:278
msgid "Save _as..."
msgstr "Сохранить как..."
#: ../src/text.c:283
msgid "_Save"
msgstr "_Сохранить"
#: ../src/text.c:292
msgid "_Open..."
msgstr "_Открыть..."
#: ../src/text.c:302
msgid "_Quit"
msgstr "_Выход"
#: ../src/text.c:723
#, c-format
msgid "Theme %s not found\n"
msgstr "Тема %s не найдена\n"
...
...
po/uk.po
View file @
ee416fc8
...
...
@@ -7,7 +7,7 @@ msgid ""
msgstr ""
"Project-Id-Version: YAD\n"
"Report-Msgid-Bugs-To: \n"
"POT-Creation-Date: 2021-04-1
7 16:19
+0300\n"
"POT-Creation-Date: 2021-04-1
8 09:24
+0300\n"
"PO-Revision-Date: 2009-04-30 16:47+0300\n"
"Last-Translator: Victor Ananjevsky <ananasik@gmail.com>\n"
"Language-Team: \n"
...
...
@@ -45,7 +45,7 @@ msgstr ""
"Вбудована підтримка GtkSpell\n"
"Використовується GTK+ %d.%d.%d\n"
#: ../src/calendar.c:39 ../src/text.c:
397
#: ../src/calendar.c:39 ../src/text.c:
585
#, c-format
msgid "Cannot open file '%s': %s\n"
msgstr "Не можу відкрити файл %s: %s\n"
...
...
@@ -65,49 +65,51 @@ msgstr "Початкове значення - менше за мінімальн
msgid "Initial value greater than maximum.\n"
msgstr "Початкове значення - більше за максимальне.\n"
#: ../src/form.c:45
3
#: ../src/form.c:45
5
msgid "Select files"
msgstr "Вибір файлу"
#: ../src/form.c:456 ../src/form.c:464 ../src/form.c:543 ../src/form.c:551
#: ../src/form.c:602 ../src/html.c:175 ../src/html.c:207 ../src/util.c:40
#: ../src/form.c:458 ../src/form.c:466 ../src/form.c:545 ../src/form.c:553
#: ../src/form.c:604 ../src/html.c:175 ../src/html.c:207 ../src/text.c:160
#: ../src/text.c:225 ../src/util.c:40
msgid "Cancel"
msgstr "Відміна"
#: ../src/form.c:457 ../src/form.c:465 ../src/form.c:544 ../src/form.c:552
#: ../src/form.c:603 ../src/html.c:174 ../src/util.c:46
#: ../src/form.c:459 ../src/form.c:467 ../src/form.c:546 ../src/form.c:554
#: ../src/form.c:605 ../src/html.c:174 ../src/text.c:161 ../src/text.c:226
#: ../src/util.c:46
msgid "OK"
msgstr "OK"
#: ../src/form.c:46
1
#: ../src/form.c:46
3
msgid "Select folders"
msgstr "Вибір каталогів"
#: ../src/form.c:54
0
#: ../src/form.c:54
2
msgid "Select or create file"
msgstr "Вибір або створення файлу"
#: ../src/form.c:5
48
#: ../src/form.c:5
50
msgid "Select or create folder"
msgstr "Вибір або створення каталогу"
#: ../src/form.c:
599
#: ../src/form.c:
601
msgid "Select date"
msgstr "Вибір дати"
#: ../src/form.c:9
12
#: ../src/form.c:9
60
msgid "Select file"
msgstr "Вибір файлу"
#: ../src/form.c:9
42
#: ../src/form.c:9
90
msgid "Select folder"
msgstr "Вибір каталогу"
#: ../src/form.c:11
10 ../src/form.c:1112
#: ../src/form.c:11
58 ../src/form.c:1160
msgid "Link"
msgstr "Посилання"
#: ../src/html.c:171
#: ../src/html.c:171
../src/text.c:157 ../src/text.c:222
msgid "YAD - Select File"
msgstr "YAD - Вибір файлу"
...
...
@@ -325,8 +327,8 @@ msgstr "Задати вирівнювання тексту діалогу (left,
#: ../src/option.c:225 ../src/option.c:370 ../src/option.c:397
#: ../src/option.c:453 ../src/option.c:463 ../src/option.c:509
#: ../src/option.c:541 ../src/option.c:553 ../src/option.c:563
#: ../src/option.c:577 ../src/option.c:638 ../src/option.c:68
5
#: ../src/option.c:71
2 ../src/option.c:714
../src/tools.c:80
#: ../src/option.c:577 ../src/option.c:638 ../src/option.c:68
7
#: ../src/option.c:71
4 ../src/option.c:716
../src/tools.c:80
msgid "TYPE"
msgstr "ТИП"
...
...
@@ -342,7 +344,7 @@ msgstr "ЗОБРАЖЕННЯ"
msgid "Use specified icon theme instead of default"
msgstr "Використовувати вказану тему іконок"
#: ../src/option.c:118 ../src/option.c:66
3
../src/browser.c:217
#: ../src/option.c:118 ../src/option.c:66
5
../src/browser.c:217
#: ../src/tools.c:81
msgid "THEME"
msgstr "ТЕМА"
...
...
@@ -572,8 +574,8 @@ msgstr "Відобразити скриті файли у діалозі виб
msgid "Set source filename"
msgstr "Задати ім'я файлу"
#: ../src/option.c:217 ../src/option.c:284 ../src/option.c:71
0
#: ../src/option.c:72
2
#: ../src/option.c:217 ../src/option.c:284 ../src/option.c:71
2
#: ../src/option.c:72
4
msgid "FILENAME"
msgstr "НАЗВА ФАЙЛУ"
...
...
@@ -619,7 +621,7 @@ msgstr "Задати ім'я програми"
#: ../src/option.c:243 ../src/option.c:245 ../src/option.c:247
#: ../src/option.c:257 ../src/option.c:401 ../src/option.c:526
#: ../src/option.c:7
08
#: ../src/option.c:7
10
msgid "STRING"
msgstr "РЯДОК"
...
...
@@ -725,7 +727,7 @@ msgid "Set initial color value"
msgstr "Задати початковий колір"
#: ../src/option.c:294 ../src/option.c:642 ../src/option.c:644
#: ../src/option.c:650 ../src/option.c:67
1 ../src/option.c:673
#: ../src/option.c:650 ../src/option.c:67
3 ../src/option.c:675
msgid "COLOR"
msgstr "КОЛІР"
...
...
@@ -1278,8 +1280,8 @@ msgid "Set initial value"
msgstr "Задати початкове значення"
#: ../src/option.c:608 ../src/option.c:610 ../src/option.c:612
#: ../src/option.c:614 ../src/option.c:618 ../src/option.c:68
1
#: ../src/option.c:68
3
#: ../src/option.c:614 ../src/option.c:618 ../src/option.c:68
3
#: ../src/option.c:68
5
msgid "VALUE"
msgstr "ЗНАЧЕННЯ"
...
...
@@ -1371,448 +1373,452 @@ msgstr "Використовувати розмітку pango"
msgid "Save file instead of print on exit"
msgstr "Зберігати файл замість виводу на виході"
#: ../src/option.c:661
#: ../src/option.c:656
msgid "Enable file operations"
msgstr "Дозволити файлові операції"
#: ../src/option.c:663
msgid "Use specified langauge for syntax highlighting"
msgstr "Використовувати вказану мову для підсвітки синтаксису"
#: ../src/option.c:66
1
#: ../src/option.c:66
3
msgid "LANG"
msgstr "МОВА"
#: ../src/option.c:66
3
#: ../src/option.c:66
5
msgid "Use specified theme"
msgstr "Використовувати вказану тему"
#: ../src/option.c:66
5
../data/yad.gschema.xml.in.h:17
#: ../src/option.c:66
7
../data/yad.gschema.xml.in.h:17
msgid "Show line numbers"
msgstr "Відображати номера строк"
#: ../src/option.c:66
7
../data/yad.gschema.xml.in.h:18
#: ../src/option.c:66
9
../data/yad.gschema.xml.in.h:18
msgid "Highlight current line"
msgstr "Виділяти активну строку"
#: ../src/option.c:6
69
#: ../src/option.c:6
71
msgid "Enable line marks"
msgstr "Дозволити позначки строк"
#: ../src/option.c:67
1
#: ../src/option.c:67
3
msgid "Set color for first type marks"
msgstr "Задати колір для поміток першого типу"
#: ../src/option.c:67
3
#: ../src/option.c:67
5
msgid "Set color for second type marks"
msgstr "Задати колір для поміток другого типу"
#: ../src/option.c:67
5
#: ../src/option.c:67
7
msgid "Set position of right margin"
msgstr "Задати позицію правого поля"
#: ../src/option.c:67
5
#: ../src/option.c:67
7
msgid "[POS]"
msgstr "[ПОЗИЦІЯ]"
#: ../src/option.c:67
7
../data/yad.gschema.xml.in.h:23
#: ../src/option.c:67
9
../data/yad.gschema.xml.in.h:23
msgid "Highlight matching brackets"
msgstr "Виділяти відповідні дужки"
#: ../src/option.c:6
79
../data/yad.gschema.xml.in.h:24
#: ../src/option.c:6
81
../data/yad.gschema.xml.in.h:24
msgid "Use autoindent"
msgstr "Використовувати автовирівнювання"
#: ../src/option.c:68
1
#: ../src/option.c:68
3
msgid "Set tabulation width"
msgstr "Задати ширину табуляції"
#: ../src/option.c:68
3
#: ../src/option.c:68
5
msgid "Set indentation width"
msgstr "Задати ширину вирівнювання"
#: ../src/option.c:68
5
#: ../src/option.c:68
7
msgid "Set smart Home/End behavior"
msgstr "Задати поведінку розумних Home/End"
#: ../src/option.c:68
7
#: ../src/option.c:68
9
msgid "Enable smart backspace"
msgstr "Використовувати розумній backspace"
#: ../src/option.c:6
89
../data/yad.gschema.xml.in.h:29
#: ../src/option.c:6
91
../data/yad.gschema.xml.in.h:29
msgid "Insert spaces instead of tabs"
msgstr "Вставляти пробіл замість табуляції"
#: ../src/option.c:69
6
#: ../src/option.c:69
8
msgid "Sets a filename filter"
msgstr "Задати фільтр файлів по масці"
#: ../src/option.c:69
6
#: ../src/option.c:69
8
msgid "NAME | PATTERN1 PATTERN2 ..."
msgstr "НАЗВА | ШАБЛОН1 ШАБЛОН2 ..."
#: ../src/option.c:
698
#: ../src/option.c:
700
msgid "Sets a mime-type filter"
msgstr "Задати фільтр файлів по типу mime"
#: ../src/option.c:
698
#: ../src/option.c:
700
msgid "NAME | MIME1 MIME2 ..."
msgstr "НАЗВА | ТИП1 ТИП2 ..."
#: ../src/option.c:70
0
#: ../src/option.c:70
2
msgid "Add filter for images"
msgstr "Додати фільтр для зображень"
#: ../src/option.c:70
0
#: ../src/option.c:70
2
msgid "[NAME]"
msgstr "[ІМ'Я]"
#: ../src/option.c:70
6
../src/tools.c:59
#: ../src/option.c:70
8
../src/tools.c:59
msgid "Print version"
msgstr "Вивести версію"
#: ../src/option.c:7
08
#: ../src/option.c:7
10
msgid "Load additional CSS settings from file or string"
msgstr "Завантажити додаткові налаштування CSS з файлу або строки"
#: ../src/option.c:71
0
#: ../src/option.c:71
2
msgid "Load additional CSS settings from file"
msgstr "Завантажити додаткові налаштування CSS з файлу"
#: ../src/option.c:71
2
#: ../src/option.c:71
4
msgid "Set policy for horizontal scrollbars (auto, always, never)"
msgstr "Задати тип горизонтальної прокрутки (auto, always, never)"
#: ../src/option.c:71
4
#: ../src/option.c:71
6
msgid "Set policy for vertical scrollbars (auto, always, never)"
msgstr "Задати тип вертикальної прокрутки (auto, always, never)"
#: ../src/option.c:71
6
#: ../src/option.c:71
8
msgid "Add path for search icons by name"
msgstr "Додати каталог для пошуку іконок"
#: ../src/option.c:71
6
#: ../src/option.c:71
8
msgid "PATH"
msgstr "КАТАЛОГ"
#: ../src/option.c:72
2
#: ../src/option.c:72
4
msgid "Load extra arguments from file"
msgstr "Завантажити додаткові аргументи з файлу"
#: ../src/option.c:9
27
#: ../src/option.c:9
31
#, c-format
msgid "Mark %s doesn't have a value\n"
msgstr "Помітці %s не надано значення\n"
#: ../src/option.c:96
4
#: ../src/option.c:96
8
msgid "Images"
msgstr "Зображення"
#: ../src/option.c:10
29
#: ../src/option.c:10
33
#, c-format
msgid "Unknown color mode: %s\n"
msgstr "Невідомий режим кольору: '%s'\n"
#: ../src/option.c:10
48
#: ../src/option.c:10
52
#, c-format
msgid "Unknown buttons layout type: %s\n"
msgstr "Невідомий тип розміщення кнопок: %s\n"
#: ../src/option.c:106
3
#: ../src/option.c:106
7
#, c-format
msgid "Unknown align type: %s\n"
msgstr "Невідомий тип вирівнювання: %s\n"
#: ../src/option.c:10
87
#: ../src/option.c:10
91
#, c-format
msgid "Unknown justification type: %s\n"
msgstr "Невідомий тип вирівнювання: %s\n"
#: ../src/option.c:110
4
#: ../src/option.c:110
8
#, c-format
msgid "Unknown tab position type: %s\n"
msgstr "Невідомий тип позиції вкладки: %s\n"
#: ../src/option.c:114
1
#: ../src/option.c:114
5
#, c-format
msgid "Unknown ellipsize type: %s\n"
msgstr "Невідомий тип урізання: %s\n"
#: ../src/option.c:115
4
#: ../src/option.c:115
8
#, c-format
msgid "Unknown orientation: %s\n"
msgstr "Невідома орієнтація: %s\n"
#: ../src/option.c:11
69
#: ../src/option.c:11
73
#, c-format
msgid "Unknown source type: %s\n"
msgstr "Невідомий тип даних: %s\n"
#: ../src/option.c:118
0
#: ../src/option.c:118
4
msgid "Progress log"
msgstr "Вікно журналу"
#: ../src/option.c:119
3
#: ../src/option.c:119
7
#, c-format
msgid "Unknown size type: %s\n"
msgstr "Невідомий тип розміру: %s\n"
#: ../src/option.c:123
5
#: ../src/option.c:123
9
#, c-format
msgid "Unknown completion type: %s\n"
msgstr "Невідомий тип доповнення: %s\n"
#: ../src/option.c:12
67
#: ../src/option.c:12
71
#, c-format
msgid "Unknown boolean format type: %s\n"
msgstr "Невідомий тип булєвських значень: %s\n"
#: ../src/option.c:128
3
#: ../src/option.c:128
7
#, c-format
msgid "Unknown grid lines type: %s\n"
msgstr "Невідомий тип розподільних ліній: %s\n"
#: ../src/option.c:130
0
#: ../src/option.c:130
4
#, c-format
msgid "Unknown scrollbar policy type: %s\n"
msgstr "Невідомий тип прокрутки: %s\n"
#: ../src/option.c:135
3
#: ../src/option.c:135
7
#, c-format
msgid "Unknown smart Home/End mode: %s\n"
msgstr "Невідомий режим розумних Home/End: '%s'\n"
#: ../src/option.c:146
3
#: ../src/option.c:146
7
#, c-format
msgid "Unknown signal: %s\n"
msgstr "Невідомий сигнал: %s\n"
#: ../src/option.c:1
697
#: ../src/option.c:1
701
msgid "File exist. Overwrite?"
msgstr "Файл існує. Перезаписати?"
#: ../src/option.c:18
89
#: ../src/option.c:18
94
msgid "- Yet another dialoging program"
msgstr "- Програма для відображення діалогів"
#. Adds general option entries
#: ../src/option.c:189
3
#: ../src/option.c:189
8
msgid "General options"
msgstr "Основні параметри"
#: ../src/option.c:189
3
#: ../src/option.c:189
8
msgid "Show general options"
msgstr "Показувати основні параметри"
#. Adds common option entries
#: ../src/option.c:1
899
#: ../src/option.c:1
904
msgid "Common options"
msgstr "Загальні параметри"
#: ../src/option.c:1
899
#: ../src/option.c:1
904
msgid "Show common options"
msgstr "Показувати загальні параметри діалогів"
#. Adds about option entries
#: ../src/option.c:19
05
#: ../src/option.c:19
10
msgid "About dialog options"
msgstr "Параметри діалогу о програмі"
#: ../src/option.c:19
05
#: ../src/option.c:19
10
msgid "Show custom about dialog options"
msgstr "Показувати параметри діалогу о програмі"
#. Adds app option entries
#: ../src/option.c:191
1
#: ../src/option.c:191
6
msgid "Application selection options"
msgstr "Параметри діалогу вибору додатка"
#: ../src/option.c:191
1
#: ../src/option.c:191
6
msgid "Show application selection options"
msgstr "Показувати параметри діалоги вибору додатка"
#. Adds calendar option entries
#: ../src/option.c:19
17
#: ../src/option.c:19
22
msgid "Calendar options"
msgstr "Параметри календаря"
#: ../src/option.c:19
17
#: ../src/option.c:19
22
msgid "Show calendar options"
msgstr "Показувати параметри календаря"
#. Adds color option entries
#: ../src/option.c:192
3
#: ../src/option.c:192
8
msgid "Color selection options"
msgstr "Параметри діалогу вибору кольору"
#: ../src/option.c:192
3
#: ../src/option.c:192
8
msgid "Show color selection options"
msgstr "Показувати параметри діалогу вибору кольору"
#. Adds dnd option entries
#: ../src/option.c:19
29
#: ../src/option.c:19
34
msgid "DND options"
msgstr "Параметри DND"
#: ../src/option.c:19
29
#: ../src/option.c:19
34
msgid "Show drag-n-drop options"
msgstr "Показувати параметри dnd"
#. Adds entry option entries
#: ../src/option.c:19
35
#: ../src/option.c:19
40
msgid "Text entry options"
msgstr "Параметри вводу тексту"
#: ../src/option.c:19
35
#: ../src/option.c:19
40
msgid "Show text entry options"
msgstr "Показувати параметри вводу тексту"
#. Adds file selection option entries
#: ../src/option.c:194
1
#: ../src/option.c:194
6
msgid "File selection options"
msgstr "Параметри діалогу вибору файлів"
#: ../src/option.c:194
1
#: ../src/option.c:194
6
msgid "Show file selection options"
msgstr "Показувати параметри діалогу вибору файлів"
#. Add font selection option entries
#: ../src/option.c:19
47
#: ../src/option.c:19
52
msgid "Font selection options"
msgstr "Параметри діалогу вибору шрифту"
#: ../src/option.c:19
47
#: ../src/option.c:19
52
msgid "Show font selection options"
msgstr "Показувати параметри діалоги вибору шрифту"
#. Add form option entries
#: ../src/option.c:195
3
#: ../src/option.c:195
8
msgid "Form options"
msgstr "Параметри діалогу форми"
#: ../src/option.c:195
3
#: ../src/option.c:195
8
msgid "Show form options"
msgstr "Показувати параметри діалогу форми"
#. Add html options entries
#: ../src/option.c:196
0
#: ../src/option.c:196
5
msgid "HTML options"
msgstr "Параметри HTML діалогу"
#: ../src/option.c:196
0
#: ../src/option.c:196
5
msgid "Show HTML options"
msgstr "Показувати параметри HTML діалогу"
#. Add icons option entries
#: ../src/option.c:19
67
#: ../src/option.c:19
72
msgid "Icons box options"
msgstr "Параметри діалогу іконок"
#: ../src/option.c:19
67
#: ../src/option.c:19
72
msgid "Show icons box options"
msgstr "Показувати параметри діалогу іконок швидкого доступу"
#. Adds list option entries
#: ../src/option.c:197
3
#: ../src/option.c:197
8
msgid "List options"
msgstr "Параметри списку"
#: ../src/option.c:197
3
#: ../src/option.c:197
8
msgid "Show list options"
msgstr "Показувати параметри списку"
#. Adds notebook option entries
#: ../src/option.c:19
79
#: ../src/option.c:19
84
msgid "Notebook options"
msgstr "Параметри діалогу з вкладками"
#: ../src/option.c:19
79
#: ../src/option.c:19
84
msgid "Show notebook dialog options"
msgstr "Показувати параметри діалогу з вкладками"
#. Adds notification option entries
#: ../src/option.c:19
86
#: ../src/option.c:19
91
msgid "Notification icon options"
msgstr "Параметри іконки повідомлень"
#: ../src/option.c:19
87
#: ../src/option.c:19
92
msgid "Show notification icon options"
msgstr "Показувати параметри іконки повідомлень"
#. Adds paned option entries
#: ../src/option.c:199
4
#: ../src/option.c:199
9
msgid "Paned dialog options"
msgstr "Параметри діалогу з панелями"
#: ../src/option.c:199
4
#: ../src/option.c:199
9
msgid "Show paned dialog options"
msgstr "Показувати параметри діалогу з панелями"
#. Adds picture option entries
#: ../src/option.c:200
0
#: ../src/option.c:200
5
msgid "Picture dialog options"
msgstr "Параметри діалогу з картинкою"
#: ../src/option.c:200
0
#: ../src/option.c:200
5
msgid "Show picture dialog options"
msgstr "Показувати параметри діалогу відображення картинки"
#. Adds print option entries
#: ../src/option.c:20
06
#: ../src/option.c:20
11
msgid "Print dialog options"
msgstr "Параметри діалогу друку"
#: ../src/option.c:20
06
#: ../src/option.c:20
11
msgid "Show print dialog options"
msgstr "Показувати параметри діалогу друку"
#. Adds progress option entries
#: ../src/option.c:201
2
#: ../src/option.c:201
7
msgid "Progress options"
msgstr "Параметри прогресу"
#: ../src/option.c:201
2
#: ../src/option.c:201
7
msgid "Show progress options"
msgstr "Показувати параметри прогресу"
#. Adds scale option entries
#: ../src/option.c:20
18
#: ../src/option.c:20
23
msgid "Scale options"
msgstr "Параметри масштабу"
#: ../src/option.c:20
18
#: ../src/option.c:20
23
msgid "Show scale options"
msgstr "Показувати параметри масштабу"
#. Adds text option entries
#: ../src/option.c:202
4
#: ../src/option.c:202
9
msgid "Text information options"
msgstr "Параметри текстової інформації"
#: ../src/option.c:202
4
#: ../src/option.c:202
9
msgid "Show text information options"
msgstr "Показувати параметри текстової інформації"
#. Adds sourceview option entries
#: ../src/option.c:203
1
#: ../src/option.c:203
6
msgid "SourceView options"
msgstr "Параметри SourceView"
#: ../src/option.c:203
1
#: ../src/option.c:203
6
msgid "Show SourceView options"
msgstr "Показувати параметри SourceView"
#. Adds file filters option entries
#: ../src/option.c:20
38
#: ../src/option.c:20
43
msgid "File filter options"
msgstr "Параметри фільтрів для діалогу вибору файлів"
#: ../src/option.c:20
38
#: ../src/option.c:20
43
msgid "Show file filter options"
msgstr "Показувати параметри фільтрів для діалогу вибору файлів"
#. Adds miscellaneous option entries
#: ../src/option.c:204
4
#: ../src/option.c:204
9
msgid "Miscellaneous options"
msgstr "Додаткові параметри"
#: ../src/option.c:204
4
#: ../src/option.c:204
9
msgid "Show miscellaneous options"
msgstr "Показувати додаткові параметри"
...
...
@@ -1915,7 +1921,23 @@ msgstr "Колір"
msgid "Name"
msgstr "Назва"
#: ../src/text.c:535
#: ../src/text.c:278
msgid "Save _as..."
msgstr "Зберегти _як..."
#: ../src/text.c:283
msgid "_Save"
msgstr "_Зберегти"
#: ../src/text.c:292
msgid "_Open..."
msgstr "_Відкрити..."
#: ../src/text.c:302
msgid "_Quit"
msgstr "В_ихід"
#: ../src/text.c:723
#, c-format
msgid "Theme %s not found\n"
msgstr "Теми %s не знайдено\n"
...
...
src/option.c
View file @
ee416fc8
...
...
@@ -652,6 +652,8 @@ static GOptionEntry text_options[] = {
N_
(
"Use pango markup"
),
NULL
},
{
"in-place"
,
0
,
0
,
G_OPTION_ARG_NONE
,
&
options
.
text_data
.
in_place
,
N_
(
"Save file instead of print on exit"
),
NULL
},
{
"file-op"
,
0
,
0
,
G_OPTION_ARG_NONE
,
&
options
.
text_data
.
file_op
,
N_
(
"Enable file operations"
),
NULL
},
{
NULL
}
};
...
...
@@ -1844,6 +1846,7 @@ yad_options_init (void)
#endif
options
.
text_data
.
formatted
=
FALSE
;
options
.
text_data
.
in_place
=
FALSE
;
options
.
text_data
.
file_op
=
FALSE
;
#ifdef HAVE_SOURCEVIEW
/* Initialize sourceview data */
...
...
src/text.c
View file @
ee416fc8
...
...
@@ -142,14 +142,202 @@ show_search ()
gdk_event_free
(
fev
);
}
/* early prototype for use in open_file_cb() */
static
void
fill_buffer_from_file
();
static
void
open_file_cb
(
GtkWidget
*
w
,
gpointer
d
)
{
GtkWidget
*
dlg
;
static
gchar
*
dir
=
NULL
;
if
(
!
dir
&&
options
.
common_data
.
uri
)
dir
=
g_path_get_dirname
(
options
.
common_data
.
uri
);
dlg
=
gtk_file_chooser_dialog_new
(
_
(
"YAD - Select File"
),
GTK_WINDOW
(
gtk_widget_get_toplevel
(
text_view
)),
GTK_FILE_CHOOSER_ACTION_OPEN
,
_
(
"Cancel"
),
GTK_RESPONSE_CANCEL
,
_
(
"OK"
),
GTK_RESPONSE_ACCEPT
,
NULL
);
if
(
dir
)
gtk_file_chooser_set_current_folder
(
GTK_FILE_CHOOSER
(
dlg
),
dir
);
if
(
gtk_dialog_run
(
GTK_DIALOG
(
dlg
))
==
GTK_RESPONSE_ACCEPT
)
{
/* set new filename and load it */
if
(
options
.
common_data
.
uri
)
g_free
(
options
.
common_data
.
uri
);
options
.
common_data
.
uri
=
gtk_file_chooser_get_filename
(
GTK_FILE_CHOOSER
(
dlg
));
fill_buffer_from_file
();
/* keep current dir */
g_free
(
dir
);
dir
=
gtk_file_chooser_get_current_folder
(
GTK_FILE_CHOOSER
(
dlg
));
}
gtk_widget_destroy
(
dlg
);
}
static
void
save_file_cb
(
GtkWidget
*
w
,
gpointer
d
)
{
GtkTextIter
start
,
end
;
gchar
*
text
;
GStatBuf
st
;
gint
mode
=
-
1
;
GError
*
err
=
NULL
;
gtk_text_buffer_get_bounds
(
GTK_TEXT_BUFFER
(
text_buffer
),
&
start
,
&
end
);
text
=
gtk_text_buffer_get_text
(
GTK_TEXT_BUFFER
(
text_buffer
),
&
start
,
&
end
,
0
);
/* g_file_set_contents changes the file permissions. so it must be kept and restore after file saving */
if
(
g_stat
(
options
.
common_data
.
uri
,
&
st
)
==
0
)
mode
=
st
.
st_mode
;
if
(
!
g_file_set_contents
(
options
.
common_data
.
uri
,
text
,
-
1
,
&
err
))
{
g_printerr
(
"Cannot save file %s: %s
\n
"
,
options
.
common_data
.
uri
,
err
->
message
);
g_error_free
(
err
);
}
else
{
/* restore permissions */
if
(
mode
!=
-
1
)
g_chmod
(
options
.
common_data
.
uri
,
st
.
st_mode
);
}
g_free
(
text
);
}
static
void
save_as_file_cb
(
GtkWidget
*
w
,
gpointer
d
)
{
GtkWidget
*
dlg
;
static
gchar
*
dir
=
NULL
;
if
(
!
dir
&&
options
.
common_data
.
uri
)
dir
=
g_path_get_dirname
(
options
.
common_data
.
uri
);
dlg
=
gtk_file_chooser_dialog_new
(
_
(
"YAD - Select File"
),
GTK_WINDOW
(
gtk_widget_get_toplevel
(
text_view
)),
GTK_FILE_CHOOSER_ACTION_SAVE
,
_
(
"Cancel"
),
GTK_RESPONSE_CANCEL
,
_
(
"OK"
),
GTK_RESPONSE_ACCEPT
,
NULL
);
gtk_file_chooser_set_create_folders
(
GTK_FILE_CHOOSER
(
dlg
),
TRUE
);
if
(
dir
)
gtk_file_chooser_set_current_folder
(
GTK_FILE_CHOOSER
(
dlg
),
dir
);
if
(
options
.
common_data
.
uri
)
gtk_file_chooser_set_filename
(
GTK_FILE_CHOOSER
(
dlg
),
options
.
common_data
.
uri
);
else
gtk_file_chooser_set_current_name
(
GTK_FILE_CHOOSER
(
dlg
),
"Untitled.txt"
);
if
(
gtk_dialog_run
(
GTK_DIALOG
(
dlg
))
==
GTK_RESPONSE_ACCEPT
)
{
/* set new filename and save it */
if
(
options
.
common_data
.
uri
)
g_free
(
options
.
common_data
.
uri
);
options
.
common_data
.
uri
=
gtk_file_chooser_get_filename
(
GTK_FILE_CHOOSER
(
dlg
));
save_file_cb
(
w
,
d
);
/* keep current dir */
g_free
(
dir
);
dir
=
gtk_file_chooser_get_current_folder
(
GTK_FILE_CHOOSER
(
dlg
));
}
gtk_widget_destroy
(
dlg
);
}
static
void
quit_cb
(
GtkWidget
*
w
,
gpointer
d
)
{
yad_exit
(
options
.
data
.
def_resp
);
}
static
void
menu_popup_cb
(
GtkTextView
*
w
,
GtkWidget
*
popup
,
gpointer
d
)
{
if
(
!
GTK_IS_MENU
(
popup
))
return
;
if
(
options
.
text_data
.
file_op
)
{
GtkWidget
*
mitem
;
/* on top */
mitem
=
gtk_separator_menu_item_new
();
gtk_menu_shell_prepend
(
GTK_MENU_SHELL
(
popup
),
mitem
);
gtk_widget_show
(
mitem
);
if
(
options
.
common_data
.
editable
)
{
mitem
=
gtk_menu_item_new_with_mnemonic
(
_
(
"Save _as..."
));
gtk_menu_shell_prepend
(
GTK_MENU_SHELL
(
popup
),
mitem
);
g_signal_connect
(
G_OBJECT
(
mitem
),
"activate"
,
G_CALLBACK
(
save_as_file_cb
),
NULL
);
gtk_widget_show
(
mitem
);
mitem
=
gtk_menu_item_new_with_mnemonic
(
_
(
"_Save"
));
gtk_menu_shell_prepend
(
GTK_MENU_SHELL
(
popup
),
mitem
);
g_signal_connect
(
G_OBJECT
(
mitem
),
"activate"
,
G_CALLBACK
(
save_file_cb
),
NULL
);
gtk_widget_show
(
mitem
);
if
(
!
options
.
common_data
.
uri
)
gtk_widget_set_sensitive
(
mitem
,
FALSE
);
}
mitem
=
gtk_menu_item_new_with_mnemonic
(
_
(
"_Open..."
));
gtk_menu_shell_prepend
(
GTK_MENU_SHELL
(
popup
),
mitem
);
g_signal_connect
(
G_OBJECT
(
mitem
),
"activate"
,
G_CALLBACK
(
open_file_cb
),
NULL
);
gtk_widget_show
(
mitem
);
/* at bootom */
mitem
=
gtk_separator_menu_item_new
();
gtk_menu_shell_append
(
GTK_MENU_SHELL
(
popup
),
mitem
);
gtk_widget_show
(
mitem
);
mitem
=
gtk_menu_item_new_with_mnemonic
(
_
(
"_Quit"
));
gtk_menu_shell_append
(
GTK_MENU_SHELL
(
popup
),
mitem
);
g_signal_connect
(
G_OBJECT
(
mitem
),
"activate"
,
G_CALLBACK
(
quit_cb
),
NULL
);
gtk_widget_show
(
mitem
);
}
}
static
gboolean
key_press_cb
(
GtkWidget
*
w
,
GdkEventKey
*
key
,
gpointer
data
)
key_press_cb
(
GtkWidget
*
w
,
GdkEventKey
*
key
,
gpointer
d
)
{
if
((
key
->
state
&
GDK_CONTROL_MASK
)
&&
(
key
->
keyval
==
GDK_KEY_F
||
key
->
keyval
==
GDK_KEY_f
))
{
show_search
();
return
TRUE
;
}
else
if
(
options
.
text_data
.
file_op
)
{
if
((
key
->
state
&
GDK_CONTROL_MASK
)
&&
(
key
->
keyval
==
GDK_KEY_O
||
key
->
keyval
==
GDK_KEY_o
))
{
open_file_cb
(
NULL
,
NULL
);
return
TRUE
;
}
else
if
((
key
->
state
&
GDK_CONTROL_MASK
)
&&
(
key
->
keyval
==
GDK_KEY_S
||
key
->
keyval
==
GDK_KEY_s
))
{
save_file_cb
(
NULL
,
NULL
);
return
TRUE
;
}
else
if
((
key
->
state
&
GDK_CONTROL_MASK
)
&&
(
key
->
state
&
GDK_SHIFT_MASK
)
&&
(
key
->
keyval
==
GDK_KEY_S
||
key
->
keyval
==
GDK_KEY_s
))
{
save_as_file_cb
(
NULL
,
NULL
);
return
TRUE
;
}
else
if
((
key
->
state
&
GDK_CONTROL_MASK
)
&&
(
key
->
keyval
==
GDK_KEY_Q
||
key
->
keyval
==
GDK_KEY_q
))
{
quit_cb
(
NULL
,
NULL
);
return
TRUE
;
}
}
return
FALSE
;
}
...
...
@@ -499,7 +687,7 @@ text_create_widget (GtkWidget * dlg)
}
#ifdef HAVE_SOURCEVIEW
if
(
options
.
source_data
.
theme
)
if
(
options
.
source_data
.
theme
&&
*
options
.
source_data
.
theme
)
{
GtkSourceStyleScheme
*
scheme
=
NULL
;
GtkSourceStyleSchemeManager
*
mgr
;
...
...
@@ -590,6 +778,9 @@ text_create_widget (GtkWidget * dlg)
/* Add keyboard handler */
g_signal_connect
(
text_view
,
"key-press-event"
,
G_CALLBACK
(
key_press_cb
),
dlg
);
if
(
options
.
text_data
.
file_op
)
g_signal_connect_after
(
text_view
,
"populate-popup"
,
G_CALLBACK
(
menu_popup_cb
),
dlg
);
/* Initialize linkifying */
if
(
options
.
text_data
.
uri
)
{
...
...
@@ -636,37 +827,19 @@ text_create_widget (GtkWidget * dlg)
void
text_print_result
(
void
)
{
GtkTextIter
start
,
end
;
gchar
*
text
;
if
(
!
options
.
common_data
.
editable
)
return
;
gtk_text_buffer_get_bounds
(
GTK_TEXT_BUFFER
(
text_buffer
),
&
start
,
&
end
);
text
=
gtk_text_buffer_get_text
(
GTK_TEXT_BUFFER
(
text_buffer
),
&
start
,
&
end
,
0
);
if
(
options
.
text_data
.
in_place
&&
options
.
common_data
.
uri
)
{
GStatBuf
st
;
GError
*
err
=
NULL
;
/* g_file_set_contents changes the file permissions. so it must kept and restore after file saving */
if
(
g_stat
(
options
.
common_data
.
uri
,
&
st
)
==
0
)
{
if
(
!
g_file_set_contents
(
options
.
common_data
.
uri
,
text
,
-
1
,
&
err
))
{
g_printerr
(
"Cannot save file %s: %s
\n
"
,
options
.
common_data
.
uri
,
err
->
message
);
g_error_free
(
err
);
}
save_file_cb
(
NULL
,
NULL
);
else
{
/* restore permissions */
g_chmod
(
options
.
common_data
.
uri
,
st
.
st_mode
);
}
}
else
g_printerr
(
"Cannot stat file %s
\n
"
,
options
.
common_data
.
uri
);
}
else
GtkTextIter
start
,
end
;
gchar
*
text
;
gtk_text_buffer_get_bounds
(
GTK_TEXT_BUFFER
(
text_buffer
),
&
start
,
&
end
);
text
=
gtk_text_buffer_get_text
(
GTK_TEXT_BUFFER
(
text_buffer
),
&
start
,
&
end
,
0
);
g_print
(
"%s"
,
text
);
g_free
(
text
);
}
}
src/yad.h
View file @
ee416fc8
...
...
@@ -474,6 +474,7 @@ typedef struct {
gchar
*
fore
;
gchar
*
back
;
gboolean
in_place
;
gboolean
file_op
;
}
YadTextData
;
#ifdef HAVE_SOURCEVIEW
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment