Commit Graph

3987 Commits

Author SHA1 Message Date
Ilia Maslakov
afb498de3a Ticket #2456 (Incorrect restore selection after UNDO)
fixed incorrect restore selection after UNDO

    test case:
        1. mcedit new_empty_file
        2. type in 0123456789
        3. F3 5*left F3 - digit '4' is not marked at this point
        4. backspace, ctrl-u - digit '4' is marked now
        5. left, 2*del, 2*ctrl-u - digits '4' and '5' are not marked

Signed-off-by: Ilia Maslakov <il.smind@gmail.com>
2011-02-04 18:32:13 +03:00
Ilia Maslakov
9b5de3c96b direct commit: utf8 fixup
Signed-off-by: Ilia Maslakov <il.smind@gmail.com>
2011-02-03 17:14:48 +03:00
Ilia Maslakov
f42e10ab1d Ticket #2484 (segfault after getting previous char)
fixed segfault after getting the previous char in utf8, if previous char's
    are: 0xB1, 0xB3, 0xB6, 0xBF, 0xBC.

Signed-off-by: Ilia Maslakov <il.smind@gmail.com>
2011-02-03 09:50:15 +03:00
Andrew Borodin
e3cbdfad04 Ticket #2489: colors of bold and selected text in viewer cannot be set in the command line
...using --colors option.

Signed-off-by: Andrew Borodin <aborodin@vmail.ru>
2011-02-02 14:55:06 +03:00
Andrew Borodin
09021fd954 Reorganization of "Show mini info" option.
"Show mini info" checkbox was moved from the "Layout" dialog window
to the "Panel options" one. Documentation was updated.
The show_mini_info global variable was transformed to the member
of panels_options_t structure.

Signed-off-by: Andrew Borodin <aborodin@vmail.ru>
2011-01-30 12:23:32 +03:00
Andrew Borodin
f13778d94f torben_fj_mode options was moved from [Midnight-Commander] section to [Panels] one.
Signed-off-by: Andrew Borodin <aborodin@vmail.ru>
2011-01-30 12:23:32 +03:00
Andrew Borodin
5341a6b53f Ticket #2305: drop backward compatibility for global panels options.
Drop backward compatibility for global panels options. These options
are read form [Panels] section, if this section exists. If this section
is abscent, default values are used.

Signed-off-by: Andrew Borodin <aborodin@vmail.ru>
2011-01-30 12:23:32 +03:00
Slava Zanko
8af4c9ca7f menu file now searched also in mc_sysconfig_dir directory
Signed-off-by: Slava Zanko <slavazanko@gmail.com>
2011-01-20 17:44:04 +02:00
Slava Zanko
c8982e822c Updated docs (man pages and comments in source code)
Signed-off-by: Slava Zanko <slavazanko@gmail.com>
2011-01-20 17:38:27 +02:00
Slava Zanko
f31863a80a Renamed variables mc_home to mc_sysconfig_dir and mc_home_alt to mc_share_data_dir for more sence
Signed-off-by: Slava Zanko <slavazanko@gmail.com>
2011-01-20 17:38:27 +02:00
Slava Zanko
acbe048486 Ticket #1851: Home config directory [xdg-user-dirs]
Instead of hardcoded (via MC_USERCONF_DIR) path mc mc now used
dynamic directories specified by environment variables:
 * XDG_CONFIG_HOME - dir for config files . By default is ~/.config/mc
 * XDG_DATA_HOME - dir for some data, such as user defuned Syntax file, menu etc By default is ~/.local/share/mc
 * XDG_CACHE_HOME - dir for temp files, such as cooledit.clip etc. By default is ~/.cache/mc

This is mainstream standard already adopted by many projects.

Old settings will be migrated at first time from ~/.mc to these dirs.

See http://standards.freedesktop.org/basedir-spec/basedir-spec-latest.html for more info.

