Progress report 2: defining layouts with QtDesigner

30 views
Skip to first unread message

Edward K. Ream

unread,
Jul 29, 2024, 3:17:28 PM7/29/24
to leo-editor
PR #4017 has passed several milestones:

- The VR and VR3 plugins no longer know about layouts.
- The define_qt_layouts plugin demonstrates that plugins can now define layouts.

Status

Layouts that can use Leo's two standard splitters are straightforward. Other layouts will be difficult or impossible to define using the DynamicWindow class.

Let's use QtDesigner!

QtDesigner's .ui files can describe any complex layout. Imo it's time to transition to such files. The benefits should be immediate.

Moreover, Leo's plugins folder already contains several .ui files, including qt_main.ui and qt_main_2.ui. It may be possible to use one of these files with minimal changes.

Summary

The PR will soon support code-based and QtDesigner-based layouts.

Edward

Edward K. Ream

unread,
Jul 29, 2024, 5:18:35 PM7/29/24
to leo-e...@googlegroups.com
On Mon, Jul 29, 2024 at 2:17 PM Edward K. Ream wrote:

Summary

The PR will soon support code-based and QtDesigner-based layouts.

I'll aim for maximum compatibility. The define_qt_layouts will (where possible) define layouts with and without QtDesigner.

Edward

Edward K. Ream

unread,
Jul 30, 2024, 5:38:24 AM7/30/24
to leo-editor
On Monday, July 29, 2024 at 4:18:35 PM UTC-5 Edward K. Ream wrote:

>> The PR will soon support code-based and QtDesigner-based layouts.
> I'll aim for maximum compatibility. The define_qt_layouts will (where possible) define layouts with and without QtDesigner.

c.frame.top is an instance of the DynamicWindow class, a subclass of QMainWindow. As a result, the DynamicWindow class must remain as it is. This constraint probably will affect the contents of the new .ui files. My goal will be to add a few methods to the DynamicWindow class, leaving all else unchanged.

Edward
Reply all
Reply to author
Forward
0 new messages