Skip to content

Unable to add additional widgets within UISliderWidget #173

@jcornall

Description

@jcornall

The current implementation of the UISliderWidget restricts the addition of further widgets within the class itself (e.g. by adding and setting a layout).

The only available workaround that preserves inheritance involves passing other widgets to the class as an argument, and connecting the slider to the widgets (and vice versa) inside the class. Using this method, each widget can be added to the FormDialog, which preserves getting/setting widget states in the UIFormWidget class. However, this isn't ideal as it is limits the complexity of the widgets you can construct in the FormDialog (both in terms of functionality and layout). Adding widgets to the FormDialog using the addWidget() method only allows the user to add widgets vertically, with no support for horizontal widgets.

As a subclass of QSlider, adding the slider to a layout created within the class causes the window to crash (it is recursive, the slider contains the layout which contains the slider etc.).

See also #125, #174, #175

Metadata

Metadata

Assignees

No one assigned

    Labels

    enhancementNew feature or request

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions