Results 1 to 8 of 8

Thread: Qt Creator problem

  1. #1
    Join Date
    Jun 2012
    Posts
    10
    Thanks
    1
    Qt products
    Qt4
    Platforms
    Windows

    Default Qt Creator problem

    At the past, when i type "ui.", the creator will automatically change it to "ui->". But it is not working now, it will remain as "ui.".

    Am I changed some setting make that this function is disabled?

    P.S: I've tried close the Qt Creator and open it again but it still remains.

  2. #2
    Join Date
    Mar 2009
    Location
    Brisbane, Australia
    Posts
    7,729
    Thanks
    13
    Thanked 1,610 Times in 1,537 Posts
    Qt products
    Qt4 Qt5
    Platforms
    Unix/X11 Windows
    Wiki edits
    17

    Default Re: Qt Creator problem

    Then ui is an instance of an object and not a pointer to one.

  3. #3
    Join Date
    Jun 2012
    Posts
    10
    Thanks
    1
    Qt products
    Qt4
    Platforms
    Windows

    Default Re: Qt Creator problem

    Quote Originally Posted by ChrisW67 View Post
    Then ui is an instance of an object and not a pointer to one.
    The ui is a pointer (confirmed).

  4. #4
    Join Date
    Mar 2009
    Location
    Brisbane, Australia
    Posts
    7,729
    Thanks
    13
    Thanked 1,610 Times in 1,537 Posts
    Qt products
    Qt4 Qt5
    Platforms
    Unix/X11 Windows
    Wiki edits
    17

    Default Re: Qt Creator problem

    Clearly the IDE disagrees with you or you have completion turned off completely. Look under Tools, Options..., Text Editor, Completion

  5. #5
    Join Date
    Jun 2012
    Posts
    10
    Thanks
    1
    Qt products
    Qt4
    Platforms
    Windows

    Default Re: Qt Creator problem

    Quote Originally Posted by ChrisW67 View Post
    Clearly the IDE disagrees with you or you have completion turned off completely. Look under Tools, Options..., Text Editor, Completion
    The completion is on and it is functioning.

    It just the "." not changing to "->" automatically if the prefix is a pointer and the symbol "{" will not adjusted to the position as before.
    For example:

    if(x)
    {


    In the past, it will auto adjusted to:

    if(x)
    {


    Added after 30 minutes:


    I had also found that after i type 3 character after it, it will change to “->”.
    For example:

    ui.xxx will become ui->xxx

    Why the auto completion not running immediately? Any setting on it?
    Last edited by jack249; 18th June 2012 at 07:54.

  6. #6
    Join Date
    Mar 2009
    Location
    Brisbane, Australia
    Posts
    7,729
    Thanks
    13
    Thanked 1,610 Times in 1,537 Posts
    Qt products
    Qt4 Qt5
    Platforms
    Unix/X11 Windows
    Wiki edits
    17

    Default Re: Qt Creator problem

    Completion and code indentation are two unrelated things.
    I have found that completion does not handle smart pointers very well and "breaks" if a full declaration of the object is not available and if certain earlier syntax problems are present.
    I have found that indentation "breaks" if syntax is broken earlier in the file.
    Does your code build?

    • Exit Qt Creator
    • Rename or move:
      • Linux: ~/.config/Nokia
      • Windows: "C:\Documents and Settings\User\Application Data\Nokia" or appropriate variation for your version of Windows
    • Try again with default settings

  7. #7
    Join Date
    Jun 2012
    Posts
    10
    Thanks
    1
    Qt products
    Qt4
    Platforms
    Windows

    Default Re: Qt Creator problem

    Quote Originally Posted by ChrisW67 View Post
    Completion and code indentation are two unrelated things.
    I have found that completion does not handle smart pointers very well and "breaks" if a full declaration of the object is not available and if certain earlier syntax problems are present.
    I have found that indentation "breaks" if syntax is broken earlier in the file.
    Does your code build?

    • Exit Qt Creator
    • Rename or move:
      • Linux: ~/.config/Nokia
      • Windows: "C:\Documents and Settings\User\Application Data\Nokia" or appropriate variation for your version of Windows
    • Try again with default settings
    Tried remove all files and folder in the path "C:\Users\JACK\AppData\Roaming\Nokia"
    After that I open the project file but it still not change the "." to "->" immediately.
    It will only change after i key in 3 characters...

  8. #8
    Join Date
    Jan 2006
    Location
    Warsaw, Poland
    Posts
    33,359
    Thanks
    3
    Thanked 5,015 Times in 4,792 Posts
    Qt products
    Qt3 Qt4 Qt5 Qt/Embedded
    Platforms
    Unix/X11 Windows Android Maemo/MeeGo
    Wiki edits
    10

    Default Re: Qt Creator problem

    Do you have an appropriate #include in your file?
    Your biological and technological distinctiveness will be added to our own. Resistance is futile.

    Please ask Qt related questions on the forum and not using private messages or visitor messages.


Similar Threads

  1. Problem With Qt Creator
    By justin123 in forum Qt Tools
    Replies: 1
    Last Post: 12th December 2010, 08:10
  2. Creator 2.0 problem
    By waynew in forum Installation and Deployment
    Replies: 2
    Last Post: 27th June 2010, 02:38
  3. Problem with Qt Creator
    By Qt Coder in forum Qt Programming
    Replies: 1
    Last Post: 8th June 2010, 13:48
  4. problem with qt creator
    By mmm286 in forum Newbie
    Replies: 1
    Last Post: 24th May 2010, 16:12
  5. A build problem in Qt creator 1
    By Dante in forum Qt Programming
    Replies: 6
    Last Post: 13th March 2009, 18:37

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.