Sep-23-2021, 05:17 PM
This could be a general question about how to add a function in an existing class:
I want the textBrowser to scroll down to the bottom every time I append sth. ofc I cannot change QtextBrowser; Since the element textBrowser is created by the .ui file, which is automatically instantiated from the QtextBrowser, I cannot (I can but it seems to be troublesome) create a new class inheriting QtextBrowser to add a new func and instantiate a textBrowser from the new class either.
so is there a general way to add a function to an existing class?
OR
is there a way to make textBrowser automatically scroll down?
Many thanks,
Christopher
I want the textBrowser to scroll down to the bottom every time I append sth. ofc I cannot change QtextBrowser; Since the element textBrowser is created by the .ui file, which is automatically instantiated from the QtextBrowser, I cannot (I can but it seems to be troublesome) create a new class inheriting QtextBrowser to add a new func and instantiate a textBrowser from the new class either.
so is there a general way to add a function to an existing class?
OR
is there a way to make textBrowser automatically scroll down?
Many thanks,
Christopher