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. Which arguments are understood by Qt?
Forum Updated to NodeBB v4.3 + New Features

Which arguments are understood by Qt?

Scheduled Pinned Locked Moved General and Desktop
3 Posts 3 Posters 787 Views 1 Watching
  • 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.
  • W Offline
    W Offline
    Wurgl
    wrote on last edited by
    #1

    <This is actually a repost from qtcentre.org where I did not get any answer within 2 weeks>

    When I look at the documentation of the class QCoreApplication/QApplication/QGuiAppication I always see a constructor with the arguments „(int & argc, char ** argv)“.

    In the documentation of class QApplication I read that the following arguments are understood:

    • -style <Style>
    • -stylesheet <Stylesheet>
    • -widgetcount
    • -reverse
    • -qmljsdebugger=<Whatever>

    QGuiApplication lists the following arguments:

    • -platform <PlatformName[ptions]>
    • -platformpluginpath <Path>
    • -platformtheme <PlatformTheme>
    • -plugin <Plugin>
    • -qwindowgeometry <Geometry>
    • -qwindowtitle <Title>
    • -session <Session>
    • -display <X11-Display>
    • -geometry <Geometry>

    In the documentation of class QStyle I see a few style names and one explicit mentioned as an example: „-style windows“

    I am wondering if there is some way in the program to retrieve all those options and present them in whatever form to the user, maybe something similar to the option --help/-h/-? which is used by many other programs. I am also wondering if and how a program can find out which styles are available, which themes and so on.

    Thanks.

    1 Reply Last reply
    0
    • R Offline
      R Offline
      Rondog
      wrote on last edited by
      #2

      I would look in the source code for the Qt Designer. It allows you to generate a preview of your Widget/Dialog using a list of styles (on my machine 'Windows Style","Fusion Style", "Macintosh Style"). If this is something that is not hard coded in the program the answer should be there.

      The help for Qt is clear on which styles are available for the different operating systems. You won't have "Machintosh Style" (aqua) on a Windows system for example.

      1 Reply Last reply
      0
      • A Offline
        A Offline
        andre
        wrote on last edited by
        #3

        For listing the available styles, you can ask QStyleFactory.

        There is no pre-built creation of help output, though there are libraries for Qt to help out with that.

        1 Reply Last reply
        0

        • Login

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