Skip to content
  • Categories
  • Recent
  • Tags
  • Popular
  • Users
  • Groups
  • Search
  • Get Qt Extensions
  • Unsolved
Collapse
Brand Logo
  1. Home
  2. Qt Development
  3. General and Desktop
  4. [SOLVED]Suggestions on implementing a proper settings dialog.

[SOLVED]Suggestions on implementing a proper settings dialog.

Scheduled Pinned Locked Moved General and Desktop
formsdialogs
4 Posts 2 Posters 1.4k Views
  • Oldest to Newest
  • Newest to Oldest
  • Most Votes
Reply
  • Reply as topic
Log in to reply
This topic has been deleted. Only users with topic management privileges can see it.
  • E Offline
    E Offline
    ealione
    wrote on 4 May 2015, 06:56 last edited by ealione 5 May 2015, 06:37
    #1

    I am at that point in my app development where I want to created a settings/preferences dialog, in order for the user to be able to tweak various parameters.

    What I intend to do is after creating the form, have it initialised every time the user presses the 'Settings' option, and deleted when he presses 'accept' or 'cancel'. Any changes he makes will be passed to my main app using signals and slots.

    Are there any better ways of doing this, do you have any suggestions from your personal experience, or some other open source code that I could study to learn more?

    1 Reply Last reply
    0
    • M Offline
      M Offline
      mcosta
      wrote on 4 May 2015, 07:03 last edited by
      #2

      Hi,

      as general rule your idea is correct.
      If your dialog is very complex and it needs a lot of resources to load or if you want make it non-modal you can think to keep it in memory and using show()when the user click on Settings and hide() when it is accepted or cancelled

      Once your problem is solved don't forget to:

      • Mark the thread as SOLVED using the Topic Tool menu
      • Vote up the answer(s) that helped you to solve the issue

      You can embed images using (http://imgur.com/) or (http://postimage.org/)

      1 Reply Last reply
      0
      • E Offline
        E Offline
        ealione
        wrote on 4 May 2015, 07:09 last edited by
        #3

        Hi mcosta,

        For the moment its quite simple, but it may well get extended in the future so I will keep it in memory. Thanks for the input.

        1 Reply Last reply
        0
        • M Offline
          M Offline
          mcosta
          wrote on 4 May 2015, 07:14 last edited by
          #4

          Hi @ealione,

          you can decide also later how to handle it; I suggest to keep in memory only if you think that the user will use it very often otherwise there's no problem to create/destroy it when is needed

          Once your problem is solved don't forget to:

          • Mark the thread as SOLVED using the Topic Tool menu
          • Vote up the answer(s) that helped you to solve the issue

          You can embed images using (http://imgur.com/) or (http://postimage.org/)

          1 Reply Last reply
          0

          1/4

          4 May 2015, 06:56

          • Login

          • Login or register to search.
          1 out of 4
          • First post
            1/4
            Last post
          0
          • Categories
          • Recent
          • Tags
          • Popular
          • Users
          • Groups
          • Search
          • Get Qt Extensions
          • Unsolved