diff options
author | Timothy Pearson <kb9vqf@pearsoncomputing.net> | 2013-02-04 14:26:06 -0600 |
---|---|---|
committer | Timothy Pearson <kb9vqf@pearsoncomputing.net> | 2013-02-04 14:26:06 -0600 |
commit | 566093084927a5b4124a18b767e5632d4b5e4deb (patch) | |
tree | 487e6488897185c50f1300c5c82d0ec5ea3c67a3 /kdejava/koala/org/kde/koala/TDEIconLoader.java | |
parent | 4769a4b79bc1358eee8198b4cd87b235d75d86fb (diff) | |
download | tdebindings-566093084927a5b4124a18b767e5632d4b5e4deb.tar.gz tdebindings-566093084927a5b4124a18b767e5632d4b5e4deb.zip |
Fix prior commit
Diffstat (limited to 'kdejava/koala/org/kde/koala/TDEIconLoader.java')
-rw-r--r-- | kdejava/koala/org/kde/koala/TDEIconLoader.java | 348 |
1 files changed, 348 insertions, 0 deletions
diff --git a/kdejava/koala/org/kde/koala/TDEIconLoader.java b/kdejava/koala/org/kde/koala/TDEIconLoader.java new file mode 100644 index 00000000..5ace9688 --- /dev/null +++ b/kdejava/koala/org/kde/koala/TDEIconLoader.java @@ -0,0 +1,348 @@ +//Auto-generated by kalyptus. DO NOT EDIT. +package org.kde.koala; + +import org.kde.qt.Qt; +import org.kde.qt.TQMovie; +import org.kde.qt.QtSupport; +import org.kde.qt.TQPixmap; +import java.util.ArrayList; +import org.kde.qt.TQIconSet; + +/** + + Iconloader for KDE. + TDEIconLoader will load the current icon theme and all its base themes. + Icons will be searched in any of these themes. Additionally, it caches + icons and applies effects according the the user's preferences. + In KDE, it is encouraged to load icons by "Group". An icon group is a + location on the screen where icons are being used. Standard groups are: + Desktop, Toolbar, MainToolbar, Small and Panel. Each group has some + centrally configured properties bound to it, including the icon size + and effects. This makes it possible to offer a consistent icon look in + all KDE applications. + The standard groups are defined below. + + <li> + TDEIcon.Desktop: Icons in the iconview of konqueror, kdesktop and similar apps. + </li> + + <li> + TDEIcon.Toolbar: Icons in toolbars. + </li> + + <li> + TDEIcon.MainToolbar: Icons in the main toolbars. + </li> + + <li> + TDEIcon.Small: Various small (typical 16x16) places: titlebars, listviews + and menu entries. + </li> + + <li> + TDEIcon.Panel: Icons in kicker's panel + </li> + The icons are stored on disk in an icon theme or in a standalone + directory. The icon theme directories contain multiple sizes and/or + depths for the same icon. The iconloader will load the correct one based + on the icon group and the current theme. Icon themes are stored globally + in share/icons, or, application specific in share/apps/$appdir/icons. + The standalone directories contain just one version of an icon. The + directories that are searched are: $appdir/pics and $appdir/toolbar. + Icons in these directories can be loaded by using the special group + "User". + @short Iconloader for KDE. + +*/ +public class TDEIconLoader implements QtSupport { + private long _qt; + private boolean _allocatedInJavaWorld = true; + protected TDEIconLoader(Class dummy){} + + /** + Constructs an iconloader. + @param appname Add the data directories of this application to the + icon search path for the "User" group. The default argument adds the + directories of the current application. + @param dirs the TDEStandardDirs object to use. If null the global one is used + Usually, you use the default iconloader, which can be accessed via + TDEGlobal.iconLoader(), so you hardly ever have to create an + iconloader object yourself. That one is the current TDEInstance's + (typically TDEApplication's) iconloader. + @short Constructs an iconloader. + @see TDEGlobal#iconLoader + @see TDEInstance#iconLoader + */ + public TDEIconLoader(String appname, TDEStandardDirs dirs) { + newTDEIconLoader(appname,dirs); + } + private native void newTDEIconLoader(String appname, TDEStandardDirs dirs); + public TDEIconLoader(String appname) { + newTDEIconLoader(appname); + } + private native void newTDEIconLoader(String appname); + public TDEIconLoader() { + newTDEIconLoader(); + } + private native void newTDEIconLoader(); + /** + Adds <code>appname</code> to the list of application specific directories. + @param appname The application name. + @short Adds <code>appname</code> to the list of application specific directories. + */ + public native void addAppDir(String appname); + /** + Loads an icon. It will try very hard to find an icon which is + suitable. If no exact match is found, a close match is searched. + If neither an exact nor a close match is found, a null pixmap or + the "unknown" pixmap is returned, depending on the value of the + <code>canReturnNull</code> parameter. + @param name The name of the icon, without extension. + @param group The icon group. This will specify the size of and effects to + be applied to the icon. + @param size If nonzero, this overrides the size specified by <code>group.</code> + See TDEIcon.StdSizes. + @param state The icon state: <code>DefaultState</code>, <code>ActiveState</code> or + <code>DisabledState.</code> Depending on the user's preferences, the iconloader + may apply a visual effect to hint about its state. + @param path_store If not null, the path of the icon is stored here. + @param canReturnNull Can return a null pixmap? If false, the + "unknown" pixmap is returned when no appropriate icon has been found. + @return the TQPixmap. Can be null when not found, depending on + <code>canReturnNull.</code> + + @short Loads an icon. + */ + public native TQPixmap loadIcon(String name, int group, int size, int state, StringBuffer path_store, boolean canReturnNull); + public native TQPixmap loadIcon(String name, int group, int size, int state, StringBuffer path_store); + public native TQPixmap loadIcon(String name, int group, int size, int state); + public native TQPixmap loadIcon(String name, int group, int size); + public native TQPixmap loadIcon(String name, int group); + /** + Creates an icon set, that will do on-demand loading of the icon. + Loading itself is done by calling loadIcon . + @param name The name of the icon, without extension. + @param group The icon group. This will specify the size of and effects to + be applied to the icon. + @param size If nonzero, this overrides the size specified by <code>group.</code> + See TDEIcon.StdSizes. + @param canReturnNull Can return a null iconset? If false, iconset + containing the "unknown" pixmap is returned when no appropriate icon has + been found. + @param immediateExistenceCheck If true on-demand icon loading will be + disabled for canReturnNull and a null iconset may be returned immediately + @return the icon set. Can be null when not found, depending on + <code>canReturnNull.</code> + + @short Creates an icon set, that will do on-demand loading of the icon. + */ + public native TQIconSet loadIconSet(String name, int group, int size, boolean canReturnNull, boolean immediateExistenceCheck); + /** + Creates an icon set, that will do on-demand loading of the icon. + Loading itself is done by calling loadIcon . + @param name The name of the icon, without extension. + @param group The icon group. This will specify the size of and effects to + be applied to the icon. + @param size If nonzero, this overrides the size specified by <code>group.</code> + See TDEIcon.StdSizes. + @param canReturnNull Can return a null iconset? If false, iconset + containing the "unknown" pixmap is returned when no appropriate icon has + been found. + @return the icon set. Can be null when not found, depending on + <code>canReturnNull.</code> + + @short Creates an icon set, that will do on-demand loading of the icon. + */ + public native TQIconSet loadIconSet(String name, int group, int size, boolean canReturnNull); + /** + Creates an icon set, that will do on-demand loading of the icon. + Loading itself is done by calling loadIcon . + @param name The name of the icon, without extension. + @param group The icon group. This will specify the size of and effects to + be applied to the icon. + @param size If nonzero, this overrides the size specified by <code>group.</code> + See TDEIcon.StdSizes. + @return the icon set. Can be null when not found + + @short Creates an icon set, that will do on-demand loading of the icon. + */ + public native TQIconSet loadIconSet(String name, int group, int size); + public native TQIconSet loadIconSet(String name, int group); + /** + Returns the path of an icon. + @param name The name of the icon, without extension. If an absolute + path is supplied for this parameter, iconPath will return it + directly. + @param group_or_size If positive, search icons whose size is + specified by the icon group <code>group_or_size.</code> If negative, search + icons whose size is - <code>group_or_size.</code> + See TDEIcon.Group and TDEIcon.StdSizes + @param canReturnNull Can return a null string? If not, a path to the + "unknown" icon will be returned. + @return the path of an icon, can be null or the "unknown" icon when + not found, depending on <code>canReturnNull.</code> + + @short Returns the path of an icon. + */ + public native String iconPath(String name, int group_or_size, boolean canReturnNull); + public native String iconPath(String name, int group_or_size); + /** + Loads an animated icon. + @param name The name of the icon. + @param group The icon group. See loadIcon(). + @param size Override the default size for <code>group.</code> + See TDEIcon.StdSizes. + @return A TQMovie object. Can be null if not found. + + @short Loads an animated icon. + */ + public native TQMovie loadMovie(String name, int group, int size); + public native TQMovie loadMovie(String name, int group); + /** + Returns the path to an animated icon. + @param name The name of the icon. + @param group The icon group. See loadIcon(). + @param size Override the default size for <code>group.</code> + See TDEIcon.StdSizes. + @return the full path to the movie, ready to be passed to TQMovie's constructor. + Empty string if not found. + + @short Returns the path to an animated icon. + */ + public native String moviePath(String name, int group, int size); + public native String moviePath(String name, int group); + /** + Loads an animated icon as a series of still frames. If you want to load + a .mng animation as TQMovie instead, please use loadMovie() instead. + @param name The name of the icon. + @param group The icon group. See loadIcon(). + @param size Override the default size for <code>group.</code> + See TDEIcon.StdSizes. + @return An ArrayList containing the absolute path of all the frames + making up the animation. + + @short Loads an animated icon as a series of still frames. + */ + public native ArrayList loadAnimated(String name, int group, int size); + public native ArrayList loadAnimated(String name, int group); + /** + Queries all available icons for a specific group, having a specific + context. + @param group_or_size If positive, search icons whose size is + specified by the icon group <code>group_or_size.</code> If negative, search + icons whose size is - <code>group_or_size.</code> + See TDEIcon.Group and TDEIcon.StdSizes + @param context The icon context. + @return a list of all icons + + @short Queries all available icons for a specific group, having a specific context. + */ + public native ArrayList queryIcons(int group_or_size, int context); + public native ArrayList queryIcons(int group_or_size); + /** + Queries all available icons for a specific context. + @param group_or_size The icon preferred group or size. If available + at this group or size, those icons will be returned, in other case, + icons of undefined size will be returned. Positive numbers are groups, + negative numbers are negated sizes. See TDEIcon.Group and + TDEIcon.StdSizes + @param context The icon context. + @return An ArrayList containing the icon names + available for that context + + @short Queries all available icons for a specific context. + */ + public native ArrayList queryIconsByContext(int group_or_size, int context); + public native ArrayList queryIconsByContext(int group_or_size); + /** + Returns a list of all icons (.png or .xpm extension) in the + given directory. + @param iconsDir the directory to search in + @return An ArrayList containing the icon paths + + @short Returns a list of all icons ( . + */ + public native ArrayList queryIconsByDir(String iconsDir); + /** + Returns the current size of the group. + @param group the group to check. + @return the current size for an icon group. + + @short Returns the current size of the group. + */ + public native int currentSize(int group); + /** + Returns a pointer to the current theme. Can be used to query + available and default sizes for groups. + @return a pointer to the current theme. 0 if no theme set. + + @short Returns a pointer to the current theme. + */ + // TDEIconTheme* theme(); >>>> NOT CONVERTED + /** + Returns a pointer to the TDEIconEffect object used by the icon loader. + @return the TDEIconEffect. + + @short Returns a pointer to the TDEIconEffect object used by the icon loader. + */ + public native TDEIconEffect iconEffect(); + /** + Called by TDEInstance.newIconLoader to reconfigure the icon loader. + @param _appname the new application name + @param _dirs the new standard directories. If 0, the directories + from TDEGlobal will be taken. + @short Called by TDEInstance.newIconLoader to reconfigure the icon loader. + */ + public native void reconfigure(String _appname, TDEStandardDirs _dirs); + /** + Adds all the default themes from other desktops at the end of + the list of icon themes. + @short Adds all the default themes from other desktops at the end of the list of icon themes. + */ + public native void addExtraDesktopThemes(); + /** + Returns if the default icon themes of other desktops have been added + to the list of icon themes where icons are searched. + @short Returns if the default icon themes of other desktops have been added to the list of icon themes where icons are searched. + */ + public native boolean extraDesktopThemesAdded(); + /** + Enables on-demand icon loading for TQIconSets using TQIconFactory. + Icons loaded via loadIconSet() will be loaded as soon as they + need to be displayed, not earlier. + Note that enabling or disabling this only affects loadIconSet() + calls after this setting is changed. + The default is disabled, as the iconloader object must not be + destroyed before all those iconsets are destroyed. + (Some broken applications use temporary TDEIconLoader objects). + Every TDEInstance 's iconloader has this feature enabled. + @param enable true to enable delayed icon loading, false to disable + @short Enables on-demand icon loading for TQIconSets using TQIconFactory. + @see #isDelayedIconSetLoadingEnabled + @see org.kde.qt.TQIconFactory + */ + public native void enableDelayedIconSetLoading(boolean enable); + /** + Checks whether delayed loading for TQIconSet is enabled. + @return whether icons for TQIconSets will be loaded on demand. + + @short Checks whether delayed loading for TQIconSet is enabled. + @see #enableDelayedIconSetLoading + @see org.kde.qt.TQIconFactory + */ + public native boolean isDelayedIconSetLoadingEnabled(); + /** + Returns the unknown icon. An icon that is used when no other icon + can be found. + @return the unknown pixmap + + @short Returns the unknown icon. + */ + public static native TQPixmap unknown(); + /** Deletes the wrapped C++ instance */ + protected native void finalize() throws InternalError; + /** Delete the wrapped C++ instance ahead of finalize() */ + public native void dispose(); + /** Has the wrapped C++ instance been deleted? */ + public native boolean isDisposed(); +} |