Recent

Author Topic: Cannot move a MessageDlg dialog  (Read 1932 times)

bpranoto

  • Full Member
  • ***
  • Posts: 134
Cannot move a MessageDlg dialog
« on: November 01, 2020, 12:47:54 pm »
A dialog which is created by MessageDlg function can not be moved relative to the parent window. It looks like the dialog is glued to the form which created it.

If we drag the dialog, the caller form also moved along the dialog.

To demonstrate the problem, show a MessageDlg from a form and then try to move the dialog. I have attached  a simple project to demonstrate this.

fpc version: 3.2.0
lazarus version : 2.10.0
o/s: linux ubuntu 18.04

Is it a bug or a feature?

jamie

  • Hero Member
  • *****
  • Posts: 6130
Re: Cannot move a MessageDlg dialog
« Reply #1 on: November 01, 2020, 03:14:58 pm »
maybe if you were to give us a workable project you would get more audience.

I've tired now but my os only logs the title of the project with an empty file. = "size on disk = 0"

that would be the lfm file.
The only true wisdom is knowing you know nothing

wp

  • Hero Member
  • *****
  • Posts: 11916
Re: Cannot move a MessageDlg dialog
« Reply #2 on: November 01, 2020, 03:16:20 pm »
The project is lacking the lpi file.

Sieben

  • Sr. Member
  • ****
  • Posts: 310
Re: Cannot move a MessageDlg dialog
« Reply #3 on: November 01, 2020, 03:23:20 pm »
I loaded the lpr file ('Open Project...'), let IDE create a new lpi and moving dialog worked just fine.
Lazarus 2.2.0, FPC 3.2.2, .deb install on Ubuntu Xenial 32 / Gtk2 / Unity7

wp

  • Hero Member
  • *****
  • Posts: 11916
Re: Cannot move a MessageDlg dialog
« Reply #4 on: November 01, 2020, 03:32:18 pm »
No, the lpi file is an essential part of the project because it lists the packages that are required and the compiler settings that you use.

jamie

  • Hero Member
  • *****
  • Posts: 6130
Re: Cannot move a MessageDlg dialog
« Reply #5 on: November 01, 2020, 03:33:43 pm »
The posters initial problem is a widget issue I would say
The only true wisdom is knowing you know nothing

bpranoto

  • Full Member
  • ***
  • Posts: 134
Re: Cannot move a MessageDlg dialog
« Reply #6 on: November 01, 2020, 04:08:15 pm »
The project is lacking the lpi file.

Sorry, here is the project with the .lpi file

Sieben

  • Sr. Member
  • ****
  • Posts: 310
Re: Cannot move a MessageDlg dialog
« Reply #7 on: November 01, 2020, 04:21:09 pm »
No, the lpi file is an essential part of the project because it lists the packages that are required and the compiler settings that you use.

Yes, I know. I was just reporting what I did and that moving MessageDlgs is not an issue, usually. And it isn't with the new zip as well.
Lazarus 2.2.0, FPC 3.2.2, .deb install on Ubuntu Xenial 32 / Gtk2 / Unity7

bpranoto

  • Full Member
  • ***
  • Posts: 134
Re: Cannot move a MessageDlg dialog
« Reply #8 on: November 01, 2020, 04:25:36 pm »
Yes, I know. I was just reporting what I did and that moving MessageDlgs is not an issue, usually. And it isn't with the new zip as well.

Is your environment same with me? BTW, the widgetset is gtk2.

Sieben

  • Sr. Member
  • ****
  • Posts: 310
Re: Cannot move a MessageDlg dialog
« Reply #9 on: November 01, 2020, 04:29:09 pm »
Environment as in signature. Gtk2 here as well.
Lazarus 2.2.0, FPC 3.2.2, .deb install on Ubuntu Xenial 32 / Gtk2 / Unity7

madref

  • Hero Member
  • *****
  • Posts: 949
  • ..... A day not Laughed is a day wasted !!
    • Nursing With Humour
Re: Cannot move a MessageDlg dialog
« Reply #10 on: November 03, 2020, 05:53:02 pm »
Why not design your own dialogue form.
This way you can put it anywhere you want.
You treat a disease, you win, you lose.
You treat a person and I guarantee you, you win, no matter the outcome.

Lazarus 3.99 (rev main_3_99-649-ge13451a5ab) FPC 3.3.1 x86_64-darwin-cocoa
Mac OS X Monterey

winni

  • Hero Member
  • *****
  • Posts: 3197
Re: Cannot move a MessageDlg dialog
« Reply #11 on: November 03, 2020, 06:51:28 pm »
Hi!

No problems here with the source from  bpranoto.
See screenshot.

System : Lin64, fpc 3.04, Laz 2.0.10 on Suse Tumbleweed

Winni

PS.: gtk2
« Last Edit: November 03, 2020, 06:59:41 pm by winni »

bpranoto

  • Full Member
  • ***
  • Posts: 134
Re: Cannot move a MessageDlg dialog
« Reply #12 on: November 03, 2020, 07:34:02 pm »
Hi!

No problems here with the source from  bpranoto.
See screenshot.

System : Lin64, fpc 3.04, Laz 2.0.10 on Suse Tumbleweed

Winni

PS.: gtk2

Thank you for trying, I guess it is somehow an environmental problem....

lucamar

  • Hero Member
  • *****
  • Posts: 4219
Re: Cannot move a MessageDlg dialog
« Reply #13 on: November 03, 2020, 08:39:11 pm »
No problems here either: Xubuntu 18.04, Lazarus/FPC 2.0.10/3.2.0 (x86_64-gtk2)

ETA: Does Ubuntu 18.04 still use Unity? If so, it might have something to do with that. If you can, try installing (and loging in a session of) gnome-fallback (IIRC it's called that ... I stoped using plain Ubuntu with 12.04 :-[)
« Last Edit: November 03, 2020, 08:46:05 pm by lucamar »
Turbo Pascal 3 CP/M - Amstrad PCW 8256 (512 KB !!!) :P
Lazarus/FPC 2.0.8/3.0.4 & 2.0.12/3.2.0 - 32/64 bits on:
(K|L|X)Ubuntu 12..18, Windows XP, 7, 10 and various DOSes.

bpranoto

  • Full Member
  • ***
  • Posts: 134
Re: Cannot move a MessageDlg dialog
« Reply #14 on: November 05, 2020, 06:02:07 am »
ETA: Does Ubuntu 18.04 still use Unity? If so, it might have something to do with that. If you can, try installing (and loging in a session of) gnome-fallback (IIRC it's called that ... I stoped using plain Ubuntu with 12.04 :-[)

No, ubuntu 18.04 uses gnome3

 

TinyPortal © 2005-2018