omz:forum

    • Register
    • Login
    • Search
    • Recent
    • Popular
    1. Home
    2. DOGGY
    3. Posts

    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.


    • Profile
    • Following 0
    • Followers 0
    • Topics 0
    • Posts 4
    • Best 1
    • Controversial 0
    • Groups 0

    Posts made by DOGGY

    • RE: Check multi-keys press

      @YaleY that would be a hard one…..

      posted in Pythonista
      DOGGY
      DOGGY
    • RE: Check multi-keys press

      @yaley Yes, sorry, as @cvp and my tries, using pygame module is not possible in Pythonista because Pythonista doesn’t have pygame Stash also cannot

      posted in Pythonista
      DOGGY
      DOGGY
    • RE: Check multi-keys press

      @yaley ok. How about using pygame module? It might work :

      import pygame
      screen = pygame.display.set_mode((0,0,320,320))
      while True:
          for event in pygame.event.get():
              if event.type == pygame.KEYDOWN or event.type == pygame.KEYUP:
                  if event.mod == pygame.KMOD_NONE:
                      print('No modifier keys were in a pressed state when this '
                        'event occurred.')
                  else:
                      if event.mod & pygame.KMOD_LSHIFT:
                           print('Left shift was in a pressed state when this event '
                            'occurred.')
                      if event.mod & pygame.KMOD_RSHIFT:
                           print('Right shift was in a pressed state when this event '
                            'occurred.')
                      if event.mod & pygame.KMOD_SHIFT:
                          print('Left shift or right shift or both were in a '
                            'pressed state when this event occurred.') 
      
      posted in Pythonista
      DOGGY
      DOGGY
    • RE: Check multi-keys press

      You can try to use

      key_command(sender)
      

      and

      get_key_commands()
      

      For documentation : visit here

      posted in Pythonista
      DOGGY
      DOGGY