Results 1 to 2 of 2

Thread: Q_PROPERTY space issue

  1. #1
    Join Date
    Jan 2008
    Location
    Bengaluru
    Posts
    144
    Thanks
    8
    Thanked 7 Times in 7 Posts
    Qt products
    Qt3 Qt4
    Platforms
    Windows

    Default Q_PROPERTY space issue

    Hi,

    I have a query regarding having space for 'name' parameter for Q_PROPERTY.

    Qt Code:
    1. Q_PROPERTY(QString MyName READ getName WRITE setName)
    To copy to clipboard, switch view to plain text mode 

    For an example, If we want to have a space for 'name' param i.e.,
    Qt Code:
    1. Q_PROPERTY(QString My Name READ getName WRITE setName)
    To copy to clipboard, switch view to plain text mode 

    How to achieve the same ? Could you please help me out?

    Thanks,
    Nikhil

  2. #2
    Join Date
    Jan 2006
    Location
    Munich, Germany
    Posts
    4,714
    Thanks
    21
    Thanked 418 Times in 411 Posts
    Qt products
    Qt3 Qt4 Qt5 Qt/Embedded
    Platforms
    Unix/X11 Windows

    Default Re: Q_PROPERTY space issue

    C/C++ does not allow variable names with spaces.
    ==========================signature=============== ==================
    S.O.L.I.D principles (use them!):
    https://en.wikipedia.org/wiki/SOLID_...iented_design)

    Do you write clean code? - if you are TDD'ing then maybe, if not, your not writing clean code.

  3. The following user says thank you to high_flyer for this useful post:

    nikhilqt (24th June 2010)

Similar Threads

  1. QTableView empty space or too little space.
    By davemar in forum Qt Programming
    Replies: 2
    Last Post: 16th October 2009, 16:00
  2. Replies: 1
    Last Post: 26th July 2009, 15:08
  3. Why and when to use Q_PROPERTY
    By Vanir in forum Qt Programming
    Replies: 4
    Last Post: 22nd November 2007, 09:25
  4. How to Use Q_PROPERTY
    By mitesh_modi in forum Qt Programming
    Replies: 7
    Last Post: 20th June 2006, 14:49
  5. linking user space and kernel space programs with qmake
    By zielchri in forum Qt Programming
    Replies: 9
    Last Post: 8th March 2006, 23:11

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.