flat assembler
Message board for the users of flat assembler.

Index > IDE Development > FASMW caption

Author
Thread Post new topic Reply to topic
vid
Verbosity in development


Joined: 05 Sep 2003
Posts: 7105
Location: Slovakia
vid
i would appreciate name of currently edited file in caption of FASMW, like "MASMSUCK.ASM - Flat Assembler 1.66" etc.
Post 21 Jun 2006, 09:15
View user's profile Send private message Visit poster's website AIM Address MSN Messenger ICQ Number Reply with quote
Madis731



Joined: 25 Sep 2003
Posts: 2140
Location: Estonia
Madis731
I have posted this kind of name convention before, but it wasn't welcome. But, HEY, lets go for a second round Very Happy

I'm in - the goals:
1) Easier differention between source files.
2) Source name should not be hidden
3) FASMW is known by its logo and doesn't need more attetntion with the name after it

some examples:
Notepad => open a file and it says: "file - Notepad"
Seamonkey (& most brosers) => open this board: "flat assembler - View topic - FASMW caption - SeaMonkey"

they both have their names at the end
Post 21 Jun 2006, 10:29
View user's profile Send private message Visit poster's website Yahoo Messenger MSN Messenger Reply with quote
comrade



Joined: 16 Jun 2003
Posts: 1137
Location: Russian Federation
comrade
vid, I have a mod for it. I was going to post it on my page but never got around to it. The mod also contains external debugger support via F8 keyboard key.


Description:
Download
Filename: fasmw_166_mod.zip
Filesize: 91.98 KB
Downloaded: 221 Time(s)


