Preparing search index...

    Collection of size values.

    export class SizesExamplePanel extends PanelPlugin {
    connections: any[];
    static descriptor() {
    const d = new Descriptor();
    d.id = 'com.docs.SizesExample';
    d.name = 'Sizes Example';
    d.defaultDockState = DockState.Detached;
    d.defaultSize = new Size(350, 250);
    return d;
    }
    constructor(pluginSystem: Editor.PluginSystem, descriptor?: Descriptor) {
    super(pluginSystem, descriptor);
    this.connections = [];
    }
    createWidget(parent: Widget): Widget {
    const root = new Widget(parent);
    const layout = new BoxLayout();
    layout.setDirection(Direction.TopToBottom);
    root.layout = layout;

    // Sizes provides standard dimension constants for consistent UI styling.
    // Apply Sizes constants to match the native Lens Studio look.
    layout.spacing = Sizes.Spacing;
    layout.setContentsMargins(Sizes.Padding, Sizes.Padding, Sizes.Padding, Sizes.Padding);

    const title = new Label(root);
    title.text = 'Sizes Constants Demo';
    layout.addWidget(title);

    const info = new Label(root);
    info.text =
    'Padding: ' + Sizes.Padding +
    '\nHalfPadding: ' + Sizes.HalfPadding +
    '\nDoublePadding: ' + Sizes.DoublePadding +
    '\nSpacing: ' + Sizes.Spacing +
    '\nButtonHeight: ' + Sizes.ButtonHeight +
    '\nButtonRadius: ' + Sizes.ButtonRadius +
    '\nInputHeight: ' + Sizes.InputHeight +
    '\nIconSide: ' + Sizes.IconSide;
    info.wordWrap = true;
    layout.addWidget(info);

    const btn = new PushButton(root);
    btn.text = 'Styled Button';
    layout.addWidget(btn);

    return root;
    }
    deinit(): void {
    this.connections.forEach((c: any) => c?.disconnect());
    this.connections = [];
    }
    }
    Index

    Constructors

    Properties

    ButtonDelegateSide: number

    Side dimension for button delegate elements.

    ButtonHeight: number

    Standard height for button widgets.

    ButtonRadius: number

    Corner radius applied to buttons.

    CheckBoxDrawedDiameter: number

    Diameter of the drawn checkbox indicator.

    CheckboxFocusPadding: number

    Padding added around a checkbox when focused.

    CheckBoxOutlineWidth: number

    Width of the checkbox outline stroke.

    CheckboxPadding: number

    Internal padding within a checkbox.

    CheckboxRadius: number

    Corner radius of the checkbox shape.

    DialogContentMargin: number

    Margin around content inside a dialog.

    DoublePadding: number

    Padding value equal to twice the standard padding.

    DragIconSizeHeight: number

    Height of the drag handle icon.

    DragIconSizeWidth: number

    Width of the drag handle icon.

    ExtentIconSide: number

    Side dimension of extent/expand icons.

    HalfPadding: number

    Padding value equal to half the standard padding.

    IconSide: number

    Standard side dimension for icons.

    InputHeight: number

    Standard height for input field widgets.

    InputRadius: number

    Corner radius applied to input fields.

    MenuItemHeight: number

    Height of individual menu items.

    MessageBoxIconSide: number

    Side dimension of the icon shown in message boxes.

    Padding: number

    Standard padding value used throughout the UI.

    PaddingLarge: number

    Larger padding value for wider spacing needs.

    ProgressBarHeight: number

    Height of progress bar widgets.

    RoundedPixmapRadius: number

    Corner radius applied to rounded pixmap images.

    SeparatorContentsMargin: number

    Margin around content adjacent to separators.

    SeparatorLineWidth: number

    Width of separator line elements.

    SizeGripSizeHeight: number

    Height of the window size grip widget.

    SizeGripSizeWidth: number

    Width of the window size grip widget.

    Spacing: number

    Standard spacing between UI elements.

    SpinboxButtonHeight: number

    Height of increment/decrement buttons in a spinbox.

    SpinboxButtonWidth: number

    Width of increment/decrement buttons in a spinbox.

    SpinboxDefaultWidth: number

    Default width of a spinbox widget.

    SplitterHandleWidth: number

    Width of the splitter handle divider.

    TextEditHeight: number

    Height of text edit widgets.

    ToolButtonPadding: number

    Internal padding within tool button widgets.

    ViewElidingGradientWidth: number

    Width of the gradient used for text eliding in views.

    ViewIndentation: number

    Indentation width for items in tree or list views.

    ViewSectionHeight: number

    Height of section headers in views.