Skip to content
  • Categories
  • Recent
  • Tags
  • Popular
  • Users
  • Groups
  • Search
  • Get Qt Extensions
  • Unsolved
Collapse
Brand Logo
  1. Home
  2. Qt Development
  3. General and Desktop
  4. How to properly use QPainter in custom Widgets (inherits from QWidget).
Qt 6.11 is out! See what's new in the release blog

How to properly use QPainter in custom Widgets (inherits from QWidget).

Scheduled Pinned Locked Moved General and Desktop
1 Posts 1 Posters 1.5k Views 1 Watching
  • Oldest to Newest
  • Newest to Oldest
  • Most Votes
Reply
  • Reply as topic
Log in to reply
This topic has been deleted. Only users with topic management privileges can see it.
  • ? Offline
    ? Offline
    A Former User
    wrote on last edited by
    #1

    I'm on the way to create my interpretation of Nassi-Shneiderman diagram.
    It's like my "exam" what i choose to myself to prove that i learned at least basics of Qt programming.
    Nassi-Shneiderman diagram looks like follows: http://www.thern.org/projects/nassi-schneiderman/ProblemSolvingTechniques_files/ns-example2.gif

    And i've got little problem:
    When i use QPainter to draw lines for multiple choise statement for example, i cannot force drawed lines stick to top corners and middle of bottom of widget, while i resizing the widget.

    Probably the way to solve that problem is use Widget Resize Event, but how to do that properly? Or here is a better way to solve that problem?

    1 Reply Last reply
    0

    • Login

    • Login or register to search.
    • First post
      Last post
    0
    • Categories
    • Recent
    • Tags
    • Popular
    • Users
    • Groups
    • Search
    • Get Qt Extensions
    • Unsolved