KickJava   Java API By Example, From Geeks To Geeks.

Java > Open Source Codes > org > apache > batik > apps > svgbrowser > Application


1 /*
2
3    Copyright 2001-2003 The Apache Software Foundation
4
5    Licensed under the Apache License, Version 2.0 (the "License");
6    you may not use this file except in compliance with the License.
7    You may obtain a copy of the License at
8
9        http://www.apache.org/licenses/LICENSE-2.0
10
11    Unless required by applicable law or agreed to in writing, software
12    distributed under the License is distributed on an "AS IS" BASIS,
13    WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
14    See the License for the specific language governing permissions and
15    limitations under the License.
16
17  */

18 package org.apache.batik.apps.svgbrowser;
19
20 import javax.swing.Action JavaDoc;
21
22 /**
23  * This interface represents a SVG viewer application.
24  *
25  * @author <a HREF="mailto:stephane@hillion.org">Stephane Hillion</a>
26  * @version $Id: Application.java,v 1.13 2004/08/18 07:12:27 vhardy Exp $
27  */

28 public interface Application {
29
30     /**
31      * Creates and shows a new viewer frame.
32      */

33     JSVGViewerFrame createAndShowJSVGViewerFrame();
34
35     /**
36      * Closes the given viewer frame.
37      */

38     void closeJSVGViewerFrame(JSVGViewerFrame f);
39
40     /**
41      * Creates an action to exit the application.
42      */

43     Action JavaDoc createExitAction(JSVGViewerFrame vf);
44
45     /**
46      * Opens the given link in a new window.
47      */

48     void openLink(String JavaDoc url);
49
50     /**
51      * Returns the XML parser class name.
52      */

53     String JavaDoc getXMLParserClassName();
54
55     /**
56      * Returns true if the XML parser must be in validation mode, false
57      * otherwise.
58      */

59     boolean isXMLParserValidating();
60
61     /**
62      * Shows the preference dialog.
63      */

64     void showPreferenceDialog(JSVGViewerFrame f);
65
66     /**
67      * Returns the user languages.
68      */

69     String JavaDoc getLanguages();
70
71     /**
72      * Returns the user stylesheet uri.
73      * @return null if no user style sheet was specified.
74      */

75     String JavaDoc getUserStyleSheetURI();
76
77     /**
78      * Returns the default value for the CSS
79      * "font-family" property
80      */

81     String JavaDoc getDefaultFontFamily();
82
83     /**
84      * Returns the CSS media to use.
85      * @return empty string if no CSS media was specified.
86      */

87     String JavaDoc getMedia();
88
89     /**
90      * Returns true if the selection overlay is painted in XOR mode, false
91      * otherwise.
92      */

93     boolean isSelectionOverlayXORMode();
94
95     /**
96      * Returns true if the input scriptType can be loaded in
97      * this application.
98      */

99     boolean canLoadScriptType(String JavaDoc scriptType);
100
101     /**
102      * Returns the allowed origins for scripts.
103      * @see ResourceOrigin
104      */

105     int getAllowedScriptOrigin();
106
107     /**
108      * Returns the allowed origins for external
109      * resources.
110      *
111      * @see ResourceOrigin
112      */

113     int getAllowedExternalResourceOrigin();
114
115     /**
116      * Notifies Application of recently visited URI
117      */

118     void addVisitedURI(String JavaDoc uri);
119
120     /**
121      * Asks Application for a list of recently visited URI
122      */

123     String JavaDoc[] getVisitedURIs();
124
125 }
126
Popular Tags