_________________
comrade (comrade64@live.com; http://comrade.ownz.com/)
Post 21 Jun 2006, 17:58
View user's profile Send private message Visit poster's website AIM Address Yahoo Messenger MSN Messenger ICQ Number Reply with quote
vid
Verbosity in development


Joined: 05 Sep 2003
Posts: 7105
Location: Slovakia
vid
thx
Post 21 Jun 2006, 18:10
View user's profile Send private message Visit poster's website AIM Address MSN Messenger ICQ Number Reply with quote
Mr_Silent



Joined: 25 Apr 2006
Posts: 30
Mr_Silent
comrade wrote:
vid, I have a mod for it...

Nice, but not perfect - if U try to save 'untitled' with some name, that name won't go into the main title (though it will appear in the tabcontrol)

Here is what I came to...
FasmW.asm

Code:
................

section '.data' data readable writeable
; Silent: changed caption
  _caption db ' - flat assembler ',VERSION_STRING,0
  ; Silent: made new fields
  ; new buffer for modified caption
  cap_buf db 0                 ; pre-init empty string
  rb 255+32                    ; reserve
  ; end new var 
................


fmopen:
 ...
       set_asmedit_text:
        invoke  SendMessage,[hwnd_asmedit],WM_SETTEXT,0,dword [esp]
        call    [VirtualFree]
        mov     eax,ebx
 ; Silent: Hook :/
     _cap_out:                                                       ;  escapes handler with updating
        invoke  SendMessage,[hwnd_tabctrl],TCM_GETCURSEL,0,0         ; GetCurrentItem
        invoke  SendMessage,[hwnd],FM_SELECT,eax,0                   ; SetCurrentItem Wink
        xor     eax,eax
        jmp     finish
 ; end hook - folows original
      load_out_of_memory:
        invoke  CloseHandle,ebx 
.....................

fmsave:
...
invoke  SendMessage,[ei.hwnd],EM_EMPTYUNDOBUFFER,0,0
        invoke  SendMessage,[hwnd_status],SB_SETTEXT,1,_null
        xor     eax,eax
 ; Silent: Another hook
        jmp     _cap_out                                                ;WAS jmp     finish
 ; end hook - folows original
      save_out_of_memory:
        invoke  CloseHandle,ebx
.....................

fmselect:
 ; Silent: start_fix
        mov     [ei.header.mask],TCIF_PARAM+TCIF_TEXT                                   ; WAS  mov [ei.header.mask],TCIF_PARAM
        mov     eax,cap_buf                                                             ; also prep. our text buffer
        mov     [ei.header.pszText],eax                                                 ;
        mov     [ei.header.cchTextMax],255                                              ;
        ;
        invoke  SendMessage,[hwnd_tabctrl],TCM_GETITEM,[wparam],ei                      ; original line
        ;
        invoke  lstrcat,[ei.header.pszText],_caption                                    ; filename + (fasm_caption + version)
        invoke  SendMessage,[hwnd],WM_SETTEXT,0,[ei.header.pszText]                ; setting new caption
 ; end_fix - folows original 
        invoke  GetWindowLong,[hwnd_asmedit],GWL_STYLE
                          
.................................
  import kernel,\
....
         lstrcat,'lstrcatA'  
    


Oogly, but works...


Last edited by Mr_Silent on 22 Jun 2006, 05:45; edited 2 times in total
Post 22 Jun 2006, 01:57
View user's profile Send private message Reply with quote
comrade



Joined: 16 Jun 2003
Posts: 1137
Location: Russian Federation
comrade
How do you know that I hadn't left out the "Untitled - flat assembler" case by design?
Post 22 Jun 2006, 03:30
View user's profile Send private message Visit poster's website AIM Address Yahoo Messenger MSN Messenger ICQ Number Reply with quote
Mr_Silent



Joined: 25 Apr 2006
Posts: 30
Mr_Silent
comrade wrote:
How do you know that I hadn't left out the "Untitled - flat assembler" case by design?

I didn't tell that Untitled should be in... I said, when you give your file REAL name (like 'MASMSUCK.ASM') by saving, this new name won't appear in caption.
EDITED: I've changed the code. Placing cap_buf at the end of .udata section resulted in additional 38kb of .exe size... M-m-m-m... Reason, anyone?
Post 22 Jun 2006, 04:06
View user's profile Send private message Reply with quote
comrade



Joined: 16 Jun 2003
Posts: 1137
Location: Russian Federation
comrade
Because you caused a lot of unitialized before cap_buf to become uninitialized.
cap_buf db 0
by itself is initialized data
Post 22 Jun 2006, 06:32
View user's profile Send private message Visit poster's website AIM Address Yahoo Messenger MSN Messenger ICQ Number Reply with quote
comrade



Joined: 16 Jun 2003
Posts: 1137
Location: Russian Federation
comrade
Just want to let you know I updated my FASMW modifications to the latest version (IDE version 0.93.15.0 that comes with FASM 1.67.26).

You can find them here:
http://comrade.ownz.com/docs/fasm.html#idemods

The modifications are:

  1. Add configurable, external debugger support. You configure the path to your debugger, press F8, and the IDE will automatically compile the file, and launch the debugger.
  2. Display the name of the file being currently editted in the program's title bar.
  3. Default all "Save modified file?" message boxes to 'Yes'. For some reason, the author decided there are times when you don't want to save your changes by default. This differs from other applications which always pick the safest option: save your work.
  4. Show the length of currently selected text in the status bar. This is useful in measuring string lengths quickly, and then using them somewhere in the code.
  5. Map Ctrl-W to close file. This is a common keyboard shortcut that FASMW IDE does not have.
  6. Unmap Escape from closing the file. I frequently press Esc to close some dialog, and end-up closing the IDE by mistake.
  7. Change the GUI font to Tahoma, instead of Win95-esque MS Sans Serif.
Post 09 Jul 2008, 17:56
View user's profile Send private message Visit poster's website AIM Address Yahoo Messenger MSN Messenger ICQ Number Reply with quote
Tomasz Grysztar



Joined: 16 Jun 2003
Posts: 7756
Location: Kraków, Poland
Tomasz Grysztar
comrade wrote:

[*]Default all "Save modified file?" message boxes to 'Yes'. For some reason, the author decided there are times when you don't want to save your changes by default. This differs from other applications which always pick the safest option: save your work.

This was actually intentional that it uses default 'Yes' when you close with Esc or Alt+X, and 'No' when you close with Alt+F4 - as I personally use Alt+F4 only when I just want to get rid of the windows, discarding whathever is there.
Once again a kind of interface weirdness adapted to my own habits. Sorry. Wink
Post 09 Jul 2008, 18:01
View user's profile Send private message Visit poster's website Reply with quote
comrade



Joined: 16 Jun 2003
Posts: 1137
Location: Russian Federation
comrade
Tomasz, I've spoken to you about this many years ago, but what do you think of putting in external debugger support to FASMW IDE? Your idea before was to keep out of the main IDE then, because you eventually wanted to add integrated debugging support to the IDE itself. Since that didn't come about (or is it going to come about? Smile), I am reasking the question. Smile
Post 09 Jul 2008, 20:24
View user's profile Send private message Visit poster's website AIM Address Yahoo Messenger MSN Messenger ICQ Number Reply with quote
Tomasz Grysztar



Joined: 16 Jun 2003
Posts: 7756
Location: Kraków, Poland
Tomasz Grysztar
Well, if I succeed to finally design the long-promised fasm's full debug info format, it will become achievable.
Post 09 Jul 2008, 22:31
View user's profile Send private message Visit poster's website Reply with quote
DOS386



Joined: 08 Dec 2006
Posts: 1901
DOS386
> to finally design the long-promised fasm's full debug

Create a new debug format ? Why not support an existing one (DWARF/STAB) ? Many people miss it (OTOH I actually have no idea how they work Confused )
Post 11 Jul 2008, 08:32
View user's profile Send private message Reply with quote
comrade



Joined: 16 Jun 2003
Posts: 1137
Location: Russian Federation
comrade
What is DWARF/STAB? Isn't MS PDB the most useful format (in terms of being the most popular)?
Post 11 Jul 2008, 14:47
View user's profile Send private message Visit poster's website AIM Address Yahoo Messenger MSN Messenger ICQ Number Reply with quote
crc



Joined: 21 Jun 2003
Posts: 637
Location: Penndel, PA [USA]
crc
Quote:
What is DWARF/STAB? Isn't MS PDB the most useful format (in terms of being the most popular)?


DWARF and STAB are more common on Unix-like systems. PDB is a proprietary file format, and isn't documented as well as DWARF or STAB if I remember correctly.
Post 11 Jul 2008, 23:48
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-2020, Tomasz Grysztar. Also on YouTube, Twitter.

Website powered by rwasa.