Recent

Author Topic: Best way to resize a window ?  (Read 5183 times)

Fred vS

  • Hero Member
  • *****
  • Posts: 3168
    • StrumPract is the musicians best friend
Best way to resize a window ?
« on: June 25, 2012, 04:35:14 pm »
Hello every Lazarus fans  :P

In a last topic, KpComp shows us how to move a panel.  ::)

Because Lazarus do not offer a resizable window without top panel tray ( borderstyle := bsnone do not give a resizable window, and all the other style are with top panel tray), i want to create my own sizable window.

For that i use a window borderstyle := bsnone and top, bottom, left and right thin panels with cursor := crSizeNS for top/bottom panels and cursor := crSizeWE for left/right panels.

The goal is to resize the window with panelmousedown on one of 4 resizing-panels and panelmousemove  :-\

See attachment from original project of KpjComP

PS : Other ideas are welcome  ;)
« Last Edit: June 25, 2012, 04:46:37 pm by Fred vS »
I use Lazarus 2.2.0 32/64 and FPC 3.2.2 32/64 on Debian 11 64 bit, Windows 10, Windows 7 32/64, Windows XP 32,  FreeBSD 64.
Widgetset: fpGUI, MSEgui, Win32, GTK2, Qt.

https://github.com/fredvs
https://gitlab.com/fredvs
https://codeberg.org/fredvs

KpjComp

  • Hero Member
  • *****
  • Posts: 680
Re: Best way to resize a window ?
« Reply #1 on: June 25, 2012, 06:10:12 pm »
It's not too much different to the moving panel.

Try this ->

I've also added a few other types of resize / moving too.

Fred vS

  • Hero Member
  • *****
  • Posts: 3168
    • StrumPract is the musicians best friend
Re: Best way to resize a window ?
« Reply #2 on: June 25, 2012, 09:30:40 pm »
@ KpjComp : Superb and you give me the moving windows for bonus, many, many thanks.  :P

Im happy.  :)

I use Lazarus 2.2.0 32/64 and FPC 3.2.2 32/64 on Debian 11 64 bit, Windows 10, Windows 7 32/64, Windows XP 32,  FreeBSD 64.
Widgetset: fpGUI, MSEgui, Win32, GTK2, Qt.

https://github.com/fredvs
https://gitlab.com/fredvs
https://codeberg.org/fredvs

 

TinyPortal © 2005-2018