Re: [MSEide-MSEgui-talk] The evil that is mfm

2020-02-14 Thread fredvs
> Where do you see "Touch form"? 

 

Fre;D




--
Sent from: http://mseide-msegui-talk.13964.n8.nabble.com/


___
mseide-msegui-talk mailing list
mseide-msegui-talk@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/mseide-msegui-talk


Re: [MSEide-MSEgui-talk] The evil that is mfm

2020-02-14 Thread Sieghard
Hello Graeme,

you wrote on Fri, 14 Feb 2020 17:45:34 +:

> > *_mfm.pas ARE necessary.  
...
> I remember I asked Martin if they were required, and his answer was
> technically no, because they are auto generated or something. So I once

As I see it, they're (kind of) auto generated if you create or modify a
form. If there is one for a form that's been modified "externally" or
where the _mfm.pas has become older than the form file itself, it won't
be automatically updated - there's no make-like mechanism to regenerate
them, you'll have to explicitely "touch form file" from the menu.
But on the other hand, the _mfm.pas files are "consumables", they are
generated as needed, and can be regenerated as often as one likes, e.g.
deleted after a build and regenereated to execute a new one.

> deleted all *_mfm.pas files from my local MSEide+MSEgui repo, and
> everything was broken.
> *shrug*

Well, wasn't that the reason Martin produced the "form2pas" program, i.e.
to regenerate any _mfm.pas files missing? There was some discussion about
that, a long time ago...
BTW, there's a "bmp2pas" program also, to create "compatible" files
from .bmp pictures, and even a general "data2pas" program for arbitrary
data. hey (seem to) provide a generalized means to load such data as a
kind of "ressource".

> So yeah, no idea what Martin meant. And no idea why they are needed.

As I see it, these file are just intermediates during the compile process
for msegui programs, needed because the tpc compiler cannot by itself
produce them, and somehow never handled fully automatically by the ide.

...
> Either way, I always thought 2 files per form/window/dialog was bad for

They're somewhat comparable to the precompiled headers of C/C++, though
lacking the automatisms of these compilers, a crutch for the fpc compiler,
so to speak.

