GUI-O Forum
    • Categories
    • Recent
    • Tags
    • Popular
    • Users
    • Groups
    • Register
    • Login

    BSL

    Scheduled Pinned Locked Moved
    General Discussion
    2
    2
    395
    Loading More Posts
    • Oldest to Newest
    • Newest to Oldest
    • Most Votes
    Reply
    • Reply as topic
    Log in to reply
    This topic has been deleted. Only users with topic management privileges can see it.
    • G
      gammda
      last edited by gammda

      Hello. GUI-O is a very interesting application. I have a question?
      I use a horizontal BSL line
      | BSL UID: bsl1 X: 0 Y: 50 ROT: 0 LEN: 100
      Then I want to rotate it 37 degrees.
      | BSL UID: bsl3 X: 0 Y: 50 ROT: 37 LEN: 100
      This line is then not 100% long, which means it is not drawn in full screen mode.
      How can I do this?

      1 Reply Last reply Reply Quote 0
      • K
        kl3m3n
        last edited by kl3m3n

        Hello gammda!

        Thank you for trying the GUI-O application. I hope you will find it useful for your use cases.

        Regarding your question... The line's rotation point is located at the start of the line. Specifying the rotation of 37 degrees means that the rotation is performed CCW (counter clockwise). To perform the CW (clockwise rotation, set the value to -37 degrees).

        In order to extend the line to the edge of the screen you need to use a little trigonometry trick to calculate the new length:

        new_length = current_length / cos(37°) = 100 / cos(37°) = 125.2
        

        So, your initialization must be modified to:

        |BSL UID:bsl3 X:0 Y:50 ROT:37 LEN:125.2
        

        NOTE THAT PARAMETER AND VALUE MUST NOT BE SPACE SEPARATED, e.g., ROT:37 works, while ROT: 37 does not!

        Hope you do some interesting project with the GUI-O application. You can always share them in our Share your projects category.

        Best regards,
        kl3m3n

        1 Reply Last reply Reply Quote 0
        • First post
          Last post