Signed-off-by: Slava Zanko <slavazanko@gmail.com>
Signed-off-by: Andrew Borodin <aborodin@vmail.ru>
2011-01-20 17:38:27 +02:00
Andrew Borodin
1f98ee6dc7 Refactoring.
(paint_panel): removed. Sending of WIDGET_DRAW message is used instead.
(update_dirty_panels): moved from panel.c to midnight.c.

Signed-off-by: Andrew Borodin <aborodin@vmail.ru>
Signed-off-by: Slava Zanko <slavazanko@gmail.com>
2011-01-19 13:03:54 +03:00
Andrew Borodin
57cdd0a08a Refactoring.
(restore_into_right_dir_panel): made static.
(panel_update_cols): moved from panel.[ch] to layout.[ch].
(set_display_type): minor cleanup and type accuracy.
(panel_display_t): type accuracy

Signed-off-by: Andrew Borodin <aborodin@vmail.ru>
2011-01-19 13:03:54 +03:00
Andrew Borodin
c7fdc8f95b Ticket #2390: file list format of panel is intialized incorrectly
...after switch panel back from quick view or info mode to file list one.

Signed-off-by: Andrew Borodin <aborodin@vmail.ru>
2011-01-19 13:03:39 +03:00
Andrew Borodin
99b60cc2b3 Ticket #2466: main menu is not drawn correctly
...after change of it visibility and activity.

Signed-off-by: Andrew Borodin <aborodin@vmail.ru>
2011-01-12 13:00:36 +03:00
Andrew Borodin
16c13be47b Added option to change mode of panel swap.
New "Simple panels swap" checkbox in "Panel options" configuration
dialog window. Unchecked by default.

Documentation update.

Signed-off-by: Andrew Borodin <aborodin@vmail.ru>
2011-01-08 16:29:18 +03:00
Andrew Borodin
2c994461a6 Forced update listing format after swap
...because of possible changed sizes.

Signed-off-by: Andrew Borodin <aborodin@vmail.ru>
2011-01-08 16:29:18 +03:00
Andrew Borodin
2a98492e77 Resort swapped panels in according with its sort options.
Signed-off-by: Andrew Borodin <aborodin@vmail.ru>
2011-01-08 16:29:18 +03:00
Andrew Borodin
2ebfd4e293 Ticket #2368: swap panels should respect sort options.
Initial step: refactoring: create new panel_sort_info_t structure
to store sort options of panel.
Type accuracy.

Signed-off-by: Andrew Borodin <aborodin@vmail.ru>
2011-01-08 16:29:18 +03:00
Ilia Maslakov
7bd3a17db7 do not set modify flag when user menu cancelled.
Signed-off-by: Ilia Maslakov <il.smind@gmail.com>
2011-01-06 16:01:52 +00:00
Ilia Maslakov
bf7675246f Ticket #2463 (do not reset selection after execute user menu)
do not reset selection after execute user menu

Signed-off-by: Ilia Maslakov <il.smind@gmail.com>
2011-01-06 16:01:51 +00:00
Andrew Borodin
186b2ff3f7 Ticket #2464: find file: don't check content regexp
...if search for content is not used.

Signed-off-by: Andrew Borodin <aborodin@vmail.ru>
2011-01-06 18:49:48 +03:00
Anton Novosyolov
a30cf7e980 Ticket #2266: filtered view default text
I suggest changing default text in filtered view (alt-!) command input line
instead current filename in panel to contents of cmdline.

It's easier to edit command line with commands like alt-tab,
alt-enter, etc., and then view the result in mcview.

Signed-off-by: Slava Zanko <slavazanko@gmail.com>
2011-01-06 11:02:00 +02:00
Andrew Borodin
45306458ca Ticket #2458: fixed broken command autocompletion.
Signed-off-by: Andrew Borodin <aborodin@vmail.ru>
2011-01-05 15:22:40 +03:00
Ilia Maslakov
ab46ad0749 Modified editor general options gialog
...added "Group undo" option.

