Lua Syntax for Zoom, Editor Bounds and Screen Resolutions!

Home Forums General Programming Lua Syntax for Zoom, Editor Bounds and Screen Resolutions!

This topic contains 1 reply, has 2 voices, and was last updated by Possemo Possemo 10 months, 1 week ago.

Viewing 2 posts - 1 through 2 (of 2 total)
  • Author
  • #83850
    • Topics: 8
    • Replies: 13
    • Total: 21

    Hi how can I slice three parameters into three variables with Lua?

    The ZOOM is so!

    ZOOM = panel: getPanelEditor (): getProperty (“uiPanelZoom”)
    The result is then 1

    code (is working!)

    function GetZOOM ()

    ZOOM = panel: getPanelEditor (): getProperty (“uiPanelZoom”)


    For the other two I miss the syntax! How do I write this correctly?

    Editor bounds
    Result should be (“0,0,800,600”) Current Editor Window Resolutions

    code (wrong syntax)

    function GetEDITOR_BOUNDS ()

    EDITOR_BOUNDS = panel: getPanelEditor (): getProperty (“Editor bounds”) Syntax ????


    Screen Resolutions (Monitor Windows)

    Result should be (“0,0,1680,1050”) Current resolution of Windows and Monitor

    code (wrong syntax)

    function GetSCREEN_RESOLUTIONS ()

    SCREEN_RESULUTIONS = Syntax ????


    How can I get the parameters EDITOR_BOUNDS and SCREEN_RESULUTIONS?

    Can someone give me an example in Lua?

    Greetings Michael

    • Topics: 13
    • Replies: 515
    • Total: 528
    • ★★★

    I can give you a working syntax for “EDITOR BOUNDS” but I would call it canvas size:

    panel:getPanelEditor():setProperty(“uiPanelCanvasRectangle”, “0 0 1530 1004”, false)

    There are no other size related properties which make sense to modify – e.g. PanelWidth and PanelHeight are not doing anything.

Viewing 2 posts - 1 through 2 (of 2 total)

You must be logged in to reply to this topic.

There is currently 0 users and 21 guests online
No users are currently active
Forum Statistics
Threads: 2,202, Posts: 15,477, Members: 56,166
Most users ever online was 12 on January 22, 2019 3:47 pm
Do NOT follow this link or you will be banned from the site!