Results 1 to 2 of 2

Thread: PyQT QwtScaleDiv constructor does not accept float min and max

  1. #1
    Join Date
    Mar 2011
    Posts
    11
    Thanks
    1
    Qt products
    Qt4
    Platforms
    Unix/X11

    Default PyQT QwtScaleDiv constructor does not accept float min and max

    Hi, if i do
    Qt Code:
    1. ticks = [0,5,10]
    2. div = QwtScaleDiv(float(ticks[0]), float(ticks[len(ticks)-1]), ticks)
    To copy to clipboard, switch view to plain text mode 
    i get the following error:
    Qt Code:
    1. div = QwtScaleDiv(x,y, ticks)
    2. TypeError: QwtScaleDiv(): arguments did not match any overloaded call:
    3. overload 1: too many arguments
    4. overload 2: argument 1 has unexpected type 'float'
    5. overload 3: not enough arguments
    6. overload 4: argument 1 has unexpected type 'float'
    To copy to clipboard, switch view to plain text mode 

    same happens if I pass int values for min, max. but if i do:
    Qt Code:
    1. div = QwtScaleDiv()
    2. div.setInterval(ticks[0], ticks[len(ticks)-1])
    To copy to clipboard, switch view to plain text mode 
    there is no problem. is this a bug (maybe in SIP?)?
    I'm on ubuntu 10.10 (amd 64) using the repo src

  2. #2
    Join Date
    Mar 2011
    Posts
    11
    Thanks
    1
    Qt products
    Qt4
    Platforms
    Unix/X11

    Default Re: PyQT QwtScaleDiv constructor does not accept float min and max

    my mistake, I missed:using python one has to know this: http://pyqwt.sourceforge.net/doc5/re...t5.QwtScaleDiv

Similar Threads

  1. Replies: 3
    Last Post: 21st December 2010, 14:51
  2. accept() and reject() slots
    By poporacer in forum Newbie
    Replies: 3
    Last Post: 19th August 2010, 01:07
  3. Upgrading from PyQt 4.5 to PyQt 4.7
    By RogerCon in forum Installation and Deployment
    Replies: 0
    Last Post: 14th July 2010, 18:52
  4. Replies: 1
    Last Post: 10th February 2009, 09:42
  5. QFileDialog accept() slot is not accessable
    By bigg in forum Qt Programming
    Replies: 4
    Last Post: 29th April 2008, 10:35

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.