flat assembler
Message board for the users of flat assembler.

Index > Main > Modify Fasm 1.73. How do this ?

Author
Thread Post new topic Reply to topic
Roman



Joined: 21 Apr 2012
Posts: 1847
Roman 31 Jul 2020, 15:57
I want recompile Fasm 1.73 source.
And put my parser proc.

1) When press compile(in Fasm) i want get Fasm text.
2) Run my proc(Call MyParser). My proc parse text.
3) Change text and Fasm do as usual compilation.

Example. My proc change this(using token ^):
Parser find ^ and replace on Fasm macro or asm text
Code:
^for i,10
^for a,20
^nxt a
^nxt i
    

And Fasm get text:
Code:
       mov esi,10 
.00:   mov edi,20
.11:   dec edi
       test edi,edi
       jnz .11
       dec esi
       test esi,esi
       jnz .00

    
Post 31 Jul 2020, 15:57
View user's profile Send private message Reply with quote
Roman



Joined: 21 Apr 2012
Posts: 1847
Roman 31 Jul 2020, 16:29
I find in fasmw source place:
do_compile:

And put :
Code:
do_compile: Call MyParserA ;its work when i press in Fasmw compile.
    

But i not found how get Fasm editor text.
And how send new text to Fasm editor.
Post 31 Jul 2020, 16:29
View user's profile Send private message Reply with quote
Roman



Joined: 21 Apr 2012
Posts: 1847
Roman 31 Jul 2020, 16:53
I set text. And see in Fasm editor text 'Hi ! Its Roma !'
But compiled old(prevision) text in Fasm edit window.
Code:
proc MyParserA
        pusha       
        invoke MessageBox,0,eax,0,0
        invoke SendMessage,[hwnd_fedit],WM_SETTEXT,0,MyBufTxt
        popa
        ret
        MyBufTxt db 'Hi ! Its Roma !',0,0,0,0,0,0
endp
    
Post 31 Jul 2020, 16:53
View user's profile Send private message Reply with quote
revolution
When all else fails, read the source


Joined: 24 Aug 2004
Posts: 20451
Location: In your JS exploiting you and your system
revolution 01 Aug 2020, 02:27
I think you are trying to use fasm macros to make an HLL.

Perhaps what you really want is an HLL?
Post 01 Aug 2020, 02:27
View user's profile Send private message Visit poster's website Reply with quote
Roman



Joined: 21 Apr 2012
Posts: 1847
Roman 01 Aug 2020, 04:45
Fasmw not have many useful stuf.
And some time easy write owner parser, than write macro.

Because fasm macro is not always clear. And how to do something in fasm macro.

Fasm macro not have break. And many good things.

Quote:
Perhaps what you really want is an HLL?

I have many programs Directx11\Directx12. I dont want rewrite all this on c++.
But i need many useful stuf in fasmw.
This is the main reason.
Post 01 Aug 2020, 04:45
View user's profile Send private message Reply with quote
Roman



Joined: 21 Apr 2012
Posts: 1847
Roman 01 Aug 2020, 04:52
I found how create new window.
Code:
_untitled22 db 'new',0
invoke SendMessage,[hwnd_main],FM_NEW,_untitled22,0
    


But how set this new window file path ? When i press compile fasm open dialog file for saving.
I dont want get fasm open dialog file for saving.
I want set file path(for new window editor text) and get compilation without fasm open dialog file for saving.
How do this ?
Post 01 Aug 2020, 04:52
View user's profile Send private message Reply with quote
DimonSoft



Joined: 03 Mar 2010
Posts: 1228
Location: Belarus
DimonSoft 01 Aug 2020, 12:15
I wouldn’t expect much help on that. What you ask for looks like a really cumbersome solution. And making changes to FASMW source code requires decent knowledge of WinAPI and assembly programming as well as skills reading code written by another person. Removing the Open Dialog is pretty straightforward then, especially having source code.

Usually people are also reluctant to help if it turns into doing someone else’s job themselves, just step by step. Especially not seeing the goal.

Nothing personal, just my opinion. Sorry.
Post 01 Aug 2020, 12:15
View user's profile Send private message Visit poster's website Reply with quote
Roman



Joined: 21 Apr 2012
Posts: 1847
Roman 01 Aug 2020, 18:36


Last edited by Roman on 06 Aug 2020, 08:42; edited 1 time in total
Post 01 Aug 2020, 18:36
View user's profile Send private message Reply with quote
bitRAKE



Joined: 21 Jul 2003
Posts: 4073
Location: vpcmpistri
bitRAKE 01 Aug 2020, 21:15
There have been people who modify FASMW to meet their needs. Have you seen Wink? Latest version on last page. It's a good discussion and links to AsmEdit core documentation. Tomasz is a very rational coder, with solid organization skills and once you gain some experience with his style, changes will be easier, imho.

All the edit window commands start with "FM_", for example FM_OPEN leads us to fmopen function - which creates the tab, read in the file data, and set name. We can see from the open_file function how to use the message.

_________________
¯\(°_o)/¯ “languages are not safe - uses can be” Bjarne Stroustrup
Post 01 Aug 2020, 21:15
View user's profile Send private message Visit poster's website Reply with quote
Roman



Joined: 21 Apr 2012
Posts: 1847
Roman 02 Aug 2020, 09:55
New video.
^inc useful for window block with register class and WndProc.
https://www.youtube.com/watch?v=nByTv4Wgy1E&feature=youtu.be


Last edited by Roman on 06 Aug 2020, 08:44; edited 2 times in total
Post 02 Aug 2020, 09:55
View user's profile Send private message Reply with quote
bitRAKE



Joined: 21 Jul 2003
Posts: 4073
Location: vpcmpistri
bitRAKE 02 Aug 2020, 10:59
This might also interest you. It's possible to aggregate your work across the web into a consolidated directory. You can copy my respository directly and play with the features. It auto-updates on Microsoft's servers. People can see your videos and code all in one place. It's a relatively new feature.

_________________
¯\(°_o)/¯ “languages are not safe - uses can be” Bjarne Stroustrup
Post 02 Aug 2020, 10:59
View user's profile Send private message Visit poster's website Reply with quote
Roman



Joined: 21 Apr 2012
Posts: 1847
Roman 18 Aug 2020, 08:57
Post 18 Aug 2020, 08:57
View user's profile Send private message Reply with quote
Roman



Joined: 21 Apr 2012
Posts: 1847
Roman 20 Aug 2020, 11:32
Post 20 Aug 2020, 11:32
View user's profile Send private message Reply with quote
revolution
When all else fails, read the source


Joined: 24 Aug 2004
Posts: 20451
Location: In your JS exploiting you and your system
revolution 20 Aug 2020, 11:32
Roman: Can you please explain what your YT links are for?
Post 20 Aug 2020, 11:32
View user's profile Send private message Visit poster's website Reply with quote
Roman



Joined: 21 Apr 2012
Posts: 1847
Roman 20 Aug 2020, 11:43
Simple showing my progress.
Maybe some features Tomas implements in new version Fasmw.
Post 20 Aug 2020, 11:43
View user's profile Send private message 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-2025, Tomasz Grysztar. Also on GitHub, YouTube.

Website powered by rwasa.