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. Get the same result by new API(QGraphicsItem)
Forum Updated to NodeBB v4.3 + New Features

Get the same result by new API(QGraphicsItem)

Scheduled Pinned Locked Moved General and Desktop
1 Posts 1 Posters 595 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.
  • S Offline
    S Offline
    stereomatching
    wrote on last edited by
    #1

    @
    QGraphicsItem *item3 = createItem( 400);
    //these wouldn't do what I want
    //item3->setTransformOriginPoint(item3->boundingRect().center());
    //item3->setTransform(item3->transform().fromScale(0.5, 0.7), true);
    //this will do want I want to do, 500 and 100 is the scaling center I want(same as boundingRect().center())
    item3->translate( 500, 100 );
    item3->scale( 0.5, 0.7 );
    item3->translate( -500, -100 );
    @

    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