Many hyperlinks are disabled.
Use anonymous login
to enable hyperlinks.
Overview
Comment: | Some work on the TAsmEdit selections. Not working though. |
---|---|
Timelines: | family | ancestors | descendants | both | NoCanvasGUI |
Files: | files | file ages | folders |
SHA1: | 95492a43df4d046f184476ad647beee591377f88 |
User & Date: | johnfound 2018-07-01 10:29:33 |
Context
2018-07-03
| ||
12:06 | More simple API for the TAsmEdit carete and selections coordinates. check-in: 67022b13a9 user: johnfound tags: NoCanvasGUI | |
2018-07-01
| ||
10:29 | Some work on the TAsmEdit selections. Not working though. check-in: 95492a43df user: johnfound tags: NoCanvasGUI | |
07:31 | Work on the GUI components. check-in: c0581e08a7 user: johnfound tags: NoCanvasGUI | |
Changes
Changes to freshlib/gui/TAsmEdit.asm.
723 724 725 726 727 728 729 730 731 732 733 734 735 736 737 738 ... 922 923 924 925 926 927 928 929 930 931 932 933 934 935 936 937 ... 956 957 958 959 960 961 962 963 964 965 966 967 968 969 |
exec esi, TAsmEdit:_AddSelRectangles, edx cmp [.cmdSelect], selCmdStart jne .sel_start_ok mov eax, [esi+TAsmEdit._caretPos + 4*ecx] mov [esi+TAsmEdit._selStart + 4*ecx], ebx mov [esi+TAsmEdit._selEnd + 4*ecx], ebx xor ecx, 1 mov eax, [esi+TAsmEdit._caretPos + 4*ecx] mov [esi+TAsmEdit._selStart + 4*ecx], eax mov [esi+TAsmEdit._selEnd + 4*ecx], eax xor ecx, 1 ................................................................................ xor ebx, ebx xor edx, edx dec ebx inc edx inc edx ; ebx = -1 edx = 2 mov eax, [.kbdState] and eax, maskShift cmovz ecx, ebx ; ecx = selCmdNone - 1 if the shift key is not pressed. inc ecx cmp ecx, edx cmova ecx, edx ; ecx = selCmdEnd if > selCmdEnd OutputValue "Selection command: ", ecx, 10, -1 ................................................................................ je .do_undo cmp eax, 3 ; Ctrl+C je .copy_to_clipboard cmp eax, 22 ; Ctrl+V je .paste_from_clipboard jmp .finish .copy_to_clipboard: stdcall ClipboardWrite, <"This is clipboard test.", 13, 10> |
| > > > | | > > > > > > > > |
723 724 725 726 727 728 729 730 731 732 733 734 735 736 737 738 739 740 741 ... 925 926 927 928 929 930 931 932 933 934 935 936 937 938 939 940 941 942 943 944 945 ... 964 965 966 967 968 969 970 971 972 973 974 975 976 977 978 979 980 |
exec esi, TAsmEdit:_AddSelRectangles, edx cmp [.cmdSelect], selCmdStart jne .sel_start_ok mov eax, [esi+TAsmEdit._caretPos + 4*ecx] mov [esi+TAsmEdit._selStart + 4*ecx], eax mov [esi+TAsmEdit._selEnd + 4*ecx], ebx OutputValue "Selection start:", eax, 10, -1 OutputValue "Selection end:", ebx, 10, -1 xor ecx, 1 mov eax, [esi+TAsmEdit._caretPos + 4*ecx] mov [esi+TAsmEdit._selStart + 4*ecx], eax mov [esi+TAsmEdit._selEnd + 4*ecx], eax xor ecx, 1 ................................................................................ xor ebx, ebx xor edx, edx dec ebx inc edx inc edx ; ebx = -1 edx = 2 mov eax, [.kbdState] test eax, maskShift cmovz ecx, ebx ; ecx = selCmdNone = -1 if the shift key is not pressed. ; continue the selection, if Ctrl key is pressed. and eax, maskCtrl or maskShift cmp eax, maskCtrl or maskShift cmove ecx, edx inc ecx cmp ecx, edx cmova ecx, edx ; ecx = selCmdEnd if > selCmdEnd OutputValue "Selection command: ", ecx, 10, -1 ................................................................................ je .do_undo cmp eax, 3 ; Ctrl+C je .copy_to_clipboard cmp eax, 22 ; Ctrl+V je .paste_from_clipboard cmp eax, 2 ; Ctrl+B je .change_caret jmp .finish .copy_to_clipboard: stdcall ClipboardWrite, <"This is clipboard test.", 13, 10> |
Changes to freshlib/test_code0/TestAsmEdit.asm.
12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 |
; Notes:
;_________________________________________________________________________________________
include "%lib%/freshlib.inc"
@BinaryType GUI, compact
options.DebugMode = 0
options.DebugMode.NoTimers = 0
options.DebugMode.XSync = 0
options.DebugMode.XErrors =0
options.DebugMode.ComputeFPS = 0
options.DebugMode.ShowFPS = 0
|
| |
12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 |
; Notes:
;_________________________________________________________________________________________
include "%lib%/freshlib.inc"
@BinaryType GUI, compact
options.DebugMode = 1
options.DebugMode.NoTimers = 0
options.DebugMode.XSync = 0
options.DebugMode.XErrors =0
options.DebugMode.ComputeFPS = 0
options.DebugMode.ShowFPS = 0
|