...
> *really bad*! Especially since you can't resolve conflicts in the
> *_mfm.pas files. :-(

They're not meant for anything useful except for compiling the program,
I think. They're not meant for analysis, they're not meant for inspection.

> If there ever was a long term goal for MSEide going forward, I would
> putting find the meaning of those files and removing them as a big
> goal going forward.

You might attempt to implement an automatic (re)generator for them, maybe
checking whether the ones lying around are still current and regenerate
obsolete ones, or just remove all of them (perhaps built in a temporary
directory anyway) after every project (re)build and always regenerating
them anew for each build.

That's my view of these beasts, as far as I found out during my work with
mseide-msegui. Currently, I'm busy with quite different things and cannot
spend much time on such problems, althoughe ther might ba some possibility
that I could soon find some use for it on ARM systems (Raspberry Pi, of
course).

-- 
-- 
(Weitergabe von Adressdaten, Telefonnummern u.ä. ohne Zustimmung
nicht gestattet, ebenso Zusendung von Werbung oder ähnlichem)
---
Mit freundlichen Grüßen, S. Schicktanz
---




___
mseide-msegui-talk mailing list
mseide-msegui-talk@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/mseide-msegui-talk


Re: [MSEide-MSEgui-talk] The evil that is mfm

2020-02-14 Thread Patrick Goupell


On 2/14/20 1:51 PM, fredvs wrote:

Right click on a file in the file list (right
side of editor window) and click on "Show as form"

This is enabled only if the 3 files are present.
The same for "Touch form", if a .mfm or _mfm.pas is missing.

By the way, do you know what is the goal of "Touch form" ?

Fre;D



In the past I would occassionaly get a corrupeted formfile.pas.

Reading the error message that displayed I would correct whatever was 
wrong in the formile.pas source.  Right clickong the file name would 
then show "Show as form" and the form would display.



Where do you see "Touch form"?


Patrick




___
mseide-msegui-talk mailing list
mseide-msegui-talk@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/mseide-msegui-talk


Re: [MSEide-MSEgui-talk] The evil that is mfm

2020-02-14 Thread fredvs
Hello.

In /mseide-msegui/tools/ there is form2pas.pas application.

It says:

program form2pas;

//convert form files (*.mfm) to pascal files (*_mfm.pas)
//commandline: form2pas FORMFILE[,UNITNAME] ...
//Default UNITNAME is FORMFILE without extension.
//
//'form2pas main.mfm formdesigner.mfm' ->
//convert main.mfm to main_mfm.pas, formdesigner.mfm to formdesigner_mfm.pas

Maybe this application will explain us what _mfm.pas is for...

Fre;D



--
Sent from: http://mseide-msegui-talk.13964.n8.nabble.com/


___
mseide-msegui-talk mailing list
mseide-msegui-talk@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/mseide-msegui-talk


Re: [MSEide-MSEgui-talk] The evil that is mfm

2020-02-14 Thread fredvs
> Right click on a file in the file list (right
> side of editor window) and click on "Show as form" 

This is enabled only if the 3 files are present.
The same for "Touch form", if a .mfm or _mfm.pas is missing.

By the way, do you know what is the goal of "Touch form" ?

Fre;D



--
Sent from: http://mseide-msegui-talk.13964.n8.nabble.com/


___
mseide-msegui-talk mailing list
mseide-msegui-talk@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/mseide-msegui-talk


Re: [MSEide-MSEgui-talk] The evil that is mfm

2020-02-14 Thread fredvs
Hello Graeme.

Indisputably one of the best feature of fpGUI is his "all in one" file
feature.

Imho, the 3 files way is more heavy and if, by chance, you could find a way
to unify all that files, I vote X 10.000 for it.

Fre;D




--
Sent from: http://mseide-msegui-talk.13964.n8.nabble.com/


___
mseide-msegui-talk mailing list
mseide-msegui-talk@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/mseide-msegui-talk


Re: [MSEide-MSEgui-talk] Procedure List add-on for MSEide

2020-02-14 Thread Graeme Geldenhuys
On 13/02/2020 11:36 pm, fredvs wrote:
> Maybe you may add a oncellevent() method that jump into the source editor to
> the line of the method that you 2xcliked.

Ah, that was there - double checked with some old MSEide build I had. It
must have gotten lost somewhere during the rebase or something.

Thanks for the code, I'll add that functionality back in.


Regards,
  Graeme

-- 
fpGUI Toolkit - a cross-platform GUI toolkit using Free Pascal
http://fpgui.sourceforge.net/

My public PGP key:  http://tinyurl.com/graeme-pgp


___
mseide-msegui-talk mailing list
mseide-msegui-talk@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/mseide-msegui-talk


Re: [MSEide-MSEgui-talk] Procedure List add-on for MSEide

2020-02-14 Thread fredvs
Hello Graeme.

It was the only feature from Geany that was missing.
And works very well.

I did add a 2xclik in mouse event the ideU version, for those that have a
broken keyboard.

Hum, in your code:

procedure tprocedurelistfo.AddProcedure(...)
...
case Language of
ltPas: 
...
ltCpp:// code ommitted - we don't need C++ support
... 
end; //case Language

If, by any chance, you cannot stop your fingers to write the code for Java,
C++ or Python, it does not matter, ideU will be very happy to welcome those
code.

(Ho, bad Fred...)

Thanks and wow Graeme.

Fre;D

 



--
Sent from: http://mseide-msegui-talk.13964.n8.nabble.com/


___
mseide-msegui-talk mailing list
mseide-msegui-talk@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/mseide-msegui-talk


Re: [MSEide-MSEgui-talk] The evil that is mfm

2020-02-14 Thread Graeme Geldenhuys
On 14/02/2020 1:34 am, fredvs wrote:
>> Afaik, the *_mfm.pas are not necessary.
>> You may delete them, there are given only for convenience (?) when you do
>> a
>> "touch form". 
> Fake news!
> 
> *_mfm.pas ARE necessary.


I remember I asked Martin if they were required, and his answer was
technically no, because they are auto generated or something. So I once
deleted all *_mfm.pas files from my local MSEide+MSEgui repo, and
everything was broken.

*shrug*

So yeah, no idea what Martin meant. And no idea why they are needed.
Granted I never bothered to look inside the MSEgui code to find out either.

Either way, I always thought 2 files per form/window/dialog was bad for
Delphi/Lazarus - hence I implemented fpGUI to *only* use the single
*.pas file. So now seeing 3 files per form/window/dialog in MSEgui is
*really bad*! Especially since you can't resolve conflicts in the
*_mfm.pas files. :-(

If there ever was a long term goal for MSEide going forward, I would
putting find the meaning of those files and removing them as a big
goal going forward.

Regards,
  Graeme

-- 
fpGUI Toolkit - a cross-platform GUI toolkit using Free Pascal
http://fpgui.sourceforge.net/

My public PGP key:  http://tinyurl.com/graeme-pgp


___
mseide-msegui-talk mailing list
mseide-msegui-talk@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/mseide-msegui-talk


Re: [MSEide-MSEgui-talk] Procedure List add-on for MSEide

2020-02-14 Thread Graeme Geldenhuys
On 14/02/2020 3:12 am, fredvs wrote:
> It works **very** well.
> I could not resist too to commit it to ideU.
> 
> Many wow and many thanks.


Glad you liked it. :-) I implemented the same feature into Lazarus IDE
some 14 years ago (wow, time flies!) as a add-on, and soon after it
became standard with Lazarus. It seems to be a popular way of
navigating/jumping to code in a unit.

https://wiki.lazarus.freepascal.org/New_IDE_features_since#procedure_list

Both Eclipse IDE and IntelliJ has the same feature, though their dialogs
look slightly different. But importantly, they are also very keyboard
friendly (no need to use the mouse).


Regards,
  Graeme

-- 
fpGUI Toolkit - a cross-platform GUI toolkit using Free Pascal
http://fpgui.sourceforge.net/

My public PGP key:  http://tinyurl.com/graeme-pgp


___
mseide-msegui-talk mailing list
mseide-msegui-talk@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/mseide-msegui-talk


Re: [MSEide-MSEgui-talk] The evil that is mfm

2020-02-14 Thread Patrick Goupell


On 2/13/20 8:34 PM, fredvs wrote:

Afaik, the *_mfm.pas are not necessary.
You may delete them, there are given only for convenience (?) when you do
a
"touch form".

Fake news!

*_mfm.pas ARE necessary.

So, sorry, I dont know the purpose of the objdata: record size: integer;
data: array
that is in *_mfm.pas.

(But I would be happy to know).

Fre;D




From what I remember the *_mfm.pas files are used to display the source 
file's underlying form.  Right click on a file in the file list (right 
side of editor window) and click on "Show as form"



I would guess that the array of integers is some type of bitmap for the 
form image.  But just a guess.



Patrick



___
mseide-msegui-talk mailing list
mseide-msegui-talk@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/mseide-msegui-talk