omz:forum

    • Register
    • Login
    • Search
    • Recent
    • Popular

    Welcome!

    This is the community forum for my apps Pythonista and Editorial.

    For individual support questions, you can also send an email. If you have a very short question or just want to say hello — I'm @olemoritz on Twitter.


    very basic ui designer question

    Pythonista
    3
    5
    3126
    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.
    • michael_recchione
      michael_recchione last edited by

      I'm playing with using the ui designer for the first time, and am confused. I'm trying to create a view with a few labels and textfields, and would like to read the values of a couple of textfields, do something with them, and display the result in another. The documentation says that I should be able to set the action from the attribute menu in the designer tool. But there doesn't seem to be that ability.

      How can you set the actions for the controls that are created in the designer tool?

      Thanks

      1 Reply Last reply Reply Quote 0
      • JonB
        JonB last edited by

        You can set actions for buttons, maybe a few others. Textfields, etc, while they do have actions, or delegates, you can't set them in the ui designer.

        What you will find is, since actions and delegates have to basically be globals In order to be used in the designer, it is somewhat limiting, so people end up just setting all of that after you load your view.

        1 Reply Last reply Reply Quote 0
        • michael_recchione
          michael_recchione last edited by

          Thanks! Two additional questions, then:

          1. Are there any examples of scripts using textfields you could point me to, to see how it's done?

          2. Is there any way to actually look at the code that the UI designer generates, and to modify it directly, as text?

          I'm new here, so I apologize if I've violated recommended practice by including new questions in an existing thread. I'm just trying to come out of the 1980's, and to add some rudimentary UI beyond the console to my code...

          Thanks in advance for any help!

          1 Reply Last reply Reply Quote 0
          • ccc
            ccc last edited by

            1. Check out the UI Tutorial examples in the UI section of Pythonista Tools. It is a great way to learn the ui module and there are great tips and tricks there. You can submit pull requests if you have ideas for improving that content.

            2. Check out the three .pyui tools at https://github.com/cclauss/Ten-lines-or-less

            1 Reply Last reply Reply Quote 0
            • michael_recchione
              michael_recchione last edited by

              Fantastic! Thanks! It works...

              1 Reply Last reply Reply Quote 0
              • First post
                Last post
              Powered by NodeBB Forums | Contributors