Results 1 to 4 of 4

Thread: how to dynamically add a textedit on clicking a button

  1. #1
    Join Date
    Feb 2017
    Posts
    2
    Qt products
    Qt3 Qt4 Qt5
    Platforms
    Windows

    Default how to dynamically add a textedit on clicking a button

    can anyone tell me how to add a textedit to my workspace at a specified position when i click on the button given in the workspace.

  2. #2
    Join Date
    Jan 2017
    Posts
    58
    Thanks
    2
    Thanked 2 Times in 2 Posts
    Qt products
    Qt5
    Platforms
    Windows

    Default Re: how to dynamically add a textedit on clicking a button

    Maybe visible property true/false?

  3. #3
    Join Date
    Feb 2017
    Posts
    2
    Qt products
    Qt3 Qt4 Qt5
    Platforms
    Windows

    Default Re: how to dynamically add a textedit on clicking a button

    No no not by that because i dont know anything about the layout or where user want to place it after clicking i want to add a new textedit dynamically when i click on a push button

  4. #4
    Join Date
    Jan 2006
    Location
    Graz, Austria
    Posts
    8,416
    Thanks
    37
    Thanked 1,544 Times in 1,494 Posts
    Qt products
    Qt3 Qt4 Qt5
    Platforms
    Unix/X11 Windows

    Default Re: how to dynamically add a textedit on clicking a button

    In the slot connected to the button's signal, you just create the instance and add it to the layout you want it to be in.

    Cheers,
    _

Similar Threads

  1. Replies: 5
    Last Post: 26th February 2016, 09:44
  2. Replies: 0
    Last Post: 20th May 2015, 06:13
  3. Draw a shape upon clicking a button
    By ZsCosa in forum Newbie
    Replies: 2
    Last Post: 22nd July 2013, 18:30
  4. Flick charm not working when clicking over a button.
    By alitoh in forum Qt Programming
    Replies: 0
    Last Post: 9th January 2012, 14:52
  5. how to get the accept signal by clicking Apply button
    By weixj2003ld in forum Qt Programming
    Replies: 3
    Last Post: 6th January 2012, 02:44

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.