Recent

Author Topic: Looking for lightweight GUI  (Read 2228 times)

sash

  • Sr. Member
  • ****
  • Posts: 266
Re: Looking for lightweight GUI
« Reply #15 on: August 21, 2019, 11:30:51 am »
libraries are native C++, then someone made C bindings and DLL's and after that someone made Pascal headers :)

Pascal headers are not wrappers (like C interface to C++) they are just another alternative (to C's headers) client interface, so there should be no runtime overhead in C -> Pascal conversion, maybe with exception of pchar to string assignments.

can't debug DLL code.
Why? Normally it is possible.
Lazarus 2.0.2 FPC 3.0.4 x86_64-linux-gtk2 -- Ubuntu 19.04 XFCE

Paul_

  • Full Member
  • ***
  • Posts: 130
Re: Looking for lightweight GUI
« Reply #16 on: August 21, 2019, 02:07:23 pm »
I can debug the program, but it in case of SFML DLL's it mostly returns assembler code without any clue where the error occurred. Not even function from Pascal headers that was called. SFML have no exceptions, only text output in some cases when you can't create window or you're loading nonexistent or unsupported file.

I don't have much experience with that. There is any possibility?

mr-highball

  • Jr. Member
  • **
  • Posts: 66
Re: Looking for lightweight GUI
« Reply #17 on: August 21, 2019, 03:13:43 pm »
for games in pascal these are probably your best bet (to my knowledge)

castle has been around for quite a while and is continually being updated, and pasvulkan is not quite a full engine yet (also to my knowledge), but appears to have some good stuff and may be more lightweight. each have UI implementations, but I've only really played around with castle and it has quite a bit of documentation. If you're up for reading some code then vulkan may be path you want to take, and it appears there is at least a template to start you out
https://github.com/BeRo1985/pasvulkan/tree/master/projects/template
-Highball

sash

  • Sr. Member
  • ****
  • Posts: 266
Re: Looking for lightweight GUI
« Reply #18 on: August 22, 2019, 10:59:06 am »
I don't have much experience with that. There is any possibility?
As I said earlier, yes, but of course to debug SFML (C++ code) you need that code to be compiled with debug info and (IDE that supports) C++ debugger.
Everything without debugging info (and proper language support) is seen "as assembler" by any native-code debuggers (incl. Lazarus).

Practically, I doubt you need it. Just handle the data you're feeding to SFML properly, with checks/exceptions on Pascal' side and it will be ok.
Lazarus 2.0.2 FPC 3.0.4 x86_64-linux-gtk2 -- Ubuntu 19.04 XFCE