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. [SOLVED] Finding the centre of a QPainterPath and its vector of direction ?

[SOLVED] Finding the centre of a QPainterPath and its vector of direction ?

Scheduled Pinned Locked Moved General and Desktop
2 Posts 0 Posters 1.8k Views
  • 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.
  • ? This user is from outside of this forum
    ? This user is from outside of this forum
    Guest
    wrote on last edited by
    #1

    I need to add text to a curve, right in the centre of the curve, rotated to be aligned with the direction of the curve. I could find the vector by finding two points close to the middle of the curve and get their relative angle, but in the API I don't seem to find any methods to get points from the curve that are not points the curve is based on.

    Any ideas? 10x in advance!

    1 Reply Last reply
    0
    • ? This user is from outside of this forum
      ? This user is from outside of this forum
      Guest
      wrote on last edited by
      #2

      Ops, I obviously need to work on my focus skills, totally missed the pointAtPercent method for QPainterPath.

      Problem solved!

      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