How do I create a custom widget with two standard widgets?
Hello, I would like to implement a custom widget that would contain a QTextEdit widget and another control. I would like the custon widget to look to the outside like a QTextEdit so that QTextEdit member methods should be exposed. This would allow the user to call QTextEdit member functions like this: customWidget->insert(), etc. The second control would be displayed to left of the QTextEdit control and would be used, for example, to display an arrow indicating which line in the QTextEdit has the cursor, etc. It could be implemented as perhaps a ListBox. The arrow would be repainted when the cursor moves. This is a simplification of the full requirements but should be sufficient to explain the problem. Ideally the custom widget would subclass QTextEdit so that all QTextEdit member methods like would be automatically available to the user of the custom widget. The problem with subclassing QTextEdit is that the custom widget has no way to create the ListBox control because the entire cus