]> git.saurik.com Git - wxWidgets.git/blobdiff - interface/wx/stdpaths.h
simplify code so it always returns the same object
[wxWidgets.git] / interface / wx / stdpaths.h
index 4d251364135683aa9b886c183729f567ce4d8bd5..29d9c849e3928d50c5f02573c141d44e42838a93 100644 (file)
     wxStandardPaths returns the standard locations in the file system and should be
     used by applications to find their data files in a portable way.
 
     wxStandardPaths returns the standard locations in the file system and should be
     used by applications to find their data files in a portable way.
 
+    Note that you must not create objects of class wxStandardPaths directly,
+    but use the global standard paths object returned by wxStandardPaths::Get()
+    (which can be of a type derived from wxStandardPaths and not of exactly
+    this type) and call the methods you need on it. The object returned by
+    Get() may be customized by overriding wxAppTraits::GetStandardPaths()
+    methods.
+
     In the description of the methods below, the example return values are given
     for the Unix, Windows and Mac OS X systems, however please note that these are
     just the examples and the actual values may differ. For example, under Windows:
     In the description of the methods below, the example return values are given
     for the Unix, Windows and Mac OS X systems, however please note that these are
     just the examples and the actual values may differ. For example, under Windows:
     This class is MT-safe: its methods may be called concurrently from different
     threads without additional locking.
 
     This class is MT-safe: its methods may be called concurrently from different
     threads without additional locking.
 
-    Note that you don't allocate an instance of class wxStandardPaths, but retrieve the
-    global standard paths object using @c wxStandardPaths::Get on which you call the
-    desired methods.
-
     @library{wxbase}
     @category{file}
 
     @library{wxbase}
     @category{file}
 
@@ -112,7 +115,7 @@ public:
     virtual wxString GetConfigDir() const;
 
     /**
     virtual wxString GetConfigDir() const;
 
     /**
-        Return the location of the applications global, i.e. not user-specific,
+        Return the location of the applications global, i.e.\ not user-specific,
         data files.
 
         Example return values:
         data files.
 
         Example return values:
@@ -156,13 +159,16 @@ public:
     virtual wxString GetExecutablePath() const;
 
     /**
     virtual wxString GetExecutablePath() const;
 
     /**
-        Return the program installation prefix, e.g. @c /usr, @c /opt or @c /home/zeitlin.
+        Return the program installation prefix, e.g.\ @c /usr, @c /opt or @c /home/zeitlin.
 
         If the prefix had been previously by SetInstallPrefix(), returns that
         value, otherwise tries to determine it automatically (Linux only right now)
         and finally returns the default @c /usr/local value if it failed.
 
 
         If the prefix had been previously by SetInstallPrefix(), returns that
         value, otherwise tries to determine it automatically (Linux only right now)
         and finally returns the default @c /usr/local value if it failed.
 
-        @note This function is only available under Unix.
+        @note This function is only available under Unix platforms (but not limited
+        to wxGTK mentioned below).
+
+        @onlyfor{wxos2,wxgtk}
     */
     wxString GetInstallPrefix() const;
 
     */
     wxString GetInstallPrefix() const;
 
@@ -234,7 +240,8 @@ public:
         - Mac: @c ~/Library/Preferences
 
         Only use this method if you have a single configuration file to put in this
         - Mac: @c ~/Library/Preferences
 
         Only use this method if you have a single configuration file to put in this
-        directory, otherwise GetUserDataDir() is more appropriate.
+        directory, otherwise GetUserDataDir() is more appropriate as the latter
+        adds @c appinfo to the path, unlike this function.
     */
     virtual wxString GetUserConfigDir() const;
 
     */
     virtual wxString GetUserConfigDir() const;
 
@@ -331,7 +338,10 @@ public:
         is set during program configuration if using GNU autotools and so it is enough
         to pass its value defined in @c config.h to this function.
 
         is set during program configuration if using GNU autotools and so it is enough
         to pass its value defined in @c config.h to this function.
 
-        @note This function is only available under Unix.
+        @note This function is only available under Unix platforms (but not limited
+        to wxGTK mentioned below).
+
+        @onlyfor{wxos2,wxgtk}
     */
     void SetInstallPrefix(const wxString& prefix);
 
     */
     void SetInstallPrefix(const wxString& prefix);