Recent

Author Topic: Modern UI in Lazarus  (Read 81732 times)

Thaddy

  • Hero Member
  • *****
  • Posts: 8515
Re: Modern UI in Lazarus
« Reply #165 on: November 20, 2017, 04:36:52 pm »
Well the link works correct, I will check it out again..... Christiano...

But I can't see any contribution to the subject here....

As I stated before (with my two seconds project), as long as you are proficient you can have any "modern" look you want.
I happen to like steampunk...
Read the manuals and if you are a professional get a proper education in computer science. Makes the forum a lot cleaner.

lainz

  • Hero Member
  • *****
  • Posts: 3179
    • Lainz
Re: Modern UI in Lazarus
« Reply #166 on: November 25, 2017, 11:49:05 pm »
Well the link works correct, I will check it out again..... Christiano...

But I can't see any contribution to the subject here....

As I stated before (with my two seconds project), as long as you are proficient you can have any "modern" look you want.
I happen to like steampunk...

I do not agree with you last time, but is true, here is my sample for modern ui. Material Design dialog with BGRAControls. Project attached and screenshot. Requires roboto font installed, you can download it on Windows with SkyFonts application.

Edit: for better looking fonts (at least looks better on Windows) change the font style for each element to fqFineClearTypeRGB.
« Last Edit: November 25, 2017, 11:52:29 pm by lainz »

TheEditor

  • New Member
  • *
  • Posts: 19
Re: Modern UI in Lazarus
« Reply #167 on: November 26, 2017, 03:42:31 am »
I'm a Lazarus newbie who needs a little help. I used fpcupdeluxe to install the BGRA packages, but when I try to run your demo I get a compile error on the Application.Scaled statement. Can't find the Scaled property in lazarus_ui.lpr. I'm thinking something went wrong with the BGRA installation.

Edit: for better looking fonts (at least looks better on Windows) change the font style for each element to fqFineClearTypeRGB.

molly

  • Hero Member
  • *****
  • Posts: 2345
Re: Modern UI in Lazarus
« Reply #168 on: November 26, 2017, 05:54:05 am »
..., but when I try to run your demo I get a compile error on the Application.Scaled statement. Can't find the Scaled property in lazarus_ui.lpr. I'm thinking something went wrong with the BGRA installation.
Nope. Something went wrong with your version of Lazarus ;-)

property scaled was added to TAplication by Ondrej @ revision 54199

Update your Lazarus... (lazarus 1.9 from trunk)
« Last Edit: November 26, 2017, 06:07:58 am by molly »

TheEditor

  • New Member
  • *
  • Posts: 19
Re: Modern UI in Lazarus
« Reply #169 on: November 26, 2017, 09:18:12 pm »
It took awhile, but I got the trunk installed. I installed bgrabitmap installed and was able to run the demo, thanks.

serkank

  • Newbie
  • Posts: 2
Re: Modern UI in Lazarus
« Reply #170 on: May 18, 2018, 03:28:05 pm »
Hi.  i want to make gui with HTML+JAVASCRIPT+CSS  and use this gui with Lazarus..  Is there a library for it ?

For example  if user click HTML button its will call Pascal function...


i was saw lainz wrote somethings about it but i didnt understand good.. 



Phil

  • Hero Member
  • *****
  • Posts: 2750
Re: Modern UI in Lazarus
« Reply #171 on: May 18, 2018, 03:32:22 pm »
Hi.  i want to make gui with HTML+JAVASCRIPT+CSS  and use this gui with Lazarus..  Is there a library for it ?

For example  if user click HTML button its will call Pascal function...


i was saw lainz wrote somethings about it but i didnt understand good..

You can now write Web apps (what you're describing) in Pascal. See parts 1 and 4 in Web App Development Overview here:

https://macpgmr.github.io/

(Note you should probably have started a new topic.)

lainz

  • Hero Member
  • *****
  • Posts: 3179
    • Lainz
Re: Modern UI in Lazarus
« Reply #172 on: May 18, 2018, 11:45:24 pm »
If you can make a web application, and forget using Electron at all, do it.

If not (for example your app needs to constantly work with local files), make a node.js app with Lazarus, convert it with Pas2JS, and make the UI with any framework you want (React, Angular, Vue, or Vanilla JS).

serkank

  • Newbie
  • Posts: 2
Re: Modern UI in Lazarus
« Reply #173 on: May 21, 2018, 08:10:48 am »
Thank you phil & Lainz .. 

Quote
If you can make a web application, and forget using Electron at all, do it.

If not (for example your app needs to constantly work with local files), make a node.js app with Lazarus, convert it with Pas2JS, and make the UI with any framework you want (React, Angular, Vue, or Vanilla JS).

Lainz i want  comunication beetwen Pascal and Web Gui .. 
i dont want Convert Pascal code to Javascript.   

I think its will be more advaged from Lazarus Gui
You can Prepare Gui with HTML , CSS , Javascipt  and Javascript Frameworks  and show Your Gui All in one Form ..


lainz

  • Hero Member
  • *****
  • Posts: 3179
    • Lainz
Re: Modern UI in Lazarus
« Reply #174 on: May 29, 2018, 08:03:20 pm »
I tested pas2js, and I can't convert a simple project due to dependencies. I don't say that doesn't works, it works but not for the project I wanted to convert, that was using this library (https://github.com/nikosdion/timecode).

I'm using brook framework, you can make an API to retrieve data and do actions in the server, then the GUI can be any website.