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.


    Make usefull examples modules!

    Pythonista
    1
    3
    2578
    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.
    • PKHG222
      PKHG222 last edited by

      wrenaud gave us this very nice example of a directory-script see
      omz-software.com/pythonista/forums/discussion/19/file-browser

      E.g he has succeeded making a 'scrollable' layer and more!
      and what I just did is this:
      I moved the "class filebrowser" into a file "filebrowser" (which seems to get automatically the extension py!!!_
      imported it like this: from filebrowser import filebrowser as fs and then finally (after putting class filebrowser between ''' and ''' )
      run(MyScene(fs()))

      And it works!!!

      So this means that it would be worthwhile (if allowed) to put those very useful classes as modules into your local space making the using modules much smaller because one line importing something is much shorter than the whole ;-)

      What do you think ... finally these generally modules if not directly available in the app (to stay 'small') should be somewhere (gist, wiki?) available???

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

        So, py-files in lib are not shown in the Pythonista lib, ok? For helper modules not necessary.
        So question remains for me: where and how to create 'lib'?

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

          Will be done shortly ;-) Thanks!

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