flat assembler
Message board for the users of flat assembler.

Index > IDE Development > FasmW minor visual...

Author
Thread Post new topic Reply to topic
Mr_Silent



Joined: 25 Apr 2006
Posts: 30
Mr_Silent 25 Apr 2006, 13:44
FasmW works fine with console-type caret, but if you uncheck that option caret will have "l-beam" look, but not the behavour. No matter which part of the symbol you click - caret will allways appear BEFORE that symbol, ...kinda odd to see that in Win32 Edit control. Here is quick fix:
ASMEDIT.INC
Code:
...
   get_mouse_position:
        ; silent: changed original code to give non-console caret lame Win32 behavour
        mov     ax,word [lparam]                     ; original line - ax <- mouse.x
        ; our part next
        test    [editor_style],AES_CONSOLECARET      ; check if ConsoleCaret is set
        jnz     silent_cct_original                  ; if yes - jump to original routine
        test    [editor_mode],AEMODE_OVERWRITE       ; check if Overwrite is set
        jnz     silent_cct_original                  ; if yes - jump to original routine
        ; not set - proceed with our course
        push ebx                                     ; preserving ebx
        mov ebx,[font_width]                         ; getting font.width
        shr ebx,1                                    ; ebx <- font.width div 2
        adc ax,bx                                    ; shifting ax on a half of the symbol
        pop ebx                                      ; ebx restore
      silent_cct_original:
        ; end cct fix - original code folows
        cwde
        cdq 
...                        
    

Offtop: Fresh seems to have that issue too
Sorry for my poor English Smile
Post 25 Apr 2006, 13:44
View user's profile Send private message Reply with quote
Tomasz Grysztar



Joined: 16 Jun 2003
Posts: 8351
Location: Kraków, Poland
Tomasz Grysztar 26 Apr 2006, 07:57
Nice, after reviewing this code a bit, I added it to the official one.

PS. This thread belongs to "IDE Development", so I moved it here.
Post 26 Apr 2006, 07:57
View user's profile Send private message Visit poster's website Reply with quote
Display posts from previous:
Post new topic Reply to topic

Jump to:  


< Last Thread | Next Thread >
Forum Rules:
You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum
You cannot attach files in this forum
You can download files in this forum


Copyright © 1999-2024, Tomasz Grysztar. Also on GitHub, YouTube.

Website powered by rwasa.