0

I don't understand to parametr *largs in example in Kivy documentation. Why is used parameter *largs for function on_swipe_callback? In standard using callback function (for me) it contents only senders name. Can *largs contentent more value? Explain me it, please.

class MyWidget(Widget):
    def __init__(self, **kwargs):
        super(MyWidget, self).__init__(**kwargs)
        self.register_event_type('on_swipe')

    def on_swipe(self):
        pass

def on_swipe_callback(*largs):
    print('my swipe is called', largs)
w = MyWidget()
w.dispatch('on_swipe')
eyllanesc
  • 235,170
  • 19
  • 170
  • 241
jasan
  • 209
  • 4
  • 15
  • 1
    Possible duplicate of [\*args and \*\*kwargs?](https://stackoverflow.com/questions/3394835/args-and-kwargs) – eyllanesc Feb 13 '18 at 23:14
  • @eyllanesc Thanks! I used bad watchword for browser.But I have next question. In callback parameter is typcally sender name ( sender of event), can I add next value to *largs? – jasan Feb 14 '18 at 09:43

0 Answers0