Results 1 to 2 of 2

Thread: How can I change the filename of a QGraphicsSvgItem

  1. #1
    Join Date
    Feb 2010
    Location
    Cuba
    Posts
    35
    Thanks
    6
    Qt products
    Qt4 Qt/Embedded
    Platforms
    Unix/X11 Windows

    Default How can I change the filename of a QGraphicsSvgItem

    Hello
    I'm using QGraphicsSvgItem to display the pieces of a chess game. I need to change the SVG file asociated to a QGraphicsSvgItem, but I can't find a way to do this without creating a new QGraphicsSvgItem object. Is there another way?
    Thanks is advanced!!

  2. #2
    Join Date
    Feb 2010
    Location
    Cuba
    Posts
    35
    Thanks
    6
    Qt products
    Qt4 Qt/Embedded
    Platforms
    Unix/X11 Windows

    Default Re: How can I change the filename of a QGraphicsSvgItem

    After reading QtAssistant once again, I found that this can be achieve using the function: void QGraphicsSvgItem::setSharedRenderer ( QSvgRenderer * renderer )This way I have not to create a new object of QGraphicsSvgItem
    Thanks for yours replies. LOL

Similar Threads

  1. QGraphicsSvgItem from QDomElement
    By casperbear in forum Newbie
    Replies: 0
    Last Post: 9th September 2010, 04:25
  2. Replies: 2
    Last Post: 29th March 2010, 12:34
  3. Problem when using QGraphicsSvgItem
    By NoRulez in forum Qt Programming
    Replies: 0
    Last Post: 20th February 2010, 17:49
  4. Problem with QGraphicsSvgItem
    By drake1983 in forum Newbie
    Replies: 1
    Last Post: 8th July 2007, 07:05
  5. QGraphicsSvgItem sizing
    By jefferai in forum Qt Programming
    Replies: 1
    Last Post: 27th June 2007, 21:48

Tags for this Thread

Bookmarks

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  
Digia, Qt and their respective logos are trademarks of Digia Plc in Finland and/or other countries worldwide.