The " based on" concept is of utmost importance: the HTML content is parsed and translated to a QTextDocument structure, which doesn't provide the full support of the above official specifications: for instance, you cannot use frames (so, not quite "year 2000".) or iframes. If you're old enough, you can imagine its support similar to a standard webpage while browsing in year 2000. Here is a MWE: from PyQt5.QtWidgets import QTextBrowser, QApplicationĪn important thing to remember is that the "HTML" used in Qt standard widgets is not intended in the common (and modern) sense: the only way to get a reliable HTML representation in Qt as it would be in a standard web browser is through the QtWebEngine module (usually with QWebEngineView).Īpart from that, all Qt widgets that can display formatted text use the QTextDocument API, which supports only a limited subset of HTML (based on the HTML 4.01 specification) and CSS (based on the CSS 2.1 specification). I don't know much about html (you probably noticed already) I have tried putting the width inside various parts with no luck I want that the columns labeled 29 and 30 are the same size regardless of the text inside. This is how it looks on my browser (this is what I want): ![]() When I open the html file in my browser the width is correct, however, on the qt app, the width always adjusts to the text. I am having trouble modifying the column width. ![]() So I have this html file generated with _html() and want to display inside a Qt application.
0 Comments
Leave a Reply. |
AuthorWrite something about yourself. No need to be fancy, just an overview. ArchivesCategories |