Signed-off-by: Ilia Maslakov <il.smind@gmail.com>
Signed-off-by: Andrew Borodin <aborodin@vmail.ru>
2011-01-01 21:17:27 +00:00
Ilia Maslakov
b39033812b Ticket #27 (group undo)
added option editor_group_undo unset by default
    added group undo mechanism

Signed-off-by: Ilia Maslakov <il.smind@gmail.com>
2011-01-01 21:17:19 +00:00
Ilia Maslakov
d84fb5d0ce updated default_editor_keymap, added default for CK_Redo
Signed-off-by: Ilia Maslakov <il.smind@gmail.com>
2010-12-30 21:23:43 +00:00
Ilia Maslakov
6832b8e7e9 binded EditRedo on alt-r
added entry Redo into editor menu

Signed-off-by: Ilia Maslakov <il.smind@gmail.com>
2010-12-30 21:23:43 +00:00
Ilia Maslakov
03363eac71 added action EditRedo.
added functions:
        * edit_push_redo_action
        * edit_pop_redo_action
        * edit_do_redo

    removed not supported (not actual) code

Signed-off-by: Ilia Maslakov <il.smind@gmail.com>
2010-12-30 21:23:42 +00:00
Ilia Maslakov
b5fc178027 Ticket #25 (mcedit: REDO)
little optimization, renamed:
        * variables stack* to undo_stack*
        * pop_action to edit_pop_undo_action
        * edit_push_action to edit_push_undo_action

Signed-off-by: Ilia Maslakov <il.smind@gmail.com>
2010-12-30 21:23:42 +00:00
Andrew Borodin
da2c82e8d3 Ticket #2170: color of panel header cannot be set in the command line
...using --colors option.

Grammar in default skin description.

Signed-off-by: Andrew Borodin <aborodin@vmail.ru>
2010-12-29 13:58:28 +03:00
Egmont Koblinger
e593572bb9 Ticket #2169: Add support for 256 colors terminals
Forget the old limit of 8 background and 16 foreground colors.
From now on Midnight Commander can use all the 256 colors,
as your favorite terminal emulator supports them - or not,
in which case it's not going to stay your favorite terminal for long.

Signed-off-by: Slava Zanko <slavazanko@gmail.com>
2010-12-29 11:58:10 +02:00
Andrew Borodin
a8b62e421e (warn_same_file): cleanup of preprocessing usage.
Signed-off-by: Andrew Borodin <aborodin@vmail.ru>
2010-12-27 15:57:16 +03:00
Andrew Borodin
7cfaeca063 Panel update: type accuracy.
Signed-off-by: Andrew Borodin <aborodin@vmail.ru>
2010-12-27 15:57:16 +03:00
Andrew Borodin
75fa78595e (single_dirsize_cmd): send CK_PanelMoveDown message instead of KEY_DOWN one to panel.
Signed-off-by: Andrew Borodin <aborodin@vmail.ru>
2010-12-27 15:57:16 +03:00
Ilia Maslakov
7d21002668 Ticket #1898 (mcedit: vertical selection bug)
now after changing the cursor position does not break the vertical text selection.

Signed-off-by: Ilia Maslakov <il.smind@gmail.com>
2010-12-23 16:03:56 +00:00
Jindrich Novy
b51ae367da fix crash in progress bar handling
Signed-off-by: Slava Zanko <slavazanko@gmail.com>
2010-12-23 14:25:39 +03:00
Andrew Borodin
4abfaf8172 Ticket #2448: division by zero in file copy progress dialog.
Signed-off-by: Andrew Borodin <aborodin@vmail.ru>
Signed-off-by: Slava Zanko <slavazanko@gmail.com>
2010-12-23 14:25:39 +03:00
Andrew Borodin
16c37545a3 (try_complete): fix completion for file names started with one character.
Signed-off-by: Andrew Borodin <aborodin@vmail.ru>
2010-12-23 13:24:55 +03:00
Ilia Maslakov
e4de4f00d1 little changes to make 'completion' more intuitive.
Signed-off-by: Ilia Maslakov <il.smind@gmail.com>
2010-12-23 13:24:55 +03:00
Andrew Borodin
b5d3857e29 Fixup of path autocompletion
...and reorganizing of some conditions.

