Recent

Author Topic: [SOLVED] Unable to change the font in TStatusBar  (Read 1644 times)

Fred vS

  • Hero Member
  • *****
  • Posts: 2905
    • StrumPract is the musicians best friend
Re: [SOLVED] Unable to change the font in TStatusBar
« Reply #15 on: October 09, 2022, 05:27:25 pm »
Have you seen the post of Fred vS ? https://forum.lazarus.freepascal.org/index.php/topic,60834.msg456440.html#msg456440
That's exactly what I want (image2) : a true StatusBar with an old school look'n'feel and a nice sizegrip.

Indeed, MSEgui is the best widgetset that exists (compared to "tenor" widgetsets like GTK, Qt, KDE, ...)
It is fully custom-able included frames.

And it does not need any dependencies and is 100% Pascal.
And the graphic result is exactly the same if you compile the same code for Linux or Windows.

https://github.com/mse-org/mseide-msegui
« Last Edit: October 09, 2022, 05:30:41 pm by Fred vS »
I use Lazarus 2.2.0 32/64 and FPC 3.2.2 32/64 on Debian 11 64 bit, Windows 10, Windows 7 32/64, Windows XP 32,  FreeBSD 64.
Widgetset: fpGUI, MSEgui, Win32, GTK2, Qt.

https://github.com/fredvs
https://gitlab.com/fredvs
https://codeberg.org/fredvs

jipété

  • Jr. Member
  • **
  • Posts: 55
Re: [SOLVED] Unable to change the font in TStatusBar
« Reply #16 on: October 09, 2022, 05:56:11 pm »
Yes, I've read many web pages 'bout it but, if I go this way, it means i'll throw away 20 years of learning.

Life isn't that easy...

Well, I think there are the people at Lazarus who must throw away their bad statusbar and restart a clean project, look what I've done in the last hour, with the code from paweld :
Code: Pascal  [Select][+][-]
  1. FormCreate;
  2.   ...
  3.   stb.Font.Name := 'Liberation Serif';
  4.   stb.Font.Size := 12;
  5.   for i := 0 to 2 do
  6.     with stb.Panels.Add do begin
  7.       Style := psOwnerDraw; // done in IDE but not working, mandatory here
  8.       Width := 60;
  9.       //Alignment := tAlignment(2); // does not work, see image1
  10.       // works better but ONLY with the last panel
  11.       //Alignment := taCenter;
  12.       //Alignment := taLeftJustify;
  13.       Alignment := taRightJustify;
  14.       Text := 'Panel ' + IntToStr(i);
  15.     end;
  16.   stb.OnDrawPanel := @stbDrawPanel;
  17. end;
Only the last panel moves, see image2 ! Really bad stuff...

Fred vS

  • Hero Member
  • *****
  • Posts: 2905
    • StrumPract is the musicians best friend
Re: [SOLVED] Unable to change the font in TStatusBar
« Reply #17 on: October 09, 2022, 06:05:02 pm »
Yes, I've read many web pages 'bout it but, if I go this way, it means i'll throw away 20 years of learning.
...

Imho, it is just the reverse, because of 20 years of learning, jumping into msegui will be easy and with pleasure.  O:-)
I use Lazarus 2.2.0 32/64 and FPC 3.2.2 32/64 on Debian 11 64 bit, Windows 10, Windows 7 32/64, Windows XP 32,  FreeBSD 64.
Widgetset: fpGUI, MSEgui, Win32, GTK2, Qt.

https://github.com/fredvs
https://gitlab.com/fredvs
https://codeberg.org/fredvs

jipété

  • Jr. Member
  • **
  • Posts: 55
Re: [SOLVED] Unable to change the font in TStatusBar
« Reply #18 on: October 09, 2022, 06:38:50 pm »
Yes yes yes yes yes...

And I've carefully done the things as explained here : https://mseide-msegui.sourceforge.io/ and at step 8, bim !
img

I do not want to start a topic 'bout mseide, I just throw away the zips and I'll stay with Laz, one day bugs will be corrected, stay tuned !

Fred vS

  • Hero Member
  • *****
  • Posts: 2905
    • StrumPract is the musicians best friend
Re: [SOLVED] Unable to change the font in TStatusBar
« Reply #19 on: October 09, 2022, 07:00:01 pm »
Yes yes yes yes yes...

And I've carefully done the things as explained here : https://mseide-msegui.sourceforge.io/ and at step 8, bim !
img

I do not want to start a topic 'bout mseide, I just throw away the zips and I'll stay with Laz, one day bugs will be corrected, stay tuned !

OK, I stop.
The only thing: the site https://mseide-msegui.sourceforge.io/ is obsolete and the maintainers of mse-org do not have access to that site to edit it.

Martin, the creator of msegui, leaves us 3 years ago and the project is continued and updated by mse-org maintainers.
https://github.com/mse-org/mseide-msegui

There is the readme.md file with all explanation how to install. (Dont forget the point 6).

In 'Settings'-'Configure MSEide'-'${MSEDIR}' select the root directory of MSEgui source. (In example: "/home/myself/mseide-msegui").


Voila, I really stop.

Fre;D
I use Lazarus 2.2.0 32/64 and FPC 3.2.2 32/64 on Debian 11 64 bit, Windows 10, Windows 7 32/64, Windows XP 32,  FreeBSD 64.
Widgetset: fpGUI, MSEgui, Win32, GTK2, Qt.

