[Gvsig_desarrolladores] extensiones gvSig
mj.gomez en telvent.abengoa.com
mj.gomez en telvent.abengoa.com
Mie Oct 4 09:12:28 CEST 2006
Muchas gracias, creo que esa es la información que necesitaba. Saludos.
Francisco José <fpenarru en iver.es>
Francisco José
Enviado por: gvsig_desarrolladores-bounces en runas.cap.gva.es
04/10/2006 08:43
Por favor, responda a Lista de Desarrolladores de gvSIG
Para:
Lista de Desarrolladores de gvSIG <gvsig_desarrolladores en runas.cap.gva.es>
cc:
Asunto:
Re: [Gvsig_desarrolladores] extensiones gvSig
mj.gomez en telvent.abengoa.com escribió:
Hola, me gustaría saber cómo añadir una extensión a la aplicación gvSig de
manera que fwAndami pueda utilizarla.
Saludos y gracias.
_______________________________________________
gvSIG_desarrolladores mailing list
gvSIG_desarrolladores en runas.cap.gva.es
http://runas.cap.gva.es/mailman/listinfo/gvsig_desarrolladores
Hola Mª José.
No entiendo exactamente a qué te refieres. Andami es el esqueleto de la
aplicación. Todo lo que cuelga del directorio gvSIG/extensiones son los
plugins, y cualquier directorio que hay ahí, Andami lo revisa
automáticamente para intentar cargar las clases que haya dentro.
Hay documentación acerca de todo esto en la web, junto con la descarga de
la versión 0.4. También necesitarás el fichero plugin-config.xsd, que
explica cómo hacer un fichero config.xml, que controla los menus, botones,
herramientas, etc y su enlace con las clases que dan soporte a cada
funcionalidad.
Por si no lo encuentras, lo adjunto.
Salu2.
--
Francisco José Peñarrubia
Equipo gvSIG
IVER T.I. S.A.
c/Salamanca 50
46005 Valencia
Spain<?xml version="1.0" encoding="UTF-8" ?>
<xs:schema xmlns:xs="http://www.w3.org/2001/XMLSchema">
<!--
action-tool => Button which fires the execution of this extension
action-command Text to identify different action-tools inside a
plugin
icon Tool icon
last If true, a separator is added.
tooltip Tooltip
enable-text Text that describes the necessary conditions to enable
a tool
position The position inside the toolbar
-->
<xs:element name="action-tool">
<xs:complexType>
<xs:attribute name="text" type="xs:string" use="optional" />
<xs:attribute name="action-command" type="xs:string" use="optional"
/>
<xs:attribute name="icon" type="xs:string" use="required" />
<xs:attribute name="last" type="xs:boolean" use="optional" />
<xs:attribute name="tooltip" type="xs:string" use="optional" />
<xs:attribute name="enable-text" type="xs:string" use="optional" />
<xs:attribute name="position" type="xs:int" use="optional" />
</xs:complexType>
</xs:element>
<!--
Plugin dependencies from other plugins
plugin-name Name of the other plugin (name of the
directory.)
Example; com.iver.cig.gvsig
-->
<xs:element name="depends">
<xs:complexType>
<xs:attribute name="plugin-name" type="xs:string" use="required" />
</xs:complexType>
</xs:element>
<!--
Extension to Andami
class-name Class that handles the extension
menu Menus installed by the extension
tool-bar Toolbar installed by this plugin
priority Orden en el que se procesaran las extensiones
durante la
carga de Andami. Se inicializan primero y
se instalan sus controles
en las barras de tareas primero. La
prioridad es
mayor cuanto más grande es el valor del
atributo
-->
<xs:element name="extension" type="extension-type"/>
<xs:complexType name="extension-type">
<xs:complexContent>
<xs:extension base="skin-extension-type">
<xs:attribute name="priority" type="xs:int"
use="optional" />
<xs:attribute name="active"
type="xs:boolean" use="optional" />
<xs:attribute name="description"
type="xs:string" use="optional" />
<xs:attribute name="alwaysvisible"
type="xs:boolean" use="optional" />
</xs:extension>
</xs:complexContent>
</xs:complexType>
<!--
Extension's section of the plugin
-->
<xs:element name="extensions">
<xs:complexType>
<xs:sequence>
<xs:element ref="extension" maxOccurs="unbounded" />
<xs:element ref="skin-extension" minOccurs="0" maxOccurs="1" />
</xs:sequence>
</xs:complexType>
</xs:element>
<!--
Main application's Icon
text Title of main window.
src path to an icon file
-->
<xs:element name="icon">
<xs:complexType>
<xs:attribute name="text" type="xs:string" use="required" />
<xs:attribute name="src" type="xs:string" use="required" />
</xs:complexType>
</xs:element>
<!--
label => In this element you can put the mesages that must appear
in the
status bar
size Size in pixels of the status label
id Id assigned to this label
-->
<xs:element name="label">
<xs:complexType>
<xs:attribute name="size" type="xs:int" use="required" />
<xs:attribute name="id" type="xs:NMTOKEN" use="required" />
</xs:complexType>
</xs:element>
<!--
Group of labels on the status bar. The order from up to down in
xml file
stands for the order right to left in Andami's principal frame.
class-name When the active view is an instance of class-name,
this
labelSet will be shown.
-->
<xs:element name="label-set">
<xs:complexType>
<xs:sequence>
<xs:element ref="label" maxOccurs="unbounded" />
</xs:sequence>
<xs:attribute name="class-name" type="xs:NMTOKEN" use="required" />
</xs:complexType>
</xs:element>
<!--
jars that are used by this plugin
library-dir Relative path where the jar files are. Usually ./
or ./lib
-->
<xs:element name="libraries">
<xs:complexType>
<xs:attribute name="library-dir" type="xs:string" use="required" />
</xs:complexType>
</xs:element>
<!--
action-command Text to identify different menus inside the same
plugin
key Abreviatura de teclado del menu
icon Menu Icon
enable-text Texto con la descripción de las condiciones que se
tienen que dar
para que se visualice la opción
tooltip Tooltip
mnemonic Accelerator key
text Menu Text
is_separator true means to add a JSeparator to the parent menu
defined by text
-->
<xs:element name="menu">
<xs:complexType>
<xs:attribute name="action-command" type="xs:string" use="optional"
/>
<xs:attribute name="key" type="xs:string" use="optional" />
<xs:attribute name="icon" type="xs:string" use="optional" />
<xs:attribute name="tooltip" type="xs:string" use="optional" />
<xs:attribute name="enable-text" type="xs:string" use="optional" />
<xs:attribute name="mnemonic" type="xs:string" use="optional" />
<xs:attribute name="text" type="xs:string" use="required" />
<xs:attribute name="position" type="xs:int" use="optional" />
<xs:attribute name="is_separator" type="xs:boolean"
use="optional" />
</xs:complexType>
</xs:element>
<!--
XML File Root
name Plugin's Name
updateURL URL of zip-file with a new plugin's version.
-->
<xs:element name="plugin-config">
<xs:complexType>
<xs:sequence>
<xs:element ref="icon" minOccurs="0"/>
<xs:element ref="depends" minOccurs="0" maxOccurs="unbounded"/>
<xs:element ref="resourceBundle" minOccurs="0"/>
<xs:element ref="label-set" minOccurs="0" maxOccurs="unbounded"/>
<xs:element ref="libraries"/>
<xs:element ref="popup-menus" minOccurs="0"/>
<xs:element ref="extensions" />
</xs:sequence>
<xs:attribute name="update-url" type="xs:string" use="optional" />
</xs:complexType>
</xs:element>
<!--
Popup menu by the plugin. The plugin must register itself as a
popup-menu listener.
-->
<xs:element name="popup-menu">
<xs:complexType>
<xs:sequence>
<xs:element ref="menu" maxOccurs="unbounded" />
</xs:sequence>
<xs:attribute name="name" type="xs:string" use="required" />
</xs:complexType>
</xs:element>
<!--
Section to define popup-menus
-->
<xs:element name="popup-menus">
<xs:complexType>
<xs:sequence>
<xs:element ref="popup-menu" maxOccurs="unbounded" />
</xs:sequence>
</xs:complexType>
</xs:element>
<!--
Properties file with translations used by the tool.
name Name of resource bundle file
-->
<xs:element name="resourceBundle">
<xs:complexType>
<xs:attribute name="name" type="xs:NMTOKEN" use="required" />
</xs:complexType>
</xs:element>
<!--
tool button that remains pressed when it is selected.
text Button's text.
action-command Text to identify the different action-tools inside
a plugin.
group Group where the selectable-tool belongs. It will
be only one selectable-tool
selected inside the group.
is-default If true, the selectable-tool will be selected by
default.
icon Icon to use.
last If true, after the tool it will appears a
separator.
tooltip Tooltip
position The position inside the toolbar
-->
<xs:element name="selectable-tool">
<xs:complexType>
<xs:attribute name="text" type="xs:string" use="optional" />
<xs:attribute name="action-command" type="xs:string" use="optional"
/>
<xs:attribute name="is-default" type="xs:boolean" use="optional" />
<xs:attribute name="last" type="xs:boolean" use="optional" />
<xs:attribute name="icon" type="xs:string" use="required" />
<xs:attribute name="tooltip" type="xs:string" use="optional" />
<xs:attribute name="enable-text" type="xs:string" use="optional" />
<xs:attribute name="group" type="xs:string" use="optional"
default="unico" />
<xs:attribute name="position" type="xs:int" use="optional" />
</xs:complexType>
</xs:element>
<!--
Extension plugin to andami
class-name Class which handles the plugin
menu Menus installed by the plugin
tool-bar Toolbar of the plugin. If it doesn't
exist, it will be created.
combo-button combo-button to be added to the status bar
combo-scale combo-scale to be added to the status bar
-->
<xs:element name="skin-extension" type="skin-extension-type"/>
<xs:complexType name="skin-extension-type">
<xs:sequence>
<xs:element ref="menu" minOccurs="0" maxOccurs="unbounded" />
<xs:element ref="tool-bar" minOccurs="0" maxOccurs="unbounded" />
<xs:element ref="combo-button" minOccurs="0" maxOccurs="unbounded"
/>
<xs:element ref="combo-scale" minOccurs="0" maxOccurs="unbounded" />
</xs:sequence>
<xs:attribute name="class-name" type="xs:NMTOKEN" use="required" />
</xs:complexType>
<!--
tool-bar => Application's main toolbar
name Toolbar name. This way, other plugins can refer to this
toolbar
and add tools to this toolbar.
position
combo-button combo-button to be added to the toolbar
commbo-scale combo-scale to be added to the toolbar
-->
<xs:element name="tool-bar">
<xs:complexType>
<xs:sequence>
<xs:element ref="action-tool" minOccurs="0" maxOccurs="unbounded"
/>
<xs:element ref="selectable-tool" minOccurs="0"
maxOccurs="unbounded" />
<xs:element ref="combo-button" minOccurs="0" maxOccurs="unbounded"
/>
<xs:element ref="combo-scale" minOccurs="0" maxOccurs="unbounded"
/>
</xs:sequence>
<xs:attribute name="name" type="xs:string" use="required" />
<xs:attribute name="position" type="xs:int" use="optional" />
</xs:complexType>
</xs:element>
<!--
combo-scale => A combo box with numeric values, and editable.
name A name to identify the combo-scale.
label The label to be displayed on the left of the combo
elements A semicolon separated list of the combo box' elements
value The initial selected value. If ommited, the first
element is selected
action-command Text to identify the different action-tools inside
a plugin.
-->
<xs:element name="combo-scale">
<xs:complexType>
<xs:attribute name="name"
type="xs:string" use="required" />
<xs:attribute name="label"
type="xs:string" use="optional" />
<xs:attribute name="elements"
use="required" />
<xs:attribute name="value" use="optional"
/>
<xs:attribute name="action-command"
type="xs:string" use="required" />
<xs:attribute name="position"
use="optional" />
</xs:complexType>
</xs:element>
<!--
combo-button => A combo button (drop-down list of selectable
buttons).
name A name to identify the combo-button
-->
<xs:element name="combo-button">
<xs:complexType>
<xs:sequence>
<xs:element ref="combo-button-element"
minOccurs="0" maxOccurs="unbounded" />
</xs:sequence>
<xs:attribute name="name"
type="xs:string" use="required" />
<xs:attribute name="position"
use="optional" />
</xs:complexType>
</xs:element>
<!--
combo-button-element => An entry (icon) on the combo-button list
action-command Text to identify the different action-tools inside
a plugin.
icon Icon to use.
-->
<xs:element name="combo-button-element">
<xs:complexType>
<xs:attribute name="icon"
type="xs:string" use="required"/>
<xs:attribute
name="action-command" type="xs:string" use="required"/>
</xs:complexType>
</xs:element>
</xs:schema>_______________________________________________
gvSIG_desarrolladores mailing list
gvSIG_desarrolladores en runas.cap.gva.es
http://runas.cap.gva.es/mailman/listinfo/gvsig_desarrolladores
------------ próxima parte ------------
Se ha borrado un adjunto en formato HTML...
URL: http://runas.cap.gva.es/pipermail/gvsig_desarrolladores/attachments/20061004/b7c28268/attachment-0001.htm
Más información sobre la lista de distribución gvSIG_desarrolladores