Sign in Join

Live chat for Free Pascal, Lazarus, Delphi and every Pascal programmer.

Mailing lists / lazarus / 2018-02

LCL-fpGUI - SIGSEGV

9 messages · 4 people · –

Reply by email Subscribe to this list Your subscription

Read-only archive. Use j and k to move between messages.

Gabor Boros

Hi All,

I want to try LCL-fpGUI. Followed the instructions from the below wiki page, a new project compiled successfully but got error at application start. If start from the IDE got SIGSEGV, if start from command line got "Access violation". I used Lazarus trunk (57276) and fpGUI's maint branch.

http://wiki.freepascal.org/fpGUI_Interface

Gabor
-------------- next part --------------
A non-text attachment was scrubbed...
Name: LCL_fpGUI_error1.png
Type: image/png
Size: 3447 bytes
Desc: not available
URL: <http://lists.lazarus-ide.org/pipermail/lazarus/attachments/20180210/17bda9f3/attachment-0002.png> -------------- next part --------------
A non-text attachment was scrubbed...
Name: LCL_fpGUI_error2.png
Type: image/png
Size: 7871 bytes
Desc: not available
URL: <http://lists.lazarus-ide.org/pipermail/lazarus/attachments/20180210/17bda9f3/attachment-0003.png>

Reply by email

Ondrej Pokorny
to Gabor Boros
Gabor Boros wrote 9 lines
Hi All, I want to try LCL-fpGUI. Followed the instructions from the below wiki page, a new project compiled successfully but got error at application start. If start from the IDE got SIGSEGV, if start from command line got "Access violation". I used Lazarus trunk (57276) and fpGUI's maint branch. http://wiki.freepascal.org/fpGUI_Interface

Disable Application.Scaled - fpGUI doesn't support it yet.

Ondrej

Reply by email

Graeme Geldenhuys
to Ondrej Pokorny: Disable Application.Scaled - fpGUI doesn't support it yet. Ondrej
Ondrej Pokorny wrote
Disable Application.Scaled - fpGUI doesn't support it yet.

Is that for multi-DPI aware applications? If so, at least in the fpGUI 'develop' branch there is built-in support for multi-DPI. So LCL-fpGUI might be able to hook into that functionality.

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

Reply by email

Ondrej Pokorny
to Graeme Geldenhuys
Graeme Geldenhuys wrote 6 lines
On 2018-02-10 09:42, Ondrej Pokorny via Lazarus wrote: > Disable Application.Scaled - fpGUI doesn't support it yet. Is that for multi-DPI aware applications? If so, at least in the fpGUI 'develop' branch there is built-in support for multi-DPI. So LCL-fpGUI might be able to hook into that functionality.

Yes, sorry. I wasn't exact: LCL-fpGUI doesn't support it yet. The same goes for the develop branch, unfortunately: LCL-fpGUI cannot be compiled with it.

What is missing in LCL-fpGUI binding: TMonitor.PixelsPerInch.

Ondrej

Reply by email

Graeme Geldenhuys
to Ondrej Pokorny
Ondrej Pokorny wrote
Yes, sorry. I wasn't exact: LCL-fpGUI doesn't support it yet. The same goes for the develop branch, unfortunately: LCL-fpGUI cannot be compiled with it.

No worries, just checking if I understood what you meant.

What is missing in LCL-fpGUI binding: TMonitor.PixelsPerInch.

In fpGUI, you can grab that information from the global fpgApplication instance. That has been around for years, so both the 'maint' and 'develop' branches have it.

     function    Screen_dpi_x: integer;
     function    Screen_dpi_y: integer;
     function    Screen_dpi: integer;

LCL-fpGUI probably only needs the last one. I don't believe non-X11 platforms (eg: Windows) support varying dpi on the x and y axis.

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

Reply by email

José Mejuto
to Graeme Geldenhuys
Graeme Geldenhuys wrote
    function    Screen_dpi: integer; LCL-fpGUI probably only needs the last one. I don't believe non-X11 platforms (eg: Windows) support varying dpi on the x and y axis.

Hello,

Yes that's the needed value, is the binding which is missing, not detected as I'm not using scaled applications.

It will be added in the next LCL-fpGUI update.

Reply by email

Ondrej Pokorny
to Graeme Geldenhuys: No worries, just checking if I understood what you meant. In fpGUI, you can grab that…
Graeme Geldenhuys wrote 10 lines
On 2018-02-10 16:31, Ondrej Pokorny via Lazarus wrote: > What is missing in LCL-fpGUI binding: TMonitor.PixelsPerInch. In fpGUI, you can grab that information from the global fpgApplication instance. That has been around for years, so both the 'maint' and 'develop' branches have it.     function    Screen_dpi_x: integer;     function    Screen_dpi_y: integer;     function    Screen_dpi: integer;

Does fpGUI support DPI on per-monitor basis? I.e. I have a high-DPI laptop screen and a normal DPI external monitor connected to it - and I work on both of them.

LCL-fpGUI probably only needs the last one. I don't believe non-X11 platforms (eg: Windows) support varying dpi on the x and y axis.

LCL scaling doesn't support varying x/y dpi either.

Ondrej

Reply by email

Graeme Geldenhuys
to Ondrej Pokorny
Ondrej Pokorny wrote
Does fpGUI support DPI on per-monitor basis? I.e. I have a high-DPI laptop screen and a normal DPI external monitor connected to it - and I work on both of them.

Last time I tested (granted that was a while back), the fpGUI application detects the DPI of the monitor it is launched on. I can't remember what happens when you drag that application from one monitor to another (where they have varying dpi values).

[Nothing related to fpGUI] I do know that Windows 10 is seriously broken in this regard. At least I think it is broken, or the implementation is seriously sh*t. eg: Take an application like Delphi XE3 and launch it on a 140+ dpi monitor. Open a debug window (or any non-docked IDE window). Drag that window to the 96dpi monitor. Boom, you have the over-scaled fuzzy looking window. Even dragging a single window application so that just over 50% of the window appears on the 96dpi monitor, and the same thing happens. Less than 50% overlap, and all is well. WTF Microsoft!!! I've got this issue at work every day. To alleviate the problem slightly, I have to change the "default monitor" to the lower dpi monitor.

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

Reply by email