https://github.com/fredvs
https://gitlab.com/fredvs
https://codeberg.org/fredvs

jipété

  • Jr. Member
  • **
  • Posts: 55
Re: [SOLVED] Unable to change the font in TStatusBar
« Reply #20 on: October 09, 2022, 07:38:57 pm »
the site is obsolete and the maintainers of mse-org do not have access to that site to edit it.
The MAIN problem of the Internet, with the http:404 caused by the rewriting of sites, what a disaster...
30 years before, Internet was a marvelous toy, and now, I'm really disappointed.

Carefully followed the steps 1 to 6 and at the step 7, "Access Violation" while opening the project file.
I'm tired, really tired...

Fred vS

  • Hero Member
  • *****
  • Posts: 2905
    • StrumPract is the musicians best friend
Re: [SOLVED] Unable to change the font in TStatusBar
« Reply #21 on: October 10, 2022, 12:24:38 am »
the site is obsolete and the maintainers of mse-org do not have access to that site to edit it.
The MAIN problem of the Internet, with the http:404 caused by the rewriting of sites, what a disaster...
30 years before, Internet was a marvelous toy, and now, I'm really disappointed.

Carefully followed the steps 1 to 6 and at the step 7, "Access Violation" while opening the project file.
I'm tired, really tired...

I am really sorry that it does not work out-of-the-box for you.
It is one of the goal of msegui and if it does not do it, it is very sad.

I just did try to install msegui on Debian 11 64 bit from init.
So removed my /home/fred/mseide-msegui directory and the hidden config file /home/fred/.mseide.

Downladed the source of msegui from https://github.com/mse-org/mseide-msegui/

And reinstall the release of mseide-binary from there https://github.com/mse-org/mseide-msegui/releases/
with setting in config all the path.

And load the project /home/fred/mseide-msegui/apps/demo/demo.prj

But no crash and out-of-the-box.
So I am very disappointed and if you could give me some light to understand why there is problems on your side,
it would be very great and highly appreciated (of course when you are less tired).

Fe;D
I use Lazarus 2.2.0 32/64 and FPC 3.2.2 32/64 on Debian 11 64 bit, Windows 10, Windows 7 32/64, Windows XP 32,  FreeBSD 64.
Widgetset: fpGUI, MSEgui, Win32, GTK2, Qt.

https://github.com/fredvs
https://gitlab.com/fredvs
https://codeberg.org/fredvs

jipété

  • Jr. Member
  • **
  • Posts: 55
Re: [SOLVED] Unable to change the font in TStatusBar
« Reply #22 on: October 10, 2022, 08:00:46 am »
Hi !

in the morning of a new day, I followed your first url and somewhere downloaded mseide-msegui-main.zip then followed the other url and downloaded mseide_5_6_8_linux_amd64.zip
Extracted the two zip files (right click / extract here) so I now have 2 folders : mseide_lin64 and mseide-msegui-main.
Opened the last folder, found the README.TXT, read the Installation chapter :
1. Download and install FPC --> no need, still here due to previous Laz install.
2. Download mseide_msegui from https://github.com/mse-org/mseide-msegui/archive/master.zip --> I copy/paste that filename in Firefox and this one asks me for a name to record the file with the proposal name is mseide-msegui-main.zip. I change it to archive.zip and now I have 3 files :
mseide_5_6_8_linux_amd64.zip 3,2 Mio
mseide-msegui-main.zip 8,1 Mio
archive.zip 8,1 Mio
Opened the two last files, which looks identical, so archive.zip is pushed in trash bin.
3. nothing to do, read the beginning of my text.
4. "Run 'yourdirectory/bin/mseide'" is wrong coz I have 2 directories. Which one is the good  'yourdirectory' ? Looking inside both, I don't know what to do coz no one owns a "bin" subdir... Found "mseide" in mseide_lin64 with a README file which looks like the same I am reading. I run the file, a little grey window comes,
5. I try to play with Settings but it's hard because I read "select 'yourdirectory/msegui'" and I don't have that. I have 'yourdirectory/mseide_lin64' and 'yourdirectory/mseide-msegui-main'. I choose the second.
6. I open the demo.prj
7. F9 compiles fine, executes fine and shows a gray window with an "Exit" button.

Everything's ok this morning.
Maybe the problem yesterday came from "the hidden config file" /path/.mseide. that I didn't notice it existed.
Have a nice day and a nice week.
--
jp

Fred vS

  • Hero Member
  • *****
  • Posts: 2905
    • StrumPract is the musicians best friend
Re: [SOLVED] Unable to change the font in TStatusBar
« Reply #23 on: October 10, 2022, 02:22:51 pm »
Hello JP.

Great, you did it!

And now you have a new (fun) problem: l'embarras du choix.  ;D

Have a perfect week (and much more).

[EDIT] In attachment, the msegui StatusBar demo of my previous picture.

Fre;D
« Last Edit: October 10, 2022, 03:33:00 pm by Fred vS »
I use Lazarus 2.2.0 32/64 and FPC 3.2.2 32/64 on Debian 11 64 bit, Windows 10, Windows 7 32/64, Windows XP 32,  FreeBSD 64.
Widgetset: fpGUI, MSEgui, Win32, GTK2, Qt.

https://github.com/fredvs
https://gitlab.com/fredvs
https://codeberg.org/fredvs

 

TinyPortal © 2005-2018