new class in our python module python allows us to place more than one class in to same pyhton module and it also enables us to mix-and-match classes and regular functions in the same module in our tooltip codewe declare python class and explicitly make it inherit from objectwhich is the foundation of all python classes we can also leave it outas we did in the aclass code examplebecause it is the default for all python classes after all the necessary tooltip creation code that occirs within the tooltip classwe switch over to non-oop python programming by creating function just below it we can add tooltip for our spinbox widgetas follows #add tooltip create_tooltip(spin'this is spin control'we could do the same for all of our other gui widgets in the very same manner we just have to pass in reference to the widget we wish to have tooltipdisplaying some extra information for our scrolledtext widgetwe made the scrol variable point to itso this is what we pass into the constructor of our tooltip creation function