Results 1 to 5 of 5

Thread: Hiding code from the user

  1. #1
    Join Date
    Jul 2010
    Posts
    10
    Thanks
    7
    Thanked 1 Time in 1 Post
    Qt products
    Qt4
    Platforms
    Windows

    Question Hiding code from the user

    I've never used Qt. I want to make it so users can edit one particular GUI and its relevant code using Qt Creator without being allowed to see my code for the rest of the program. Is this possible?
    Last edited by Plixil; 19th July 2010 at 04:07. Reason: more information

  2. #2
    Join Date
    Oct 2006
    Location
    New Delhi, India
    Posts
    2,467
    Thanks
    8
    Thanked 334 Times in 317 Posts
    Qt products
    Qt4
    Platforms
    Unix/X11 Windows

    Default Re: Hiding code from the user

    Why dont you ship the editable gui as a library / dll. You can give the user code only for that gui and he can edit and build it again.
    You will need to provide some architecture in your design where you load the dll for the gui.

  3. #3
    Join Date
    Apr 2010
    Posts
    769
    Thanks
    1
    Thanked 94 Times in 86 Posts
    Qt products
    Qt3 Qt4
    Platforms
    Unix/X11

    Default Re: Hiding code from the user

    Correct; either build everything using dynamic libraries, and ship only the libraries you don't want the user to have access to, or use Qt's plugin framework to load bits and pieces at runtime. Both approaches are essentially identical, but the plugin framework shields you from the details of dynamic linking somewhat.

  4. #4
    Join Date
    Jul 2010
    Posts
    10
    Thanks
    7
    Thanked 1 Time in 1 Post
    Qt products
    Qt4
    Platforms
    Windows

    Default Re: Hiding code from the user

    Both of those ideas sound great . DLLs scare the hell out of me and the plugin option sounds easier so I'll look into that. Thank you both very much

    Edit: Which base class would you recommend I extend for their GUI?

  5. #5
    Join Date
    Oct 2006
    Location
    New Delhi, India
    Posts
    2,467
    Thanks
    8
    Thanked 334 Times in 317 Posts
    Qt products
    Qt4
    Platforms
    Unix/X11 Windows

    Default Re: Hiding code from the user

    For GUI, QWidget is the base class...

Similar Threads

  1. Difficult Cast I cannot figure out!
    By jgrauman in forum Qt Programming
    Replies: 4
    Last Post: 26th June 2010, 08:56
  2. A relative newbie, wondering whether Qt will support MPX
    By Solar Granulation in forum Newbie
    Replies: 0
    Last Post: 26th February 2010, 21:29
  3. Replies: 3
    Last Post: 24th April 2009, 23:41
  4. Replies: 12
    Last Post: 3rd April 2006, 07:11
  5. Replies: 6
    Last Post: 10th January 2006, 14:07

Tags for this Thread

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.