Ticket #1489 (indent block)

added bindings for shift block 'EditShiftBlockLeft', 'EditShiftBlockRight'
    EditShiftBlockLeft, EditShiftBlockRight - force move block without option_persistent_selections checking

Signed-off-by: Ilia Maslakov <il.smind@gmail.com>
This commit is contained in:
Ilia Maslakov 2009-10-28 11:32:48 +00:00
parent 5ac43584cc
commit 359c9406d1
5 changed files with 19 additions and 0 deletions

View File

@ -2991,6 +2991,14 @@ edit_execute_cmd (WEdit *edit, int command, int char_for_insertion)
edit_block_move_cmd (edit);
break;
case CK_Shift_Block_Left:
if (edit->mark1 != edit->mark2)
edit_move_block_to_left (edit);
break;
case CK_Shift_Block_Right:
if (edit->mark1 != edit->mark2)
edit_move_block_to_right (edit);
break;
case CK_XStore:
edit_copy_to_X_buf_cmd (edit);
break;

View File

@ -44,6 +44,9 @@ EditRemove = f8
EditUnmark =
EditFind = f7
EditShiftBlockLeft =
EditShiftBlockRight =
EditPageUpHighlight = shift-pgup
EditPageDownHighlight = shift-pgdn
EditLeftHighlight = shift-left

View File

@ -43,6 +43,9 @@ EditRemove = f8
EditUnmark =
EditFind = f7
EditShiftBlockLeft =
EditShiftBlockRight =
EditPageUpHighlight = shift-pgup
EditPageDownHighlight = shift-pgdn
EditLeftHighlight = shift-left

View File

@ -60,6 +60,8 @@
#define CK_Unmark 206
#define CK_Save_Block 207
#define CK_Column_Mark 208
#define CK_Shift_Block_Left 211
#define CK_Shift_Block_Right 212
/* search and replace */
#define CK_Find 301

View File

@ -171,6 +171,9 @@ static const name_keymap_t command_names[] = {
{ "EditParagraphUpAltHighlight", CK_Paragraph_Up_Alt_Highlight },
{ "EditParagraphDownAltHighlight", CK_Paragraph_Down_Alt_Highlight },
{ "EditShiftBlockLeft", CK_Shift_Block_Left },
{ "EditShiftBlockRight", CK_Shift_Block_Right },
{ "EditXStore", CK_XStore },
{ "EditXCut", CK_XCut },
{ "EditXPaste", CK_XPaste },