Recent

Author Topic: Proposing new widgetset: dwindows  (Read 17299 times)

iahung

  • New Member
  • *
  • Posts: 22
Re: Proposing new widgetset: dwindows
« Reply #45 on: December 13, 2022, 01:46:44 am »
This means you have to translate gtk headers in order to translate dw.h to pascal.

Wrap dwindows means writing Pascal FFI definitions for dw_xxx API. The dw_xxx API already wraps the underlying widget sets, like what LCL does.

The dw_xxx API uses data structures provided by the gtk headers >:( The same way they are using data structures provided by windows.h on Windows >:( You either have to translate the subset used by dw.h or use the full gtk headers >:(

Bogen85

  • Hero Member
  • *****
  • Posts: 703
Re: Proposing new widgetset: dwindows
« Reply #46 on: December 13, 2022, 01:50:16 am »
We used to met on github. I know you. In no way I could consider the screenshots you posted as good enough looking. The was odd is too underestimated, I would say ugly. CudaText Qt6 looks so ugly on your XFCE4:

https://github.com/Alexey-T/CudaText/issues/4595

I've not used it (the qt6 preview) since then. I agree before rounding the fonts it looked ugly. Also that was a fresh config and the font sizes were much larger than my defaults that I used at on qt5, and there are scaling issues with the sizes I was using.

In contrast with gtk3 I'd consider the qt6 one actually usable. Prior to the font cleanup I would not have used it (the qt6 one). The qt5 one is stable and the officially released one, and that is what I use.


iahung

  • New Member
  • *
  • Posts: 22
Re: Proposing new widgetset: dwindows
« Reply #47 on: December 13, 2022, 01:52:45 am »
@Bogen85 Another point for gtk. The Linux world split in two: GTK and QT. I personally run a Qt free Linux system. Running a GTK free Linux system is much more difficult. As web browsers like Chromium and Firefox are all gtk based. Imagine you are running a Qt free Linux system, it's naturally for you to choose gtk based applications rather than Qt based applications that you will have to install Qt and it so many dependencies. It's only less worse than a KDE applications, as it will pull in KDE craps too not only Qt >:(

PierceNg

  • Sr. Member
  • ****
  • Posts: 429
    • SamadhiWeb
Re: Proposing new widgetset: dwindows
« Reply #48 on: December 13, 2022, 02:05:10 am »
This means you have to translate gtk headers in order to translate dw.h to pascal.

Wrap dwindows means writing Pascal FFI definitions for dw_xxx API. The dw_xxx API already wraps the underlying widget sets, like what LCL does.

The dw_xxx API uses data structures provided by the gtk headers >:( The same way they are using data structures provided by windows.h on Windows >:( You either have to translate the subset used by dw.h or use the full gtk headers >:(

That sounds bad. Can you point to some examples? The public API functions list in dw.h all appear to use dwindows abstract types like HWND, DWResources, etc. 

Bogen85

  • Hero Member
  • *****
  • Posts: 703
Re: Proposing new widgetset: dwindows
« Reply #49 on: December 13, 2022, 02:09:30 am »
@Bogen85 Another point for gtk. The Linux world split in two: GTK and QT. I personally run a Qt free Linux system. Running a GTK free Linux system is much more difficult. As web browsers like Chromium and Firefox are all gtk based. Imagine you are running a Qt free Linux system, it's naturally for you to choose gtk based applications rather than Qt based applications that you will have to install Qt and it so many dependencies. It's only less worse than a KDE applications, as it will pull in KDE craps too not only Qt >:(

Thanks. I understand where you are coming from.

I can't run Qt-free and use CudaText and there are several other apps that I use and depend on that are Qt based.
I'm not giving up CudaText. Period. Giving up Qt would be giving up CudaText for me. The gtk2 based CudaText is unsuitable to me.
Would I like the gtk3 one to work? yes.

Would I like my system theming (icon, fonts, colors, etc) to work with all my apps? Yes.

But I can't give up CudaText and the few other Qt apps I use. Some of which there are absolutely no alternatives I can use.

Imagine you are running a Qt free Linux system, it's naturally for you to choose gtk based applications rather than Qt based applications that you will have to install Qt and it so many dependencies.

Sigh, yes. And agreed.

I should not be bashing on GTK.

I would like to see GTK3/GTK4 working with CudaText, but in the interim I can't use CudaText-gtk2 and I'm not going to use gedit or geany or Sublime instead of CudaText just because of this issue...


It's only less worse than a KDE applications, as it will pull in KDE craps too not only Qt >:(

Yes... As I said, I can't tolerate KDE apps on non KDE. And I can't tolerate KDE... So no "win" either way there...

Thanks iahung, all your points are valid.

It would nice if there was an straightforward path out of this mess....
« Last Edit: December 13, 2022, 02:11:26 am by Bogen85 »

iahung

  • New Member
  • *
  • Posts: 22
Re: Proposing new widgetset: dwindows
« Reply #50 on: December 13, 2022, 02:11:36 am »
This means you have to translate gtk headers in order to translate dw.h to pascal.

Wrap dwindows means writing Pascal FFI definitions for dw_xxx API. The dw_xxx API already wraps the underlying widget sets, like what LCL does.

The dw_xxx API uses data structures provided by the gtk headers >:( The same way they are using data structures provided by windows.h on Windows >:( You either have to translate the subset used by dw.h or use the full gtk headers >:(

That sounds bad. Can you point to some examples? The public API functions list in dw.h all appear to use dwindows abstract types like HWND, DWResources, etc.

Try commenting out gtk headers on dw.h and compile dwtest.c, you will see ;D

Bogen85

  • Hero Member
  • *****
  • Posts: 703
Re: Proposing new widgetset: dwindows
« Reply #51 on: December 13, 2022, 02:17:54 am »
...
We used to met on github. I know you. In no way I could consider the screenshots you posted as good enough looking. The was odd is too underestimated, I would say ugly. CudaText Qt6 looks so ugly on your XFCE4:

https://github.com/Alexey-T/CudaText/issues/4595

Yes, I would like Gtk3 or Gtk4 working for Lazarus.

https://github.com/Alexey-T/CudaText/issues/4334
Quote
Most dark themes very hard to use (bad contrast of menu bar in Qt5 version) #4334
bogen85 opened this issue on Sep 1 · 36 comments

If Dwindows would truly bring gtk3/gtk4 support to Lazarus via an abstracted stable API, I'm all for it.


PierceNg

  • Sr. Member
  • ****
  • Posts: 429
    • SamadhiWeb
Re: Proposing new widgetset: dwindows
« Reply #52 on: December 13, 2022, 02:31:38 am »
That sounds bad. Can you point to some examples? The public API functions list in dw.h all appear to use dwindows abstract types like HWND, DWResources, etc.

Try commenting out gtk headers on dw.h and compile dwtest.c, you will see ;D

Just did, on Windows 10, and dwtest built and ran using Visual Studio 2019 VC++ using the bundled makefile.

I don't understand the point you are making. Obviously, as a wrapper for GTK, dwindows does GTK things when it makes GTK API calls, including using GTK-specific types. Such GTK types don't exist in non-GTK environments (like Windows, Android) and aren't used when dwindows is built for those other environments.

iahung

  • New Member
  • *
  • Posts: 22
Re: Proposing new widgetset: dwindows
« Reply #53 on: December 13, 2022, 02:49:07 am »
New users are unable to reply private messages nor modifying their posts, bad forum >:(

iahung

  • New Member
  • *
  • Posts: 22
Re: Proposing new widgetset: dwindows
« Reply #54 on: December 13, 2022, 02:51:09 am »
That sounds bad. Can you point to some examples? The public API functions list in dw.h all appear to use dwindows abstract types like HWND, DWResources, etc.

Try commenting out gtk headers on dw.h and compile dwtest.c, you will see ;D

Just did, on Windows 10, and dwtest built and ran using Visual Studio 2019 VC++ using the bundled makefile.

I don't understand the point you are making. Obviously, as a wrapper for GTK, dwindows does GTK things when it makes GTK API calls, including using GTK-specific types. Such GTK types don't exist in non-GTK environments (like Windows, Android) and aren't used when dwindows is built for those other environments.

It's me that don't understand what you are trying to do. On Windows, you will have to comment out windows.h and other windows api headers to see how it turned out. When I tell you about gtk I assumed it's on Linux. It makes no sense on Windows >:D

PierceNg

  • Sr. Member
  • ****
  • Posts: 429
    • SamadhiWeb
Re: Proposing new widgetset: dwindows
« Reply #55 on: December 13, 2022, 02:54:55 am »
It's me that don't understand what you are trying to do. On Windows, you will have to comment out windows.h and other windows api headers to see how it turned out. When I tell you about gtk I assumed it's on Linux. It makes no sense on Windows >:D

You're basically saying if you take out a car's engine, then the car won't work. Like, duh.

I'm done with this sub thread. Have a nice day.

iahung

  • New Member
  • *
  • Posts: 22
Re: Proposing new widgetset: dwindows
« Reply #56 on: December 13, 2022, 03:03:40 am »
It's me that don't understand what you are trying to do. On Windows, you will have to comment out windows.h and other windows api headers to see how it turned out. When I tell you about gtk I assumed it's on Linux. It makes no sense on Windows >:D

You're basically saying if you take out a car's engine, then the car won't work. Like, duh.

I'm done with this sub thread. Have a nice day.

What's going on with you?  :o

dwindows itself is like the LCL. On Windows the engine is WinApi. On Linux the engine is GTK. You are commenting out GTK headers on Windows that are basically not being used at all. Then you tell me it will work even if you "taken out the engine"? :o

Imagine you are drive a hybrid car and disconnect the electric engine then you tell your car will work regardless if the electric engine is available or not. Good job :-X

Bogen85

  • Hero Member
  • *****
  • Posts: 703
Re: Proposing new widgetset: dwindows
« Reply #57 on: December 13, 2022, 03:04:03 am »
New users are unable to reply private messages nor modifying their posts, bad forum >:(

Yeah. I ran into that at first... it is a screening out trolls and spammers think from what I've heard...

But it negatively affects those it should not affect...

iahung

  • New Member
  • *
  • Posts: 22
Re: Proposing new widgetset: dwindows
« Reply #58 on: December 13, 2022, 03:07:17 am »
My point is still valid. You will need the GTK headers to use dwindows (on Linux) and Windows headers on Windows. Both of them, we already have. So it's not a problem for us. But it's still true. dw.h uses data structures from these headers, try commenting out them (respected to your platform) and compile dwtest.c then you will see if I was right or not. Your line of argument is like you expect it to work without the headers, it's simply wrong ::)

iahung

  • New Member
  • *
  • Posts: 22
Re: Proposing new widgetset: dwindows
« Reply #59 on: December 13, 2022, 03:08:37 am »
New users are unable to reply private messages nor modifying their posts, bad forum >:(

Yeah. I ran into that at first... it is a screening out trolls and spammers think from what I've heard...

But it negatively affects those it should not affect...

If it's the same for everyone then I'm no special ::)

 

TinyPortal © 2005-2018