Signed-off-by: Andrew Borodin <aborodin@vmail.ru>
Signed-off-by: Ilia Maslakov <il.smind@gmail.com>
2010-12-22 10:35:32 +03:00
Andrew Borodin
e8b36e50ca Ticket #2288: regression of path autocompletion.
(check_is_cd): fix of cd command check.
Type accuracy: check_is_cd() now returns gboolean instead of int.
Initialize start and end variables.

Signed-off-by: Andrew Borodin <aborodin@vmail.ru>
Signed-off-by: Ilia Maslakov <il.smind@gmail.com>
2010-12-22 10:35:23 +03:00
Ilia Maslakov
40523a2c01 Ticket #2449 (search position is reset but should not be)
steps to reproduce:

    mcview_remember_file_position=1

    test file: file1.ext
        123
        456
        123
        qwe
        123
        123
        qwe
        123
        qwe
        456

    1) open file1.ext in mcedit search text 'qwe'
    2) close file1.ext
    3) open file1.ext in mcview
    4) close file1.ext
    5) reopen file1.ext in mcedit and search again text 'qwe'

    search position is reset but should not be reset.

Signed-off-by: Ilia Maslakov <il.smind@gmail.com>
2010-12-15 21:04:19 +00:00
Ilia Maslakov
2e73ca4989 Ticket #2437 (mcedit: selection length trouble)
now selection length do not changed after text is backspaced in middle selection.

Signed-off-by: Ilia Maslakov <il.smind@gmail.com>
2010-12-13 12:02:16 +02:00
Ilia Maslakov
bac3fbe8a9 Ticket #2238 (mcedit: do not reset selection after copy to clipboard)
In mcedit, when the selected text is copied to the clipboard, the selection disappears.
    This behavior contradicts to the traditional behavior of all modern text editors and is highly annoying.
    Now selection don't reset after the text is copied into the clipboard.

Signed-off-by: Ilia Maslakov <il.smind@gmail.com>
2010-12-10 11:32:09 +03:00
Andrew Borodin
3e91f81a88 Restore space after address in hex mode.
Signed-off-by: Andrew Borodin <aborodin@vmail.ru>
2010-12-06 14:44:04 +03:00
Andrew Borodin
0f3729426a Ticket #2435: goto to the specified address in hex mode of viewer.
Viewer Goto dialog doesn't allow go to the specified offset. The value
of input line is rounded to the next line start. Such bevaviour
is useless in hex mode of viewer. In hex mode we must heve a
capability to go to the specified address as is without any round.

Signed-off-by: Andrew Borodin <aborodin@vmail.ru>
2010-12-06 14:44:04 +03:00
Andrew Borodin
d459c83db3 Ticket #1651: user menu in standalone mcedit: filetype-specific items don't show.
And some type accuracy was made.

Signed-off-by: Andrew Borodin <aborodin@vmail.ru>
2010-12-06 13:55:18 +03:00
Ilia Maslakov
f153e1ad29 renamed:
* PanelCtrlNextPage into PanelGotoChildDir
    * PanelCtrlPrevPage into PanelGotoParentDir

Signed-off-by: Ilia Maslakov <il.smind@gmail.com>
2010-12-04 09:06:06 +00:00
Ilia Maslakov
2690d2d9f5 Ticket #2375 (do cd .. if command line is empty)
New keybinding "PanelSmartJumpUp" for the jump to the parent directory if command line is empty. Not defined by default.
    This binding maybe used for bind 'Backspace' as hotkey for 'cd ..' (only if command line is empty).

Signed-off-by: Ilia Maslakov <il.smind@gmail.com>
2010-12-04 09:05:07 +00:00