Index: tags/v2_0_0_Build_2050/applications/appgvSIG/gpl.txt
===================================================================
--- tags/v2_0_0_Build_2050/applications/appgvSIG/gpl.txt	(revision 0)
+++ tags/v2_0_0_Build_2050/applications/appgvSIG/gpl.txt	(revision 38653)
@@ -0,0 +1,340 @@
+		    GNU GENERAL PUBLIC LICENSE
+		       Version 2, June 1991
+
+ Copyright (C) 1989, 1991 Free Software Foundation, Inc.
+                       59 Temple Place, Suite 330, Boston, MA  02111-1307  USA
+ Everyone is permitted to copy and distribute verbatim copies
+ of this license document, but changing it is not allowed.
+
+			    Preamble
+
+  The licenses for most software are designed to take away your
+freedom to share and change it.  By contrast, the GNU General Public
+License is intended to guarantee your freedom to share and change free
+software--to make sure the software is free for all its users.  This
+General Public License applies to most of the Free Software
+Foundation's software and to any other program whose authors commit to
+using it.  (Some other Free Software Foundation software is covered by
+the GNU Library General Public License instead.)  You can apply it to
+your programs, too.
+
+  When we speak of free software, we are referring to freedom, not
+price.  Our General Public Licenses are designed to make sure that you
+have the freedom to distribute copies of free software (and charge for
+this service if you wish), that you receive source code or can get it
+if you want it, that you can change the software or use pieces of it
+in new free programs; and that you know you can do these things.
+
+  To protect your rights, we need to make restrictions that forbid
+anyone to deny you these rights or to ask you to surrender the rights.
+These restrictions translate to certain responsibilities for you if you
+distribute copies of the software, or if you modify it.
+
+  For example, if you distribute copies of such a program, whether
+gratis or for a fee, you must give the recipients all the rights that
+you have.  You must make sure that they, too, receive or can get the
+source code.  And you must show them these terms so they know their
+rights.
+
+  We protect your rights with two steps: (1) copyright the software, and
+(2) offer you this license which gives you legal permission to copy,
+distribute and/or modify the software.
+
+  Also, for each author's protection and ours, we want to make certain
+that everyone understands that there is no warranty for this free
+software.  If the software is modified by someone else and passed on, we
+want its recipients to know that what they have is not the original, so
+that any problems introduced by others will not reflect on the original
+authors' reputations.
+
+  Finally, any free program is threatened constantly by software
+patents.  We wish to avoid the danger that redistributors of a free
+program will individually obtain patent licenses, in effect making the
+program proprietary.  To prevent this, we have made it clear that any
+patent must be licensed for everyone's free use or not licensed at all.
+
+  The precise terms and conditions for copying, distribution and
+modification follow.
+
+		    GNU GENERAL PUBLIC LICENSE
+   TERMS AND CONDITIONS FOR COPYING, DISTRIBUTION AND MODIFICATION
+
+  0. This License applies to any program or other work which contains
+a notice placed by the copyright holder saying it may be distributed
+under the terms of this General Public License.  The "Program", below,
+refers to any such program or work, and a "work based on the Program"
+means either the Program or any derivative work under copyright law:
+that is to say, a work containing the Program or a portion of it,
+either verbatim or with modifications and/or translated into another
+language.  (Hereinafter, translation is included without limitation in
+the term "modification".)  Each licensee is addressed as "you".
+
+Activities other than copying, distribution and modification are not
+covered by this License; they are outside its scope.  The act of
+running the Program is not restricted, and the output from the Program
+is covered only if its contents constitute a work based on the
+Program (independent of having been made by running the Program).
+Whether that is true depends on what the Program does.
+
+  1. You may copy and distribute verbatim copies of the Program's
+source code as you receive it, in any medium, provided that you
+conspicuously and appropriately publish on each copy an appropriate
+copyright notice and disclaimer of warranty; keep intact all the
+notices that refer to this License and to the absence of any warranty;
+and give any other recipients of the Program a copy of this License
+along with the Program.
+
+You may charge a fee for the physical act of transferring a copy, and
+you may at your option offer warranty protection in exchange for a fee.
+
+  2. You may modify your copy or copies of the Program or any portion
+of it, thus forming a work based on the Program, and copy and
+distribute such modifications or work under the terms of Section 1
+above, provided that you also meet all of these conditions:
+
+    a) You must cause the modified files to carry prominent notices
+    stating that you changed the files and the date of any change.
+
+    b) You must cause any work that you distribute or publish, that in
+    whole or in part contains or is derived from the Program or any
+    part thereof, to be licensed as a whole at no charge to all third
+    parties under the terms of this License.
+
+    c) If the modified program normally reads commands interactively
+    when run, you must cause it, when started running for such
+    interactive use in the most ordinary way, to print or display an
+    announcement including an appropriate copyright notice and a
+    notice that there is no warranty (or else, saying that you provide
+    a warranty) and that users may redistribute the program under
+    these conditions, and telling the user how to view a copy of this
+    License.  (Exception: if the Program itself is interactive but
+    does not normally print such an announcement, your work based on
+    the Program is not required to print an announcement.)
+
+These requirements apply to the modified work as a whole.  If
+identifiable sections of that work are not derived from the Program,
+and can be reasonably considered independent and separate works in
+themselves, then this License, and its terms, do not apply to those
+sections when you distribute them as separate works.  But when you
+distribute the same sections as part of a whole which is a work based
+on the Program, the distribution of the whole must be on the terms of
+this License, whose permissions for other licensees extend to the
+entire whole, and thus to each and every part regardless of who wrote it.
+
+Thus, it is not the intent of this section to claim rights or contest
+your rights to work written entirely by you; rather, the intent is to
+exercise the right to control the distribution of derivative or
+collective works based on the Program.
+
+In addition, mere aggregation of another work not based on the Program
+with the Program (or with a work based on the Program) on a volume of
+a storage or distribution medium does not bring the other work under
+the scope of this License.
+
+  3. You may copy and distribute the Program (or a work based on it,
+under Section 2) in object code or executable form under the terms of
+Sections 1 and 2 above provided that you also do one of the following:
+
+    a) Accompany it with the complete corresponding machine-readable
+    source code, which must be distributed under the terms of Sections
+    1 and 2 above on a medium customarily used for software interchange; or,
+
+    b) Accompany it with a written offer, valid for at least three
+    years, to give any third party, for a charge no more than your
+    cost of physically performing source distribution, a complete
+    machine-readable copy of the corresponding source code, to be
+    distributed under the terms of Sections 1 and 2 above on a medium
+    customarily used for software interchange; or,
+
+    c) Accompany it with the information you received as to the offer
+    to distribute corresponding source code.  (This alternative is
+    allowed only for noncommercial distribution and only if you
+    received the program in object code or executable form with such
+    an offer, in accord with Subsection b above.)
+
+The source code for a work means the preferred form of the work for
+making modifications to it.  For an executable work, complete source
+code means all the source code for all modules it contains, plus any
+associated interface definition files, plus the scripts used to
+control compilation and installation of the executable.  However, as a
+special exception, the source code distributed need not include
+anything that is normally distributed (in either source or binary
+form) with the major components (compiler, kernel, and so on) of the
+operating system on which the executable runs, unless that component
+itself accompanies the executable.
+
+If distribution of executable or object code is made by offering
+access to copy from a designated place, then offering equivalent
+access to copy the source code from the same place counts as
+distribution of the source code, even though third parties are not
+compelled to copy the source along with the object code.
+
+  4. You may not copy, modify, sublicense, or distribute the Program
+except as expressly provided under this License.  Any attempt
+otherwise to copy, modify, sublicense or distribute the Program is
+void, and will automatically terminate your rights under this License.
+However, parties who have received copies, or rights, from you under
+this License will not have their licenses terminated so long as such
+parties remain in full compliance.
+
+  5. You are not required to accept this License, since you have not
+signed it.  However, nothing else grants you permission to modify or
+distribute the Program or its derivative works.  These actions are
+prohibited by law if you do not accept this License.  Therefore, by
+modifying or distributing the Program (or any work based on the
+Program), you indicate your acceptance of this License to do so, and
+all its terms and conditions for copying, distributing or modifying
+the Program or works based on it.
+
+  6. Each time you redistribute the Program (or any work based on the
+Program), the recipient automatically receives a license from the
+original licensor to copy, distribute or modify the Program subject to
+these terms and conditions.  You may not impose any further
+restrictions on the recipients' exercise of the rights granted herein.
+You are not responsible for enforcing compliance by third parties to
+this License.
+
+  7. If, as a consequence of a court judgment or allegation of patent
+infringement or for any other reason (not limited to patent issues),
+conditions are imposed on you (whether by court order, agreement or
+otherwise) that contradict the conditions of this License, they do not
+excuse you from the conditions of this License.  If you cannot
+distribute so as to satisfy simultaneously your obligations under this
+License and any other pertinent obligations, then as a consequence you
+may not distribute the Program at all.  For example, if a patent
+license would not permit royalty-free redistribution of the Program by
+all those who receive copies directly or indirectly through you, then
+the only way you could satisfy both it and this License would be to
+refrain entirely from distribution of the Program.
+
+If any portion of this section is held invalid or unenforceable under
+any particular circumstance, the balance of the section is intended to
+apply and the section as a whole is intended to apply in other
+circumstances.
+
+It is not the purpose of this section to induce you to infringe any
+patents or other property right claims or to contest validity of any
+such claims; this section has the sole purpose of protecting the
+integrity of the free software distribution system, which is
+implemented by public license practices.  Many people have made
+generous contributions to the wide range of software distributed
+through that system in reliance on consistent application of that
+system; it is up to the author/donor to decide if he or she is willing
+to distribute software through any other system and a licensee cannot
+impose that choice.
+
+This section is intended to make thoroughly clear what is believed to
+be a consequence of the rest of this License.
+
+  8. If the distribution and/or use of the Program is restricted in
+certain countries either by patents or by copyrighted interfaces, the
+original copyright holder who places the Program under this License
+may add an explicit geographical distribution limitation excluding
+those countries, so that distribution is permitted only in or among
+countries not thus excluded.  In such case, this License incorporates
+the limitation as if written in the body of this License.
+
+  9. The Free Software Foundation may publish revised and/or new versions
+of the General Public License from time to time.  Such new versions will
+be similar in spirit to the present version, but may differ in detail to
+address new problems or concerns.
+
+Each version is given a distinguishing version number.  If the Program
+specifies a version number of this License which applies to it and "any
+later version", you have the option of following the terms and conditions
+either of that version or of any later version published by the Free
+Software Foundation.  If the Program does not specify a version number of
+this License, you may choose any version ever published by the Free Software
+Foundation.
+
+  10. If you wish to incorporate parts of the Program into other free
+programs whose distribution conditions are different, write to the author
+to ask for permission.  For software which is copyrighted by the Free
+Software Foundation, write to the Free Software Foundation; we sometimes
+make exceptions for this.  Our decision will be guided by the two goals
+of preserving the free status of all derivatives of our free software and
+of promoting the sharing and reuse of software generally.
+
+			    NO WARRANTY
+
+  11. BECAUSE THE PROGRAM IS LICENSED FREE OF CHARGE, THERE IS NO WARRANTY
+FOR THE PROGRAM, TO THE EXTENT PERMITTED BY APPLICABLE LAW.  EXCEPT WHEN
+OTHERWISE STATED IN WRITING THE COPYRIGHT HOLDERS AND/OR OTHER PARTIES
+PROVIDE THE PROGRAM "AS IS" WITHOUT WARRANTY OF ANY KIND, EITHER EXPRESSED
+OR IMPLIED, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF
+MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE.  THE ENTIRE RISK AS
+TO THE QUALITY AND PERFORMANCE OF THE PROGRAM IS WITH YOU.  SHOULD THE
+PROGRAM PROVE DEFECTIVE, YOU ASSUME THE COST OF ALL NECESSARY SERVICING,
+REPAIR OR CORRECTION.
+
+  12. IN NO EVENT UNLESS REQUIRED BY APPLICABLE LAW OR AGREED TO IN WRITING
+WILL ANY COPYRIGHT HOLDER, OR ANY OTHER PARTY WHO MAY MODIFY AND/OR
+REDISTRIBUTE THE PROGRAM AS PERMITTED ABOVE, BE LIABLE TO YOU FOR DAMAGES,
+INCLUDING ANY GENERAL, SPECIAL, INCIDENTAL OR CONSEQUENTIAL DAMAGES ARISING
+OUT OF THE USE OR INABILITY TO USE THE PROGRAM (INCLUDING BUT NOT LIMITED
+TO LOSS OF DATA OR DATA BEING RENDERED INACCURATE OR LOSSES SUSTAINED BY
+YOU OR THIRD PARTIES OR A FAILURE OF THE PROGRAM TO OPERATE WITH ANY OTHER
+PROGRAMS), EVEN IF SUCH HOLDER OR OTHER PARTY HAS BEEN ADVISED OF THE
+POSSIBILITY OF SUCH DAMAGES.
+
+		     END OF TERMS AND CONDITIONS
+
+	    How to Apply These Terms to Your New Programs
+
+  If you develop a new program, and you want it to be of the greatest
+possible use to the public, the best way to achieve this is to make it
+free software which everyone can redistribute and change under these terms.
+
+  To do so, attach the following notices to the program.  It is safest
+to attach them to the start of each source file to most effectively
+convey the exclusion of warranty; and each file should have at least
+the "copyright" line and a pointer to where the full notice is found.
+
+    <one line to give the program's name and a brief idea of what it does.>
+    Copyright (C) <year>  <name of author>
+
+    This program is free software; you can redistribute it and/or modify
+    it under the terms of the GNU General Public License as published by
+    the Free Software Foundation; either version 2 of the License, or
+    (at your option) any later version.
+
+    This program is distributed in the hope that it will be useful,
+    but WITHOUT ANY WARRANTY; without even the implied warranty of
+    MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
+    GNU General Public License for more details.
+
+    You should have received a copy of the GNU General Public License
+    along with this program; if not, write to the Free Software
+    Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA  02111-1307  USA
+
+
+Also add information on how to contact you by electronic and paper mail.
+
+If the program is interactive, make it output a short notice like this
+when it starts in an interactive mode:
+
+    Gnomovision version 69, Copyright (C) year name of author
+    Gnomovision comes with ABSOLUTELY NO WARRANTY; for details type `show w'.
+    This is free software, and you are welcome to redistribute it
+    under certain conditions; type `show c' for details.
+
+The hypothetical commands `show w' and `show c' should show the appropriate
+parts of the General Public License.  Of course, the commands you use may
+be called something other than `show w' and `show c'; they could even be
+mouse-clicks or menu items--whatever suits your program.
+
+You should also get your employer (if you work as a programmer) or your
+school, if any, to sign a "copyright disclaimer" for the program, if
+necessary.  Here is a sample; alter the names:
+
+  Yoyodyne, Inc., hereby disclaims all copyright interest in the program
+  `Gnomovision' (which makes passes at compilers) written by James Hacker.
+
+  <signature of Ty Coon>, 1 April 1989
+  Ty Coon, President of Vice
+
+This General Public License does not permit incorporating your program into
+proprietary programs.  If your program is a subroutine library, you may
+consider it more useful to permit linking proprietary applications with the
+library.  If this is what you want to do, use the GNU Library General
+Public License instead of this License.

Property changes on: tags/v2_0_0_Build_2050/applications/appgvSIG/gpl.txt
___________________________________________________________________
Added: svn:keywords
   + Author Date Id Revision
Added: svn:eol-style
   + native

Index: tags/v2_0_0_Build_2050/applications/appgvSIG/buildNumber.properties
===================================================================
--- tags/v2_0_0_Build_2050/applications/appgvSIG/buildNumber.properties	(revision 0)
+++ tags/v2_0_0_Build_2050/applications/appgvSIG/buildNumber.properties	(revision 38653)
@@ -0,0 +1,3 @@
+#maven.buildNumber.plugin properties file
+#Thu Aug 09 12:35:18 CEST 2012
+buildNumber=2050
Index: tags/v2_0_0_Build_2050/applications/appgvSIG/src-test/test/TestClassLoader.java
===================================================================
--- tags/v2_0_0_Build_2050/applications/appgvSIG/src-test/test/TestClassLoader.java	(revision 0)
+++ tags/v2_0_0_Build_2050/applications/appgvSIG/src-test/test/TestClassLoader.java	(revision 38653)
@@ -0,0 +1,206 @@
+/* gvSIG. Sistema de Informaci�n Geogr�fica de la Generalitat Valenciana
+ *
+ * Copyright (C) 2005 IVER T.I. and Generalitat Valenciana.
+ *
+ * This program is free software; you can redistribute it and/or
+ * modify it under the terms of the GNU General Public License
+ * as published by the Free Software Foundation; either version 2
+ * of the License, or (at your option) any later version.
+ *
+ * This program is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
+ * GNU General Public License for more details.
+ *
+ * You should have received a copy of the GNU General Public License
+ * along with this program; if not, write to the Free Software
+ * Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA  02111-1307,USA.
+ *
+ * For more information, contact:
+ *
+ *  Generalitat Valenciana
+ *   Conselleria d'Infraestructures i Transport
+ *   Av. Blasco Ib��ez, 50
+ *   46010 VALENCIA
+ *   SPAIN
+ *
+ *      +34 963862235
+ *   gvsig@gva.es
+ *      www.gvsig.gva.es
+ *
+ *    or
+ *
+ *   IVER T.I. S.A
+ *   Salamanca 50
+ *   46005 Valencia
+ *   Spain
+ *
+ *   +34 963163400
+ *   dac@iver.es
+ */
+
+/* CVS MESSAGES:
+*
+* $Id$
+* $Log$
+* Revision 1.1  2006-11-08 10:57:55  jaume
+* remove unecessary imports
+*
+*
+*/
+package test;
+
+import java.io.DataInputStream;
+import java.io.File;
+import java.io.IOException;
+import java.io.InputStream;
+import java.net.MalformedURLException;
+import java.net.URL;
+import java.util.ArrayList;
+import java.util.Enumeration;
+import java.util.Hashtable;
+import java.util.jar.JarException;
+import java.util.zip.ZipEntry;
+import java.util.zip.ZipFile;
+
+public class TestClassLoader extends ClassLoader{
+	private Hashtable jarz = new Hashtable();
+	private Hashtable classes = new Hashtable();
+	private String baseDir;
+
+	public TestClassLoader(String baseDir) throws IOException {
+		this.baseDir = baseDir;
+
+		File dir = new File(baseDir);
+
+
+		URL[] jars = (URL[]) getJarURLs(dir).toArray(new URL[0]);
+
+		if (jars == null) {
+			throw new IllegalArgumentException("jars cannot be null"); //$NON-NLS-1$
+		}
+
+		//Se itera por las URLS que deben de ser jar's
+		ZipFile[] jarFiles = new ZipFile[jars.length];
+
+		for (int i = 0; i < jars.length; i++) {
+			jarFiles[i] = new ZipFile(jars[i].getPath());
+			Enumeration files = jarFiles[i].entries();
+			while (files.hasMoreElements()) {
+				//Se obtiene la entrada
+				ZipEntry file = (ZipEntry) files.nextElement();
+				String fileName = file.getName();
+
+				//Se obtiene el nombre de la clase
+				if (!fileName.toLowerCase().endsWith(".class")) { //$NON-NLS-1$
+					continue;
+				}
+
+				fileName = fileName.substring(0, fileName.length() - 6).replace('/',
+				'.');
+
+				//Se cromprueba si ya hab�a una clase con dicho nombre
+				if (jarz.get(fileName) != null) {
+					throw new JarException(
+							"two or more classes with the same name in the jars: " +
+							fileName);
+				}
+
+				//Se registra la clase
+				jarz.put(fileName, jarFiles[i]);
+				try {
+					loadClass(fileName, true);
+				} catch (ClassNotFoundException e) {
+					// TODO Auto-generated catch block
+					e.printStackTrace();
+				}
+			}
+
+		}
+	}
+
+	private ArrayList getJarURLs(File file) {
+		ArrayList jars = new ArrayList();
+		if (file.isDirectory()) {
+			String[] fileNames = file.list();
+			for (int i = 0; i < fileNames.length; i++) {
+				File file1 = new File(file+ File.separator + fileNames[i]);
+				if (file1.isDirectory()) {
+					jars.addAll(getJarURLs(file1));
+				} else {
+					if (file1.getAbsolutePath().endsWith(".jar")) {
+						try {
+							jars.add(file1.toURL());
+						} catch (MalformedURLException e) {
+							e.printStackTrace();
+						}
+					}
+				}
+			}
+		} else {
+			if (file.getAbsolutePath().endsWith(".jar")) {
+				try {
+					jars.add(new URL(file.getAbsolutePath()));
+				} catch (MalformedURLException e) {
+					e.printStackTrace();
+				}
+			}
+		}
+		return jars;
+	}
+
+	protected synchronized Class loadClass(String className, boolean resolve) throws ClassNotFoundException {
+		Class c;
+		System.out.print("Loading class ["+className+"]...");
+		try {
+			c = super.loadClass(className, resolve);
+		} catch (ClassNotFoundException e) {
+			ZipFile file = (ZipFile) jarz.get(className);
+			ZipEntry classFile = file.getEntry(className);
+			byte[] classBytes;
+			try {
+				classBytes = loadClassBytes(classFile, file.getInputStream(classFile));
+			} catch (IOException e1) {
+				throw new ClassNotFoundException(className);
+			}
+			c = defineClass(className, classBytes, 0, classBytes.length);
+		}
+		System.out.println(" Ok!");
+
+		return c;
+	}
+
+	protected Class findClass(String className) throws ClassNotFoundException {
+		return loadClass(className);
+	}
+
+	private byte[] loadClassBytes(ZipEntry classFile, InputStream is)
+	throws IOException {
+		// Get size of class file
+		int size = (int) classFile.getSize();
+
+		// Reserve space to read
+		byte[] buff = new byte[size];
+
+		// Get stream to read from
+		DataInputStream dis = new DataInputStream(is);
+
+		// Read in data
+		dis.readFully(buff);
+
+		// close stream
+		dis.close();
+
+		// return data
+		return buff;
+	}
+
+	public static void main(String args[]) {
+		try {
+			TestClassLoader cl = new TestClassLoader("lib-test/");
+		} catch (IOException e) {
+			// TODO Auto-generated catch block
+			e.printStackTrace();
+		}
+	}
+}

Property changes on: tags/v2_0_0_Build_2050/applications/appgvSIG/src-test/test/TestClassLoader.java
___________________________________________________________________
Added: svn:keywords
   + Author Date Id Revision
Added: svn:eol-style
   + native

Index: tags/v2_0_0_Build_2050/applications/appgvSIG/src-test/org/gvsig/app/AllTests.java
===================================================================
--- tags/v2_0_0_Build_2050/applications/appgvSIG/src-test/org/gvsig/app/AllTests.java	(revision 0)
+++ tags/v2_0_0_Build_2050/applications/appgvSIG/src-test/org/gvsig/app/AllTests.java	(revision 38653)
@@ -0,0 +1,31 @@
+package org.gvsig.app;
+
+import junit.framework.Test;
+import junit.framework.TestSuite;
+
+import org.gvsig.app.gui.filter.TestFilterExpressionFromWhereIsEmpty_Method;
+import org.gvsig.app.panelGroup.Test2ExceptionsUsingTabbedPanel;
+import org.gvsig.app.panelGroup.Test2ExceptionsUsingTreePanel;
+import org.gvsig.app.panelGroup.TestPanelGroupLoaderFromExtensionPoint;
+import org.gvsig.app.project.ProjectTest;
+import org.gvsig.app.sqlQueryValidation.TestSQLQueryValidation;
+import org.gvsig.app.test.Persistence;
+
+public class AllTests {
+
+	public static Test suite() {
+		TestSuite suite = new TestSuite("Test for org.gvsig.app");
+		//$JUnit-BEGIN$
+		suite.addTestSuite(Persistence.class);
+		suite.addTestSuite(ProjectTest.class);
+		suite.addTestSuite(TestFilterExpressionFromWhereIsEmpty_Method.class);
+		suite.addTestSuite(TestSQLQueryValidation.class);
+		suite.addTestSuite(TestPanelGroupLoaderFromExtensionPoint.class);
+		suite.addTestSuite(Test2ExceptionsUsingTabbedPanel.class);
+		suite.addTestSuite(Test2ExceptionsUsingTreePanel.class);
+		
+		//$JUnit-END$
+		return suite;
+	}
+
+}

Property changes on: tags/v2_0_0_Build_2050/applications/appgvSIG/src-test/org/gvsig/app/AllTests.java
___________________________________________________________________
Added: svn:keywords
   + Author Date Id Revision
Added: svn:eol-style
   + native

Index: tags/v2_0_0_Build_2050/applications/appgvSIG/src-test/org/gvsig/app/panelGroup/Test2ExceptionsUsingTabbedPanel.java
===================================================================
--- tags/v2_0_0_Build_2050/applications/appgvSIG/src-test/org/gvsig/app/panelGroup/Test2ExceptionsUsingTabbedPanel.java	(revision 0)
+++ tags/v2_0_0_Build_2050/applications/appgvSIG/src-test/org/gvsig/app/panelGroup/Test2ExceptionsUsingTabbedPanel.java	(revision 38653)
@@ -0,0 +1,283 @@
+/* gvSIG. Sistema de Informaci�n Geogr�fica de la Generalitat Valenciana
+ *
+ * Copyright (C) 2007 IVER T.I. and Generalitat Valenciana.
+ *
+ * This program is free software; you can redistribute it and/or
+ * modify it under the terms of the GNU General Public License
+ * as published by the Free Software Foundation; either version 2
+ * of the License, or (at your option) any later version.
+ *
+ * This program is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
+ * GNU General Public License for more details.
+ *
+ * You should have received a copy of the GNU General Public License
+ * along with this program; if not, write to the Free Software
+ * Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA  02111-1307,USA.
+ */
+
+package org.gvsig.app.panelGroup;
+
+import junit.framework.TestCase;
+
+import org.gvsig.gui.beans.Messages;
+import org.gvsig.gui.beans.panelGroup.PanelGroupManager;
+import org.gvsig.gui.beans.panelGroup.tabbedPanel.TabbedPanel;
+import org.gvsig.tools.exception.BaseException;
+
+import org.gvsig.app.panelGroup.loaders.PanelGroupLoaderFromExtensionPoint;
+import org.gvsig.app.panelGroup.samples.Samples_ExtensionPointsOfIPanels;
+
+/**
+ * <p>
+ * Tests the loading of layers using a {@link TabbedPanel TabbedPanel} object
+ * and a {@link PanelGroupLoaderFromExtensionPoint
+ * PanelGroupLoaderFromExtensionPoint} loader Tests also the managing of the
+ * different kind of exceptions which could be launched during this process.
+ * </p>
+ * 
+ * @version 11/12/2007
+ * @author Pablo Piqueras Bartolom� (pablo.piqueras@iver.es)
+ */
+public class Test2ExceptionsUsingTabbedPanel extends TestCase {
+	private TabbedPanel panelGroup;
+	private PanelGroupManager manager;
+	private PanelGroupLoaderFromExtensionPoint loader;
+	private String validationText;
+	private String localizedMessage;
+
+	/*
+	 * (non-Javadoc)
+	 * @see junit.framework.TestCase#setUp()
+	 */
+	protected void setUp() throws Exception {
+		super.setUp();
+
+		manager = PanelGroupManager.getManager();
+		manager.registerPanelGroup(TabbedPanel.class);
+		manager.setDefaultType(TabbedPanel.class);
+		panelGroup = (TabbedPanel) manager.getPanelGroup(Samples_ExtensionPointsOfIPanels.REFERENCE3);
+	}
+
+	/*
+	 * (non-Javadoc)
+	 * @see junit.framework.TestCase#tearDown()
+	 */
+	protected void tearDown() throws Exception {
+		super.tearDown();
+		manager.deregisterPanelGroup(TabbedPanel.class);
+	}
+
+	/**
+	 * <p>Test the 'PanelGroup' exceptions </p>
+	 */
+	public void test1() {
+		Samples_ExtensionPointsOfIPanels.loadSample();
+
+		validationText = Messages.getText("couldnt_add_some_panel_exception") + "\n  " + Messages.getText("couldnt_load_panels_from_extension_point_exception") + "\n  Error cargando un panel: / by zero.";
+
+		try {
+			System.out.println("----- Test 1 -----");
+			loader = new PanelGroupLoaderFromExtensionPoint(Samples_ExtensionPointsOfIPanels.EXTENSIONPOINT4_NAME);
+
+			// Begin: Test the normal load
+			panelGroup.loadPanels(loader);
+			// End: Test the normal load
+		} catch (BaseException bE) {
+			localizedMessage = bE.getLocalizedMessageStack();
+			System.out.println(localizedMessage);
+			System.out.println("------------------");
+			assertEquals(localizedMessage, validationText);
+			return;
+		} catch (Exception e) {
+			e.printStackTrace();
+			System.out.println("------------------");
+			fail();
+			return;
+		}
+
+		System.out.println("------------------");
+		fail();
+	}
+
+	/**
+	 * <p>Test the 'PanelGroup' exceptions </p>
+	 */
+	public void test2() {
+		validationText = Messages.getText("couldnt_add_some_panel_exception") + "\n  Panel de etiqueta Information_LABEL sin tama�o inicial definido.";
+
+		try {
+			System.out.println("----- Test 2 -----");
+			loader = new PanelGroupLoaderFromExtensionPoint(Samples_ExtensionPointsOfIPanels.EXTENSIONPOINT5_NAME);
+
+			// Begin: Test the normal load
+			panelGroup.loadPanels(loader);
+			// End: Test the normal load
+		} catch (BaseException bE) {
+			localizedMessage = bE.getLocalizedMessageStack().trim();
+			System.out.println(localizedMessage);
+			System.out.println("------------------");
+			assertEquals(localizedMessage, validationText);
+			return;
+		} catch (Exception e) {
+			e.printStackTrace();
+			System.out.println("------------------");
+			fail();
+			return;
+		}
+
+		System.out.println("------------------");
+		fail();
+	}
+
+	/**
+	 * <p>Test the 'PanelGroup' exceptions </p>
+	 */
+	public void test3() {
+		validationText = Messages.getText("empty_panel_group_exception");
+
+		try {
+			System.out.println("----- Test 3 -----");
+			loader = new PanelGroupLoaderFromExtensionPoint(Samples_ExtensionPointsOfIPanels.EXTENSIONPOINT6_NAME);
+
+			// Begin: Test the normal load
+			panelGroup.loadPanels(loader);
+			// End: Test the normal load
+		} catch (BaseException bE) {
+			localizedMessage = bE.getLocalizedMessageStack().trim();
+			System.out.println(localizedMessage);
+			System.out.println("------------------");
+			assertEquals(localizedMessage, validationText);
+			return;
+		} catch (Exception e) {
+			e.printStackTrace();
+			System.out.println("------------------");
+			fail();
+			return;
+		}
+
+		System.out.println("------------------");
+		fail();
+	}
+
+	/**
+	 * <p>Test the 'PanelGroup' exceptions </p>
+	 */
+	public void test4() {
+		validationText = Messages.getText("empty_panel_group_gui_exception");
+
+		try {
+			System.out.println("----- Test 4 -----");
+			loader = new PanelGroupLoaderFromExtensionPoint(Samples_ExtensionPointsOfIPanels.EXTENSIONPOINT7_NAME);
+
+			// Begin: Test the normal load
+			panelGroup.loadPanels(loader);
+			// End: Test the normal load
+		} catch (BaseException bE) {
+			localizedMessage = bE.getLocalizedMessageStack().trim();
+			System.out.println(localizedMessage);
+			System.out.println("------------------");
+			assertEquals(localizedMessage, validationText);
+			return;
+		} catch (Exception e) {
+			e.printStackTrace();
+			System.out.println("------------------");
+			fail();
+			return;
+		}
+
+		System.out.println("------------------");
+		fail();
+	}
+
+	/**
+	 * <p>Test the 'PanelGroup' exceptions </p>
+	 */
+	public void test5() {
+		validationText = Messages.getText("couldnt_add_some_panel_exception") + "\n  " + Messages.getText("couldnt_load_panels_from_extension_point_exception") + "\n  Error cargando un panel: / by zero.\n  Panel de etiqueta Information_LABEL sin tama�o inicial definido.\n  " + Messages.getText("empty_panel_group_exception");
+
+		try {
+			System.out.println("----- Test 5 -----");
+			loader = new PanelGroupLoaderFromExtensionPoint(Samples_ExtensionPointsOfIPanels.EXTENSIONPOINT8_NAME);
+
+			// Begin: Test the normal load
+			panelGroup.loadPanels(loader);
+			// End: Test the normal load
+		} catch (BaseException bE) {
+			localizedMessage = bE.getLocalizedMessageStack().trim();
+			System.out.println(localizedMessage);
+			System.out.println("------------------");
+			assertEquals(localizedMessage, validationText);
+			return;
+		} catch (Exception e) {
+			e.printStackTrace();
+			System.out.println("------------------");
+			fail();
+			return;
+		}
+
+		System.out.println("------------------");
+		fail();
+	}
+
+	/**
+	 * <p>Test the 'PanelGroup' exceptions </p>
+	 */
+	public void test6() {
+		validationText = Messages.getText("couldnt_add_some_panel_exception") + "\n  " + Messages.getText("couldnt_load_panels_from_extension_point_exception") + "\n  Error cargando un panel: / by zero.\n  Panel de etiqueta Information_LABEL sin tama�o inicial definido.\n  " + Messages.getText("empty_panel_group_gui_exception");
+
+		try {
+			System.out.println("----- Test 6 -----");
+			loader = new PanelGroupLoaderFromExtensionPoint(Samples_ExtensionPointsOfIPanels.EXTENSIONPOINT9_NAME);
+
+			// Begin: Test the normal load
+			panelGroup.loadPanels(loader);
+			// End: Test the normal load
+		} catch (BaseException bE) {
+			localizedMessage = bE.getLocalizedMessageStack().trim();
+			System.out.println(localizedMessage);
+			System.out.println("------------------");
+			assertEquals(localizedMessage, validationText);
+			return;
+		} catch (Exception e) {
+			e.printStackTrace();
+			System.out.println("------------------");
+			fail();
+			return;
+		}
+
+		System.out.println("------------------");
+		fail();
+	}
+
+	/**
+	 * <p>Test the 'PanelGroup' exceptions </p>
+	 */
+	public void test7() {
+		validationText = Messages.getText("couldnt_add_some_panel_exception") + "\n  " + Messages.getText("couldnt_load_panels_from_extension_point_exception") + "\n  Error cargando un panel: / by zero.\n  Panel de etiqueta Information_LABEL sin tama�o inicial definido.";
+
+		try {
+			System.out.println("----- Test 7 -----");
+			loader = new PanelGroupLoaderFromExtensionPoint(Samples_ExtensionPointsOfIPanels.EXTENSIONPOINT10_NAME);
+
+			// Begin: Test the normal load
+			panelGroup.loadPanels(loader);
+			// End: Test the normal load
+		} catch (BaseException bE) {
+			localizedMessage = bE.getLocalizedMessageStack().trim();
+			System.out.println(localizedMessage);
+			System.out.println("------------------");
+			assertEquals(localizedMessage, validationText);
+			return;
+		} catch (Exception e) {
+			e.printStackTrace();
+			System.out.println("------------------");
+			fail();
+			return;
+		}
+
+		System.out.println("------------------");
+		fail();
+	}
+}
Index: tags/v2_0_0_Build_2050/applications/appgvSIG/src-test/org/gvsig/app/panelGroup/TestPanelGroupLoaderFromExtensionPoint.java
===================================================================
--- tags/v2_0_0_Build_2050/applications/appgvSIG/src-test/org/gvsig/app/panelGroup/TestPanelGroupLoaderFromExtensionPoint.java	(revision 0)
+++ tags/v2_0_0_Build_2050/applications/appgvSIG/src-test/org/gvsig/app/panelGroup/TestPanelGroupLoaderFromExtensionPoint.java	(revision 38653)
@@ -0,0 +1,82 @@
+/* gvSIG. Sistema de Informaci�n Geogr�fica de la Generalitat Valenciana
+ *
+ * Copyright (C) 2007 IVER T.I. and Generalitat Valenciana.
+ *
+ * This program is free software; you can redistribute it and/or
+ * modify it under the terms of the GNU General Public License
+ * as published by the Free Software Foundation; either version 2
+ * of the License, or (at your option) any later version.
+ *
+ * This program is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
+ * GNU General Public License for more details.
+ *
+ * You should have received a copy of the GNU General Public License
+ * along with this program; if not, write to the Free Software
+ * Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA  02111-1307,USA.
+ */
+
+package org.gvsig.app.panelGroup;
+
+import java.util.ArrayList;
+
+import junit.framework.TestCase;
+
+import org.gvsig.gui.beans.panelGroup.panels.IPanel;
+
+import org.gvsig.app.panelGroup.loaders.PanelGroupLoaderFromExtensionPoint;
+import org.gvsig.app.panelGroup.samples.Samples_ExtensionPointsOfIPanels;
+
+/**
+ * <p>Tests {@link PanelGroupLoaderFromExtensionPoint PanelGroupLoaderFromExtensionPoint}.</p>
+ * 
+ * @version 16/10/2007
+ * @author Pablo Piqueras Bartolom� (pablo.piqueras@iver.es) 
+ */
+public class TestPanelGroupLoaderFromExtensionPoint extends TestCase {
+
+	/*
+	 * (non-Javadoc)
+	 * @see junit.framework.TestCase#setUp()
+	 */
+	protected void setUp() throws Exception {
+		super.setUp();
+	}
+
+	/*
+	 * (non-Javadoc)
+	 * @see junit.framework.TestCase#tearDown()
+	 */
+	protected void tearDown() throws Exception {
+		super.tearDown();
+	}
+	
+	/**
+	 * <p>Test, results must be valid.</p>
+	 */
+	public void test() {
+		try {
+			Samples_ExtensionPointsOfIPanels.loadSample();
+			
+			PanelGroupLoaderFromExtensionPoint loader = new PanelGroupLoaderFromExtensionPoint(Samples_ExtensionPointsOfIPanels.EXTENSIONPOINT1_NAME);
+			ArrayList<IPanel> panels = new ArrayList<IPanel>();
+
+			loader.loadPanels(panels);
+
+			// Check that has loaded all panels
+			assertEquals(Samples_ExtensionPointsOfIPanels.EXTENSIONPOINTS1_CLASSES.length, panels.size());
+			
+			int i = 0;
+
+			while (i < Samples_ExtensionPointsOfIPanels.EXTENSIONPOINTS2_CLASSES.length) {
+				// Check order and class types
+				assertTrue(panels.get(i).getClass() == (Samples_ExtensionPointsOfIPanels.EXTENSIONPOINTS1_CLASSES[i++]));
+			}
+
+		} catch (Exception e) {
+			e.printStackTrace();
+			fail();
+		}
+	}
+}
Index: tags/v2_0_0_Build_2050/applications/appgvSIG/src-test/org/gvsig/app/panelGroup/Test1ButtonsPanel.java
===================================================================
--- tags/v2_0_0_Build_2050/applications/appgvSIG/src-test/org/gvsig/app/panelGroup/Test1ButtonsPanel.java	(revision 0)
+++ tags/v2_0_0_Build_2050/applications/appgvSIG/src-test/org/gvsig/app/panelGroup/Test1ButtonsPanel.java	(revision 38653)
@@ -0,0 +1,132 @@
+/* gvSIG. Sistema de Informaci�n Geogr�fica de la Generalitat Valenciana
+ *
+ * Copyright (C) 2007 IVER T.I. and Generalitat Valenciana.
+ *
+ * This program is free software; you can redistribute it and/or
+ * modify it under the terms of the GNU General Public License
+ * as published by the Free Software Foundation; either version 2
+ * of the License, or (at your option) any later version.
+ *
+ * This program is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
+ * GNU General Public License for more details.
+ *
+ * You should have received a copy of the GNU General Public License
+ * along with this program; if not, write to the Free Software
+ * Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA  02111-1307,USA.
+ */
+
+package org.gvsig.app.panelGroup;
+
+import javax.swing.JFrame;
+
+import org.gvsig.gui.beans.buttonspanel.ButtonsPanel;
+import org.gvsig.gui.beans.buttonspanel.ButtonsPanelEvent;
+import org.gvsig.gui.beans.buttonspanel.ButtonsPanelListener;
+import org.gvsig.gui.beans.panelGroup.PanelGroupManager;
+import org.gvsig.gui.beans.panelGroup.loaders.PanelGroupLoaderFromList;
+import org.gvsig.gui.beans.panelGroup.tabbedPanel.TabbedPanel;
+import org.gvsig.tools.exception.BaseException;
+
+import org.gvsig.andami.ui.mdiManager.WindowInfo;
+import org.gvsig.app.panelGroup.samples.Samples_ExtensionPointsOfIPanels;
+
+/**
+ * <p>
+ * Tests {@link PanelGroupDialog PanelGroupDialog}.
+ * </p>
+ * <p>
+ * Tests {@link PanelGroupManager PanelGroupManager},
+ * {@link PanelGroupLoaderFromList PanelGroupLoaderFromList},
+ * {@link TabbedPanel TabbedPanel}, and a resizable {@link PanelGroupDialog
+ * PanelGroupDialog}.
+ * </p>
+ * 
+ * @version 16/10/2007
+ * @author Pablo Piqueras Bartolom� (pablo.piqueras@iver.es)
+ */
+public class Test1ButtonsPanel {
+	/**
+	 * <p>Element for the interface.</p>
+	 */
+	private static JFrame jFrame;
+
+	/**
+	 * <p>
+	 * Test method for the Test1ButtonsPanel.
+	 * </p>
+	 * <p>
+	 * Tests {@link PanelGroupManager PanelGroupManager},
+	 * {@link PanelGroupLoaderFromList PanelGroupLoaderFromList},
+	 * {@link TabbedPanel TabbedPanel}, and a resizable {@link PanelGroupDialog
+	 * PanelGroupDialog}.
+	 * </p>
+	 * 
+	 * @param args
+	 *            optional arguments
+	 */
+	public static void main(String[] args) {
+		try {
+			// Objects creation
+			jFrame = new JFrame();
+
+			PanelGroupManager manager = PanelGroupManager.getManager();
+			manager.registerPanelGroup(TabbedPanel.class);
+			manager.setDefaultType(TabbedPanel.class);
+
+			TabbedPanel panelGroup = (TabbedPanel) manager.getPanelGroup(Samples_ExtensionPointsOfIPanels.REFERENCE1);
+
+			PanelGroupLoaderFromList loader = new PanelGroupLoaderFromList(Samples_ExtensionPointsOfIPanels.EXTENSIONPOINTS1_CLASSES);
+
+			// Creates the IWindow
+			PanelGroupDialog panelGroupDialog = new PanelGroupDialog(Samples_ExtensionPointsOfIPanels.REFERENCE1_NAME, "Panels with Buttons", 800, 650, (byte)WindowInfo.RESIZABLE, panelGroup);
+
+			// Begin: Test the normal load
+			panelGroupDialog.loadPanels(loader);
+			// End: Test the normal load
+
+			panelGroupDialog.addButtonPressedListener(new ButtonsPanelListener() {
+				/*
+				 * @see org.gvsig.gui.beans.buttonspanel.ButtonsPanelListener#actionButtonPressed(org.gvsig.gui.beans.buttonspanel.ButtonsPanelEvent)
+				 */
+				public void actionButtonPressed(ButtonsPanelEvent e) {
+					switch (e.getButton()) {
+						case ButtonsPanel.BUTTON_ACCEPT:
+							System.out.println("Accept Button pressed.");
+							hideJFrame();
+							System.exit(0);
+							break;
+						case ButtonsPanel.BUTTON_CANCEL:
+							System.out.println("Cancel Button pressed.");
+							hideJFrame();
+							System.exit(0);
+							break;
+						case ButtonsPanel.BUTTON_APPLY:
+							System.out.println("Apply Button pressed.");
+							break;
+					}
+				}
+			});
+
+			jFrame.setTitle("Test resizable PanelGroupDialog with tabs and using PanelGroupLoaderFromList");
+		    jFrame.setDefaultCloseOperation(JFrame.EXIT_ON_CLOSE);
+		    jFrame.setSize(panelGroupDialog.getPreferredSize());
+		    jFrame.getContentPane().add(panelGroupDialog);
+
+			jFrame.setVisible(true);
+
+		} catch (BaseException bE) {
+			System.out.println(bE.getLocalizedMessageStack());
+		} catch (Exception e) {
+			e.printStackTrace();
+		}
+	}
+
+	/**
+	 * <p>Hides the {@link JFrame JFrame}, hiding the graphical interface.</p>
+	 */
+	private static void hideJFrame() {
+		jFrame.setVisible(false);
+	}
+}
Index: tags/v2_0_0_Build_2050/applications/appgvSIG/src-test/org/gvsig/app/panelGroup/Test2ButtonsPanel.java
===================================================================
--- tags/v2_0_0_Build_2050/applications/appgvSIG/src-test/org/gvsig/app/panelGroup/Test2ButtonsPanel.java	(revision 0)
+++ tags/v2_0_0_Build_2050/applications/appgvSIG/src-test/org/gvsig/app/panelGroup/Test2ButtonsPanel.java	(revision 38653)
@@ -0,0 +1,127 @@
+/* gvSIG. Sistema de Informaci�n Geogr�fica de la Generalitat Valenciana
+ *
+ * Copyright (C) 2007 IVER T.I. and Generalitat Valenciana.
+ *
+ * This program is free software; you can redistribute it and/or
+ * modify it under the terms of the GNU General Public License
+ * as published by the Free Software Foundation; either version 2
+ * of the License, or (at your option) any later version.
+ *
+ * This program is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
+ * GNU General Public License for more details.
+ *
+ * You should have received a copy of the GNU General Public License
+ * along with this program; if not, write to the Free Software
+ * Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA  02111-1307,USA.
+ */
+
+package org.gvsig.app.panelGroup;
+
+import javax.swing.JFrame;
+
+import org.gvsig.gui.beans.buttonspanel.ButtonsPanel;
+import org.gvsig.gui.beans.buttonspanel.ButtonsPanelEvent;
+import org.gvsig.gui.beans.buttonspanel.ButtonsPanelListener;
+import org.gvsig.gui.beans.panelGroup.PanelGroupManager;
+import org.gvsig.gui.beans.panelGroup.tabbedPanel.TabbedPanel;
+import org.gvsig.tools.exception.BaseException;
+
+import org.gvsig.andami.ui.mdiManager.WindowInfo;
+import org.gvsig.app.panelGroup.loaders.PanelGroupLoaderFromExtensionPoint;
+import org.gvsig.app.panelGroup.samples.Samples_ExtensionPointsOfIPanels;
+
+/**
+ * <p>
+ * Tests {@link PanelGroupDialog PanelGroupDialog}.
+ * </p>
+ * <p>
+ * Tests {@link PanelGroupManager PanelGroupManager},
+ * {@link PanelGroupLoaderFromExtensionPoint PanelGroupLoaderFromExtensionPoint}, {@link TabbedPanel TabbedPanel}, and a resizable {@link PanelGroupDialog
+ * PanelGroupDialog}.
+ * </p>
+ * 
+ * @version 16/10/2007
+ * @author Pablo Piqueras Bartolom� (pablo.piqueras@iver.es)
+ */
+public class Test2ButtonsPanel {
+	/**
+	 * <p>Element for the interface.</p>
+	 */
+	private static JFrame jFrame;
+
+	/**
+	 * <p>
+	 * Test method for the Test2ButtonsPanel.
+	 * </p>
+	 * 
+	 * @param args
+	 *            optional arguments
+	 */
+	public static void main(String[] args) {
+		try {
+			// Objects creation
+			jFrame = new JFrame();
+
+			Samples_ExtensionPointsOfIPanels.loadSample();
+
+			PanelGroupManager manager = PanelGroupManager.getManager();
+			manager.registerPanelGroup(TabbedPanel.class);
+			manager.setDefaultType(TabbedPanel.class);
+
+			TabbedPanel panelGroup = (TabbedPanel) manager.getPanelGroup(Samples_ExtensionPointsOfIPanels.REFERENCE1);
+
+			PanelGroupLoaderFromExtensionPoint loader = new PanelGroupLoaderFromExtensionPoint(Samples_ExtensionPointsOfIPanels.EXTENSIONPOINT1_NAME);
+
+			// Creates the IWindow
+			PanelGroupDialog panelGroupDialog = new PanelGroupDialog(Samples_ExtensionPointsOfIPanels.REFERENCE1_NAME, "Panels with Buttons", 800, 650, (byte)WindowInfo.RESIZABLE, panelGroup);
+
+			// Begin: Test the normal load
+			panelGroupDialog.loadPanels(loader);
+			// End: Test the normal load
+
+			panelGroupDialog.addButtonPressedListener(new ButtonsPanelListener() {
+				/*
+				 * @see org.gvsig.gui.beans.buttonspanel.ButtonsPanelListener#actionButtonPressed(org.gvsig.gui.beans.buttonspanel.ButtonsPanelEvent)
+				 */
+				public void actionButtonPressed(ButtonsPanelEvent e) {
+					switch (e.getButton()) {
+						case ButtonsPanel.BUTTON_ACCEPT:
+							System.out.println("Accept Button pressed.");
+							hideJFrame();
+							System.exit(0);
+							break;
+						case ButtonsPanel.BUTTON_CANCEL:
+							System.out.println("Cancel Button pressed.");
+							hideJFrame();
+							System.exit(0);
+							break;
+						case ButtonsPanel.BUTTON_APPLY:
+							System.out.println("Apply Button pressed.");
+							break;
+					}
+				}
+			});
+
+			jFrame.setTitle("Test resizable PanelGroupDialog with tabs and using PanelGroupLoaderFromExtensionPoint");
+		    jFrame.setDefaultCloseOperation(JFrame.EXIT_ON_CLOSE);
+		    jFrame.setSize(panelGroupDialog.getPreferredSize());
+		    jFrame.getContentPane().add(panelGroupDialog);
+
+			jFrame.setVisible(true);
+
+		} catch (BaseException bE) {
+			System.out.println(bE.getLocalizedMessageStack());
+		} catch (Exception e) {
+			e.printStackTrace();
+		}
+	}
+
+	/**
+	 * <p>Hides the {@link JFrame JFrame}, hiding the graphical interface.</p>
+	 */
+	private static void hideJFrame() {
+		jFrame.setVisible(false);
+	}
+}
Index: tags/v2_0_0_Build_2050/applications/appgvSIG/src-test/org/gvsig/app/panelGroup/Test2TreePanel.java
===================================================================
--- tags/v2_0_0_Build_2050/applications/appgvSIG/src-test/org/gvsig/app/panelGroup/Test2TreePanel.java	(revision 0)
+++ tags/v2_0_0_Build_2050/applications/appgvSIG/src-test/org/gvsig/app/panelGroup/Test2TreePanel.java	(revision 38653)
@@ -0,0 +1,76 @@
+/* gvSIG. Sistema de Informaci�n Geogr�fica de la Generalitat Valenciana
+ *
+ * Copyright (C) 2007 IVER T.I. and Generalitat Valenciana.
+ *
+ * This program is free software; you can redistribute it and/or
+ * modify it under the terms of the GNU General Public License
+ * as published by the Free Software Foundation; either version 2
+ * of the License, or (at your option) any later version.
+ *
+ * This program is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
+ * GNU General Public License for more details.
+ *
+ * You should have received a copy of the GNU General Public License
+ * along with this program; if not, write to the Free Software
+ * Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA  02111-1307,USA.
+ */
+
+package org.gvsig.app.panelGroup;
+
+import javax.swing.JFrame;
+
+import org.gvsig.gui.beans.panelGroup.PanelGroupManager;
+import org.gvsig.gui.beans.panelGroup.treePanel.TreePanel;
+import org.gvsig.tools.exception.BaseException;
+
+import org.gvsig.app.panelGroup.loaders.PanelGroupLoaderFromExtensionPoint;
+import org.gvsig.app.panelGroup.samples.Samples_ExtensionPointsOfIPanels;
+
+/**
+ * <p>Tests the creation of a {@link TreePanel TreePanel} object using {@link PanelGroupLoaderFromExtensionPoint PanelGroupLoaderFromExtensionPoint} .</p>
+ * 
+ * @version 17/10/2007
+ * @author Pablo Piqueras Bartolom� (pablo.piqueras@iver.es) 
+ */
+public class Test2TreePanel {
+	private static JFrame jFrame;
+	private static TreePanel panelGroup;
+	
+	/**
+	 * <p>Test method for the Test2TreePanel.</p>
+	 * 
+	 * @param args optional arguments
+	 */
+	public static void main(String[] args) {
+		try {
+			Samples_ExtensionPointsOfIPanels.loadSample();
+
+			PanelGroupManager manager = PanelGroupManager.getManager();
+			manager.registerPanelGroup(TreePanel.class);
+			manager.setDefaultType(TreePanel.class);
+
+			panelGroup = (TreePanel) manager.getPanelGroup(Samples_ExtensionPointsOfIPanels.REFERENCE2);
+			PanelGroupLoaderFromExtensionPoint loader = new PanelGroupLoaderFromExtensionPoint(Samples_ExtensionPointsOfIPanels.EXTENSIONPOINT2_NAME);
+
+			// Begin: Test the normal load
+			panelGroup.loadPanels(loader);
+			// End: Test the normal load
+
+			// Objects creation
+			jFrame = new JFrame();
+			jFrame.setTitle("Test TreePanel using PanelGroupLoaderFromExtensionPoint");
+		    jFrame.setDefaultCloseOperation(JFrame.EXIT_ON_CLOSE);
+		    jFrame.setSize(panelGroup.getPreferredSize());
+		    jFrame.getContentPane().add(panelGroup);
+		    
+			jFrame.setVisible(true);
+			
+		} catch (BaseException e) {
+			System.out.println(e.getLocalizedMessageStack());
+		} catch (Exception e) {
+			e.printStackTrace();
+		}
+	}
+}
Index: tags/v2_0_0_Build_2050/applications/appgvSIG/src-test/org/gvsig/app/panelGroup/Test3ButtonsPanel.java
===================================================================
--- tags/v2_0_0_Build_2050/applications/appgvSIG/src-test/org/gvsig/app/panelGroup/Test3ButtonsPanel.java	(revision 0)
+++ tags/v2_0_0_Build_2050/applications/appgvSIG/src-test/org/gvsig/app/panelGroup/Test3ButtonsPanel.java	(revision 38653)
@@ -0,0 +1,117 @@
+/* gvSIG. Sistema de Informaci�n Geogr�fica de la Generalitat Valenciana
+ *
+ * Copyright (C) 2007 IVER T.I. and Generalitat Valenciana.
+ *
+ * This program is free software; you can redistribute it and/or
+ * modify it under the terms of the GNU General Public License
+ * as published by the Free Software Foundation; either version 2
+ * of the License, or (at your option) any later version.
+ *
+ * This program is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
+ * GNU General Public License for more details.
+ *
+ * You should have received a copy of the GNU General Public License
+ * along with this program; if not, write to the Free Software
+ * Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA  02111-1307,USA.
+ */
+
+package org.gvsig.app.panelGroup;
+
+import javax.swing.JFrame;
+
+import org.gvsig.gui.beans.buttonspanel.ButtonsPanel;
+import org.gvsig.gui.beans.buttonspanel.ButtonsPanelEvent;
+import org.gvsig.gui.beans.buttonspanel.ButtonsPanelListener;
+import org.gvsig.gui.beans.panelGroup.PanelGroupManager;
+import org.gvsig.gui.beans.panelGroup.loaders.PanelGroupLoaderFromList;
+import org.gvsig.gui.beans.panelGroup.treePanel.TreePanel;
+import org.gvsig.tools.exception.BaseException;
+
+import org.gvsig.andami.ui.mdiManager.WindowInfo;
+import org.gvsig.app.panelGroup.samples.Samples_ExtensionPointsOfIPanels;
+
+/** 
+ * <p>Tests {@link PanelGroupDialog PanelGroupDialog}.</p>
+ * <p>Tests {@link PanelGroupManager PanelGroupManager}, {@link PanelGroupLoaderFromList PanelGroupLoaderFromList}, 
+ *  {@link TreePanel TreePanel}, and a resizable {@link PanelGroupDialog PanelGroupDialog}.</p>
+ * 
+ * @version 22/10/2007
+ * @author Pablo Piqueras Bartolom� (pablo.piqueras@iver.es) 
+ */
+public class Test3ButtonsPanel {
+	/**
+	 * <p>Element for the interface.</p>
+	 */
+	private static JFrame jFrame;
+	private static TreePanel panelGroup;
+
+	/**
+	 * <p>Test method for the Test3ButtonsPanel.</p>
+	 * 
+	 * @param args optional arguments
+	 */
+	public static void main(String[] args) {
+		try {
+			// Objects creation
+			jFrame = new JFrame();
+
+			PanelGroupManager manager = PanelGroupManager.getManager();
+			manager.registerPanelGroup(TreePanel.class);
+			manager.setDefaultType(TreePanel.class);
+
+			panelGroup = (TreePanel) manager.getPanelGroup(Samples_ExtensionPointsOfIPanels.REFERENCE1);
+			
+			PanelGroupLoaderFromList loader = new PanelGroupLoaderFromList(Samples_ExtensionPointsOfIPanels.EXTENSIONPOINTS1_CLASSES);
+
+			// Creates the IWindow
+			PanelGroupDialog panelGroupDialog = new PanelGroupDialog(Samples_ExtensionPointsOfIPanels.REFERENCE1_NAME, "Panel with Buttons", 800, 650, (byte)WindowInfo.RESIZABLE, panelGroup);
+			
+			// Begin: Test the normal load
+			panelGroupDialog.loadPanels(loader);
+			// End: Test the normal load
+
+			panelGroupDialog.addButtonPressedListener(new ButtonsPanelListener() {
+				/*
+				 * @see org.gvsig.gui.beans.buttonspanel.ButtonsPanelListener#actionButtonPressed(org.gvsig.gui.beans.buttonspanel.ButtonsPanelEvent)
+				 */
+				public void actionButtonPressed(ButtonsPanelEvent e) {
+					switch (e.getButton()) {
+						case ButtonsPanel.BUTTON_ACCEPT:
+							System.out.println("Accept Button pressed.");
+							hideJFrame();
+							System.exit(0);
+							break;
+						case ButtonsPanel.BUTTON_CANCEL:
+							System.out.println("Cancel Button pressed.");
+							hideJFrame();
+							System.exit(0);
+							break;
+						case ButtonsPanel.BUTTON_APPLY:
+							System.out.println("Apply Button pressed.");
+							break;
+					}
+				}
+			});
+			
+			jFrame.setTitle("Test resizable PanelGroupDialog with tree and using PanelGroupLoaderFromList");
+		    jFrame.setDefaultCloseOperation(JFrame.EXIT_ON_CLOSE);
+		    jFrame.setSize(panelGroupDialog.getPreferredSize());
+		    jFrame.getContentPane().add(panelGroupDialog);
+		    
+			jFrame.setVisible(true);			
+		} catch (BaseException bE) {
+			System.out.println(bE.getLocalizedMessageStack());
+		} catch (Exception e) {
+			e.printStackTrace();
+		}
+	}
+	
+	/**
+	 * <p>Hides the {@link JFrame JFrame}, hiding the graphical interface.</p>
+	 */
+	private static void hideJFrame() {
+		jFrame.setVisible(false);
+	}
+}
Index: tags/v2_0_0_Build_2050/applications/appgvSIG/src-test/org/gvsig/app/panelGroup/Test1ButtonsPanelWithExceptionsMessage.java
===================================================================
--- tags/v2_0_0_Build_2050/applications/appgvSIG/src-test/org/gvsig/app/panelGroup/Test1ButtonsPanelWithExceptionsMessage.java	(revision 0)
+++ tags/v2_0_0_Build_2050/applications/appgvSIG/src-test/org/gvsig/app/panelGroup/Test1ButtonsPanelWithExceptionsMessage.java	(revision 38653)
@@ -0,0 +1,127 @@
+/* gvSIG. Sistema de Informaci�n Geogr�fica de la Generalitat Valenciana
+ *
+ * Copyright (C) 2007 IVER T.I. and Generalitat Valenciana.
+ *
+ * This program is free software; you can redistribute it and/or
+ * modify it under the terms of the GNU General Public License
+ * as published by the Free Software Foundation; either version 2
+ * of the License, or (at your option) any later version.
+ *
+ * This program is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
+ * GNU General Public License for more details.
+ *
+ * You should have received a copy of the GNU General Public License
+ * along with this program; if not, write to the Free Software
+ * Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA  02111-1307,USA.
+ */
+
+package org.gvsig.app.panelGroup;
+
+import javax.swing.JFrame;
+
+import org.gvsig.gui.beans.buttonspanel.ButtonsPanel;
+import org.gvsig.gui.beans.buttonspanel.ButtonsPanelEvent;
+import org.gvsig.gui.beans.buttonspanel.ButtonsPanelListener;
+import org.gvsig.gui.beans.panelGroup.PanelGroupManager;
+import org.gvsig.gui.beans.panelGroup.loaders.PanelGroupLoaderFromList;
+import org.gvsig.gui.beans.panelGroup.tabbedPanel.TabbedPanel;
+import org.gvsig.tools.exception.BaseException;
+
+import org.gvsig.andami.ui.mdiManager.WindowInfo;
+import org.gvsig.app.panelGroup.samples.Samples_ExtensionPointsOfIPanels;
+
+/**
+ * <p>
+ * Test method for the Test1ButtonsPanelWithExceptionsMessage.
+ * </p>
+ * <p>
+ * Tests the message dialog caused by the exceptions produced during the loading
+ * of panels, using {@link PanelGroupManager PanelGroupManager},
+ * {@link PanelGroupLoaderFromList PanelGroupLoaderFromList},
+ * {@link TabbedPanel TabbedPanel}, and a resizable {@link PanelGroupDialog
+ * PanelGroupDialog}.
+ * </p>
+ * 
+ * @version 17/12/2007
+ * @author Pablo Piqueras Bartolom� (pablo.piqueras@iver.es)
+ */
+public class Test1ButtonsPanelWithExceptionsMessage {
+	/**
+	 * <p>Element for the interface.</p>
+	 */
+	private static JFrame jFrame;
+
+	/**
+	 * <p>
+	 * Test method for the Test1ButtonsPanelWithExceptionsMessage.
+	 * </p>
+	 * 
+	 * @param args
+	 *            optional arguments
+	 */
+	public static void main(String[] args) {
+		try {
+			// Objects creation
+			jFrame = new JFrame();
+
+			PanelGroupManager manager = PanelGroupManager.getManager();
+			manager.registerPanelGroup(TabbedPanel.class);
+			manager.setDefaultType(TabbedPanel.class);
+
+			TabbedPanel panelGroup = (TabbedPanel) manager.getPanelGroup(Samples_ExtensionPointsOfIPanels.REFERENCE3);
+
+			PanelGroupLoaderFromList loader = new PanelGroupLoaderFromList(Samples_ExtensionPointsOfIPanels.EXTENSIONPOINTS10_CLASSES);
+
+			// Creates the IWindow
+			PanelGroupDialog panelGroupDialog = new PanelGroupDialog(Samples_ExtensionPointsOfIPanels.REFERENCE3_NAME, "Panels with Buttons", 800, 650, (byte)WindowInfo.RESIZABLE, panelGroup);
+
+			// Begin: Test the normal load
+			panelGroupDialog.loadPanels(loader);
+			// End: Test the normal load
+
+			panelGroupDialog.addButtonPressedListener(new ButtonsPanelListener() {
+				/*
+				 * @see org.gvsig.gui.beans.buttonspanel.ButtonsPanelListener#actionButtonPressed(org.gvsig.gui.beans.buttonspanel.ButtonsPanelEvent)
+				 */
+				public void actionButtonPressed(ButtonsPanelEvent e) {
+					switch (e.getButton()) {
+						case ButtonsPanel.BUTTON_ACCEPT:
+							System.out.println("Accept Button pressed.");
+							hideJFrame();
+							System.exit(0);
+							break;
+						case ButtonsPanel.BUTTON_CANCEL:
+							System.out.println("Cancel Button pressed.");
+							hideJFrame();
+							System.exit(0);
+							break;
+						case ButtonsPanel.BUTTON_APPLY:
+							System.out.println("Apply Button pressed.");
+							break;
+					}
+				}
+			});
+
+			jFrame.setTitle("Test resizable PanelGroupDialog with tabs and using PanelGroupLoaderFromList");
+		    jFrame.setDefaultCloseOperation(JFrame.EXIT_ON_CLOSE);
+		    jFrame.setSize(panelGroupDialog.getPreferredSize());
+		    jFrame.getContentPane().add(panelGroupDialog);
+
+			jFrame.setVisible(true);
+
+		} catch (BaseException bE) {
+			System.out.println(bE.getLocalizedMessageStack());
+		} catch (Exception e) {
+			e.printStackTrace();
+		}
+	}
+
+	/**
+	 * <p>Hides the {@link JFrame JFrame}, hiding the graphical interface.</p>
+	 */
+	private static void hideJFrame() {
+		jFrame.setVisible(false);
+	}
+}
Index: tags/v2_0_0_Build_2050/applications/appgvSIG/src-test/org/gvsig/app/panelGroup/Test4ButtonsPanel.java
===================================================================
--- tags/v2_0_0_Build_2050/applications/appgvSIG/src-test/org/gvsig/app/panelGroup/Test4ButtonsPanel.java	(revision 0)
+++ tags/v2_0_0_Build_2050/applications/appgvSIG/src-test/org/gvsig/app/panelGroup/Test4ButtonsPanel.java	(revision 38653)
@@ -0,0 +1,121 @@
+/* gvSIG. Sistema de Informaci�n Geogr�fica de la Generalitat Valenciana
+ *
+ * Copyright (C) 2007 IVER T.I. and Generalitat Valenciana.
+ *
+ * This program is free software; you can redistribute it and/or
+ * modify it under the terms of the GNU General Public License
+ * as published by the Free Software Foundation; either version 2
+ * of the License, or (at your option) any later version.
+ *
+ * This program is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
+ * GNU General Public License for more details.
+ *
+ * You should have received a copy of the GNU General Public License
+ * along with this program; if not, write to the Free Software
+ * Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA  02111-1307,USA.
+ */
+
+package org.gvsig.app.panelGroup;
+
+import javax.swing.JFrame;
+
+import org.gvsig.gui.beans.buttonspanel.ButtonsPanel;
+import org.gvsig.gui.beans.buttonspanel.ButtonsPanelEvent;
+import org.gvsig.gui.beans.buttonspanel.ButtonsPanelListener;
+import org.gvsig.gui.beans.panelGroup.PanelGroupManager;
+import org.gvsig.gui.beans.panelGroup.treePanel.TreePanel;
+import org.gvsig.tools.exception.BaseException;
+
+import org.gvsig.andami.ui.mdiManager.WindowInfo;
+import org.gvsig.app.panelGroup.loaders.PanelGroupLoaderFromExtensionPoint;
+import org.gvsig.app.panelGroup.samples.Samples_ExtensionPointsOfIPanels;
+
+/**
+ * <p>Tests {@link PanelGroupDialog PanelGroupDialog}.</p>
+ * <p>Tests {@link PanelGroupManager PanelGroupManager}, {@link PanelGroupLoaderFromExtensionPoint PanelGroupLoaderFromExtensionPoint}, 
+ *  {@link TreePanel TreePanel}, and a resizable {@link PanelGroupDialog PanelGroupDialog}.</p>
+ * 
+ * @version 22/10/2007
+ * @author Pablo Piqueras Bartolom� (pablo.piqueras@iver.es) 
+ */
+public class Test4ButtonsPanel {
+	/**
+	 * <p>Element for the interface.</p>
+	 */
+	private static JFrame jFrame;
+	private static TreePanel panelGroup;
+
+	/**
+	 * <p>Test method for the Test4ButtonsPanel.</p>
+	 * <p>Tests {@link PanelGroupManager PanelGroupManager}, {@link PanelGroupLoaderFromExtensionPoint PanelGroupLoaderFromExtensionPoint}, 
+	 *  {@link TreePanel TreePanel}, and a resizable {@link PanelGroupDialog PanelGroupDialog}.</p>
+	 * 
+	 * @param args optional arguments
+	 */
+	public static void main(String[] args) {
+		try {
+			// Objects creation
+			jFrame = new JFrame();
+
+			Samples_ExtensionPointsOfIPanels.loadSample();
+
+			PanelGroupManager manager = PanelGroupManager.getManager();
+			manager.registerPanelGroup(TreePanel.class);
+			manager.setDefaultType(TreePanel.class);
+
+			panelGroup = (TreePanel) manager.getPanelGroup(Samples_ExtensionPointsOfIPanels.REFERENCE1);
+
+			PanelGroupLoaderFromExtensionPoint loader = new PanelGroupLoaderFromExtensionPoint(Samples_ExtensionPointsOfIPanels.EXTENSIONPOINT1_NAME);
+			
+			// Creates the IWindow
+			PanelGroupDialog panelGroupDialog = new PanelGroupDialog(Samples_ExtensionPointsOfIPanels.REFERENCE1_NAME, "Panel with Buttons", 150, 150, (byte)WindowInfo.RESIZABLE, panelGroup);
+
+			// Begin: Test the normal load
+			panelGroupDialog.loadPanels(loader);
+			// End: Test the normal load
+			
+			panelGroupDialog.addButtonPressedListener(new ButtonsPanelListener() {
+				/*
+				 * @see org.gvsig.gui.beans.buttonspanel.ButtonsPanelListener#actionButtonPressed(org.gvsig.gui.beans.buttonspanel.ButtonsPanelEvent)
+				 */
+				public void actionButtonPressed(ButtonsPanelEvent e) {
+					switch (e.getButton()) {
+						case ButtonsPanel.BUTTON_ACCEPT:
+							System.out.println("Accept Button pressed.");
+							hideJFrame();
+							System.exit(0);
+							break;
+						case ButtonsPanel.BUTTON_CANCEL:
+							System.out.println("Cancel Button pressed.");
+							hideJFrame();
+							System.exit(0);
+							break;
+						case ButtonsPanel.BUTTON_APPLY:
+							System.out.println("Apply Button pressed.");
+							break;
+					}
+				}
+			});
+
+			jFrame.setTitle("Test resizable PanelGroupDialog with tree and using PanelGroupLoaderFromExtensionPoint");
+		    jFrame.setDefaultCloseOperation(JFrame.EXIT_ON_CLOSE);
+		    jFrame.setSize(panelGroupDialog.getPreferredSize());
+		    jFrame.getContentPane().add(panelGroupDialog);
+		    
+			jFrame.setVisible(true);	
+		} catch (BaseException bE) {
+			System.out.println(bE.getLocalizedMessageStack());
+		} catch (Exception e) {
+			e.printStackTrace();
+		}
+	}
+	
+	/**
+	 * <p>Hides the {@link JFrame JFrame}, hiding the graphical interface.</p>
+	 */
+	private static void hideJFrame() {
+		jFrame.setVisible(false);
+	}
+}
Index: tags/v2_0_0_Build_2050/applications/appgvSIG/src-test/org/gvsig/app/panelGroup/Test2ButtonsPanelWithExceptionsMessage.java
===================================================================
--- tags/v2_0_0_Build_2050/applications/appgvSIG/src-test/org/gvsig/app/panelGroup/Test2ButtonsPanelWithExceptionsMessage.java	(revision 0)
+++ tags/v2_0_0_Build_2050/applications/appgvSIG/src-test/org/gvsig/app/panelGroup/Test2ButtonsPanelWithExceptionsMessage.java	(revision 38653)
@@ -0,0 +1,119 @@
+/* gvSIG. Sistema de Informaci�n Geogr�fica de la Generalitat Valenciana
+ *
+ * Copyright (C) 2007 IVER T.I. and Generalitat Valenciana.
+ *
+ * This program is free software; you can redistribute it and/or
+ * modify it under the terms of the GNU General Public License
+ * as published by the Free Software Foundation; either version 2
+ * of the License, or (at your option) any later version.
+ *
+ * This program is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
+ * GNU General Public License for more details.
+ *
+ * You should have received a copy of the GNU General Public License
+ * along with this program; if not, write to the Free Software
+ * Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA  02111-1307,USA.
+ */
+
+package org.gvsig.app.panelGroup;
+
+import javax.swing.JFrame;
+
+import org.gvsig.gui.beans.buttonspanel.ButtonsPanel;
+import org.gvsig.gui.beans.buttonspanel.ButtonsPanelEvent;
+import org.gvsig.gui.beans.buttonspanel.ButtonsPanelListener;
+import org.gvsig.gui.beans.panelGroup.PanelGroupManager;
+import org.gvsig.gui.beans.panelGroup.tabbedPanel.TabbedPanel;
+import org.gvsig.tools.exception.BaseException;
+
+import org.gvsig.andami.ui.mdiManager.WindowInfo;
+import org.gvsig.app.panelGroup.loaders.PanelGroupLoaderFromExtensionPoint;
+import org.gvsig.app.panelGroup.samples.Samples_ExtensionPointsOfIPanels;
+
+/**
+ * <p>Test method for the Test2ButtonsPanelWithExceptionsMessage.</p>
+ * <p>Tests the message dialog caused by the exceptions produced during the loading of panels, using {@link PanelGroupManager PanelGroupManager},
+ *  {@link PanelGroupLoaderFromExtensionPoint PanelGroupLoaderFromExtensionPoint}, {@link TabbedPanel TabbedPanel}, and a resizable {@link PanelGroupDialog PanelGroupDialog}.</p>
+ * 
+ * @version 17/12/2007
+ * @author Pablo Piqueras Bartolom� (pablo.piqueras@iver.es) 
+ */
+public class Test2ButtonsPanelWithExceptionsMessage {
+	/**
+	 * <p>Element for the interface.</p>
+	 */
+	private static JFrame jFrame;
+
+	/**
+	 * <p>Test method for the Test2ButtonsPanelWithExceptionsMessage.</p>
+	 * 
+	 * @param args optional arguments
+	 */
+	public static void main(String[] args) {
+		try {
+			// Objects creation
+			jFrame = new JFrame();
+
+			Samples_ExtensionPointsOfIPanels.loadSample();
+
+			PanelGroupManager manager = PanelGroupManager.getManager();
+			manager.registerPanelGroup(TabbedPanel.class);
+			manager.setDefaultType(TabbedPanel.class);
+
+			TabbedPanel panelGroup = (TabbedPanel) manager.getPanelGroup(Samples_ExtensionPointsOfIPanels.REFERENCE3);
+
+			PanelGroupLoaderFromExtensionPoint loader = new PanelGroupLoaderFromExtensionPoint(Samples_ExtensionPointsOfIPanels.EXTENSIONPOINT10_NAME);
+
+			// Creates the IWindow
+			PanelGroupDialog panelGroupDialog = new PanelGroupDialog(Samples_ExtensionPointsOfIPanels.REFERENCE3_NAME, "Panels with Buttons", 800, 650, (byte)WindowInfo.RESIZABLE, panelGroup);
+			
+			// Begin: Test the normal load
+			panelGroupDialog.loadPanels(loader);
+			// End: Test the normal load
+
+			panelGroupDialog.addButtonPressedListener(new ButtonsPanelListener() {
+				/*
+				 * @see org.gvsig.gui.beans.buttonspanel.ButtonsPanelListener#actionButtonPressed(org.gvsig.gui.beans.buttonspanel.ButtonsPanelEvent)
+				 */
+				public void actionButtonPressed(ButtonsPanelEvent e) {
+					switch (e.getButton()) {
+						case ButtonsPanel.BUTTON_ACCEPT:
+							System.out.println("Accept Button pressed.");
+							hideJFrame();
+							System.exit(0);
+							break;
+						case ButtonsPanel.BUTTON_CANCEL:
+							System.out.println("Cancel Button pressed.");
+							hideJFrame();
+							System.exit(0);
+							break;
+						case ButtonsPanel.BUTTON_APPLY:
+							System.out.println("Apply Button pressed.");
+							break;
+					}
+				}
+			});
+
+			jFrame.setTitle("Test resizable PanelGroupDialog with tabs and using PanelGroupLoaderFromExtensionPoint");
+		    jFrame.setDefaultCloseOperation(JFrame.EXIT_ON_CLOSE);
+		    jFrame.setSize(panelGroupDialog.getPreferredSize());
+		    jFrame.getContentPane().add(panelGroupDialog);
+		    
+			jFrame.setVisible(true);
+			
+		} catch (BaseException bE) {
+			System.out.println(bE.getLocalizedMessageStack());
+		} catch (Exception e) {
+			e.printStackTrace();
+		}
+	}
+	
+	/**
+	 * <p>Hides the {@link JFrame JFrame}, hiding the graphical interface.</p>
+	 */
+	private static void hideJFrame() {
+		jFrame.setVisible(false);
+	}
+}
Index: tags/v2_0_0_Build_2050/applications/appgvSIG/src-test/org/gvsig/app/panelGroup/Test5ButtonsPanel.java
===================================================================
--- tags/v2_0_0_Build_2050/applications/appgvSIG/src-test/org/gvsig/app/panelGroup/Test5ButtonsPanel.java	(revision 0)
+++ tags/v2_0_0_Build_2050/applications/appgvSIG/src-test/org/gvsig/app/panelGroup/Test5ButtonsPanel.java	(revision 38653)
@@ -0,0 +1,117 @@
+/* gvSIG. Sistema de Informaci�n Geogr�fica de la Generalitat Valenciana
+ *
+ * Copyright (C) 2007 IVER T.I. and Generalitat Valenciana.
+ *
+ * This program is free software; you can redistribute it and/or
+ * modify it under the terms of the GNU General Public License
+ * as published by the Free Software Foundation; either version 2
+ * of the License, or (at your option) any later version.
+ *
+ * This program is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
+ * GNU General Public License for more details.
+ *
+ * You should have received a copy of the GNU General Public License
+ * along with this program; if not, write to the Free Software
+ * Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA  02111-1307,USA.
+ */
+
+package org.gvsig.app.panelGroup;
+
+import javax.swing.JFrame;
+
+import org.gvsig.gui.beans.buttonspanel.ButtonsPanel;
+import org.gvsig.gui.beans.buttonspanel.ButtonsPanelEvent;
+import org.gvsig.gui.beans.buttonspanel.ButtonsPanelListener;
+import org.gvsig.gui.beans.panelGroup.PanelGroupManager;
+import org.gvsig.gui.beans.panelGroup.loaders.PanelGroupLoaderFromList;
+import org.gvsig.gui.beans.panelGroup.tabbedPanel.TabbedPanel;
+import org.gvsig.tools.exception.BaseException;
+
+import org.gvsig.app.panelGroup.samples.Samples_ExtensionPointsOfIPanels;
+
+/**
+ * <p>Tests {@link PanelGroupDialog PanelGroupDialog}.</p>
+ * <p>Tests {@link PanelGroupManager PanelGroupManager}, {@link PanelGroupLoaderFromList PanelGroupLoaderFromList}, 
+ *  {@link TabbedPanel TabbedPanel}, and a non resizable {@link PanelGroupDialog PanelGroupDialog}.</p>
+ * 
+ * @version 19/10/2007
+ * @author Pablo Piqueras Bartolom� (pablo.piqueras@iver.es) 
+ */
+public class Test5ButtonsPanel {
+	/**
+	 * <p>Element for the interface.</p>
+	 */
+	private static JFrame jFrame;
+
+	/**
+	 * <p>Test method for the Test5ButtonsPanel.</p>
+	 * 
+	 * @param args optional arguments
+	 */
+	public static void main(String[] args) {
+		try {
+			// Objects creation
+			jFrame = new JFrame();
+
+			PanelGroupManager manager = PanelGroupManager.getManager();
+			manager.registerPanelGroup(TabbedPanel.class);
+			manager.setDefaultType(TabbedPanel.class);
+
+			TabbedPanel panelGroup = (TabbedPanel) manager.getPanelGroup(Samples_ExtensionPointsOfIPanels.REFERENCE1);
+			
+			PanelGroupLoaderFromList loader = new PanelGroupLoaderFromList(Samples_ExtensionPointsOfIPanels.EXTENSIONPOINTS1_CLASSES);
+			
+			// Creates the IWindow
+			PanelGroupDialog panelGroupDialog = new PanelGroupDialog(Samples_ExtensionPointsOfIPanels.REFERENCE1_NAME, "Panel with Buttons", 800, 650, (byte)0, panelGroup);
+
+			// Begin: Test the normal load
+			panelGroupDialog.loadPanels(loader);
+			// End: Test the normal load
+			
+			panelGroupDialog.addButtonPressedListener(new ButtonsPanelListener() {
+				/*
+				 * @see org.gvsig.gui.beans.buttonspanel.ButtonsPanelListener#actionButtonPressed(org.gvsig.gui.beans.buttonspanel.ButtonsPanelEvent)
+				 */
+				public void actionButtonPressed(ButtonsPanelEvent e) {
+					switch (e.getButton()) {
+						case ButtonsPanel.BUTTON_ACCEPT:
+							System.out.println("Accept Button pressed.");
+							hideJFrame();
+							System.exit(0);
+							break;
+						case ButtonsPanel.BUTTON_CANCEL:
+							System.out.println("Cancel Button pressed.");
+							hideJFrame();
+							System.exit(0);
+							break;
+						case ButtonsPanel.BUTTON_APPLY:
+							System.out.println("Apply Button pressed.");
+							break;
+					}
+				}
+			});
+			
+			jFrame.setTitle("Test Non Resizable PanelGroupDialog with tabs and using PanelGroupLoaderFromList");
+		    jFrame.setDefaultCloseOperation(JFrame.EXIT_ON_CLOSE);
+		    jFrame.setSize(panelGroupDialog.getPreferredSize());
+		    jFrame.getContentPane().add(panelGroupDialog);
+		    
+		    jFrame.setResizable(false);
+			jFrame.setVisible(true);
+			
+		} catch (BaseException bE) {
+			System.out.println(bE.getLocalizedMessageStack());
+		} catch (Exception e) {
+			e.printStackTrace();
+		}
+	}
+
+	/**
+	 * <p>Hides the {@link JFrame JFrame}, hiding the graphical interface.</p>
+	 */
+	private static void hideJFrame() {
+		jFrame.setVisible(false);
+	}
+}
Index: tags/v2_0_0_Build_2050/applications/appgvSIG/src-test/org/gvsig/app/panelGroup/Test3ButtonsPanelWithExceptionsMessage.java
===================================================================
--- tags/v2_0_0_Build_2050/applications/appgvSIG/src-test/org/gvsig/app/panelGroup/Test3ButtonsPanelWithExceptionsMessage.java	(revision 0)
+++ tags/v2_0_0_Build_2050/applications/appgvSIG/src-test/org/gvsig/app/panelGroup/Test3ButtonsPanelWithExceptionsMessage.java	(revision 38653)
@@ -0,0 +1,117 @@
+/* gvSIG. Sistema de Informaci�n Geogr�fica de la Generalitat Valenciana
+ *
+ * Copyright (C) 2007 IVER T.I. and Generalitat Valenciana.
+ *
+ * This program is free software; you can redistribute it and/or
+ * modify it under the terms of the GNU General Public License
+ * as published by the Free Software Foundation; either version 2
+ * of the License, or (at your option) any later version.
+ *
+ * This program is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
+ * GNU General Public License for more details.
+ *
+ * You should have received a copy of the GNU General Public License
+ * along with this program; if not, write to the Free Software
+ * Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA  02111-1307,USA.
+ */
+
+package org.gvsig.app.panelGroup;
+
+import javax.swing.JFrame;
+
+import org.gvsig.gui.beans.buttonspanel.ButtonsPanel;
+import org.gvsig.gui.beans.buttonspanel.ButtonsPanelEvent;
+import org.gvsig.gui.beans.buttonspanel.ButtonsPanelListener;
+import org.gvsig.gui.beans.panelGroup.PanelGroupManager;
+import org.gvsig.gui.beans.panelGroup.loaders.PanelGroupLoaderFromList;
+import org.gvsig.gui.beans.panelGroup.treePanel.TreePanel;
+import org.gvsig.tools.exception.BaseException;
+
+import org.gvsig.andami.ui.mdiManager.WindowInfo;
+import org.gvsig.app.panelGroup.samples.Samples_ExtensionPointsOfIPanels;
+
+/**
+ * <p>Test method for the Test1ButtonsPanelWithExceptionsMessage.</p>
+ * <p>Tests the message dialog caused by the exceptions produced during the loading of panels, using {@link PanelGroupManager PanelGroupManager},
+ *  {@link PanelGroupLoaderFromList PanelGroupLoaderFromList}, {@link TreePanel TreePanel}, and a resizable {@link PanelGroupDialog PanelGroupDialog}.</p>
+ * 
+ * @version 17/12/2007
+ * @author Pablo Piqueras Bartolom� (pablo.piqueras@iver.es) 
+ */
+public class Test3ButtonsPanelWithExceptionsMessage {
+	/**
+	 * <p>Element for the interface.</p>
+	 */
+	private static JFrame jFrame;
+	private static TreePanel panelGroup;
+
+	/**
+	 * <p>Test method for the Test3ButtonsPanelWithExceptionsMessage.</p>
+	 * 
+	 * @param args optional arguments
+	 */
+	public static void main(String[] args) {
+		try {
+			// Objects creation
+			jFrame = new JFrame();
+
+			PanelGroupManager manager = PanelGroupManager.getManager();
+			manager.registerPanelGroup(TreePanel.class);
+			manager.setDefaultType(TreePanel.class);
+
+			panelGroup = (TreePanel) manager.getPanelGroup(Samples_ExtensionPointsOfIPanels.REFERENCE3);
+			
+			PanelGroupLoaderFromList loader = new PanelGroupLoaderFromList(Samples_ExtensionPointsOfIPanels.EXTENSIONPOINTS10_CLASSES);
+
+			// Creates the IWindow
+			PanelGroupDialog panelGroupDialog = new PanelGroupDialog(Samples_ExtensionPointsOfIPanels.REFERENCE3_NAME, "Panel with Buttons", 800, 650, (byte)WindowInfo.RESIZABLE, panelGroup);
+			
+			// Begin: Test the normal load
+			panelGroupDialog.loadPanels(loader);
+			// End: Test the normal load
+
+			panelGroupDialog.addButtonPressedListener(new ButtonsPanelListener() {
+				/*
+				 * @see org.gvsig.gui.beans.buttonspanel.ButtonsPanelListener#actionButtonPressed(org.gvsig.gui.beans.buttonspanel.ButtonsPanelEvent)
+				 */
+				public void actionButtonPressed(ButtonsPanelEvent e) {
+					switch (e.getButton()) {
+						case ButtonsPanel.BUTTON_ACCEPT:
+							System.out.println("Accept Button pressed.");
+							hideJFrame();
+							System.exit(0);
+							break;
+						case ButtonsPanel.BUTTON_CANCEL:
+							System.out.println("Cancel Button pressed.");
+							hideJFrame();
+							System.exit(0);
+							break;
+						case ButtonsPanel.BUTTON_APPLY:
+							System.out.println("Apply Button pressed.");
+							break;
+					}
+				}
+			});
+			
+			jFrame.setTitle("Test resizable PanelGroupDialog with tree and using PanelGroupLoaderFromList");
+		    jFrame.setDefaultCloseOperation(JFrame.EXIT_ON_CLOSE);
+		    jFrame.setSize(panelGroupDialog.getPreferredSize());
+		    jFrame.getContentPane().add(panelGroupDialog);
+		    
+			jFrame.setVisible(true);			
+		} catch (BaseException bE) {
+			System.out.println(bE.getLocalizedMessageStack());
+		} catch (Exception e) {
+			e.printStackTrace();
+		}
+	}
+	
+	/**
+	 * <p>Hides the {@link JFrame JFrame}, hiding the graphical interface.</p>
+	 */
+	private static void hideJFrame() {
+		jFrame.setVisible(false);
+	}
+}
Index: tags/v2_0_0_Build_2050/applications/appgvSIG/src-test/org/gvsig/app/panelGroup/Test6ButtonsPanel.java
===================================================================
--- tags/v2_0_0_Build_2050/applications/appgvSIG/src-test/org/gvsig/app/panelGroup/Test6ButtonsPanel.java	(revision 0)
+++ tags/v2_0_0_Build_2050/applications/appgvSIG/src-test/org/gvsig/app/panelGroup/Test6ButtonsPanel.java	(revision 38653)
@@ -0,0 +1,120 @@
+/* gvSIG. Sistema de Informaci�n Geogr�fica de la Generalitat Valenciana
+ *
+ * Copyright (C) 2007 IVER T.I. and Generalitat Valenciana.
+ *
+ * This program is free software; you can redistribute it and/or
+ * modify it under the terms of the GNU General Public License
+ * as published by the Free Software Foundation; either version 2
+ * of the License, or (at your option) any later version.
+ *
+ * This program is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
+ * GNU General Public License for more details.
+ *
+ * You should have received a copy of the GNU General Public License
+ * along with this program; if not, write to the Free Software
+ * Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA  02111-1307,USA.
+ */
+
+package org.gvsig.app.panelGroup;
+
+import javax.swing.JFrame;
+
+import org.gvsig.gui.beans.buttonspanel.ButtonsPanel;
+import org.gvsig.gui.beans.buttonspanel.ButtonsPanelEvent;
+import org.gvsig.gui.beans.buttonspanel.ButtonsPanelListener;
+import org.gvsig.gui.beans.panelGroup.PanelGroupManager;
+import org.gvsig.gui.beans.panelGroup.tabbedPanel.TabbedPanel;
+import org.gvsig.tools.exception.BaseException;
+
+import org.gvsig.andami.ui.mdiManager.WindowInfo;
+import org.gvsig.app.panelGroup.loaders.PanelGroupLoaderFromExtensionPoint;
+import org.gvsig.app.panelGroup.samples.Samples_ExtensionPointsOfIPanels;
+
+/**
+ * <p>Tests {@link PanelGroupDialog PanelGroupDialog}.</p>
+ * <p>Tests {@link PanelGroupManager PanelGroupManager}, {@link PanelGroupLoaderFromExtensionPoint PanelGroupLoaderFromExtensionPoint}, 
+ *  {@link TabbedPanel TabbedPanel}, and a non resizable {@link PanelGroupDialog PanelGroupDialog}.</p>
+ * 
+ * @version 22/10/2007
+ * @author Pablo Piqueras Bartolom� (pablo.piqueras@iver.es) 
+ */
+public class Test6ButtonsPanel {
+	/**
+	 * <p>Element for the interface.</p>
+	 */
+	private static JFrame jFrame;
+
+	/**
+	 * <p>Test method for the Test6ButtonsPanel.</p>
+	 * 
+	 * @param args optional arguments
+	 */
+	public static void main(String[] args) {
+		try {
+			// Objects creation
+			jFrame = new JFrame();
+
+			Samples_ExtensionPointsOfIPanels.loadSample();
+
+			PanelGroupManager manager = PanelGroupManager.getManager();
+			manager.registerPanelGroup(TabbedPanel.class);
+			manager.setDefaultType(TabbedPanel.class);
+
+			TabbedPanel panelGroup = (TabbedPanel) manager.getPanelGroup(Samples_ExtensionPointsOfIPanels.REFERENCE1);
+			
+			PanelGroupLoaderFromExtensionPoint loader = new PanelGroupLoaderFromExtensionPoint(Samples_ExtensionPointsOfIPanels.EXTENSIONPOINT1_NAME);
+			
+			// Creates the IWindow
+			PanelGroupDialog panelGroupDialog = new PanelGroupDialog(Samples_ExtensionPointsOfIPanels.REFERENCE1_NAME, "Panel with Buttons", 800, 650, (byte)WindowInfo.RESIZABLE, panelGroup);
+
+			// Begin: Test the normal load
+			panelGroupDialog.loadPanels(loader);
+			// End: Test the normal load
+			
+			panelGroupDialog.addButtonPressedListener(new ButtonsPanelListener() {
+				/*
+				 * @see org.gvsig.gui.beans.buttonspanel.ButtonsPanelListener#actionButtonPressed(org.gvsig.gui.beans.buttonspanel.ButtonsPanelEvent)
+				 */
+				public void actionButtonPressed(ButtonsPanelEvent e) {
+					switch (e.getButton()) {
+						case ButtonsPanel.BUTTON_ACCEPT:
+							System.out.println("Accept Button pressed.");
+							hideJFrame();
+							System.exit(0);
+							break;
+						case ButtonsPanel.BUTTON_CANCEL:
+							System.out.println("Cancel Button pressed.");
+							hideJFrame();
+							System.exit(0);
+							break;
+						case ButtonsPanel.BUTTON_APPLY:
+							System.out.println("Apply Button pressed.");
+							break;
+					}
+				}
+			});
+			
+			jFrame.setTitle("Test Non Resizable PanelGroupDialog with tabs and using PanelGroupLoaderFromExtensionPoint");
+		    jFrame.setDefaultCloseOperation(JFrame.EXIT_ON_CLOSE);
+		    jFrame.setSize(panelGroupDialog.getPreferredSize());
+		    jFrame.getContentPane().add(panelGroupDialog);
+		    
+		    jFrame.setResizable(false);
+			jFrame.setVisible(true);
+			
+		} catch (BaseException bE) {
+			System.out.println(bE.getLocalizedMessageStack());
+		} catch (Exception e) {
+			e.printStackTrace();
+		}
+	}
+
+	/**
+	 * <p>Hides the {@link JFrame JFrame}, hiding the graphical interface.</p>
+	 */
+	private static void hideJFrame() {
+		jFrame.setVisible(false);
+	}
+}
Index: tags/v2_0_0_Build_2050/applications/appgvSIG/src-test/org/gvsig/app/panelGroup/Test4ButtonsPanelWithExceptionsMessage.java
===================================================================
--- tags/v2_0_0_Build_2050/applications/appgvSIG/src-test/org/gvsig/app/panelGroup/Test4ButtonsPanelWithExceptionsMessage.java	(revision 0)
+++ tags/v2_0_0_Build_2050/applications/appgvSIG/src-test/org/gvsig/app/panelGroup/Test4ButtonsPanelWithExceptionsMessage.java	(revision 38653)
@@ -0,0 +1,119 @@
+/* gvSIG. Sistema de Informaci�n Geogr�fica de la Generalitat Valenciana
+ *
+ * Copyright (C) 2007 IVER T.I. and Generalitat Valenciana.
+ *
+ * This program is free software; you can redistribute it and/or
+ * modify it under the terms of the GNU General Public License
+ * as published by the Free Software Foundation; either version 2
+ * of the License, or (at your option) any later version.
+ *
+ * This program is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
+ * GNU General Public License for more details.
+ *
+ * You should have received a copy of the GNU General Public License
+ * along with this program; if not, write to the Free Software
+ * Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA  02111-1307,USA.
+ */
+
+package org.gvsig.app.panelGroup;
+
+import javax.swing.JFrame;
+
+import org.gvsig.gui.beans.buttonspanel.ButtonsPanel;
+import org.gvsig.gui.beans.buttonspanel.ButtonsPanelEvent;
+import org.gvsig.gui.beans.buttonspanel.ButtonsPanelListener;
+import org.gvsig.gui.beans.panelGroup.PanelGroupManager;
+import org.gvsig.gui.beans.panelGroup.treePanel.TreePanel;
+import org.gvsig.tools.exception.BaseException;
+
+import org.gvsig.andami.ui.mdiManager.WindowInfo;
+import org.gvsig.app.panelGroup.loaders.PanelGroupLoaderFromExtensionPoint;
+import org.gvsig.app.panelGroup.samples.Samples_ExtensionPointsOfIPanels;
+
+/**
+ * <p>Test method for the Test2ButtonsPanelWithExceptionsMessage.</p>
+ * <p>Tests the message dialog caused by the exceptions produced during the loading of panels, using {@link PanelGroupManager PanelGroupManager},
+ *  {@link PanelGroupLoaderFromExtensionPoint PanelGroupLoaderFromExtensionPoint}, {@link TreePanel TreePanel}, and a resizable {@link PanelGroupDialog PanelGroupDialog}.</p>
+ * 
+ * @version 17/12/2007
+ * @author Pablo Piqueras Bartolom� (pablo.piqueras@iver.es) 
+ */
+public class Test4ButtonsPanelWithExceptionsMessage {
+	/**
+	 * <p>Element for the interface.</p>
+	 */
+	private static JFrame jFrame;
+	private static TreePanel panelGroup;
+
+	/**
+	 * <p>Test method for the Test4ButtonsPanelWithExceptionsMessage.</p>
+	 * 
+	 * @param args optional arguments
+	 */
+	public static void main(String[] args) {
+		try {
+			// Objects creation
+			jFrame = new JFrame();
+
+			Samples_ExtensionPointsOfIPanels.loadSample();
+
+			PanelGroupManager manager = PanelGroupManager.getManager();
+			manager.registerPanelGroup(TreePanel.class);
+			manager.setDefaultType(TreePanel.class);
+
+			panelGroup = (TreePanel) manager.getPanelGroup(Samples_ExtensionPointsOfIPanels.REFERENCE3);
+
+			PanelGroupLoaderFromExtensionPoint loader = new PanelGroupLoaderFromExtensionPoint(Samples_ExtensionPointsOfIPanels.EXTENSIONPOINT10_NAME);
+			
+			// Creates the IWindow
+			PanelGroupDialog panelGroupDialog = new PanelGroupDialog(Samples_ExtensionPointsOfIPanels.REFERENCE3_NAME, "Panel with Buttons", 150, 150, (byte)WindowInfo.RESIZABLE, panelGroup);
+
+			// Begin: Test the normal load
+			panelGroupDialog.loadPanels(loader);
+			// End: Test the normal load
+			
+			panelGroupDialog.addButtonPressedListener(new ButtonsPanelListener() {
+				/*
+				 * @see org.gvsig.gui.beans.buttonspanel.ButtonsPanelListener#actionButtonPressed(org.gvsig.gui.beans.buttonspanel.ButtonsPanelEvent)
+				 */
+				public void actionButtonPressed(ButtonsPanelEvent e) {
+					switch (e.getButton()) {
+						case ButtonsPanel.BUTTON_ACCEPT:
+							System.out.println("Accept Button pressed.");
+							hideJFrame();
+							System.exit(0);
+							break;
+						case ButtonsPanel.BUTTON_CANCEL:
+							System.out.println("Cancel Button pressed.");
+							hideJFrame();
+							System.exit(0);
+							break;
+						case ButtonsPanel.BUTTON_APPLY:
+							System.out.println("Apply Button pressed.");
+							break;
+					}
+				}
+			});
+
+			jFrame.setTitle("Test resizable PanelGroupDialog with tree and using PanelGroupLoaderFromExtensionPoint");
+		    jFrame.setDefaultCloseOperation(JFrame.EXIT_ON_CLOSE);
+		    jFrame.setSize(panelGroupDialog.getPreferredSize());
+		    jFrame.getContentPane().add(panelGroupDialog);
+		    
+			jFrame.setVisible(true);	
+		} catch (BaseException bE) {
+			System.out.println(bE.getLocalizedMessageStack());
+		} catch (Exception e) {
+			e.printStackTrace();
+		}
+	}
+	
+	/**
+	 * <p>Hides the {@link JFrame JFrame}, hiding the graphical interface.</p>
+	 */
+	private static void hideJFrame() {
+		jFrame.setVisible(false);
+	}
+}
Index: tags/v2_0_0_Build_2050/applications/appgvSIG/src-test/org/gvsig/app/panelGroup/Test7ButtonsPanel.java
===================================================================
--- tags/v2_0_0_Build_2050/applications/appgvSIG/src-test/org/gvsig/app/panelGroup/Test7ButtonsPanel.java	(revision 0)
+++ tags/v2_0_0_Build_2050/applications/appgvSIG/src-test/org/gvsig/app/panelGroup/Test7ButtonsPanel.java	(revision 38653)
@@ -0,0 +1,116 @@
+/* gvSIG. Sistema de Informaci�n Geogr�fica de la Generalitat Valenciana
+ *
+ * Copyright (C) 2007 IVER T.I. and Generalitat Valenciana.
+ *
+ * This program is free software; you can redistribute it and/or
+ * modify it under the terms of the GNU General Public License
+ * as published by the Free Software Foundation; either version 2
+ * of the License, or (at your option) any later version.
+ *
+ * This program is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
+ * GNU General Public License for more details.
+ *
+ * You should have received a copy of the GNU General Public License
+ * along with this program; if not, write to the Free Software
+ * Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA  02111-1307,USA.
+ */
+
+package org.gvsig.app.panelGroup;
+
+import javax.swing.JFrame;
+
+import org.gvsig.gui.beans.buttonspanel.ButtonsPanel;
+import org.gvsig.gui.beans.buttonspanel.ButtonsPanelEvent;
+import org.gvsig.gui.beans.buttonspanel.ButtonsPanelListener;
+import org.gvsig.gui.beans.panelGroup.PanelGroupManager;
+import org.gvsig.gui.beans.panelGroup.loaders.PanelGroupLoaderFromList;
+import org.gvsig.gui.beans.panelGroup.treePanel.TreePanel;
+import org.gvsig.tools.exception.BaseException;
+
+import org.gvsig.app.panelGroup.samples.Samples_ExtensionPointsOfIPanels;
+
+/**
+ * <p>Tests {@link PanelGroupDialog PanelGroupDialog}.</p>
+ * <p>Tests {@link PanelGroupManager PanelGroupManager}, {@link PanelGroupLoaderFromList PanelGroupLoaderFromList}, 
+ *  {@link TreePanel TreePanel}, and a non resizable {@link PanelGroupDialog PanelGroupDialog}.</p>
+ * 
+ * @version 22/10/2007
+ * @author Pablo Piqueras Bartolom� (pablo.piqueras@iver.es) 
+ */
+public class Test7ButtonsPanel {
+	/**
+	 * <p>Element for the interface.</p>
+	 */
+	private static JFrame jFrame;
+	private static TreePanel panelGroup;
+
+	/**
+	 * <p>Test method for the Test7ButtonsPanel.</p>
+	 * 
+	 * @param args optional arguments
+	 */
+	public static void main(String[] args) {
+		try {
+			jFrame = new JFrame();
+
+			PanelGroupManager manager = PanelGroupManager.getManager();
+			manager.registerPanelGroup(TreePanel.class);
+			manager.setDefaultType(TreePanel.class);
+
+			panelGroup = (TreePanel) manager.getPanelGroup(Samples_ExtensionPointsOfIPanels.REFERENCE1);
+			
+			PanelGroupLoaderFromList loader = new PanelGroupLoaderFromList(Samples_ExtensionPointsOfIPanels.EXTENSIONPOINTS1_CLASSES);
+			
+			// Creates the IWindow
+			PanelGroupDialog panelGroupDialog = new PanelGroupDialog(Samples_ExtensionPointsOfIPanels.REFERENCE1_NAME, "Panel with Buttons", 800, 650, (byte)0, panelGroup);
+
+			// Begin: Test the normal load
+			panelGroupDialog.loadPanels(loader);
+			// End: Test the normal load
+
+			panelGroupDialog.addButtonPressedListener(new ButtonsPanelListener() {
+				/*
+				 * @see org.gvsig.gui.beans.buttonspanel.ButtonsPanelListener#actionButtonPressed(org.gvsig.gui.beans.buttonspanel.ButtonsPanelEvent)
+				 */
+				public void actionButtonPressed(ButtonsPanelEvent e) {
+					switch (e.getButton()) {
+						case ButtonsPanel.BUTTON_ACCEPT:
+							System.out.println("Accept Button pressed.");
+							hideJFrame();
+							System.exit(0);
+							break;
+						case ButtonsPanel.BUTTON_CANCEL:
+							System.out.println("Cancel Button pressed.");
+							hideJFrame();
+							System.exit(0);
+							break;
+						case ButtonsPanel.BUTTON_APPLY:
+							System.out.println("Apply Button pressed.");
+							break;
+					}
+				}
+			});
+
+			jFrame.setTitle("Test non resizable PanelGroupDialog with a tree and using PanelGroupLoaderFromList");
+		    jFrame.setDefaultCloseOperation(JFrame.EXIT_ON_CLOSE);
+		    jFrame.setSize(panelGroupDialog.getPreferredSize());
+		    jFrame.getContentPane().add(panelGroupDialog);
+		    
+		    jFrame.setResizable(false);
+			jFrame.setVisible(true);
+		} catch (BaseException bE) {
+			System.out.println(bE.getLocalizedMessageStack());
+		} catch (Exception e) {
+			e.printStackTrace();
+		}
+	}
+
+	/**
+	 * <p>Hides the {@link JFrame JFrame}, hiding the graphical interface.</p>
+	 */
+	private static void hideJFrame() {
+		jFrame.setVisible(false);
+	}
+}
Index: tags/v2_0_0_Build_2050/applications/appgvSIG/src-test/org/gvsig/app/panelGroup/Test8ButtonsPanel.java
===================================================================
--- tags/v2_0_0_Build_2050/applications/appgvSIG/src-test/org/gvsig/app/panelGroup/Test8ButtonsPanel.java	(revision 0)
+++ tags/v2_0_0_Build_2050/applications/appgvSIG/src-test/org/gvsig/app/panelGroup/Test8ButtonsPanel.java	(revision 38653)
@@ -0,0 +1,120 @@
+/* gvSIG. Sistema de Informaci�n Geogr�fica de la Generalitat Valenciana
+ *
+ * Copyright (C) 2007 IVER T.I. and Generalitat Valenciana.
+ *
+ * This program is free software; you can redistribute it and/or
+ * modify it under the terms of the GNU General Public License
+ * as published by the Free Software Foundation; either version 2
+ * of the License, or (at your option) any later version.
+ *
+ * This program is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
+ * GNU General Public License for more details.
+ *
+ * You should have received a copy of the GNU General Public License
+ * along with this program; if not, write to the Free Software
+ * Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA  02111-1307,USA.
+ */
+
+package org.gvsig.app.panelGroup;
+
+import javax.swing.JFrame;
+
+import org.gvsig.gui.beans.buttonspanel.ButtonsPanel;
+import org.gvsig.gui.beans.buttonspanel.ButtonsPanelEvent;
+import org.gvsig.gui.beans.buttonspanel.ButtonsPanelListener;
+import org.gvsig.gui.beans.panelGroup.PanelGroupManager;
+import org.gvsig.gui.beans.panelGroup.treePanel.TreePanel;
+import org.gvsig.tools.exception.BaseException;
+
+import org.gvsig.andami.ui.mdiManager.WindowInfo;
+import org.gvsig.app.panelGroup.loaders.PanelGroupLoaderFromExtensionPoint;
+import org.gvsig.app.panelGroup.samples.Samples_ExtensionPointsOfIPanels;
+
+/**
+ * <p>Tests {@link PanelGroupDialog PanelGroupDialog}.</p>
+ * <p>Tests {@link PanelGroupManager PanelGroupManager}, {@link PanelGroupLoaderFromExtensionPoint PanelGroupLoaderFromExtensionPoint}, 
+ *  {@link TreePanel TreePanel}, and a non resizable {@link PanelGroupDialog PanelGroupDialog}.</p>
+ * 
+ * @version 22/10/2007
+ * @author Pablo Piqueras Bartolom� (pablo.piqueras@iver.es) 
+ */
+public class Test8ButtonsPanel {
+	/**
+	 * <p>Element for the interface.</p>
+	 */
+	private static JFrame jFrame;
+	private static TreePanel panelGroup;
+
+	/**
+	 * <p>Test method for the Test8ButtonsPanel.</p>
+	 * <p>Tests the G.U.I. when adds panels with different dimensions, to a resizable <code>PanelGroupDialog</code>.</p>
+	 * 
+	 * @param args optional arguments
+	 */
+	public static void main(String[] args) {
+		try {
+			jFrame = new JFrame();
+
+			PanelGroupManager manager = PanelGroupManager.getManager();
+			manager.registerPanelGroup(TreePanel.class);
+			manager.setDefaultType(TreePanel.class);
+
+			Samples_ExtensionPointsOfIPanels.loadSample();
+
+			panelGroup = (TreePanel) manager.getPanelGroup(Samples_ExtensionPointsOfIPanels.REFERENCE1);
+			
+			PanelGroupLoaderFromExtensionPoint loader = new PanelGroupLoaderFromExtensionPoint(Samples_ExtensionPointsOfIPanels.EXTENSIONPOINT1_NAME);
+			
+			// Creates the IWindow
+			PanelGroupDialog panelGroupDialog = new PanelGroupDialog(Samples_ExtensionPointsOfIPanels.REFERENCE1_NAME, "Panel with Buttons", 150, 150, (byte)WindowInfo.RESIZABLE, panelGroup);
+
+			// Begin: Test the normal load
+			panelGroupDialog.loadPanels(loader);
+			// End: Test the normal load
+			
+			panelGroupDialog.addButtonPressedListener(new ButtonsPanelListener() {
+				/*
+				 * @see org.gvsig.gui.beans.buttonspanel.ButtonsPanelListener#actionButtonPressed(org.gvsig.gui.beans.buttonspanel.ButtonsPanelEvent)
+				 */
+				public void actionButtonPressed(ButtonsPanelEvent e) {
+					switch (e.getButton()) {
+						case ButtonsPanel.BUTTON_ACCEPT:
+							System.out.println("Accept Button pressed.");
+							hideJFrame();
+							System.exit(0);
+							break;
+						case ButtonsPanel.BUTTON_CANCEL:
+							System.out.println("Cancel Button pressed.");
+							hideJFrame();
+							System.exit(0);
+							break;
+						case ButtonsPanel.BUTTON_APPLY:
+							System.out.println("Apply Button pressed.");
+							break;
+					}
+				}
+			});
+			
+			jFrame.setTitle("Test non resizable PanelGroupDialog with a tree and using PanelGroupLoaderFromExtensionPoint");
+		    jFrame.setDefaultCloseOperation(JFrame.EXIT_ON_CLOSE);
+		    jFrame.setSize(panelGroupDialog.getPreferredSize());
+		    jFrame.getContentPane().add(panelGroupDialog);
+		    
+		    jFrame.setResizable(false);
+			jFrame.setVisible(true);
+		} catch (BaseException bE) {
+			System.out.println(bE.getLocalizedMessageStack());
+		} catch (Exception e) {
+			e.printStackTrace();
+		}
+	}
+
+	/**
+	 * <p>Hides the {@link JFrame JFrame}, hiding the graphical interface.</p>
+	 */
+	private static void hideJFrame() {
+		jFrame.setVisible(false);
+	}
+}
Index: tags/v2_0_0_Build_2050/applications/appgvSIG/src-test/org/gvsig/app/panelGroup/Test2ExceptionsUsingTreePanel.java
===================================================================
--- tags/v2_0_0_Build_2050/applications/appgvSIG/src-test/org/gvsig/app/panelGroup/Test2ExceptionsUsingTreePanel.java	(revision 0)
+++ tags/v2_0_0_Build_2050/applications/appgvSIG/src-test/org/gvsig/app/panelGroup/Test2ExceptionsUsingTreePanel.java	(revision 38653)
@@ -0,0 +1,279 @@
+/* gvSIG. Sistema de Informaci�n Geogr�fica de la Generalitat Valenciana
+ *
+ * Copyright (C) 2007 IVER T.I. and Generalitat Valenciana.
+ *
+ * This program is free software; you can redistribute it and/or
+ * modify it under the terms of the GNU General Public License
+ * as published by the Free Software Foundation; either version 2
+ * of the License, or (at your option) any later version.
+ *
+ * This program is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
+ * GNU General Public License for more details.
+ *
+ * You should have received a copy of the GNU General Public License
+ * along with this program; if not, write to the Free Software
+ * Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA  02111-1307,USA.
+ */
+
+package org.gvsig.app.panelGroup;
+
+import junit.framework.TestCase;
+
+import org.gvsig.gui.beans.Messages;
+import org.gvsig.gui.beans.panelGroup.PanelGroupManager;
+import org.gvsig.gui.beans.panelGroup.treePanel.TreePanel;
+import org.gvsig.tools.exception.BaseException;
+
+import org.gvsig.app.panelGroup.loaders.PanelGroupLoaderFromExtensionPoint;
+import org.gvsig.app.panelGroup.samples.Samples_ExtensionPointsOfIPanels;
+
+/**
+ * <p>Tests the loading of layers using a {@link TreePanel TreePanel} object and a {@link PanelGroupLoaderFromExtensionPoint PanelGroupLoaderFromExtensionPoint} loader
+ * Tests also the managing of the different kind of exceptions which could be launched during this process.</p>
+ * 
+ * @version 11/12/2007
+ * @author Pablo Piqueras Bartolom� (pablo.piqueras@iver.es) 
+ */
+public class Test2ExceptionsUsingTreePanel extends TestCase {
+	private TreePanel panelGroup;
+	private PanelGroupManager manager;
+	private PanelGroupLoaderFromExtensionPoint loader;
+	private String validationText;
+	private String localizedMessage;
+
+	/*
+	 * (non-Javadoc)
+	 * @see junit.framework.TestCase#setUp()
+	 */
+	protected void setUp() throws Exception {
+		super.setUp();
+
+		manager = PanelGroupManager.getManager();
+		manager.registerPanelGroup(TreePanel.class);
+		manager.setDefaultType(TreePanel.class);
+		panelGroup = (TreePanel) manager.getPanelGroup(Samples_ExtensionPointsOfIPanels.REFERENCE3);
+	}
+
+	/*
+	 * (non-Javadoc)
+	 * @see junit.framework.TestCase#tearDown()
+	 */
+	protected void tearDown() throws Exception {
+		super.tearDown();
+		manager.deregisterPanelGroup(TreePanel.class);
+	}
+	
+	/**
+	 * <p>Test the 'PanelGroup' exceptions </p>
+	 */
+	public void test1() {
+		Samples_ExtensionPointsOfIPanels.loadSample();
+
+		validationText = Messages.getText("couldnt_add_some_panel_exception") + "\n  " + Messages.getText("couldnt_load_panels_from_extension_point_exception") + "\n  Error cargando un panel: / by zero.";
+
+		try {
+			System.out.println("----- Test 1 -----");
+			loader = new PanelGroupLoaderFromExtensionPoint(Samples_ExtensionPointsOfIPanels.EXTENSIONPOINT4_NAME);
+
+			// Begin: Test the normal load
+			panelGroup.loadPanels(loader);
+			// End: Test the normal load
+		} catch (BaseException bE) {
+			localizedMessage = bE.getLocalizedMessageStack();
+			System.out.println(localizedMessage);
+			System.out.println("------------------");
+			assertEquals(localizedMessage, validationText);
+			return;
+		} catch (Exception e) {
+			e.printStackTrace();
+			System.out.println("------------------");
+			fail();
+			return;
+		}
+
+		System.out.println("------------------");
+		fail();
+	}
+	
+	/**
+	 * <p>Test the 'PanelGroup' exceptions </p>
+	 */
+	public void test2() {
+		validationText = Messages.getText("couldnt_add_some_panel_exception") + "\n  Panel de etiqueta Information_LABEL sin tama�o inicial definido.";
+
+		try {
+			System.out.println("----- Test 2 -----");
+			loader = new PanelGroupLoaderFromExtensionPoint(Samples_ExtensionPointsOfIPanels.EXTENSIONPOINT5_NAME);
+
+			// Begin: Test the normal load
+			panelGroup.loadPanels(loader);
+			// End: Test the normal load
+		} catch (BaseException bE) {
+			localizedMessage = bE.getLocalizedMessageStack().trim();
+			System.out.println(localizedMessage);
+			System.out.println("------------------");
+			assertEquals(localizedMessage, validationText);
+			return;
+		} catch (Exception e) {
+			e.printStackTrace();
+			System.out.println("------------------");
+			fail();
+			return;
+		}
+
+		System.out.println("------------------");
+		fail();
+	}
+	
+	/**
+	 * <p>Test the 'PanelGroup' exceptions </p>
+	 */
+	public void test3() {
+		validationText = Messages.getText("empty_panel_group_exception");
+
+		try {
+			System.out.println("----- Test 3 -----");
+			loader = new PanelGroupLoaderFromExtensionPoint(Samples_ExtensionPointsOfIPanels.EXTENSIONPOINT6_NAME);
+
+			// Begin: Test the normal load
+			panelGroup.loadPanels(loader);
+			// End: Test the normal load
+		} catch (BaseException bE) {
+			localizedMessage = bE.getLocalizedMessageStack().trim();
+			System.out.println(localizedMessage);
+			System.out.println("------------------");
+			assertEquals(localizedMessage, validationText);
+			return;
+		} catch (Exception e) {
+			e.printStackTrace();
+			System.out.println("------------------");
+			fail();
+			return;
+		}
+
+		System.out.println("------------------");
+		fail();
+	}
+	
+	/**
+	 * <p>Test the 'PanelGroup' exceptions </p>
+	 */
+	public void test4() {
+		validationText = Messages.getText("empty_panel_group_gui_exception");
+
+		try {
+			System.out.println("----- Test 4 -----");
+			loader = new PanelGroupLoaderFromExtensionPoint(Samples_ExtensionPointsOfIPanels.EXTENSIONPOINT7_NAME);
+
+			// Begin: Test the normal load
+			panelGroup.loadPanels(loader);
+			// End: Test the normal load
+		} catch (BaseException bE) {
+			localizedMessage = bE.getLocalizedMessageStack().trim();
+			System.out.println(localizedMessage);
+			System.out.println("------------------");
+			assertEquals(localizedMessage, validationText);
+			return;
+		} catch (Exception e) {
+			e.printStackTrace();
+			System.out.println("------------------");
+			fail();
+			return;
+		}
+
+		System.out.println("------------------");
+		fail();
+	}
+	
+	/**
+	 * <p>Test the 'PanelGroup' exceptions </p>
+	 */
+	public void test5() {
+		validationText = Messages.getText("couldnt_add_some_panel_exception") + "\n  " + Messages.getText("couldnt_load_panels_from_extension_point_exception") + "\n  Error cargando un panel: / by zero.\n  Panel de etiqueta Information_LABEL sin tama�o inicial definido.\n  " + Messages.getText("empty_panel_group_exception");
+
+		try {
+			System.out.println("----- Test 5 -----");
+			loader = new PanelGroupLoaderFromExtensionPoint(Samples_ExtensionPointsOfIPanels.EXTENSIONPOINT8_NAME);
+
+			// Begin: Test the normal load
+			panelGroup.loadPanels(loader);
+			// End: Test the normal load
+		} catch (BaseException bE) {
+			localizedMessage = bE.getLocalizedMessageStack().trim();
+			System.out.println(localizedMessage);
+			System.out.println("------------------");
+			assertEquals(localizedMessage, validationText);
+			return;
+		} catch (Exception e) {
+			e.printStackTrace();
+			System.out.println("------------------");
+			fail();
+			return;
+		}
+
+		System.out.println("------------------");
+		fail();
+	}
+	
+	/**
+	 * <p>Test the 'PanelGroup' exceptions </p>
+	 */
+	public void test6() {
+		validationText = Messages.getText("couldnt_add_some_panel_exception") + "\n  " + Messages.getText("couldnt_load_panels_from_extension_point_exception") + "\n  Error cargando un panel: / by zero.\n  Panel de etiqueta Information_LABEL sin tama�o inicial definido.\n  " + Messages.getText("empty_panel_group_gui_exception");
+
+		try {
+			System.out.println("----- Test 6 -----");
+			loader = new PanelGroupLoaderFromExtensionPoint(Samples_ExtensionPointsOfIPanels.EXTENSIONPOINT9_NAME);
+
+			// Begin: Test the normal load
+			panelGroup.loadPanels(loader);
+			// End: Test the normal load
+		} catch (BaseException bE) {
+			localizedMessage = bE.getLocalizedMessageStack().trim();
+			System.out.println(localizedMessage);
+			System.out.println("------------------");
+			assertEquals(localizedMessage, validationText);
+			return;
+		} catch (Exception e) {
+			e.printStackTrace();
+			System.out.println("------------------");
+			fail();
+			return;
+		}
+
+		System.out.println("------------------");
+		fail();
+	}
+	
+	/**
+	 * <p>Test the 'PanelGroup' exceptions </p>
+	 */
+	public void test7() {
+		validationText = Messages.getText("couldnt_add_some_panel_exception") + "\n  " + Messages.getText("couldnt_load_panels_from_extension_point_exception") + "\n  Error cargando un panel: / by zero.\n  Panel de etiqueta Information_LABEL sin tama�o inicial definido.";
+
+		try {
+			System.out.println("----- Test 7 -----");
+			loader = new PanelGroupLoaderFromExtensionPoint(Samples_ExtensionPointsOfIPanels.EXTENSIONPOINT10_NAME);
+
+			// Begin: Test the normal load
+			panelGroup.loadPanels(loader);
+			// End: Test the normal load
+		} catch (BaseException bE) {
+			localizedMessage = bE.getLocalizedMessageStack().trim();
+			System.out.println(localizedMessage);
+			System.out.println("------------------");
+			assertEquals(localizedMessage, validationText);
+			return;
+		} catch (Exception e) {
+			e.printStackTrace();
+			System.out.println("------------------");
+			fail();
+			return;
+		}
+
+		System.out.println("------------------");
+		fail();
+	}
+}
Index: tags/v2_0_0_Build_2050/applications/appgvSIG/src-test/org/gvsig/app/panelGroup/Test2TabbedPanel.java
===================================================================
--- tags/v2_0_0_Build_2050/applications/appgvSIG/src-test/org/gvsig/app/panelGroup/Test2TabbedPanel.java	(revision 0)
+++ tags/v2_0_0_Build_2050/applications/appgvSIG/src-test/org/gvsig/app/panelGroup/Test2TabbedPanel.java	(revision 38653)
@@ -0,0 +1,73 @@
+/* gvSIG. Sistema de Informaci�n Geogr�fica de la Generalitat Valenciana
+ *
+ * Copyright (C) 2007 IVER T.I. and Generalitat Valenciana.
+ *
+ * This program is free software; you can redistribute it and/or
+ * modify it under the terms of the GNU General Public License
+ * as published by the Free Software Foundation; either version 2
+ * of the License, or (at your option) any later version.
+ *
+ * This program is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
+ * GNU General Public License for more details.
+ *
+ * You should have received a copy of the GNU General Public License
+ * along with this program; if not, write to the Free Software
+ * Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA  02111-1307,USA.
+ */
+
+package org.gvsig.app.panelGroup;
+
+import javax.swing.JFrame;
+
+import org.gvsig.gui.beans.panelGroup.PanelGroupManager;
+import org.gvsig.gui.beans.panelGroup.tabbedPanel.TabbedPanel;
+import org.gvsig.tools.exception.BaseException;
+
+import org.gvsig.app.panelGroup.loaders.PanelGroupLoaderFromExtensionPoint;
+import org.gvsig.app.panelGroup.samples.Samples_ExtensionPointsOfIPanels;
+
+/**
+ * <p>Tests the creation of a {@link TabbedPanel TabbedPanel} object using {@link PanelGroupLoaderFromExtensionPoint PanelGroupLoaderFromExtensionPoint} .</p>
+ * 
+ * @version 16/10/2007
+ * @author Pablo Piqueras Bartolom� (pablo.piqueras@iver.es) 
+ */
+public class Test2TabbedPanel {
+	/**
+	 * <p>Test method for the Test2TabbedPanel.</p>
+	 * 
+	 * @param args optional arguments
+	 */
+	public static void main(String[] args) {
+		try {
+			Samples_ExtensionPointsOfIPanels.loadSample();
+			
+			PanelGroupManager manager = PanelGroupManager.getManager();
+			manager.registerPanelGroup(TabbedPanel.class);
+			manager.setDefaultType(TabbedPanel.class);
+
+			TabbedPanel panelGroup = (TabbedPanel) manager.getPanelGroup(Samples_ExtensionPointsOfIPanels.REFERENCE2);
+			PanelGroupLoaderFromExtensionPoint loader = new PanelGroupLoaderFromExtensionPoint(Samples_ExtensionPointsOfIPanels.EXTENSIONPOINT2_NAME);
+
+			// Begin: Test the normal load
+			panelGroup.loadPanels(loader);
+			// End: Test the normal load
+
+			// Objects creation
+			JFrame jFrame = new JFrame();
+			jFrame.setTitle("Test TabbedPanel using PanelGroupLoaderFromExtensionPoint");
+		    jFrame.setDefaultCloseOperation(JFrame.EXIT_ON_CLOSE);
+		    jFrame.setSize(panelGroup.getPreferredSize());
+		    jFrame.getContentPane().add(panelGroup);
+		    
+			jFrame.setVisible(true);
+			
+		} catch (BaseException bE) {
+			System.out.println(bE.getLocalizedMessageStack());
+		} catch (Exception e) {
+			e.printStackTrace();
+		}
+	}
+}
\ No newline at end of file
Index: tags/v2_0_0_Build_2050/applications/appgvSIG/src-test/org/gvsig/app/panelGroup/samples/SamplePanSharpeningPanel.java
===================================================================
--- tags/v2_0_0_Build_2050/applications/appgvSIG/src-test/org/gvsig/app/panelGroup/samples/SamplePanSharpeningPanel.java	(revision 0)
+++ tags/v2_0_0_Build_2050/applications/appgvSIG/src-test/org/gvsig/app/panelGroup/samples/SamplePanSharpeningPanel.java	(revision 38653)
@@ -0,0 +1,136 @@
+/* gvSIG. Sistema de Informaci�n Geogr�fica de la Generalitat Valenciana
+ *
+ * Copyright (C) 2007 IVER T.I. and Generalitat Valenciana.
+ *
+ * This program is free software; you can redistribute it and/or
+ * modify it under the terms of the GNU General Public License
+ * as published by the Free Software Foundation; either version 2
+ * of the License, or (at your option) any later version.
+ *
+ * This program is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
+ * GNU General Public License for more details.
+ *
+ * You should have received a copy of the GNU General Public License
+ * along with this program; if not, write to the Free Software
+ * Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA  02111-1307,USA.
+ */
+
+package org.gvsig.app.panelGroup.samples;
+
+import java.awt.Color;
+import java.awt.Dimension;
+import java.awt.event.MouseAdapter;
+import java.awt.event.MouseEvent;
+import java.io.Serializable;
+
+import javax.swing.JScrollPane;
+import javax.swing.JTextArea;
+
+import org.gvsig.gui.beans.panelGroup.panels.AbstractPanel;
+
+/**
+ * <p>Sample of {@link AbstractPanel AbstractPanel}.</p>
+ * 
+ * @version 16/10/2007
+ * @author Pablo Piqueras Bartolom� (pablo.piqueras@iver.es) 
+ */
+public class SamplePanSharpeningPanel extends AbstractPanel implements Serializable {
+	private static final long serialVersionUID = 648806623810248226L;
+
+	/**
+	 * <p>Element for the interface.</p>
+	 */
+	private JTextArea jTextArea = null;
+	
+	/**
+	 * @see AbstractPanel#AbstractPanel()
+	 */
+	public SamplePanSharpeningPanel() {
+		super();
+		initialize();
+	}
+	
+	/**
+	 * @see AbstractPanel#AbstractPanel(String, String, String)
+	 */
+	public SamplePanSharpeningPanel(String id, String label, String labelGroup) {
+		super(id, label, labelGroup);
+		initialize();
+	}
+
+	@Override
+	protected void initialize() {
+		add(new JScrollPane(getJTextArea()));
+		setToolTipText(getID());
+		
+		setID(Samples_ExtensionPointsOfIPanels.PANELS1_IDS[4]);
+		setLabel(Samples_ExtensionPointsOfIPanels.PANELS1_LABELS[4]);
+		setLabelGroup(Samples_ExtensionPointsOfIPanels.PANELS1_LABELGROUPS[4]);
+		setPreferredSize(new Dimension(Samples_ExtensionPointsOfIPanels.PANELS_DEFAULT_WIDTH, Samples_ExtensionPointsOfIPanels.PANELS_DEFAULT_HEIGHT));
+		resetChangedStatus();
+	}
+	
+	/**
+	 * This method initializes jTextArea
+	 *
+	 * @return JTextArea
+	 */
+	private JTextArea getJTextArea() {
+		if (jTextArea == null) {
+			jTextArea = new JTextArea(5, 40);
+			jTextArea.setText("I\'m a JTextArea object in the \"Panel\" with:\n\nID: " + getID() + "\nLabel: " + getLabel() + "\nLabelGroup: " + getLabelGroup());
+			jTextArea.setEditable(false);
+			jTextArea.setBackground(Color.MAGENTA);
+			jTextArea.addMouseListener(new MouseAdapter() {
+				
+				public void mouseClicked(MouseEvent e) {
+					if (getPanelGroup() != null) {
+						getPanelGroup().setEnabledAcceptButton(! getPanelGroup().isEnabledAcceptButton());
+						getPanelGroup().setEnabledApplyButton(! getPanelGroup().isEnabledApplyButton());
+					}	
+				}
+			});
+		}
+
+		return jTextArea;
+	}
+
+	@Override
+	public void setID(String id) {
+		super.setID(id);
+		
+		setToolTipText(getID());
+		getJTextArea().setText("I\'m a JTextArea object in the \"Panel\" with:\n\nID: " + getID() + "\nLabel: " + getLabel() + "\nLabelGroup: " + getLabelGroup());
+	}
+
+	@Override
+	public void setLabel(String label) {
+		super.setLabel(label);
+		
+		getJTextArea().setText("I\'m a JTextArea object in the \"Panel\" with:\n\nID: " + getID() + "\nLabel: " + getLabel() + "\nLabelGroup: " + getLabelGroup());
+	}
+
+	@Override
+	public void setLabelGroup(String labelGroup) {
+		super.setLabelGroup(labelGroup);
+		
+		getJTextArea().setText("I\'m a JTextArea object in the \"Panel\" with:\n\nID: " + getID() + "\nLabel: " + getLabel() + "\nLabelGroup: " + getLabelGroup());
+	}
+
+	public void accept() {
+	}
+
+	public void apply() {
+	}
+
+	public void cancel() {
+	}
+
+	public void selected() {
+		System.out.println("I'm the IPanel: " + toString() + "\n and I've been selected. My information is: " +
+				 "\n\tID: " + getID() + "\n\tLABEL_GROUP: " + getLabelGroup() + "\n\tLABEL: " + getLabel() + "\n\tCLASS: " + getClass() +
+				 "\n\tMy Preferred Size: " + getPreferredSize() + "\n\tAnd My size: " + getSize());
+	}
+}
Index: tags/v2_0_0_Build_2050/applications/appgvSIG/src-test/org/gvsig/app/panelGroup/samples/SamplePanelWithoutGroupLabel.java
===================================================================
--- tags/v2_0_0_Build_2050/applications/appgvSIG/src-test/org/gvsig/app/panelGroup/samples/SamplePanelWithoutGroupLabel.java	(revision 0)
+++ tags/v2_0_0_Build_2050/applications/appgvSIG/src-test/org/gvsig/app/panelGroup/samples/SamplePanelWithoutGroupLabel.java	(revision 38653)
@@ -0,0 +1,124 @@
+/* gvSIG. Sistema de Informaci�n Geogr�fica de la Generalitat Valenciana
+ *
+ * Copyright (C) 2007 IVER T.I. and Generalitat Valenciana.
+ *
+ * This program is free software; you can redistribute it and/or
+ * modify it under the terms of the GNU General Public License
+ * as published by the Free Software Foundation; either version 2
+ * of the License, or (at your option) any later version.
+ *
+ * This program is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
+ * GNU General Public License for more details.
+ *
+ * You should have received a copy of the GNU General Public License
+ * along with this program; if not, write to the Free Software
+ * Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA  02111-1307,USA.
+ */
+
+package org.gvsig.app.panelGroup.samples;
+
+import java.awt.Color;
+import java.awt.Dimension;
+import java.io.Serializable;
+
+import javax.swing.JScrollPane;
+import javax.swing.JTextArea;
+
+import org.gvsig.gui.beans.panelGroup.panels.AbstractPanel;
+
+/**
+ * <p>Sample of {@link AbstractPanel AbstractPanel}.</p>
+ * 
+ * @version 23/10/2007
+ * @author Pablo Piqueras Bartolom� (pablo.piqueras@iver.es) 
+ */
+public class SamplePanelWithoutGroupLabel extends AbstractPanel implements Serializable {
+	private static final long serialVersionUID = -5449402170753829090L;
+
+	/**
+	 * <p>Element for the interface.</p>
+	 */
+	private JTextArea jTextArea = null;
+
+	/**
+	 * @see AbstractPanel#AbstractPanel()
+	 */
+	public SamplePanelWithoutGroupLabel() {
+		super();
+		initialize();
+	}
+
+	/**
+	 * @see AbstractPanel#AbstractPanel(String, String, String)
+	 */
+	public SamplePanelWithoutGroupLabel(String id, String label, String labelGroup) {
+		super(id, label, labelGroup);
+		initialize();
+	}
+
+	@Override
+	protected void initialize() {
+		add(new JScrollPane(getJTextArea()));
+		setToolTipText(getID());
+		
+		setID(Samples_ExtensionPointsOfIPanels.PANELS3_IDS[0]);
+		setLabel(Samples_ExtensionPointsOfIPanels.PANELS3_LABELS[0]);
+		setPreferredSize(new Dimension(Samples_ExtensionPointsOfIPanels.PANELS_DEFAULT_WIDTH, Samples_ExtensionPointsOfIPanels.PANELS_DEFAULT_HEIGHT));
+		resetChangedStatus();
+	}
+	
+	/**
+	 * This method initializes jTextArea
+	 *
+	 * @return JTextArea
+	 */
+	private JTextArea getJTextArea() {
+		if (jTextArea == null) {
+			jTextArea = new JTextArea(5, 40);
+			jTextArea.setText("I\'m a JTextArea object in the \"Panel\" with:\n\nID: " + getID() + "\nLabel: " + getLabel() + "\nLabelGroup: " + getLabelGroup());
+			jTextArea.setEditable(false);
+			jTextArea.setBackground(Color.WHITE);
+		}
+
+		return jTextArea;
+	}
+
+	@Override
+	public void setID(String id) {
+		super.setID(id);
+
+		setToolTipText(getID());
+		getJTextArea().setText("I\'m a JTextArea object in the \"Panel\" with:\n\nID: " + getID() + "\nLabel: " + getLabel() + "\nLabelGroup: " + getLabelGroup());
+	}
+
+	@Override
+	public void setLabel(String label) {
+		super.setLabel(label);
+		
+		getJTextArea().setText("I\'m a JTextArea object in the \"Panel\" with:\n\nID: " + getID() + "\nLabel: " + getLabel() + "\nLabelGroup: " + getLabelGroup());
+	}
+
+	@Override
+	public void setLabelGroup(String labelGroup) {
+		super.setLabelGroup(labelGroup);
+		
+		getJTextArea().setText("I\'m a JTextArea object in the \"Panel\" with:\n\nID: " + getID() + "\nLabel: " + getLabel() + "\nLabelGroup: " + getLabelGroup());
+	}
+
+	public void accept() {
+	}
+
+	public void apply() {
+	}
+
+	public void cancel() {
+	}
+
+	public void selected() {
+		System.out.println("I'm the IPanel: " + toString() + "\n and I've been selected. My information is: " +
+				 "\n\tID: " + getID() + "\n\tLABEL_GROUP: " + getLabelGroup() + "\n\tLABEL: " + getLabel() + "\n\tCLASS: " + getClass() +
+				 "\n\tMy Preferred Size: " + getPreferredSize() + "\n\tAnd My size: " + getSize());
+	}
+}
Index: tags/v2_0_0_Build_2050/applications/appgvSIG/src-test/org/gvsig/app/panelGroup/samples/SampleInvisiblePanel.java
===================================================================
--- tags/v2_0_0_Build_2050/applications/appgvSIG/src-test/org/gvsig/app/panelGroup/samples/SampleInvisiblePanel.java	(revision 0)
+++ tags/v2_0_0_Build_2050/applications/appgvSIG/src-test/org/gvsig/app/panelGroup/samples/SampleInvisiblePanel.java	(revision 38653)
@@ -0,0 +1,148 @@
+/* gvSIG. Sistema de Informaci�n Geogr�fica de la Generalitat Valenciana
+ *
+ * Copyright (C) 2007 IVER T.I. and Generalitat Valenciana.
+ *
+ * This program is free software; you can redistribute it and/or
+ * modify it under the terms of the GNU General Public License
+ * as published by the Free Software Foundation; either version 2
+ * of the License, or (at your option) any later version.
+ *
+ * This program is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
+ * GNU General Public License for more details.
+ *
+ * You should have received a copy of the GNU General Public License
+ * along with this program; if not, write to the Free Software
+ * Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA  02111-1307,USA.
+ */
+
+package org.gvsig.app.panelGroup.samples;
+
+import java.awt.Color;
+import java.awt.Dimension;
+import java.io.Serializable;
+
+import javax.swing.JScrollPane;
+import javax.swing.JTextArea;
+
+import org.gvsig.gui.beans.panelGroup.panels.AbstractPanel;
+
+/**
+ * <p>Sample of {@link AbstractPanel AbstractPanel}.</p>
+ * 
+ * @version 10/12/2007
+ * @author Pablo Piqueras Bartolom� (pablo.piqueras@iver.es) 
+ */
+public class SampleInvisiblePanel extends AbstractPanel implements Serializable {
+	private static final long serialVersionUID = -1629511810619122126L;
+
+	/**
+	 * <p>Element for the interface.</p>
+	 */
+	private JTextArea jTextArea = null;
+	
+	/**
+	 * @see AbstractPanel#AbstractPanel()
+	 */
+	public SampleInvisiblePanel() {
+		super();
+		initialize();
+	}
+	
+	/**
+	 * @see AbstractPanel#AbstractPanel(String, String, String)
+	 */
+	public SampleInvisiblePanel(String id, String label, String labelGroup) {
+		super(id, label, labelGroup);
+		initialize();
+	}
+	
+	@Override
+	protected void initialize() {
+		add(new JScrollPane(getJTextArea()));
+		setToolTipText(getID());
+		
+		setID(Samples_ExtensionPointsOfIPanels.PANELS1_IDS[0]);
+		setLabel(Samples_ExtensionPointsOfIPanels.PANELS1_LABELS[0]);
+		setLabelGroup(Samples_ExtensionPointsOfIPanels.PANELS1_LABELGROUPS[0]);
+		setPreferredSize(new Dimension(Samples_ExtensionPointsOfIPanels.PANELS_DEFAULT_WIDTH, Samples_ExtensionPointsOfIPanels.PANELS_DEFAULT_HEIGHT));
+		resetChangedStatus();
+		setVisible(false);
+	}
+	
+	/**
+	 * This method initializes jTextArea
+	 *
+	 * @return JTextArea
+	 */
+	private JTextArea getJTextArea() {
+		if (jTextArea == null) {
+			jTextArea = new JTextArea(5, 40);
+			jTextArea.setText("I\'m a JTextArea object in the \"Panel\" with:\n\nID: " + getID() + "\nLabel: " + getLabel() + "\nLabelGroup: " + getLabelGroup());
+			jTextArea.setEditable(false);
+			jTextArea.setBackground(Color.RED);
+		}
+
+		return jTextArea;
+	}
+	
+	@Override
+	public void setID(String id) {
+		super.setID(id);
+		
+		setToolTipText(getID());
+		getJTextArea().setText("I\'m a JTextArea object in the \"Panel\" with:\n\nID: " + getID() + "\nLabel: " + getLabel() + "\nLabelGroup: " + getLabelGroup());
+		hasChanged = true;
+	}
+
+	@Override
+	public void setLabel(String label) {
+		super.setLabel(label);
+		
+		getJTextArea().setText("I\'m a JTextArea object in the \"Panel\" with:\n\nID: " + getID() + "\nLabel: " + getLabel() + "\nLabelGroup: " + getLabelGroup());
+		hasChanged = true;
+	}
+
+	@Override
+	public void setLabelGroup(String labelGroup) {
+		super.setLabelGroup(labelGroup);
+		
+		getJTextArea().setText("I\'m a JTextArea object in the \"Panel\" with:\n\nID: " + getID() + "\nLabel: " + getLabel() + "\nLabelGroup: " + getLabelGroup());
+		hasChanged = true;
+	}
+
+	/*
+	 * (non-Javadoc)
+	 * @see org.gvsig.gui.beans.panelGroup.panels.IPanel#accept()
+	 */
+	public void accept() {
+		System.out.println("I'm the IPanel: " + toString() + "\n and I'm executing an 'accept' method.");
+	}
+
+	/*
+	 * (non-Javadoc)
+	 * @see org.gvsig.gui.beans.panelGroup.panels.IPanel#apply()
+	 */
+	public void apply() {
+		System.out.println("I'm the IPanel: " + toString() + "\n and I'm executing an 'apply' method.");
+	}
+
+	/*
+	 * (non-Javadoc)
+	 * @see org.gvsig.gui.beans.panelGroup.panels.IPanel#cancel()
+	 */
+	public void cancel() {
+		System.out.println("I'm the IPanel: " + toString() + "\n and I'm executing a 'cancel' method.");
+	}
+
+	/*
+	 * (non-Javadoc)
+	 * @see org.gvsig.gui.beans.panelGroup.panels.IPanel#selected()
+	 */
+	public void selected() {
+		System.out.println("I'm the IPanel: " + toString() + "\n and I've been selected. My information is: " +
+				 "\n\tID: " + getID() + "\n\tLABEL_GROUP: " + getLabelGroup() + "\n\tLABEL: " + getLabel() + "\n\tCLASS: " + getClass() +
+				 "\n\tMy Preferred Size: " + getPreferredSize() + "\n\tAnd My size: " + getSize());
+	}
+}
Index: tags/v2_0_0_Build_2050/applications/appgvSIG/src-test/org/gvsig/app/panelGroup/samples/SampleBandSetupPanel.java
===================================================================
--- tags/v2_0_0_Build_2050/applications/appgvSIG/src-test/org/gvsig/app/panelGroup/samples/SampleBandSetupPanel.java	(revision 0)
+++ tags/v2_0_0_Build_2050/applications/appgvSIG/src-test/org/gvsig/app/panelGroup/samples/SampleBandSetupPanel.java	(revision 38653)
@@ -0,0 +1,143 @@
+/* gvSIG. Sistema de Informaci�n Geogr�fica de la Generalitat Valenciana
+ *
+ * Copyright (C) 2007 IVER T.I. and Generalitat Valenciana.
+ *
+ * This program is free software; you can redistribute it and/or
+ * modify it under the terms of the GNU General Public License
+ * as published by the Free Software Foundation; either version 2
+ * of the License, or (at your option) any later version.
+ *
+ * This program is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
+ * GNU General Public License for more details.
+ *
+ * You should have received a copy of the GNU General Public License
+ * along with this program; if not, write to the Free Software
+ * Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA  02111-1307,USA.
+ */
+
+package org.gvsig.app.panelGroup.samples;
+
+import java.awt.Color;
+import java.awt.Dimension;
+import java.awt.event.MouseAdapter;
+import java.awt.event.MouseEvent;
+import java.io.Serializable;
+
+import javax.swing.JScrollPane;
+import javax.swing.JTextArea;
+
+import org.gvsig.gui.beans.panelGroup.AbstractPanelGroup;
+import org.gvsig.gui.beans.panelGroup.panels.AbstractPanel;
+
+/**
+ * <p>Sample of {@link AbstractPanel AbstractPanel}.</p>
+ * 
+ * @version 16/10/2007
+ * @author Pablo Piqueras Bartolom� (pablo.piqueras@iver.es) 
+ */
+public class SampleBandSetupPanel extends AbstractPanel implements Serializable {
+	private static final long serialVersionUID = 40652963597544670L;
+
+	/**
+	 * <p>Element for the interface.</p>
+	 */
+	private JTextArea jTextArea = null;
+
+	/**
+	 * @see AbstractPanel#AbstractPanel()
+	 */
+	public SampleBandSetupPanel() {
+		super();
+		initialize();
+	}
+
+	/**
+	 * @see AbstractPanel#AbstractPanel(String, String, String)
+	 */
+	public SampleBandSetupPanel(String id, String label, String labelGroup) {
+		super(id, label, labelGroup);
+		initialize();
+	}
+
+	@Override
+	protected void initialize() {
+		add(new JScrollPane(getJTextArea()));
+		setToolTipText(getID());
+		
+		setID(Samples_ExtensionPointsOfIPanels.PANELS1_IDS[1]);
+		setLabel(Samples_ExtensionPointsOfIPanels.PANELS1_LABELS[1]);
+		setLabelGroup(Samples_ExtensionPointsOfIPanels.PANELS1_LABELGROUPS[1]);
+		setPreferredSize(new Dimension(Samples_ExtensionPointsOfIPanels.PANELS_DEFAULT_WIDTH, Samples_ExtensionPointsOfIPanels.PANELS_DEFAULT_HEIGHT));
+		resetChangedStatus();
+	}
+	
+	/**
+	 * This method initializes jTextArea
+	 *
+	 * @return JTextArea
+	 */
+	private JTextArea getJTextArea() {
+		if (jTextArea == null) {
+			jTextArea = new JTextArea(5, 40);
+			jTextArea.setText("I\'m a JTextArea object in the \"Panel\" with:\n\nID: " + getID() + "\nLabel: " + getLabel() + "\nLabelGroup: " + getLabelGroup());
+			jTextArea.setEditable(false);
+			jTextArea.setBackground(Color.GREEN);
+			
+			jTextArea.addMouseListener(new MouseAdapter() {
+				
+				public void mouseClicked(MouseEvent e) {
+					if (getPanelGroup() != null) {
+						getPanelGroup().setEnabledAcceptButton(! getPanelGroup().isEnabledAcceptButton());
+						getPanelGroup().setEnabledApplyButton(! getPanelGroup().isEnabledApplyButton());
+						getPanelGroup().setEnabledCancelButton(! getPanelGroup().isEnabledCancelButton());
+					}	
+				}
+			});
+		}
+
+		return jTextArea;
+	}
+
+	@Override
+	public void setID(String id) {
+		super.setID(id);
+
+		setToolTipText(getID());
+		getJTextArea().setText("I\'m a JTextArea object in the \"Panel\" with:\n\nID: " + getID() + "\nLabel: " + getLabel() + "\nLabelGroup: " + getLabelGroup());
+	}
+
+	@Override
+	public void setLabel(String label) {
+		super.setLabel(label);
+		
+		getJTextArea().setText("I\'m a JTextArea object in the \"Panel\" with:\n\nID: " + getID() + "\nLabel: " + getLabel() + "\nLabelGroup: " + getLabelGroup());
+	}
+
+	@Override
+	public void setLabelGroup(String labelGroup) {
+		super.setLabelGroup(labelGroup);
+		
+		getJTextArea().setText("I\'m a JTextArea object in the \"Panel\" with:\n\nID: " + getID() + "\nLabel: " + getLabel() + "\nLabelGroup: " + getLabelGroup());
+	}
+
+	public void accept() {
+	}
+
+	public void apply() {
+	}
+
+	public void cancel() {
+	}
+
+	public void selected() {
+		System.out.println("I'm the IPanel: " + toString() + "\n and I've been selected. My information is: " +
+				 "\n\tID: " + getID() + "\n\tLABEL_GROUP: " + getLabelGroup() + "\n\tLABEL: " + getLabel() + "\n\tCLASS: " + getClass() +
+				 "\n\tMy Preferred Size: " + getPreferredSize() + "\n\tAnd My size: " + getSize());
+	}
+
+	public void setPanelGroup(AbstractPanelGroup panelGroup) {
+		super.setPanelGroup(panelGroup);
+	}
+}
Index: tags/v2_0_0_Build_2050/applications/appgvSIG/src-test/org/gvsig/app/panelGroup/samples/SampleEnhancedPanel.java
===================================================================
--- tags/v2_0_0_Build_2050/applications/appgvSIG/src-test/org/gvsig/app/panelGroup/samples/SampleEnhancedPanel.java	(revision 0)
+++ tags/v2_0_0_Build_2050/applications/appgvSIG/src-test/org/gvsig/app/panelGroup/samples/SampleEnhancedPanel.java	(revision 38653)
@@ -0,0 +1,137 @@
+/* gvSIG. Sistema de Informaci�n Geogr�fica de la Generalitat Valenciana
+ *
+ * Copyright (C) 2007 IVER T.I. and Generalitat Valenciana.
+ *
+ * This program is free software; you can redistribute it and/or
+ * modify it under the terms of the GNU General Public License
+ * as published by the Free Software Foundation; either version 2
+ * of the License, or (at your option) any later version.
+ *
+ * This program is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
+ * GNU General Public License for more details.
+ *
+ * You should have received a copy of the GNU General Public License
+ * along with this program; if not, write to the Free Software
+ * Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA  02111-1307,USA.
+ */
+
+package org.gvsig.app.panelGroup.samples;
+
+import java.awt.Color;
+import java.awt.Dimension;
+import java.awt.event.MouseAdapter;
+import java.awt.event.MouseEvent;
+import java.io.Serializable;
+
+import javax.swing.JScrollPane;
+import javax.swing.JTextArea;
+
+import org.gvsig.gui.beans.panelGroup.panels.AbstractPanel;
+
+/**
+ * <p>Sample of {@link AbstractPanel AbstractPanel}.</p>
+ * 
+ * @version 16/10/2007
+ * @author Pablo Piqueras Bartolom� (pablo.piqueras@iver.es) 
+ */
+public class SampleEnhancedPanel extends AbstractPanel implements Serializable {
+	private static final long serialVersionUID = -7469300452126449245L;
+
+	/**
+	 * <p>Element for the interface.</p>
+	 */
+	private JTextArea jTextArea = null;
+	
+	/**
+	 * @see AbstractPanel#AbstractPanel()
+	 */
+	public SampleEnhancedPanel() {
+		super();
+		initialize();
+	}
+	
+	/**
+	 * @see AbstractPanel#AbstractPanel(String, String, String)
+	 */
+	public SampleEnhancedPanel(String id, String label, String labelGroup) {
+		super(id, label, labelGroup);
+		initialize();
+	}
+	
+	@Override
+	protected void initialize() {
+		add(new JScrollPane(getJTextArea()));
+		setToolTipText(getID());
+		
+		setID(Samples_ExtensionPointsOfIPanels.PANELS1_IDS[3]);
+		setLabel(Samples_ExtensionPointsOfIPanels.PANELS1_LABELS[3]);
+		setLabelGroup(Samples_ExtensionPointsOfIPanels.PANELS1_LABELGROUPS[3]);
+		setPreferredSize(new Dimension(Samples_ExtensionPointsOfIPanels.PANELS_DEFAULT_WIDTH, Samples_ExtensionPointsOfIPanels.PANELS_DEFAULT_HEIGHT));
+		resetChangedStatus();
+	}
+	
+	/**
+	 * This method initializes jTextArea
+	 *
+	 * @return JTextArea
+	 */
+	private JTextArea getJTextArea() {
+		if (jTextArea == null) {
+			jTextArea = new JTextArea(5, 40);
+			jTextArea.setText("I\'m a JTextArea object in the \"Panel\" with:\n\nID: " + getID() + "\nLabel: " + getLabel() + "\nLabelGroup: " + getLabelGroup());
+			jTextArea.setEditable(false);
+			jTextArea.setBackground(Color.CYAN);
+			jTextArea.addMouseListener(new MouseAdapter() {
+				
+				public void mouseClicked(MouseEvent e) {
+					if (getPanelGroup() != null) {
+						getPanelGroup().setEnabledCancelButton(! getPanelGroup().isEnabledCancelButton());
+					}	
+				}
+			});
+		}
+
+		return jTextArea;
+	}
+	
+	@Override
+	public void setID(String id) {
+		super.setID(id);
+
+		setToolTipText(getID());
+		getJTextArea().setText("I\'m a JTextArea object in the \"Panel\" with:\n\nID: " + getID() + "\nLabel: " + getLabel() + "\nLabelGroup: " + getLabelGroup());
+	}
+
+	@Override
+	public void setLabel(String label) {
+		super.setLabel(label);
+		
+		getJTextArea().setText("I\'m a JTextArea object in the \"Panel\" with:\n\nID: " + getID() + "\nLabel: " + getLabel() + "\nLabelGroup: " + getLabelGroup());
+	}
+
+	@Override
+	public void setLabelGroup(String labelGroup) {
+		super.setLabelGroup(labelGroup);
+		
+		getJTextArea().setText("I\'m a JTextArea object in the \"Panel\" with:\n\nID: " + getID() + "\nLabel: " + getLabel() + "\nLabelGroup: " + getLabelGroup());
+	}
+
+	public void accept() {
+	}
+
+
+	public void apply() {
+	}
+
+	public void cancel() {
+	}
+
+
+	public void selected() {
+		System.out.println("I'm the IPanel: " + toString() + "\n and I've been selected. My information is: " +
+				 "\n\tID: " + getID() + "\n\tLABEL_GROUP: " + getLabelGroup() + "\n\tLABEL: " + getLabel() + "\n\tCLASS: " + getClass() +
+				 "\n\tMy Preferred Size: " + getPreferredSize() + "\n\tAnd My size: " + getSize());
+	}
+}
Index: tags/v2_0_0_Build_2050/applications/appgvSIG/src-test/org/gvsig/app/panelGroup/samples/SamplePanelGroupLabelRepeated.java
===================================================================
--- tags/v2_0_0_Build_2050/applications/appgvSIG/src-test/org/gvsig/app/panelGroup/samples/SamplePanelGroupLabelRepeated.java	(revision 0)
+++ tags/v2_0_0_Build_2050/applications/appgvSIG/src-test/org/gvsig/app/panelGroup/samples/SamplePanelGroupLabelRepeated.java	(revision 38653)
@@ -0,0 +1,126 @@
+/* gvSIG. Sistema de Informaci�n Geogr�fica de la Generalitat Valenciana
+ *
+ * Copyright (C) 2007 IVER T.I. and Generalitat Valenciana.
+ *
+ * This program is free software; you can redistribute it and/or
+ * modify it under the terms of the GNU General Public License
+ * as published by the Free Software Foundation; either version 2
+ * of the License, or (at your option) any later version.
+ *
+ * This program is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
+ * GNU General Public License for more details.
+ *
+ * You should have received a copy of the GNU General Public License
+ * along with this program; if not, write to the Free Software
+ * Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA  02111-1307,USA.
+ */
+
+package org.gvsig.app.panelGroup.samples;
+
+import java.awt.Color;
+import java.awt.Dimension;
+import java.io.Serializable;
+
+import javax.swing.JScrollPane;
+import javax.swing.JTextArea;
+
+import org.gvsig.gui.beans.panelGroup.panels.AbstractPanel;
+
+/**
+ * <p>Sample of {@link AbstractPanel AbstractPanel}.</p>
+ * 
+ * @version 23/10/2007
+ * @author Pablo Piqueras Bartolom� (pablo.piqueras@iver.es) 
+ */
+public class SamplePanelGroupLabelRepeated extends AbstractPanel implements Serializable {
+	private static final long serialVersionUID = 1857806149242138609L;
+
+	/**
+	 * <p>Element for the interface.</p>
+	 */
+	private JTextArea jTextArea = null;
+
+	/**
+	 * @see AbstractPanel#AbstractPanel()
+	 */
+	public SamplePanelGroupLabelRepeated() {
+		super();
+		initialize();
+	}
+
+	/**
+	 * @see AbstractPanel#AbstractPanel(String, String, String)
+	 */
+	public SamplePanelGroupLabelRepeated(String id, String label, String labelGroup) {
+		super(id, label, labelGroup);
+		initialize();
+	}
+
+	@Override
+	protected void initialize() {
+		add(new JScrollPane(getJTextArea()));
+		setToolTipText(getID());
+
+		setID(Samples_ExtensionPointsOfIPanels.PANELS3_IDS[1]);
+		setLabel(Samples_ExtensionPointsOfIPanels.PANELS3_LABELS[1]);
+		setLabelGroup(Samples_ExtensionPointsOfIPanels.PANELS3_LABELGROUPS[1]);
+		setPreferredSize(new Dimension(Samples_ExtensionPointsOfIPanels.PANELS_DEFAULT_WIDTH, Samples_ExtensionPointsOfIPanels.PANELS_DEFAULT_HEIGHT));
+		resetChangedStatus();
+	}
+	
+	/**
+	 * This method initializes jTextArea
+	 *
+	 * @return JTextArea
+	 */
+	private JTextArea getJTextArea() {
+		if (jTextArea == null) {
+			jTextArea = new JTextArea(5, 40);
+			jTextArea.setText("I\'m a JTextArea object in the \"Panel\" with:\n\nID: " + getID() + "\nLabel: " + getLabel() + "\nLabelGroup: " + getLabelGroup());
+			jTextArea.setEditable(false);
+			jTextArea.setBackground(Color.GRAY);
+		}
+
+		return jTextArea;
+	}
+
+	@Override
+	public void setID(String id) {
+		super.setID(id);
+
+		setToolTipText(getID());
+		getJTextArea().setText("I\'m a JTextArea object in the \"Panel\" with:\n\nID: " + getID() + "\nLabel: " + getLabel() + "\nLabelGroup: " + getLabelGroup());
+	}
+
+	@Override
+	public void setLabel(String label) {
+		super.setLabel(label);
+		
+		getJTextArea().setText("I\'m a JTextArea object in the \"Panel\" with:\n\nID: " + getID() + "\nLabel: " + getLabel() + "\nLabelGroup: " + getLabelGroup());
+	}
+
+	@Override
+	public void setLabelGroup(String labelGroup) {
+		super.setLabelGroup(labelGroup);
+		
+		getJTextArea().setText("I\'m a JTextArea object in the \"Panel\" with:\n\nID: " + getID() + "\nLabel: " + getLabel() + "\nLabelGroup: " + getLabelGroup());
+	}
+
+	public void accept() {
+	}
+
+	public void apply() {
+	}
+
+	public void cancel() {
+	}
+
+	public void selected() {
+		System.out.println("I'm the IPanel: " + toString() + "\n and I've been selected. My information is: " +
+				 "\n\tID: " + getID() + "\n\tLABEL_GROUP: " + getLabelGroup() + "\n\tLABEL: " + getLabel() + "\n\tCLASS: " + getClass() +
+				 "\n\tMy Preferred Size: " + getPreferredSize() + "\n\tAnd My size: " + getSize());
+	}
+}
+
Index: tags/v2_0_0_Build_2050/applications/appgvSIG/src-test/org/gvsig/app/panelGroup/samples/SampleScalePanel.java
===================================================================
--- tags/v2_0_0_Build_2050/applications/appgvSIG/src-test/org/gvsig/app/panelGroup/samples/SampleScalePanel.java	(revision 0)
+++ tags/v2_0_0_Build_2050/applications/appgvSIG/src-test/org/gvsig/app/panelGroup/samples/SampleScalePanel.java	(revision 38653)
@@ -0,0 +1,136 @@
+/* gvSIG. Sistema de Informaci�n Geogr�fica de la Generalitat Valenciana
+ *
+ * Copyright (C) 2007 IVER T.I. and Generalitat Valenciana.
+ *
+ * This program is free software; you can redistribute it and/or
+ * modify it under the terms of the GNU General Public License
+ * as published by the Free Software Foundation; either version 2
+ * of the License, or (at your option) any later version.
+ *
+ * This program is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
+ * GNU General Public License for more details.
+ *
+ * You should have received a copy of the GNU General Public License
+ * along with this program; if not, write to the Free Software
+ * Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA  02111-1307,USA.
+ */
+
+package org.gvsig.app.panelGroup.samples;
+
+import java.awt.Color;
+import java.awt.Dimension;
+import java.awt.event.MouseAdapter;
+import java.awt.event.MouseEvent;
+import java.io.Serializable;
+
+import javax.swing.JScrollPane;
+import javax.swing.JTextArea;
+
+import org.gvsig.gui.beans.panelGroup.panels.AbstractPanel;
+
+/**
+ * <p>Sample of {@link AbstractPanel AbstractPanel}.</p>
+ * 
+ * @version 16/10/2007
+ * @author Pablo Piqueras Bartolom� (pablo.piqueras@iver.es) 
+ */
+public class SampleScalePanel extends AbstractPanel implements Serializable {
+	private static final long serialVersionUID = -4160464669737958732L;
+
+	/**
+	 * <p>Element for the interface.</p>
+	 */
+	private JTextArea jTextArea = null;
+	
+	/**
+	 * @see AbstractPanel#AbstractPanel()
+	 */
+	public SampleScalePanel() {
+		super();
+		initialize();
+	}
+	
+	/**
+	 * @see AbstractPanel#AbstractPanel(String, String, String)
+	 */
+	public SampleScalePanel(String id, String label, String labelGroup) {
+		super(id, label, labelGroup);
+		initialize();
+	}
+	
+	@Override
+	protected void initialize() {
+		add(new JScrollPane(getJTextArea()));
+		setToolTipText(getID());
+		
+		setID(Samples_ExtensionPointsOfIPanels.PANELS1_IDS[5]);
+		setLabel(Samples_ExtensionPointsOfIPanels.PANELS1_LABELS[5]);
+		setLabelGroup(Samples_ExtensionPointsOfIPanels.PANELS1_LABELGROUPS[5]);
+		setPreferredSize(new Dimension(Samples_ExtensionPointsOfIPanels.PANELS_DEFAULT_WIDTH, Samples_ExtensionPointsOfIPanels.PANELS_DEFAULT_HEIGHT));
+		resetChangedStatus();
+	}
+	
+	/**
+	 * This method initializes jTextArea
+	 *
+	 * @return JTextArea
+	 */
+	private JTextArea getJTextArea() {
+		if (jTextArea == null) {
+			jTextArea = new JTextArea(5, 40);
+			jTextArea.setText("I\'m a JTextArea object in the \"Panel\" with:\n\nID: " + getID() + "\nLabel: " + getLabel() + "\nLabelGroup: " + getLabelGroup());
+			jTextArea.setEditable(false);
+			jTextArea.setBackground(Color.YELLOW);
+			jTextArea.addMouseListener(new MouseAdapter() {
+				
+				public void mouseClicked(MouseEvent e) {
+					if (getPanelGroup() != null) {
+						getPanelGroup().setEnabledApplyButton(! getPanelGroup().isEnabledApplyButton());
+						getPanelGroup().setEnabledCancelButton(! getPanelGroup().isEnabledCancelButton());
+					}	
+				}
+			});
+		}
+
+		return jTextArea;
+	}
+	
+	@Override
+	public void setID(String id) {
+		super.setID(id);
+		
+		setToolTipText(getID());
+		getJTextArea().setText("I\'m a JTextArea object in the \"Panel\" with:\n\nID: " + getID() + "\nLabel: " + getLabel() + "\nLabelGroup: " + getLabelGroup());
+	}
+
+	@Override
+	public void setLabel(String label) {
+		super.setLabel(label);
+		
+		getJTextArea().setText("I\'m a JTextArea object in the \"Panel\" with:\n\nID: " + getID() + "\nLabel: " + getLabel() + "\nLabelGroup: " + getLabelGroup());
+	}
+
+	@Override
+	public void setLabelGroup(String labelGroup) {
+		super.setLabelGroup(labelGroup);
+		
+		getJTextArea().setText("I\'m a JTextArea object in the \"Panel\" with:\n\nID: " + getID() + "\nLabel: " + getLabel() + "\nLabelGroup: " + getLabelGroup());
+	}
+
+	public void accept() {
+	}
+
+	public void apply() {
+	}
+
+	public void cancel() {
+	}
+
+	public void selected() {
+		System.out.println("I'm the IPanel: " + toString() + "\n and I've been selected. My information is: " +
+				 "\n\tID: " + getID() + "\n\tLABEL_GROUP: " + getLabelGroup() + "\n\tLABEL: " + getLabel() + "\n\tCLASS: " + getClass() +
+				 "\n\tMy Preferred Size: " + getPreferredSize() + "\n\tAnd My size: " + getSize());
+	}
+}
Index: tags/v2_0_0_Build_2050/applications/appgvSIG/src-test/org/gvsig/app/panelGroup/samples/SampleInitializingExcetionPanel.java
===================================================================
--- tags/v2_0_0_Build_2050/applications/appgvSIG/src-test/org/gvsig/app/panelGroup/samples/SampleInitializingExcetionPanel.java	(revision 0)
+++ tags/v2_0_0_Build_2050/applications/appgvSIG/src-test/org/gvsig/app/panelGroup/samples/SampleInitializingExcetionPanel.java	(revision 38653)
@@ -0,0 +1,150 @@
+/* gvSIG. Sistema de Informaci�n Geogr�fica de la Generalitat Valenciana
+ *
+ * Copyright (C) 2007 IVER T.I. and Generalitat Valenciana.
+ *
+ * This program is free software; you can redistribute it and/or
+ * modify it under the terms of the GNU General Public License
+ * as published by the Free Software Foundation; either version 2
+ * of the License, or (at your option) any later version.
+ *
+ * This program is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
+ * GNU General Public License for more details.
+ *
+ * You should have received a copy of the GNU General Public License
+ * along with this program; if not, write to the Free Software
+ * Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA  02111-1307,USA.
+ */
+
+package org.gvsig.app.panelGroup.samples;
+
+import java.awt.Color;
+import java.io.Serializable;
+
+import javax.swing.JScrollPane;
+import javax.swing.JTextArea;
+
+import org.gvsig.gui.beans.panelGroup.panels.AbstractPanel;
+
+/**
+ * <p>Sample of {@link AbstractPanel AbstractPanel}.</p>
+ * 
+ * @version 16/10/2007
+ * @author Pablo Piqueras Bartolom� (pablo.piqueras@iver.es) 
+ */
+public class SampleInitializingExcetionPanel extends AbstractPanel implements Serializable {
+	private static final long serialVersionUID = -876907003975432865L;
+
+	/**
+	 * <p>Element for the interface.</p>
+	 */
+	private JTextArea jTextArea = null;
+
+	/**
+	 * @see AbstractPanel#AbstractPanel()
+	 */
+	public SampleInitializingExcetionPanel() {
+		super();
+		initialize();
+	}
+
+	/**
+	 * @see AbstractPanel#AbstractPanel(String, String, String)
+	 */
+	public SampleInitializingExcetionPanel(String id, String label, String labelGroup) {
+		super(id, label, labelGroup);
+		
+		initialize();
+	}
+
+	@Override
+	protected void initialize() {
+		add(new JScrollPane(getJTextArea()));
+		setToolTipText(getID());
+		
+		setID(Samples_ExtensionPointsOfIPanels.PANELS1_IDS[0]);
+		setLabel(Samples_ExtensionPointsOfIPanels.PANELS1_LABELS[0]);
+		setLabelGroup(Samples_ExtensionPointsOfIPanels.PANELS1_LABELGROUPS[0]);
+		
+		// Force to generate an exception
+		double badValue = 2 / 0;
+
+		resetChangedStatus();
+	}
+	
+	/**
+	 * This method initializes jTextArea
+	 *
+	 * @return JTextArea
+	 */
+	private JTextArea getJTextArea() {
+		if (jTextArea == null) {
+			jTextArea = new JTextArea(5, 40);
+			jTextArea.setText("I\'m a JTextArea object in the \"Panel\" with:\n\nID: " + getID() + "\nLabel: " + getLabel() + "\nLabelGroup: " + getLabelGroup());
+			jTextArea.setEditable(false);
+			jTextArea.setBackground(Color.GREEN);
+		}
+
+		return jTextArea;
+	}
+
+	@Override
+	public void setID(String id) {
+		super.setID(id);
+
+		setToolTipText(getID());
+		getJTextArea().setText("I\'m a JTextArea object in the \"Panel\" with:\n\nID: " + getID() + "\nLabel: " + getLabel() + "\nLabelGroup: " + getLabelGroup());
+		hasChanged = true;
+	}
+
+	@Override
+	public void setLabel(String label) {
+		super.setLabel(label);
+		
+		getJTextArea().setText("I\'m a JTextArea object in the \"Panel\" with:\n\nID: " + getID() + "\nLabel: " + getLabel() + "\nLabelGroup: " + getLabelGroup());
+		hasChanged = true;
+	}
+
+	@Override
+	public void setLabelGroup(String labelGroup) {
+		super.setLabelGroup(labelGroup);
+		
+		getJTextArea().setText("I\'m a JTextArea object in the \"Panel\" with:\n\nID: " + getID() + "\nLabel: " + getLabel() + "\nLabelGroup: " + getLabelGroup());
+		hasChanged = true;
+	}
+
+	/*
+	 * (non-Javadoc)
+	 * @see org.gvsig.gui.beans.panelGroup.panels.IPanel#accept()
+	 */
+	public void accept() {
+		System.out.println("I'm the IPanel: " + toString() + "\n and I'm executing an 'accept' method.");
+	}
+
+	/*
+	 * (non-Javadoc)
+	 * @see org.gvsig.gui.beans.panelGroup.panels.IPanel#apply()
+	 */
+	public void apply() {
+		System.out.println("I'm the IPanel: " + toString() + "\n and I'm executing an 'apply' method.");
+	}
+
+	/*
+	 * (non-Javadoc)
+	 * @see org.gvsig.gui.beans.panelGroup.panels.IPanel#cancel()
+	 */
+	public void cancel() {
+		System.out.println("I'm the IPanel: " + toString() + "\n and I'm executing a 'cancel' method.");
+	}
+
+	/*
+	 * (non-Javadoc)
+	 * @see org.gvsig.gui.beans.panelGroup.panels.IPanel#selected()
+	 */
+	public void selected() {
+		System.out.println("I'm the IPanel: " + toString() + "\n and I've been selected. My information is: " +
+		 "\n\tID: " + getID() + "\n\tLABEL_GROUP: " + getLabelGroup() + "\n\tLABEL: " + getLabel() + "\n\tCLASS: " + getClass() +
+		 "\n\tMy Preferred Size: " + getPreferredSize() + "\n\tAnd My size: " + getSize());
+	}
+}
Index: tags/v2_0_0_Build_2050/applications/appgvSIG/src-test/org/gvsig/app/panelGroup/samples/SampleTransparencyPanel.java
===================================================================
--- tags/v2_0_0_Build_2050/applications/appgvSIG/src-test/org/gvsig/app/panelGroup/samples/SampleTransparencyPanel.java	(revision 0)
+++ tags/v2_0_0_Build_2050/applications/appgvSIG/src-test/org/gvsig/app/panelGroup/samples/SampleTransparencyPanel.java	(revision 38653)
@@ -0,0 +1,136 @@
+/* gvSIG. Sistema de Informaci�n Geogr�fica de la Generalitat Valenciana
+ *
+ * Copyright (C) 2007 IVER T.I. and Generalitat Valenciana.
+ *
+ * This program is free software; you can redistribute it and/or
+ * modify it under the terms of the GNU General Public License
+ * as published by the Free Software Foundation; either version 2
+ * of the License, or (at your option) any later version.
+ *
+ * This program is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
+ * GNU General Public License for more details.
+ *
+ * You should have received a copy of the GNU General Public License
+ * along with this program; if not, write to the Free Software
+ * Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA  02111-1307,USA.
+ */
+
+package org.gvsig.app.panelGroup.samples;
+
+import java.awt.Color;
+import java.awt.Dimension;
+import java.awt.event.MouseAdapter;
+import java.awt.event.MouseEvent;
+import java.io.Serializable;
+
+import javax.swing.JScrollPane;
+import javax.swing.JTextArea;
+
+import org.gvsig.gui.beans.panelGroup.panels.AbstractPanel;
+
+
+/**
+ * <p>Sample of {@link AbstractPanel AbstractPanel}.</p>
+ * 
+ * @version 16/10/2007
+ * @author Pablo Piqueras Bartolom� (pablo.piqueras@iver.es) 
+ */
+public class SampleTransparencyPanel extends AbstractPanel implements Serializable {
+	private static final long serialVersionUID = -4145789119404234621L;
+
+	/**
+	 * <p>Element for the interface.</p>
+	 */
+	private JTextArea jTextArea = null;
+	
+	/**
+	 * @see AbstractPanel#AbstractPanel()
+	 */
+	public SampleTransparencyPanel() {
+		super();
+		initialize();
+	}
+	
+	/**
+	 * @see AbstractPanel#AbstractPanel(String, String, String)
+	 */
+	public SampleTransparencyPanel(String id, String label, String labelGroup) {
+		super(id, label, labelGroup);
+		initialize();
+	}
+	
+	@Override
+	protected void initialize() {
+		add(new JScrollPane(getJTextArea()));
+		setToolTipText(getID());
+		
+		setID(Samples_ExtensionPointsOfIPanels.PANELS1_IDS[2]);
+		setLabel(Samples_ExtensionPointsOfIPanels.PANELS1_LABELS[2]);
+		setLabelGroup(Samples_ExtensionPointsOfIPanels.PANELS1_LABELGROUPS[2]);
+		setPreferredSize(new Dimension(Samples_ExtensionPointsOfIPanels.PANELS_DEFAULT_WIDTH, Samples_ExtensionPointsOfIPanels.PANELS_DEFAULT_HEIGHT));
+		resetChangedStatus();
+	}
+	
+	/**
+	 * This method initializes jTextArea
+	 *
+	 * @return JTextArea
+	 */
+	private JTextArea getJTextArea() {
+		if (jTextArea == null) {
+			jTextArea = new JTextArea(5, 40);
+			jTextArea.setText("I\'m a JTextArea object in the \"Panel\" with:\n\nID: " + getID() + "\nLabel: " + getLabel() + "\nLabelGroup: " + getLabelGroup());
+			jTextArea.setEditable(false);
+			jTextArea.setBackground(Color.BLUE);
+			jTextArea.addMouseListener(new MouseAdapter() {
+				
+				public void mouseClicked(MouseEvent e) {
+					if (getPanelGroup() != null) {
+						getPanelGroup().setEnabledApplyButton(! getPanelGroup().isEnabledApplyButton());
+					}	
+				}
+			});
+		}
+
+		return jTextArea;
+	}
+	
+	@Override
+	public void setID(String id) {
+		super.setID(id);
+		
+		setToolTipText(getID());
+		getJTextArea().setText("I\'m a JTextArea object in the \"Panel\" with:\n\nID: " + getID() + "\nLabel: " + getLabel() + "\nLabelGroup: " + getLabelGroup());
+	}
+
+	@Override
+	public void setLabel(String label) {
+		super.setLabel(label);
+		
+		getJTextArea().setText("I\'m a JTextArea object in the \"Panel\" with:\n\nID: " + getID() + "\nLabel: " + getLabel() + "\nLabelGroup: " + getLabelGroup());
+	}
+
+	@Override
+	public void setLabelGroup(String labelGroup) {
+		super.setLabelGroup(labelGroup);
+		
+		getJTextArea().setText("I\'m a JTextArea object in the \"Panel\" with:\n\nID: " + getID() + "\nLabel: " + getLabel() + "\nLabelGroup: " + getLabelGroup());
+	}
+
+	public void accept() {
+	}
+
+	public void apply() {
+	}
+
+	public void cancel() {
+	}
+
+	public void selected() {
+		System.out.println("I'm the IPanel: " + toString() + "\n and I've been selected. My information is: " +
+				 "\n\tID: " + getID() + "\n\tLABEL_GROUP: " + getLabelGroup() + "\n\tLABEL: " + getLabel() + "\n\tCLASS: " + getClass() +
+				 "\n\tMy Preferred Size: " + getPreferredSize() + "\n\tAnd My size: " + getSize());
+	}
+}
Index: tags/v2_0_0_Build_2050/applications/appgvSIG/src-test/org/gvsig/app/panelGroup/samples/SampleUndefinedPreferredSizeExceptionPanel.java
===================================================================
--- tags/v2_0_0_Build_2050/applications/appgvSIG/src-test/org/gvsig/app/panelGroup/samples/SampleUndefinedPreferredSizeExceptionPanel.java	(revision 0)
+++ tags/v2_0_0_Build_2050/applications/appgvSIG/src-test/org/gvsig/app/panelGroup/samples/SampleUndefinedPreferredSizeExceptionPanel.java	(revision 38653)
@@ -0,0 +1,144 @@
+/* gvSIG. Sistema de Informaci�n Geogr�fica de la Generalitat Valenciana
+ *
+ * Copyright (C) 2007 IVER T.I. and Generalitat Valenciana.
+ *
+ * This program is free software; you can redistribute it and/or
+ * modify it under the terms of the GNU General Public License
+ * as published by the Free Software Foundation; either version 2
+ * of the License, or (at your option) any later version.
+ *
+ * This program is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
+ * GNU General Public License for more details.
+ *
+ * You should have received a copy of the GNU General Public License
+ * along with this program; if not, write to the Free Software
+ * Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA  02111-1307,USA.
+ */
+
+package org.gvsig.app.panelGroup.samples;
+
+import java.awt.Color;
+import java.io.Serializable;
+
+import javax.swing.JScrollPane;
+import javax.swing.JTextArea;
+
+import org.gvsig.gui.beans.panelGroup.panels.AbstractPanel;
+
+/**
+ * 
+ * @version 30/11/2007
+ * @author Pablo Piqueras Bartolom� (pablo.piqueras@iver.es) 
+ */
+public class SampleUndefinedPreferredSizeExceptionPanel extends AbstractPanel implements Serializable {
+	private static final long serialVersionUID = 1210497562221898739L;
+
+	/**
+	 * <p>Element for the interface.</p>
+	 */
+	private JTextArea jTextArea = null;
+	
+	/**
+	 * @see AbstractPanel#AbstractPanel()
+	 */
+	public SampleUndefinedPreferredSizeExceptionPanel() {
+		super();
+		initialize();
+	}
+	
+	/**
+	 * @see AbstractPanel#AbstractPanel(String, String, String)
+	 */
+	public SampleUndefinedPreferredSizeExceptionPanel(String id, String label, String labelGroup) {
+		super(id, label, labelGroup);
+		initialize();
+	}
+	
+	@Override
+	protected void initialize() {
+		add(new JScrollPane(getJTextArea()));
+		setToolTipText(getID());
+		
+		setID(Samples_ExtensionPointsOfIPanels.PANELS1_IDS[0]);
+		setLabel(Samples_ExtensionPointsOfIPanels.PANELS1_LABELS[0]);
+		setLabelGroup(Samples_ExtensionPointsOfIPanels.PANELS1_LABELGROUPS[0]);
+		resetChangedStatus();
+	}
+	
+	/**
+	 * This method initializes jTextArea
+	 *
+	 * @return JTextArea
+	 */
+	private JTextArea getJTextArea() {
+		if (jTextArea == null) {
+			jTextArea = new JTextArea(5, 40);
+			jTextArea.setText("I\'m a JTextArea object in the \"Panel\" with:\n\nID: " + getID() + "\nLabel: " + getLabel() + "\nLabelGroup: " + getLabelGroup());
+			jTextArea.setEditable(false);
+			jTextArea.setBackground(Color.RED);
+		}
+
+		return jTextArea;
+	}
+	
+	@Override
+	public void setID(String id) {
+		super.setID(id);
+		
+		setToolTipText(getID());
+		getJTextArea().setText("I\'m a JTextArea object in the \"Panel\" with:\n\nID: " + getID() + "\nLabel: " + getLabel() + "\nLabelGroup: " + getLabelGroup());
+		hasChanged = true;
+	}
+
+	@Override
+	public void setLabel(String label) {
+		super.setLabel(label);
+		
+		getJTextArea().setText("I\'m a JTextArea object in the \"Panel\" with:\n\nID: " + getID() + "\nLabel: " + getLabel() + "\nLabelGroup: " + getLabelGroup());
+		hasChanged = true;
+	}
+
+	@Override
+	public void setLabelGroup(String labelGroup) {
+		super.setLabelGroup(labelGroup);
+		
+		getJTextArea().setText("I\'m a JTextArea object in the \"Panel\" with:\n\nID: " + getID() + "\nLabel: " + getLabel() + "\nLabelGroup: " + getLabelGroup());
+		hasChanged = true;
+	}
+
+	/*
+	 * (non-Javadoc)
+	 * @see org.gvsig.gui.beans.panelGroup.panels.IPanel#accept()
+	 */
+	public void accept() {
+		System.out.println("I'm the IPanel: " + toString() + "\n and I'm executing an 'accept' method.");
+	}
+
+	/*
+	 * (non-Javadoc)
+	 * @see org.gvsig.gui.beans.panelGroup.panels.IPanel#apply()
+	 */
+	public void apply() {
+		System.out.println("I'm the IPanel: " + toString() + "\n and I'm executing an 'apply' method.");
+	}
+
+	/*
+	 * (non-Javadoc)
+	 * @see org.gvsig.gui.beans.panelGroup.panels.IPanel#cancel()
+	 */
+	public void cancel() {
+		System.out.println("I'm the IPanel: " + toString() + "\n and I'm executing a 'cancel' method.");
+	}
+
+	/*
+	 * (non-Javadoc)
+	 * @see org.gvsig.gui.beans.panelGroup.panels.IPanel#selected()
+	 */
+	public void selected() {
+		System.out.println("I'm the IPanel: " + toString() + "\n and I've been selected. My information is: " +
+				 "\n\tID: " + getID() + "\n\tLABEL_GROUP: " + getLabelGroup() + "\n\tLABEL: " + getLabel() + "\n\tCLASS: " + getClass() +
+				 "\n\tMy Preferred Size: " + getPreferredSize() + "\n\tAnd My size: " + getSize());
+	}
+}
Index: tags/v2_0_0_Build_2050/applications/appgvSIG/src-test/org/gvsig/app/panelGroup/samples/SampleInfoPanel.java
===================================================================
--- tags/v2_0_0_Build_2050/applications/appgvSIG/src-test/org/gvsig/app/panelGroup/samples/SampleInfoPanel.java	(revision 0)
+++ tags/v2_0_0_Build_2050/applications/appgvSIG/src-test/org/gvsig/app/panelGroup/samples/SampleInfoPanel.java	(revision 38653)
@@ -0,0 +1,140 @@
+/* gvSIG. Sistema de Informaci�n Geogr�fica de la Generalitat Valenciana
+ *
+ * Copyright (C) 2007 IVER T.I. and Generalitat Valenciana.
+ *
+ * This program is free software; you can redistribute it and/or
+ * modify it under the terms of the GNU General Public License
+ * as published by the Free Software Foundation; either version 2
+ * of the License, or (at your option) any later version.
+ *
+ * This program is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
+ * GNU General Public License for more details.
+ *
+ * You should have received a copy of the GNU General Public License
+ * along with this program; if not, write to the Free Software
+ * Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA  02111-1307,USA.
+ */
+
+package org.gvsig.app.panelGroup.samples;
+
+import java.awt.Color;
+import java.awt.Dimension;
+import java.awt.event.MouseAdapter;
+import java.awt.event.MouseEvent;
+import java.io.Serializable;
+
+import javax.swing.JScrollPane;
+import javax.swing.JTextArea;
+
+import org.gvsig.gui.beans.panelGroup.panels.AbstractPanel;
+
+/**
+ * <p>Sample of {@link AbstractPanel AbstractPanel}.</p>
+ * 
+ * @version 16/10/2007
+ * @author Pablo Piqueras Bartolom� (pablo.piqueras@iver.es) 
+ */
+public class SampleInfoPanel extends AbstractPanel implements Serializable {
+	private static final long serialVersionUID = -1629511810619122126L;
+
+	/**
+	 * <p>Element for the interface.</p>
+	 */
+	private JTextArea jTextArea = null;
+	
+	/**
+	 * @see AbstractPanel#AbstractPanel()
+	 */
+	public SampleInfoPanel() {
+		super();
+		initialize();
+	}
+	
+	/**
+	 * @see AbstractPanel#AbstractPanel(String, String, String)
+	 */
+	public SampleInfoPanel(String id, String label, String labelGroup) {
+		super(id, label, labelGroup);
+		initialize();
+	}
+	
+	@Override
+	protected void initialize() {
+		add(new JScrollPane(getJTextArea()));
+		setToolTipText(getID());
+		
+		setID(Samples_ExtensionPointsOfIPanels.PANELS1_IDS[0]);
+		setLabel(Samples_ExtensionPointsOfIPanels.PANELS1_LABELS[0]);
+		setLabelGroup(Samples_ExtensionPointsOfIPanels.PANELS1_LABELGROUPS[0]);
+		setPreferredSize(new Dimension(Samples_ExtensionPointsOfIPanels.PANELS_DEFAULT_WIDTH, Samples_ExtensionPointsOfIPanels.PANELS_DEFAULT_HEIGHT));
+		resetChangedStatus();
+	}
+	
+	/**
+	 * This method initializes jTextArea
+	 *
+	 * @return JTextArea
+	 */
+	private JTextArea getJTextArea() {
+		if (jTextArea == null) {
+			jTextArea = new JTextArea(5, 40);
+			jTextArea.setText("I\'m a JTextArea object in the \"Panel\" with:\n\nID: " + getID() + "\nLabel: " + getLabel() + "\nLabelGroup: " + getLabelGroup());
+			jTextArea.setEditable(false);
+			jTextArea.setBackground(Color.RED);
+			
+			jTextArea.addMouseListener(new MouseAdapter() {
+				
+				public void mouseClicked(MouseEvent e) {
+					if (getPanelGroup() != null) {
+						getPanelGroup().setEnabledAcceptButton(! getPanelGroup().isEnabledAcceptButton());
+					}	
+				}
+			});
+		}
+
+		return jTextArea;
+	}
+	
+	@Override
+	public void setID(String id) {
+		super.setID(id);
+		
+		setToolTipText(getID());
+		getJTextArea().setText("I\'m a JTextArea object in the \"Panel\" with:\n\nID: " + getID() + "\nLabel: " + getLabel() + "\nLabelGroup: " + getLabelGroup());
+	}
+
+	@Override
+	public void setLabel(String label) {
+		super.setLabel(label);
+		
+		getJTextArea().setText("I\'m a JTextArea object in the \"Panel\" with:\n\nID: " + getID() + "\nLabel: " + getLabel() + "\nLabelGroup: " + getLabelGroup());
+	}
+
+	@Override
+	public void setLabelGroup(String labelGroup) {
+		super.setLabelGroup(labelGroup);
+		
+		getJTextArea().setText("I\'m a JTextArea object in the \"Panel\" with:\n\nID: " + getID() + "\nLabel: " + getLabel() + "\nLabelGroup: " + getLabelGroup());
+	}
+
+
+	public void accept() {
+	}
+
+
+	public void apply() {
+	}
+
+
+	public void cancel() {
+	}
+
+
+	public void selected() {
+		System.out.println("I'm the IPanel: " + toString() + "\n and I've been selected. My information is: " +
+				 "\n\tID: " + getID() + "\n\tLABEL_GROUP: " + getLabelGroup() + "\n\tLABEL: " + getLabel() + "\n\tCLASS: " + getClass() +
+				 "\n\tMy Preferred Size: " + getPreferredSize() + "\n\tAnd My size: " + getSize());
+	}
+}
Index: tags/v2_0_0_Build_2050/applications/appgvSIG/src-test/org/gvsig/app/panelGroup/samples/Samples_ExtensionPointsOfIPanels.java
===================================================================
--- tags/v2_0_0_Build_2050/applications/appgvSIG/src-test/org/gvsig/app/panelGroup/samples/Samples_ExtensionPointsOfIPanels.java	(revision 0)
+++ tags/v2_0_0_Build_2050/applications/appgvSIG/src-test/org/gvsig/app/panelGroup/samples/Samples_ExtensionPointsOfIPanels.java	(revision 38653)
@@ -0,0 +1,154 @@
+/* gvSIG. Sistema de Informaci�n Geogr�fica de la Generalitat Valenciana
+ *
+ * Copyright (C) 2007 IVER T.I. and Generalitat Valenciana.
+ *
+ * This program is free software; you can redistribute it and/or
+ * modify it under the terms of the GNU General Public License
+ * as published by the Free Software Foundation; either version 2
+ * of the License, or (at your option) any later version.
+ *
+ * This program is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
+ * GNU General Public License for more details.
+ *
+ * You should have received a copy of the GNU General Public License
+ * along with this program; if not, write to the Free Software
+ * Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA  02111-1307,USA.
+ */
+
+package org.gvsig.app.panelGroup.samples;
+
+import org.gvsig.gui.beans.panelGroup.PanelGroupManager;
+import org.gvsig.gui.beans.panelGroup.loaders.PanelGroupLoaderFromList;
+import org.gvsig.gui.beans.panelGroup.panels.AbstractPanel;
+import org.gvsig.gui.beans.panelGroup.tabbedPanel.TabbedPanel;
+import org.gvsig.gui.beans.panelGroup.treePanel.TreePanel;
+import org.gvsig.tools.ToolsLocator;
+import org.gvsig.tools.extensionpoint.ExtensionPoint;
+import org.gvsig.tools.extensionpoint.ExtensionPointManager;
+
+import org.gvsig.app.panelGroup.PanelGroupDialog;
+import org.gvsig.app.panelGroup.loaders.PanelGroupLoaderFromExtensionPoint;
+
+/**
+ * <p>
+ * This class has information to create samples to test
+ * {@link PanelGroupManager PanelGroupManager}, {@link TabbedPanel TabbedPanel},
+ * {@link TreePanel TreePanel}, {@link AbstractPanel AbstractPanel},
+ * {@link PanelGroupLoaderUtilities PanelGroupLoaderUtilities},
+ * {@link PanelGroupLoaderFromList PanelGroupLoaderFromList},
+ * {@link PanelGroupLoaderFromExtensionPoint PanelGroupLoaderFromExtensionPoint}
+ * , and {@link PanelGroupDialog PanelGroupDialog}.
+ * </p>
+ * 
+ * @version 16/10/2007
+ * @author Pablo Piqueras Bartolom� (pablo.piqueras@iver.es)
+ */
+public class Samples_ExtensionPointsOfIPanels {
+	public final static String EXTENSIONPOINT1_NAME = "RasterLayerProperties";
+	public final static String EXTENSIONPOINT2_NAME = "ImaginaryLayerProperties";
+	public final static String EXTENSIONPOINT3_NAME = "Other tests";
+	public final static String EXTENSIONPOINT4_NAME = "Test 1 exceptions";
+	public final static String EXTENSIONPOINT5_NAME = "Test 2 exceptions";
+	public final static String EXTENSIONPOINT6_NAME = "Test 3 exceptions";
+	public final static String EXTENSIONPOINT7_NAME = "Test 4 exceptions";
+	public final static String EXTENSIONPOINT8_NAME = "Test 5 exceptions";
+	public final static String EXTENSIONPOINT9_NAME = "Test 6 exceptions";
+	public final static String EXTENSIONPOINT10_NAME = "Test 7 exceptions";
+	public final static String[] EXTENSIONPOINTS1_NAMES = {"Information", "Bands", "Transparency", "Enhanced", "PanSharpening", "Scale"};
+	public final static String[] EXTENSIONPOINTS2_NAMES = {"Information", "Transparency", "Scale"};
+	public final static String[] EXTENSIONPOINTS3_OTHER_NAMES = {"SamplePanelWithoutGroupLabel", "SamplePanelGroupLabelRepeated"};
+	public final static String[] EXTENSIONPOINTS4_NAMES = {
+			"SampleInitializingExcetionPanel", "SampleInfoPanel" }; // Test 'ListCouldntLoadPanelFromListException' with any 'Exception'
+	public final static String[] EXTENSIONPOINTS5_NAMES = {"SampleInfoPanel", "SampleUndefinedPreferredSizeExceptionPanel"}; // Test 'ListCouldntAddPanelException' with a 'PanelWithNoPreferredSizeDefinedException'
+	public final static String[] EXTENSIONPOINTS6_NAMES = {}; // Test 'ListCouldntAddPanelException' with a 'EmptyPanelGroupException'
+	public final static String[] EXTENSIONPOINTS7_NAMES = {"SampleInvisiblePanel.class"}; // Test 'ListCouldntAddPanelException' with a 'EmptyPanelGroupGUIException'
+	public final static String[] EXTENSIONPOINTS8_NAMES = {"SampleInitializingExcetionPanel", "SampleUndefinedPreferredSizeExceptionPanel"}; // Test 'ListCouldntAddPanelException' with a 'PanelWithNoPreferredSizeDefinedException', a 'EmptyPanelGroupException' and a 'ListCouldntLoadPanelFromListException' with any 'Exception'
+	public final static String[] EXTENSIONPOINTS9_NAMES = {"SampleInvisiblePanel", "SampleInitializingExcetionPanel", "SampleUndefinedPreferredSizeExceptionPanel"}; // Test 'ListCouldntAddPanelException' with a 'PanelWithNoPreferredSizeDefinedException', a 'EmptyPanelGroupGUIException' and a 'ListCouldntLoadPanelFromListException' with any 'Exception'
+	public final static String[] EXTENSIONPOINTS10_NAMES = {"SampleBandSetupPanel", "SampleInvisiblePanel", "SampleInitializingExcetionPanel", "SampleUndefinedPreferredSizeExceptionPanel"}; // Test 'ListCouldntAddPanelException' with a 'PanelWithNoPreferredSizeDefinedException', a EmptyPanelGroupGUIException and a 'ListCouldntLoadPanelFromListException' with any 'Exception'
+	public final static Class[] EXTENSIONPOINTS1_CLASSES = {SampleInfoPanel.class, SampleBandSetupPanel.class, SampleTransparencyPanel.class, SampleEnhancedPanel.class, SamplePanSharpeningPanel.class, SampleScalePanel.class};
+	public final static Class[] EXTENSIONPOINTS2_CLASSES = {SampleInfoPanel.class, SampleTransparencyPanel.class, SampleScalePanel.class};
+	public final static Class[] OTHER_PANELS_EXTENSIONPOINTS3_CLASSES = {SamplePanelWithoutGroupLabel.class, SamplePanelGroupLabelRepeated.class};
+	public final static Class[] EXTENSIONPOINTS4_CLASSES = {
+			SampleInitializingExcetionPanel.class, SampleInfoPanel.class }; // Test 'ListCouldntLoadPanelFromListException' with any 'Exception'
+	public final static Class[] EXTENSIONPOINTS5_CLASSES = {SampleInfoPanel.class, SampleUndefinedPreferredSizeExceptionPanel.class}; // Test 'ListCouldntAddPanelException' with a 'PanelWithNoPreferredSizeDefinedException'
+	public final static Class[] EXTENSIONPOINTS6_CLASSES = {}; // Test 'ListCouldntAddPanelException' with a 'EmptyPanelGroupException'
+	public final static Class[] EXTENSIONPOINTS7_CLASSES = {SampleInvisiblePanel.class}; // Test 'ListCouldntAddPanelException' with a 'EmptyPanelGroupGUIException'
+	public final static Class[] EXTENSIONPOINTS8_CLASSES = {SampleInitializingExcetionPanel.class, SampleUndefinedPreferredSizeExceptionPanel.class}; // Test 'ListCouldntAddPanelException' with a 'PanelWithNoPreferredSizeDefinedException', a 'EmptyPanelGroupException' and a 'ListCouldntLoadPanelFromListException' with any 'Exception'
+	public final static Class[] EXTENSIONPOINTS9_CLASSES = {SampleInvisiblePanel.class, SampleInitializingExcetionPanel.class, SampleUndefinedPreferredSizeExceptionPanel.class}; // Test 'ListCouldntAddPanelException' with a 'PanelWithNoPreferredSizeDefinedException', a 'EmptyPanelGroupGUIException' and a 'ListCouldntLoadPanelFromListException' with any 'Exception'
+	public final static Class[] EXTENSIONPOINTS10_CLASSES = {SampleBandSetupPanel.class, SampleInvisiblePanel.class, SampleInitializingExcetionPanel.class, SampleUndefinedPreferredSizeExceptionPanel.class}; // Test 'ListCouldntAddPanelException' with a 'PanelWithNoPreferredSizeDefinedException', a EmptyPanelGroupGUIException and a 'ListCouldntLoadPanelFromListException' with any 'Exception'
+	public final static Object REFERENCE1 = new String("Raster Layer");
+	public final static Object REFERENCE2 = new String("Imaginary Layer");
+	public final static Object REFERENCE3 = new String("Other tests");
+	public final static String REFERENCE1_NAME = "Raster Layer reference";
+	public final static String REFERENCE2_NAME = "Imaginary Layer reference";
+	public final static String REFERENCE3_NAME = "Other tests reference";
+	public final static String[] PANELS1_IDS = {"Information_ID", "Bands_ID", "Transparency_ID", "Enhanced_ID", "PanSharpening_ID", "Scale_ID"};
+	public final static String[] PANELS2_IDS = {"Information_ID", "Transparency_ID", "Scale_ID"};
+	public final static String[] PANELS3_IDS = {"WithoutGroup_ID", "GroupLabelRepeated_ID"};
+	public final static String[] PANELS1_LABELS = {"Information_LABEL", "Bands_LABEL", "Transparency_LABEL", "Enhanced_LABEL", "PanSharpening_LABEL", "Scale_LABEL"};
+	public final static String[] PANELS2_LABELS = {"Information_LABEL", "Transparency_LABEL", "Scale_LABEL"};
+	public final static String[] PANELS3_LABELS = {"WithoutGroup_LABEL", "GroupLabelRepeated_LABEL"};
+	public final static String[] PANELS1_LABELGROUPS = {"Information_LABELGROUP", "Bands_LABELGROUP", "Transparency_LABELGROUP", "Enhanced_LABELGROUP", "PanSharpening_LABELGROUP", "Scale_LABELGROUP"};
+	public final static String[] PANELS2_LABELGROUPS = {"Information_LABELGROUP", "Transparency_LABELGROUP", "Scale_LABELGROUP"};
+	public final static String[] PANELS3_LABELGROUPS = {null, "GroupLabelRepeated_LABELGROUP"};
+	public final static short PANELS_DEFAULT_WIDTH = 500;
+	public final static short PANELS_DEFAULT_HEIGHT = 400;
+
+
+	/**
+	 * <p>Loads the information of the sample.</p>
+	 */
+	public static void loadSample() {
+			ExtensionPointManager epMan = ToolsLocator.getExtensionPointManager();
+
+		ExtensionPoint ep = epMan.add(EXTENSIONPOINT1_NAME, "");
+
+		ep.append(EXTENSIONPOINTS1_NAMES[0], "", EXTENSIONPOINTS1_CLASSES[0]);
+		ep.append(EXTENSIONPOINTS1_NAMES[1], "", EXTENSIONPOINTS1_CLASSES[1]);
+		ep.append(EXTENSIONPOINTS1_NAMES[2], "", EXTENSIONPOINTS1_CLASSES[2]);
+		ep.append(EXTENSIONPOINTS1_NAMES[3], "", EXTENSIONPOINTS1_CLASSES[3]);
+		ep.append(EXTENSIONPOINTS1_NAMES[4], "", EXTENSIONPOINTS1_CLASSES[4]);
+		ep.append(EXTENSIONPOINTS1_NAMES[5], "", EXTENSIONPOINTS1_CLASSES[5]);
+
+		ep = epMan.add(EXTENSIONPOINT2_NAME, "");
+		ep.append(EXTENSIONPOINTS2_NAMES[0], "", EXTENSIONPOINTS2_CLASSES[0]);
+		ep.append(EXTENSIONPOINTS2_NAMES[1], "", EXTENSIONPOINTS2_CLASSES[1]);
+		ep.append(EXTENSIONPOINTS2_NAMES[2], "", EXTENSIONPOINTS2_CLASSES[2]);
+
+		ep = epMan.add(EXTENSIONPOINT3_NAME, "");
+		ep.append(EXTENSIONPOINTS3_OTHER_NAMES[0], "",
+				OTHER_PANELS_EXTENSIONPOINTS3_CLASSES[0]);
+		ep.append(EXTENSIONPOINTS3_OTHER_NAMES[1], "",
+				OTHER_PANELS_EXTENSIONPOINTS3_CLASSES[1]);
+
+		ep = epMan.add(EXTENSIONPOINT4_NAME, "");
+		ep.append(EXTENSIONPOINTS4_NAMES[0], "", EXTENSIONPOINTS4_CLASSES[0]);
+		ep.append(EXTENSIONPOINTS4_NAMES[1], "", EXTENSIONPOINTS4_CLASSES[1]);
+
+		ep = epMan.add(EXTENSIONPOINT5_NAME, "");
+		ep.append(EXTENSIONPOINTS5_NAMES[0], "", EXTENSIONPOINTS5_CLASSES[0]);
+		ep.append(EXTENSIONPOINTS5_NAMES[1], "", EXTENSIONPOINTS5_CLASSES[1]);
+
+		epMan.add(EXTENSIONPOINT6_NAME, "");
+
+		ep = epMan.add(EXTENSIONPOINT7_NAME, "");
+		ep.append(EXTENSIONPOINTS7_NAMES[0], "", EXTENSIONPOINTS7_CLASSES[0]);
+
+		ep = epMan.add(EXTENSIONPOINT8_NAME, "");
+		ep.append(EXTENSIONPOINTS8_NAMES[0], "", EXTENSIONPOINTS8_CLASSES[0]);
+		ep.append(EXTENSIONPOINTS8_NAMES[1], "", EXTENSIONPOINTS8_CLASSES[1]);
+
+		ep = epMan.add(EXTENSIONPOINT9_NAME, "");
+		ep.append(EXTENSIONPOINTS9_NAMES[0], "", EXTENSIONPOINTS9_CLASSES[0]);
+		ep.append(EXTENSIONPOINTS9_NAMES[1], "", EXTENSIONPOINTS9_CLASSES[1]);
+		ep.append(EXTENSIONPOINTS9_NAMES[2], "", EXTENSIONPOINTS9_CLASSES[2]);
+
+		ep = epMan.add(EXTENSIONPOINT10_NAME, "");
+		ep.append(EXTENSIONPOINTS10_NAMES[0], "", EXTENSIONPOINTS10_CLASSES[0]);
+		ep.append(EXTENSIONPOINTS10_NAMES[1], "", EXTENSIONPOINTS10_CLASSES[1]);
+		ep.append(EXTENSIONPOINTS10_NAMES[2], "", EXTENSIONPOINTS10_CLASSES[2]);
+		ep.append(EXTENSIONPOINTS10_NAMES[3], "", EXTENSIONPOINTS10_CLASSES[3]);
+	}
+}
Index: tags/v2_0_0_Build_2050/applications/appgvSIG/src-test/org/gvsig/app/test/Persistence.java
===================================================================
--- tags/v2_0_0_Build_2050/applications/appgvSIG/src-test/org/gvsig/app/test/Persistence.java	(revision 0)
+++ tags/v2_0_0_Build_2050/applications/appgvSIG/src-test/org/gvsig/app/test/Persistence.java	(revision 38653)
@@ -0,0 +1,94 @@
+package org.gvsig.app.test;
+
+import junit.framework.TestCase;
+
+import org.gvsig.app.extension.ProjectExtension;
+
+/**
+ * @author Fernando Gonz�lez Cort�s
+ */
+//TODO comentado para que compile
+public class Persistence extends TestCase {
+	private ProjectExtension pe;
+
+	/*
+	 * @see TestCase#setUp()
+	 */
+	protected void setUp() throws Exception {
+		pe = new ProjectExtension();
+//		pe.inicializar();
+//		LayerFactory.setDriversPath(
+//		"/root/workspace/Andami/gvSIG/extensiones/com.iver.cit.gvsig/drivers");
+//
+//		LayerFactory.getDataSourceFactory().addFileDataSource("gdbms dbf driver", "prueba",
+//				"test/cities.dbf");
+
+	}
+
+	public void testPersist() throws Throwable {
+//		Project p = new Project();
+//
+//		/*
+//		 * A�adimos una vista con una capa
+//		 */
+//		ProjectView v = new ProjectView();
+//		ViewPort vp = new ViewPort( CRSFactory.getCRS("EPSG:23030"));
+//		vp.setImageSize(new Dimension(500, 500));
+//
+//		MapContext fmap = new MapContext(vp);
+//		v.setMapContext(fmap);
+//		FLayer l = LayerFactory.createLayer("Vias",
+//			(VectorialFileDriver) LayerFactory.getDM().getDriver("gvSIG shp driver"),
+//			new File("test/cities.shp"),
+//			CRSFactory.getCRS("EPSG:23030"));
+//		fmap.getLayers().addLayer(l);
+//
+//		/*
+//		 * A�adimos la tabla del tema anterior
+//		 */
+//		SelectableDataSource sds1 = ((FLyrVect) l).getRecordset();
+//		EditableAdapter ea1 = new EditableAdapter();
+//		ea1.setOriginalDataSource(sds1);
+//
+//		ProjectTable pt1 = ProjectFactory.createTable("tabla", ea1);
+//		p.addDocument(pt1);
+//
+//		/*
+//		 * A�adimos otra tabla
+//		 */
+//		SelectableDataSource sds2 = new SelectableDataSource(LayerFactory.getDataSourceFactory().createRandomDataSource("prueba", DataSourceFactory.MANUAL_OPENING));
+//		EditableAdapter ea2 = new EditableAdapter();
+//		ea2.setOriginalDataSource(sds2);
+//		ProjectTable pt2 = ProjectFactory.createTable("tabla2", ea2);
+//		p.addTable(pt2);
+//
+//		/*
+//		 * Creamos un join
+//		 */
+//		String sql = "custom com_iver_cit_gvsig_arcjoin tables '"+
+//		sds1.getName()+"', '"+sds1.getName()+"' values(NAME,NAME);";
+//
+//		SelectableDataSource result = new SelectableDataSource(
+//				LayerFactory.getDataSourceFactory()
+//				.executeSQL(sql, DataSourceFactory.MANUAL_OPENING));
+//		EditableAdapter auxea=new EditableAdapter();
+//		auxea.setOriginalDataSource(result);
+//
+//		pt1.replaceDataSource(auxea);
+//
+//		/*
+//		 * Guardamos y cargamos
+//		 */
+//		File temp = File.createTempFile("junit-", ".gvp");
+//		temp.deleteOnExit();
+//		pe.writeProject(temp, p);
+//
+//		Project p2 = pe.readProject(temp);
+//
+//		/*
+//		 * Comprobamos que las dos tablas son id�nticas
+//		 */
+//		assertTrue(((ProjectTable)p2.getDocumentsByType(ProjectTableFactory.registerName).get(0)).getModel().getRecordset().getAsString().equals(((ProjectTable)p.getTables().get(0)).getModel().getRecordset().getAsString()));
+//		assertTrue(((ProjectTable)p2.getDocumentsByType(ProjectTableFactory.registerName).get(1)).getModel().getRecordset().getAsString().equals(((ProjectTable)p.getTables().get(1)).getModel().getRecordset().getAsString()));
+	}
+}

Property changes on: tags/v2_0_0_Build_2050/applications/appgvSIG/src-test/org/gvsig/app/test/Persistence.java
___________________________________________________________________
Added: svn:keywords
   + Author Date Id Revision
Added: svn:eol-style
   + native

Index: tags/v2_0_0_Build_2050/applications/appgvSIG/src-test/org/gvsig/app/sqlQueryValidation/TestSQLQueryValidation.java
===================================================================
--- tags/v2_0_0_Build_2050/applications/appgvSIG/src-test/org/gvsig/app/sqlQueryValidation/TestSQLQueryValidation.java	(revision 0)
+++ tags/v2_0_0_Build_2050/applications/appgvSIG/src-test/org/gvsig/app/sqlQueryValidation/TestSQLQueryValidation.java	(revision 38653)
@@ -0,0 +1,410 @@
+package org.gvsig.app.sqlQueryValidation;
+
+import junit.framework.TestCase;
+
+/* gvSIG. Sistema de Informaci�n Geogr�fica de la Generalitat Valenciana
+ *
+ * Copyright (C) 2004 IVER T.I. and Generalitat Valenciana.
+ *
+ * This program is free software; you can redistribute it and/or
+ * modify it under the terms of the GNU General Public License
+ * as published by the Free Software Foundation; either version 2
+ * of the License, or (at your option) any later version.
+ *
+ * This program is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
+ * GNU General Public License for more details.
+ *
+ * You should have received a copy of the GNU General Public License
+ * along with this program; if not, write to the Free Software
+ * Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA  02111-1307,USA.
+ *
+ * For more information, contact:
+ *
+ *  Generalitat Valenciana
+ *   Conselleria d'Infraestructures i Transport
+ *   Av. Blasco Ib��ez, 50
+ *   46010 VALENCIA
+ *   SPAIN
+ *
+ *      +34 963862235
+ *   gvsig@gva.es
+ *      www.gvsig.gva.es
+ *
+ *    or
+ *
+ *   IVER T.I. S.A
+ *   Salamanca 50
+ *   46005 Valencia
+ *   Spain
+ *
+ *   +34 963163400
+ *   dac@iver.es
+ */
+
+/**
+ * Tests the methods of the class SQLQueryValidation
+ *    (This class is made without inner static methods for don't create problems to Zql, in this way,
+ *     it's possible to add more tests, with or without long queries.)
+ * 
+ * @author Pablo Piqueras Bartolom� (p_queras@hotmail.com)
+ */
+ public class TestSQLQueryValidation extends TestCase{
+	
+	/*
+	 *  (non-Javadoc)
+	 * @see junit.framework.TestCase#setUp()
+	 */
+	protected void setUp() throws Exception {
+		super.setUp();
+	}
+
+	/*
+	 *  (non-Javadoc)
+	 * @see junit.framework.TestCase#tearDown()
+	 */
+	protected void tearDown() throws Exception {
+		super.tearDown();
+	}
+	
+	/**
+	 * A test (Correct)
+	 */
+	public void test1() {
+		String query = "SELECT r.name, f.id FROM room r, flat f WHERE (r.user_name LIKE 'P%') AND (r.flat = f.id) AND (r.color_wall LIKE 'white') AND (r.height < 2.20);";
+		
+		System.out.println("�Es v�lida '" + query + "' ?");
+		SQLQueryValidation sqlQueryValidation = new SQLQueryValidation(query, false);
+
+		if (sqlQueryValidation.validateQuery()) {
+			System.out.println("Yes.");
+		}
+		else {
+			System.out.println("No.");
+			System.out.println(sqlQueryValidation.getErrorPositionAsMessage());
+			System.out.println(sqlQueryValidation.getErrorMessage());
+			fail();
+		}
+	}
+	
+	/**
+	 * A test (Correct)
+	 */
+	public void test2() {
+		String query = "SELECT * FROM House;";
+
+		System.out.println("�Es v�lida '" + query + "' ?");
+		SQLQueryValidation sqlQueryValidation = new SQLQueryValidation(query, false);
+
+		if (sqlQueryValidation.validateQuery()) {
+			System.out.println("Yes.");
+		}
+		else {
+			System.out.println("No.");
+			System.out.println(sqlQueryValidation.getErrorPositionAsMessage());
+			System.out.println(sqlQueryValidation.getErrorMessage());
+			fail();
+		}
+	}
+
+	/**
+	 * A test (Incorrect)
+	 */
+	public void test3() {
+		String query = "SELECT a* FROM House;";
+
+		System.out.println("�Es v�lida '" + query + "' ?");
+		SQLQueryValidation sqlQueryValidation = new SQLQueryValidation(query, false);
+
+		if (sqlQueryValidation.validateQuery()) {
+			System.out.println("Yes.");
+		}
+		else {
+			System.out.println("No.");
+			System.out.println(sqlQueryValidation.getErrorPositionAsMessage());
+			System.out.println(sqlQueryValidation.getErrorMessage());
+			fail();
+		}
+	}
+	
+	/**
+	 * A test (Correct)
+	 */
+	public void test4() {
+		String query = "SELECT * FROM House;";
+
+		System.out.println("�Es v�lida '" + query + "' ?");
+		SQLQueryValidation sqlQueryValidation = new SQLQueryValidation(query, false);
+
+		if (sqlQueryValidation.validateQuery()) {
+			System.out.println("Yes.");
+		}
+		else {
+			System.out.println("No.");
+			System.out.println(sqlQueryValidation.getErrorPositionAsMessage());
+			System.out.println(sqlQueryValidation.getErrorMessage());
+			fail();
+		}
+	}
+
+	/**
+	 * A test (Correct)
+	 */
+	public void test5() {
+		String query = "r.level = f.level AND r.user_name LIKE \'P%\';";
+
+		System.out.println("�Es v�lida '" + query + "' ?");
+		SQLQueryValidation sqlQueryValidation = new SQLQueryValidation(query, true);
+
+		if (sqlQueryValidation.validateQuery()) {
+			System.out.println("Yes.");
+		}
+		else {
+			System.out.println("No.");
+			System.out.println(sqlQueryValidation.getErrorPositionAsMessage());
+			System.out.println(sqlQueryValidation.getErrorMessage());
+			fail();
+		}
+	}
+
+	/**
+	 * A test (Incorrect)
+	 */
+	public void test6() {
+		String query = "r.level = f.level a e3 w 	q3 	 �32	9'}97AND r.user_name LIKE \'P%\';";
+
+		System.out.println("�Es v�lida '" + query + "' ?");
+		SQLQueryValidation sqlQueryValidation = new SQLQueryValidation(query, true);
+
+		if (sqlQueryValidation.validateQuery()) {
+			System.out.println("Yes.");
+		}
+		else {
+			System.out.println("No.");
+			System.out.println(sqlQueryValidation.getErrorPositionAsMessage());
+			System.out.println(sqlQueryValidation.getErrorMessage());			
+			fail();
+		}
+	}
+	
+	/**
+	 * A test (Correct)
+	 */
+	public void test7() {
+		String query = "\"codigo\" = 'Canal d'Elx'";
+
+		System.out.println("�Es v�lida '" + query + "' ?");
+		SQLQueryValidation sqlQueryValidation = new SQLQueryValidation(query, true);
+
+		if (sqlQueryValidation.validateQuery()) {
+			System.out.println("Yes.");
+		}
+		else {
+			System.out.println("No.");
+			System.out.println(sqlQueryValidation.getErrorPositionAsMessage());
+			System.out.println(sqlQueryValidation.getErrorMessage());			
+			fail();
+		}
+	}
+	
+	/**
+	 * A test (Correct)
+	 */
+	public void test8() {
+		String query = "\"codigo\" = 'Canal de la M�nega'";
+
+		System.out.println("�Es v�lida '" + query + "' ?");
+		SQLQueryValidation sqlQueryValidation = new SQLQueryValidation(query, true);
+
+		if (sqlQueryValidation.validateQuery()) {
+			System.out.println("Yes.");
+		}
+		else {
+			System.out.println("No.");
+			System.out.println(sqlQueryValidation.getErrorPositionAsMessage());
+			System.out.println(sqlQueryValidation.getErrorMessage());			
+			fail();
+		}
+	}
+	
+	/**
+	 * A test (Correct)
+	 */
+	public void test9() {
+		String query = "\"codigo\" = 'Espa�a'";
+
+		System.out.println("�Es v�lida '" + query + "' ?");
+		SQLQueryValidation sqlQueryValidation = new SQLQueryValidation(query, true);
+
+		if (sqlQueryValidation.validateQuery()) {
+			System.out.println("Yes.");
+		}
+		else {
+			System.out.println("No.");
+			System.out.println(sqlQueryValidation.getErrorPositionAsMessage());
+			System.out.println(sqlQueryValidation.getErrorMessage());			
+			fail();
+		}
+	}
+	
+	/**
+	 * A test (Correct)
+	 */
+	public void test10() {
+		String query = "\"codigo\" = ('Canal d'Elx')";
+
+		System.out.println("�Es v�lida '" + query + "' ?");
+		SQLQueryValidation sqlQueryValidation = new SQLQueryValidation(query, true);
+
+		if (sqlQueryValidation.validateQuery()) {
+			System.out.println("Yes.");
+		}
+		else {
+			System.out.println("No.");
+			System.out.println(sqlQueryValidation.getErrorPositionAsMessage());
+			System.out.println(sqlQueryValidation.getErrorMessage());			
+			fail();
+		}
+	}
+	
+	/**
+	 * A test (Correct)
+	 */
+	public void test11() {
+		String query = "\"codigo\" = ( 'Canal d'Elx' )";
+
+		System.out.println("�Es v�lida '" + query + "' ?");
+		SQLQueryValidation sqlQueryValidation = new SQLQueryValidation(query, true);
+
+		if (sqlQueryValidation.validateQuery()) {
+			System.out.println("Yes.");
+		}
+		else {
+			System.out.println("No.");
+			System.out.println(sqlQueryValidation.getErrorPositionAsMessage());
+			System.out.println(sqlQueryValidation.getErrorMessage());			
+			fail();
+		}
+	}
+	
+	/**
+	 * A test (Correct)
+	 */
+	public void test12() {
+		String query = "\"codigo\" = ( 'Canal d'Elx')";
+
+		System.out.println("�Es v�lida '" + query + "' ?");
+		SQLQueryValidation sqlQueryValidation = new SQLQueryValidation(query, true);
+
+		if (sqlQueryValidation.validateQuery()) {
+			System.out.println("Yes.");
+		}
+		else {
+			System.out.println("No.");
+			System.out.println(sqlQueryValidation.getErrorPositionAsMessage());
+			System.out.println(sqlQueryValidation.getErrorMessage());			
+			fail();
+		}
+	}
+	
+	/**
+	 * A test (Correct)
+	 */
+	public void test13() {
+		String query = "\"codigo\" = ('Canal d'Elx' )";
+
+		System.out.println("�Es v�lida '" + query + "' ?");
+		SQLQueryValidation sqlQueryValidation = new SQLQueryValidation(query, true);
+
+		if (sqlQueryValidation.validateQuery()) {
+			System.out.println("Yes.");
+		}
+		else {
+			System.out.println("No.");
+			System.out.println(sqlQueryValidation.getErrorPositionAsMessage());
+			System.out.println(sqlQueryValidation.getErrorMessage());			
+			fail();
+		}
+	}	
+	
+	/**
+	 * A test (Incorrect)
+	 */
+	public void test14() {
+		String query = "\"codigo\" = ('Canal d' Elx' )";
+
+		System.out.println("�Es v�lida '" + query + "' ?");
+		SQLQueryValidation sqlQueryValidation = new SQLQueryValidation(query, true);
+
+		if (sqlQueryValidation.validateQuery()) {
+			System.out.println("Yes.");
+		}
+		else {
+			System.out.println("No.");
+			System.out.println(sqlQueryValidation.getErrorPositionAsMessage());
+			System.out.println(sqlQueryValidation.getErrorMessage());			
+			fail();
+		}
+	}
+		
+	/**
+	 * A test (Incorrect)
+	 */
+	public void test15() {
+		String query = "\"codigo\" = ('Canal d'Elx d'Alacant' )";
+
+		System.out.println("�Es v�lida '" + query + "' ?");
+		SQLQueryValidation sqlQueryValidation = new SQLQueryValidation(query, true);
+
+		if (sqlQueryValidation.validateQuery()) {
+			System.out.println("Yes.");
+		}
+		else {
+			System.out.println("No.");
+			System.out.println(sqlQueryValidation.getErrorPositionAsMessage());
+			System.out.println(sqlQueryValidation.getErrorMessage());			
+			fail();
+		}
+	}	
+	
+	/**
+	 * A test (Incorrect)
+	 */
+	public void test16() {
+		String query = "\"fecha\" = Date(11-ene-2004)";
+
+		System.out.println("�Es v�lida '" + query + "' ?");
+		SQLQueryValidation sqlQueryValidation = new SQLQueryValidation(query, true);
+
+		if (sqlQueryValidation.validateQuery()) {
+			System.out.println("Yes.");
+		}
+		else {
+			System.out.println("No.");
+			System.out.println(sqlQueryValidation.getErrorPositionAsMessage());
+			System.out.println(sqlQueryValidation.getErrorMessage());			
+			fail();
+		}
+	}
+	
+	/**
+	 * A test (Correct)
+	 */
+	public void test17() {
+		String query = "\"fecha\" = 11-ene-2004";
+
+		System.out.println("�Es v�lida '" + query + "' ?");
+		SQLQueryValidation sqlQueryValidation = new SQLQueryValidation(query, true);
+
+		if (sqlQueryValidation.validateQuery()) {
+			System.out.println("Yes.");
+		}
+		else {
+			System.out.println("No.");
+			System.out.println(sqlQueryValidation.getErrorPositionAsMessage());
+			System.out.println(sqlQueryValidation.getErrorMessage());			
+			fail();
+		}
+	}
+ }
\ No newline at end of file

Property changes on: tags/v2_0_0_Build_2050/applications/appgvSIG/src-test/org/gvsig/app/sqlQueryValidation/TestSQLQueryValidation.java
___________________________________________________________________
Added: svn:eol-style
   + native

Index: tags/v2_0_0_Build_2050/applications/appgvSIG/src-test/org/gvsig/app/gui/filter/TestFilterExpressionFromWhereIsEmpty_Method.java
===================================================================
--- tags/v2_0_0_Build_2050/applications/appgvSIG/src-test/org/gvsig/app/gui/filter/TestFilterExpressionFromWhereIsEmpty_Method.java	(revision 0)
+++ tags/v2_0_0_Build_2050/applications/appgvSIG/src-test/org/gvsig/app/gui/filter/TestFilterExpressionFromWhereIsEmpty_Method.java	(revision 38653)
@@ -0,0 +1,120 @@
+package org.gvsig.app.gui.filter;
+
+import junit.framework.TestCase;
+
+
+/* gvSIG. Sistema de Informaci�n Geogr�fica de la Generalitat Valenciana
+ *
+ * Copyright (C) 2004 IVER T.I. and Generalitat Valenciana.
+ *
+ * This program is free software; you can redistribute it and/or
+ * modify it under the terms of the GNU General Public License
+ * as published by the Free Software Foundation; either version 2
+ * of the License, or (at your option) any later version.
+ *
+ * This program is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
+ * GNU General Public License for more details.
+ *
+ * You should have received a copy of the GNU General Public License
+ * along with this program; if not, write to the Free Software
+ * Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA  02111-1307,USA.
+ *
+ * For more information, contact:
+ *
+ *  Generalitat Valenciana
+ *   Conselleria d'Infraestructures i Transport
+ *   Av. Blasco Ib��ez, 50
+ *   46010 VALENCIA
+ *   SPAIN
+ *
+ *      +34 963862235
+ *   gvsig@gva.es
+ *      www.gvsig.gva.es
+ *
+ *    or
+ *
+ *   IVER T.I. S.A
+ *   Salamanca 50
+ *   46005 Valencia
+ *   Spain
+ *
+ *   +34 963163400
+ *   dac@iver.es
+ */
+
+/**
+ * @author Pablo Piqueras Bartolom� (p_queras@hotmail.com)
+ */
+public class TestFilterExpressionFromWhereIsEmpty_Method extends TestCase {
+	/*
+	 *  (non-Javadoc)
+	 * @see junit.framework.TestCase#setUp()
+	 */
+	protected void setUp() throws Exception {
+		super.setUp();
+	}
+
+	/*
+	 *  (non-Javadoc)
+	 * @see junit.framework.TestCase#tearDown()
+	 */
+	protected void tearDown() throws Exception {
+		super.tearDown();
+	}	
+
+	/**
+	 * Test 1 (valid)
+	 */
+	public void test1() {
+		String expression = new String("select * from 'gdbms144426c_10fc90fa1aa__7c18' where ;");
+		
+		System.out.println("� Es vac�o el filtro en: " + expression + " ? ");
+
+		if (this.filterExpressionFromWhereIsEmpty(expression))
+			System.out.println("Si.");
+		else
+			System.out.println("No.");
+	}
+	
+	/**
+	 * Test 2 (invalid)
+	 */
+	public void test2() {
+		String expression = new String("select * from 'gdbms158fd70_10fc92ee61e__7c18' where layer < '61';");
+		
+		System.out.println("� Es vac�o el filtro en: " + expression + " ? ");
+
+		if (this.filterExpressionFromWhereIsEmpty(expression))
+			System.out.println("Si.");
+		else
+			System.out.println("No.");
+	}	
+	
+	/**
+	 * Returns true if the WHERE subconsultation of the filterExpression is empty ("")
+	 * 
+	 * @param expression An string
+	 * @return A boolean value 
+	 */
+	private boolean filterExpressionFromWhereIsEmpty(String expression) {
+		String subExpression = expression.trim();
+		int pos;	
+		
+		// Remove last ';' if exists
+		if (subExpression.charAt(subExpression.length() -1) == ';')
+			subExpression = subExpression.substring(0, subExpression.length() -1).trim();
+		
+		// If there is no 'where' clause
+		if ((pos = subExpression.indexOf("where")) == -1)
+			return false;
+		
+		// If there is no subexpression in the WHERE clause -> true
+		subExpression = subExpression.substring(pos + 5, subExpression.length()).trim(); // + 5 is the length of 'where'
+		if ( subExpression.length() == 0 )
+			return true;
+		else
+			return false;
+	}
+}

Property changes on: tags/v2_0_0_Build_2050/applications/appgvSIG/src-test/org/gvsig/app/gui/filter/TestFilterExpressionFromWhereIsEmpty_Method.java
___________________________________________________________________
Added: svn:eol-style
   + native

Index: tags/v2_0_0_Build_2050/applications/appgvSIG/src-test/org/gvsig/app/project/ProjectTest.java
===================================================================
--- tags/v2_0_0_Build_2050/applications/appgvSIG/src-test/org/gvsig/app/project/ProjectTest.java	(revision 0)
+++ tags/v2_0_0_Build_2050/applications/appgvSIG/src-test/org/gvsig/app/project/ProjectTest.java	(revision 38653)
@@ -0,0 +1,91 @@
+/* gvSIG. Sistema de Informaci�n Geogr�fica de la Generalitat Valenciana
+ *
+ * Copyright (C) 2005 IVER T.I. and Generalitat Valenciana.
+ *
+ * This program is free software; you can redistribute it and/or
+ * modify it under the terms of the GNU General Public License
+ * as published by the Free Software Foundation; either version 2
+ * of the License, or (at your option) any later version.
+ *
+ * This program is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
+ * GNU General Public License for more details.
+ *
+ * You should have received a copy of the GNU General Public License
+ * along with this program; if not, write to the Free Software
+ * Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA  02111-1307,USA.
+ *
+ * For more information, contact:
+ *
+ *  Generalitat Valenciana
+ *   Conselleria d'Infraestructures i Transport
+ *   Av. Blasco Ib��ez, 50
+ *   46010 VALENCIA
+ *   SPAIN
+ *
+ *      +34 963862235
+ *   gvsig@gva.es
+ *      www.gvsig.gva.es
+ *
+ *    or
+ *
+ *   IVER T.I. S.A
+ *   Salamanca 50
+ *   46005 Valencia
+ *   Spain
+ *
+ *   +34 963163400
+ *   dac@iver.es
+ */
+
+/* CVS MESSAGES:
+*
+* $Id$
+* $Log$
+* Revision 1.1  2006-11-08 10:57:55  jaume
+* remove unecessary imports
+*
+*
+*/
+package org.gvsig.app.project;
+
+import junit.framework.TestCase;
+
+//TODO comentado para que compile
+public class ProjectTest extends TestCase {
+	static final String projectFile1 = "test/test.gvp";
+	static final String projectFile2 = "test/test.gvp";
+	static final String projectFile3 = null;
+	static final String projectFile4 = null;
+
+	static final String driversPath = "lib-test/drivers";
+	Project p1, p2;
+
+	public void setUp() {
+
+//		LayerFactory.setDriversPath(driversPath);
+//
+//		Reader reader;
+//
+//		// TODO Install drivers support for testing
+//		try {
+//			reader = new FileReader(new File(projectFile1));
+//
+//			XmlTag tag = (XmlTag) XmlTag.unmarshal(reader);
+//			XMLEntity xml=new XMLEntity(tag);
+//			p1 = Project.createFromXML(xml);
+//			p2 = Project.createFromXML(xml);
+//		} catch (Exception e) {
+//			e.printStackTrace();
+//		}
+
+	}
+
+//	public void testSignature() {
+//		try {
+//			assertTrue(p1.computeSignature() == p2.computeSignature());
+//		} catch (SaveException e) {}
+////		assertTrue(p1.equals(p2));
+//	}
+}

Property changes on: tags/v2_0_0_Build_2050/applications/appgvSIG/src-test/org/gvsig/app/project/ProjectTest.java
___________________________________________________________________
Added: svn:keywords
   + Author Date Id Revision
Added: svn:eol-style
   + native

Index: tags/v2_0_0_Build_2050/applications/appgvSIG/config/gva-logo.png
===================================================================
Cannot display: file marked as a binary type.
svn:mime-type = application/octet-stream

Property changes on: tags/v2_0_0_Build_2050/applications/appgvSIG/config/gva-logo.png
___________________________________________________________________
Added: svn:mime-type
   + application/octet-stream

Index: tags/v2_0_0_Build_2050/applications/appgvSIG/config/disid.html
===================================================================
--- tags/v2_0_0_Build_2050/applications/appgvSIG/config/disid.html	(revision 0)
+++ tags/v2_0_0_Build_2050/applications/appgvSIG/config/disid.html	(revision 38653)
@@ -0,0 +1,27 @@
+<html>
+<body>
+
+<img src="disid-logo.jpeg"><br>
+
+<h2>DiSiD Technologies</h2>
+<br>
+<p>
+<a href="http://www.disid.com/">http://www.disid.com/</a>
+</p>
+<p>Empresa de ingenier&iacute;a inform&aacute;tica especializada en tecnolog&iacute;a Java.</p>
+<p>Nuestro objetivo es proveer soluciones software enfocadas a resolver problemas y necesidades con
+el objetivo de ofrecer s&oacute;lo lo que los clientes necesitan, evitando gestiones innecesarias.</p>
+<br>
+<p>Especializados en:
+<ul>
+<li>Sistemas de informaci&oacute;n geogr&aacute;fica (gvSIG)</li>
+<li>Reconocimiento y trazabilidad de personas y Activos con representaci&oacute;n gr&aacute;fica</li>
+<li>e-business y Tiendas virtuales</li>
+<li>Portales corporativos y Marketing on-line</li>
+<li>Consultor&iacute;a tecnol&oacute;gica, desarrollo, soporte y formaci&oacute;n Java</li>
+</ul>
+<br>
+<img src="gvsig-logo1-association.jpg">
+<p><em>Miembro de la <a href="http://www.gvsig.com/">Asociaci&oacute;n gvSIG</a></em>
+</body>
+</html>
\ No newline at end of file

Property changes on: tags/v2_0_0_Build_2050/applications/appgvSIG/config/disid.html
___________________________________________________________________
Added: svn:mime-type
   + text/plain

Index: tags/v2_0_0_Build_2050/applications/appgvSIG/config/prodevelop-logo.png
===================================================================
Cannot display: file marked as a binary type.
svn:mime-type = application/octet-stream

Property changes on: tags/v2_0_0_Build_2050/applications/appgvSIG/config/prodevelop-logo.png
___________________________________________________________________
Added: svn:mime-type
   + application/octet-stream

Index: tags/v2_0_0_Build_2050/applications/appgvSIG/config/text_gl.properties
===================================================================
--- tags/v2_0_0_Build_2050/applications/appgvSIG/config/text_gl.properties	(revision 0)
+++ tags/v2_0_0_Build_2050/applications/appgvSIG/config/text_gl.properties	(revision 38653)
@@ -0,0 +1,706 @@
+#Translations for language [gl]
+#Mon Oct 30 09:38:21 CET 2006
+(escala_maxima)=(escala m\u00e1xima)
+(escala_minima)=(escala m\u00ednima)
+1\:=
+_(Simbolo_unico)=(S\u00edmbolo \u00fanico)
+__proyeccion_actual=Proxecci\u00f3n actual\:
+__redimensionar_texto_escala=Redimensionar o texto a escala coa vista.
+__seleccion_de_fuente=Selecci\u00f3n de fonte
+A0=A0
+A1=A1
+A2=A2
+A3=A3
+A4=A4
+abajo=Abaixo
+abrir=Abrir
+abrir_plantilla=Abrir modelo
+abrir_proyecto=Abrir proxecto
+abrir_tooltip=Abre un proxecto existente
+Abrir_una_capa=Abrir capa
+Accion_Predefinida=Acci\u00f3n predefinida
+aceptar=Aceptar
+Aceptar=Aceptar
+acerca_de=Acerca de...
+activar=Activate
+activar_regla=Activar regra
+activos=Activos
+add_delete_edit_fields=
+add_layer=Engadir capa
+add_rows=
+adjust_transparency=Axustar transparencia
+agrupacion=
+agrupar=Agrupar
+agrupar_capas=Agrupar capas
+agrupar_graficos=Agrupar gr\u00e1ficos
+agrupar_linea=Agrupar li\u00f1a gr\u00e1fica con gr\u00e1ficos
+Ajustar_transparencia=Axustar transparencia
+ajustes_linea_grafica=Axustes de li\u00f1a gr\u00e1fica
+Al_leer_la_leyenda=\u00d3 l\u00e9r a lenda
+alias=Alias
+align_center=
+align_down=
+align_left=
+align_right=
+align_to_layout_center=
+align_to_layout_down=
+align_to_layout_left=
+align_to_layout_right=
+align_to_layout_up=
+align_to_layout_vertical_center=
+align_up=
+align_vertical_center=
+alineamiento=Ali\u00f1amento\:
+alinear=Ali\u00f1ar
+alinear_graficos=Ali\u00f1ar gr\u00e1ficos
+alta=Alta
+alto=Alto
+altura=Altura\:
+Altura_fija_de_texto=Altura fixa do texto
+ambito=\u00c1mbeto
+Anadir=Engadir
+Anadir_al_conjunto=Engadir ao conxunto
+Anadir_capa=Engadir capa
+Anadir_Capa=Engadir capa
+anadir_tag=
+Anadir_todos=Engadir todos
+ancho=Largo
+ancho_alto=Ancho alto
+anchura=Largo\:
+Aplicar=Aplicar
+Archivo=Arquivo
+arriba=Arriba
+ascending_order=Orde ascendente
+ascending_order_tooltip=Ordena polo campo seleccionado en orde ascendente
+Atributo=Atributo
+automatico=Autom\u00e1tico
+Ayuda=Axuda
+back=Anterior
+background_color=C\u00f3r de fondo
+baja=Baixa
+Bajar_capa=Baixar capa
+bandas=Bandas
+barra=Barra\:
+base=base
+base_datos=Base de datos
+bmp=Arquivos de tipo bmp
+Bold=
+borra_seleccion=Borra selecci\u00f3n
+borrador=Borrador
+borrar=Borrar
+box=
+brillo=Brillo
+brillo_y_contraste=Brillo e Contraste
+browse=Examinar
+cajetin=
+Calcular_intervalos=Calcular intervalos
+calidad=Calidade
+cambiar_el_alto_de_los_elementos_seleccionados_hasta_coincidir_con_el_mas_alto=
+cambiar_el_ancho_de_los_elementos_seleccionados_hasta_coincidir_con_el_mas_ancho=
+cambiar_el_tamano_de_los_elementos_seleccionados_hasta_coincidir_con_el_mas_grande=
+Cambio_Color=Cambio c\u00f3r
+cambio_nombre=Cambio de nome
+campo=Campo
+Campo=Campo
+campo_altura_texto=Campo de altura de texto\:
+Campo_de_clasificacion=Campo de clasificaci\u00f3n
+Campo_de_etiquetado=Campo de etiquetado
+Campos=Campos
+cancel=Cancelar
+Cancel=Cancelar
+cancelar=Cancelar
+Cancelar=Cancelar
+Capa=Capa
+Capas=Capas
+Capas_del_localizador=Capas do localizador
+Centimetros=Cent\u00edmetros
+cerrar=Pechar
+Cerrar=Pechar
+change=
+change_before=
+change_behind=
+change_height=
+change_width=
+circulo=C\u00edrculo
+clave=Clave
+close=Pechar
+coincidir_tamanyo=
+colocar_a_margenes=Colocar con referencia a marxes.
+colocar_alrededor_seleccionados=Colocar ao redor dos gr\u00e1ficos seleccionados.
+colocar_alrededor_todos=Colocar ao redor de t\u00f3dolos gr\u00e1ficos
+colocar_delante=Colocar diante
+colocar_detras=Colocar detr\u00e1s
+color=Cor\:
+Color_final=Cor final
+Color_inicio=Cor de inicio
+color_texto=Cor do texto
+comentarios=Comentarios
+comenzar_edicion=
+compleja=
+configurar=Configurar
+configurar_localizador=Configurar localizador
+Configurar_localizador=Configurar localizador
+confirmar_borrar=Seguro que desexa borrar o elemento?
+conflicto_de_nombres_de_mapas_al_pegar=
+conflicto_de_nombres_de_tablas_al_pegar=
+conflicto_de_nombres_de_vistas_al_pegar=
+conflito_de_nombres_de_tablas_al_pegar=
+conservar_escala_visualizacion=Conservar escala de visualizaci\u00f3n
+consulta=Consulta
+Contengan=Conte\u00f1an
+contraste=Contraste
+coor_geograficas=Coordenadas xeogr\u00e1ficas
+copiar=
+copy=Copiar
+cortar=
+creation_date=Data de creaci\u00f3n
+Crucen_con=Crucen con
+cuando_activo=Cando activo
+cut=
+Dado_un_campo_de_atributos=Dado un campo de atributos
+debera_introducir_nombres_para_las_vistas_a_pegar=
+debera_introducir_nombres_para_los_mapas_a_pegar=
+default_projection=
+default_value=
+dehacer=Desfacer
+delete_field=Borrar campo
+Derecha=Dereita
+Derecho=Dereito
+desagrupar=Desagrupar
+desagrupar_capas=
+desagrupar_graficos=Desagrupar gr\u00e1ficos
+descending_order=Orde descendente
+descending_order_tooltip=Ordena polo campo seleccionado en orde descendente
+descripcion_de_configuracion_capa_de_anotaciones=
+descripcion_de_crear_capa_de_anotaciones=
+desde_arriba=Dende arriba\:
+desde_izquierda=Dende a esquerda
+desea_borrar_el_documento=
+desea_borrar_la_capa=
+desea_continuar=
+deshacer=Desfacer
+desplaza_los_elementos_seleccionados_a_la_derecha=
+desplaza_los_elementos_seleccionados_a_la_izquierda=
+desplaza_los_elementos_seleccionados_al_centro_por_el_eje_x=
+desplaza_los_elementos_seleccionados_al_centro_por_el_eje_y=
+desplaza_los_elementos_seleccionados_hacia_abajo=
+desplaza_los_elementos_seleccionados_hacia_arriba=
+Desplazamiento=Desprazamento
+desviacion_tipica=Desviaci\u00f3n t\u00edpica
+distance_units=Unidades de medida
+distribuir=Distribu\u00edr\:
+distribuir_elementos_sobre_todo_el_layout=
+distributes_down=
+distributes_horizontal=
+distributes_left=
+distributes_right=
+distributes_to_layout_down=
+distributes_to_layout_horizontal=
+distributes_to_layout_left=Distribuye izquierda del layout
+distributes_to_layout_right=
+distributes_to_layout_up=
+distributes_to_layout_vertical=
+distributes_up=
+distributes_vertical=
+distribuye_el_espacio_entre_los_elementos_en_horizontal=
+distribuye_el_espacio_entre_los_elementos_en_vertical=
+distribuye_los_elementos_seleccionados_de_forma_equidistante_de_abajo_hacia_arriba=
+distribuye_los_elementos_seleccionados_de_forma_equidistante_de_arriba_hacia_abajo=
+distribuye_los_elementos_seleccionados_de_forma_equidistante_de_derecha_a_izquierda=
+distribuye_los_elementos_seleccionados_de_forma_equidistante_de_izquierda_a_derecha=
+distribuye_los_elementos_seleccionados_de_forma_equidistante_y_horizontal=
+distribuye_los_elementos_seleccionados_de_forma_equidistante_y_vertical=
+divisiones_izquierda=Divisi\u00f3ns \u00e1 esquerda
+documento=
+documentos_existentes=Documentos existentes
+draw_text_only=
+driver=Driver
+Dxffiles=Arquivos .DXF
+edicion=Edici\u00f3n
+editable=
+Editar_leyenda=Editar lenda
+editar_vertices=Editar v\u00e9rtices
+el_numero_maximo_de_intervalos_para_este_campo_es=O n\u00famero m\u00e1ximo de intervalos para este campo \u00e9
+Elegir_Color=Elixir Cor
+Elegir_Fuente=Elixir fonte
+elemento_ya_existe=
+Elementos_seleccionados_de_la_capa=Elementos seleccionados da capa
+Eliminar=Eliminar
+eliminar_capa=Eliminar capa
+eliminar_columna=
+eliminar_extremos=Eliminar extremos
+eliminar_fila=
+en_el_mapa=No mapa\:
+En_metros=En metros
+En_pixels=En pixels
+en_unidades=
+Encuadre=Encadre
+Encuadre_Vista=Encadre sobre a vista
+enlace_vivo=Ligaz\u00f3n viva
+Enlazar_a_fichero_de_texto=Ligar a arquivo de texto
+Enlazar_a_ficheros_de_imagen=Ligar a arquivos de imaxe
+equal_intervals=Intervalos iguais
+Error_exportando_SLD=
+Error_guardando_la_leyenda=Erro ao gardar a lenda
+Error_guardando_la_plantilla=
+escala=Escala
+Escala=Escala
+escala_desconocida=
+escala_maxima=Escala m\u00e1xima
+Escala_Maxima=Escala m\u00e1xima
+escala_minima=Escala m\u00ednima
+Escala_Minima=Escala m\u00ednima
+escala_usuario=Escala especificada polo usuario
+espaciado_horizontal=Espaciado horizontal da malla
+espaciado_vertical=Espaciado vertical da malla
+espacio=Espazo\:
+estadisticas=Estat\u00edsticas
+este_por_debajo_de_=Estea por debaixo de
+este_por_encima_de=Estea por riba de
+Esten_contenidos_en=Estean contidos en
+Etiqueta=Etiqueta
+Etiquetados=Etiquetados
+etiquetas=Etiquetas
+Etiquetas_estandar=Etiquetas est\u00e1ndar
+Examinar=Examinar
+export=Exportar
+exportar=Exportar
+exportar_pdf=Exportar a pdf
+exportar_ps=Exportar a ps
+extension=Extensi\u00f3n
+Extent=Extent
+extents_no_coincidentes=Extensi\u00f3ns non coincidentes
+factor_zoom_incorrecto=
+fallo_capas=Erro accedendo \u00e1s capas. As seguintes capas van ser eliminadas do proxecto
+family=
+fichero=
+Fichero=Arquivo
+fichero_existe=Arquivo existe
+fichero_incorrecto=Arquivo incorrecto
+fichero_ya_existe_seguro_desea_guardarlo=
+field_already_exists=
+field_decimal_count=
+field_default_value=
+field_length=
+field_manager=
+field_name=
+field_type=
+filtro=Filtro
+finish=Rematar
+Font=Fonte
+formato=Formato
+Formato_de_numero_erroneo=
+formato_incorrecto=Formato incorrecto
+fuente=Fonte
+General=Xeral
+georeferenciado=
+gestion_encuadre=Xesti\u00f3n de Encadre
+grados=Graos\:
+Grados=Graos
+Graficos=Gr\u00e1ficos
+grosor_linea=Grosor de li\u00f1a\:
+group=Agrupar
+group_graphic_line=
+grupo=
+guardado=Gardado en
+guardar=Gardar
+Guardar=Gardar
+guardar_cambios=\u00bfQuere gardar os cambios?
+guardar_como=Gardar como
+guardar_como_plantilla=Gardar como dese\u00f1o
+Guardar_el_zoom_actual=Gardar o zoom
+Guardar_leyenda=Gardar lenda
+guardar_proyecto=Gardar proxecto
+guardar_tooltip=Gardar os cambios ao proxecto
+Habilitar_etiquetado=Habilitar etiquetado
+Hiperenlace=Hiperligaz\u00f3n
+horizontal=Horizontal
+horizontal_space=
+Identificar_Resultados=Identificar resultados
+Igual_que_la_impresora=Igual que a impresora
+igual_todos_lados=Desprazamento igual por t\u00f3dolos lados
+imagen=Imaxe
+Implimir=
+importar=Importar
+Imprimir=Imprimir
+Indexando=Indexando...
+Indexando_espacialmente=Indexando espacialmente a capa
+indexar_campos=
+Inferior=Inferior
+info=Informaci\u00f3n
+informacion=Informaci\u00f3n
+Informacion=Informaci\u00f3n
+Inicializando=Inicializando
+initial_warning=
+insert_row=Inserir fila
+Insertar=Insertar
+insertar_cajetin=Inserir cadro de rotulaci\u00f3n
+insertar_circulo=Insertar c\u00edrculo
+insertar_columna=
+insertar_escala=Insertar escala
+insertar_fila=
+insertar_imagen=Insertar imaxe
+insertar_leyenda=Insertar lenda
+insertar_linea=Insertar li\u00f1a
+insertar_norte=Insertar norte
+insertar_poligono=Insertar pol\u00edgono
+insertar_polilinea=Inserir polili\u00f1a
+insertar_punto=Insertar punto
+insertar_rectangulo=Insertar rect\u00e1ngulo
+insertar_texto=Insertar texto
+insertar_vista=Insertar vista
+Intersecten_con=Intersecten con
+Intervalo=Intervalo
+Intervalos=Intervalos
+introduce_nombre=Introduce o novo nome
+introduzca_el_nombre_de_la_nueva_capa_de_anotaciones=
+introduzca_nuevo_nombre_para_la_vista=
+invalid_value_for_gap=
+invert_selection=
+Italic=
+Izquierda=Esquerda
+Izquierdo=Esquerdo
+join=Empalmar
+jpg=Arquivos JPEG
+kilometros=Kil\u00f3metros
+Kilometros=Kil\u00f3metros
+leyenda=Lenda
+Leyenda=Lenda
+leyenda_campo_unido=Estase a utilizar un campo da uni\u00f3n na lenda (e/ou etiquetado). Cambie a lenda antes de quitar a uni\u00f3n, por favor.
+Leyenda_Por_Defecto=Lenda por defecto
+linea=Li\u00f1a
+linea_grafica=Li\u00f1a gr\u00e1fica
+lineal_directo=Lineal directo
+link=Ligazon
+Link=Ligaz\u00f3n
+localizador=Localizador
+locked_element=
+locked_element_it_cannot_be_deleted=
+locked_element_it_cannot_be_renamed=
+m/pixel=metros/pixel
+malla_activada=Malla activada
+manage_fields=
+mantener_intervalo=Manter intervalo
+map_units=Unidades de mapa
+mapa=
+Mapa=Mapa
+mapas=Mapas
+marco=Marco
+marco_vista=Marco da vista
+margenes=M\u00e1rxenes\:
+mas_de_100_simbolos=M\u00e1is de 100 s\u00edmbolos non adoitan aportar informaci\u00f3n nun plano
+max_length_is=
+maximo=M\u00e1ximo
+MDIFrame.quiere_salir=Est\u00e1 seguro de que quere sa\u00edr?
+MDIFrame.salir=Sa\u00edr
+media=Media
+medir_area=Medir \u00c1rea
+medir_distancias=Medir distancias
+metadatos=Metadatos
+metros=Metros
+Metros=Metros
+Milimetros=Mil\u00edmetros
+Millas=Millas
+minimo=M\u00ednimo
+modificar=
+modification_date=\u00daltima data de modificaci\u00f3n
+mostrar_escala_numerica=
+Mostrar_siempre=Amosar sempre
+mostrar_unidades=Amosar unidades
+move_elements=
+Muestra_atributos=Amosa os atributos das capas seleccionadas
+muestra_los_elementos_de_la_capa_usando_un_simbolo_por_cada_valor_unico=Amosa os elementos da capa empregando un s\u00edmbolo por cada valor \u00fanico
+Muestra_los_elementos_de_la_capa_usando_una_gama_de_colores_en_funcion_del_valor_de_un_determinado_campo_de_atributos=Amosa os elementos da capa empregando unha gama de cores en funci\u00f3n do valor dun determinado campo de atributos
+Muestra_todos_los_elementos_de_una_capa_usando_el_mismo_simbolo=Amosa todolos elementos dunha capa empregando o mesmo s\u00edmbolo
+natural_intervals=Intervalos naturais
+navegacion=Navegaci\u00f3n
+navegacion_vista=Navegaci\u00f3n vista
+necesita_una_capa_activa=
+necesita_una_capa_vectorial_activa=Necesita unha capa vectorial activa
+new_field=Novo campo
+new_field_properties=
+next=Seguinte
+ninguna_impresora_configurada=Ningunha impresora configurada
+Nivel_de_transparencia=Nivel de transparencia
+no=Non
+no_activos=Non activos
+No_de_intervalos=N\u00ba de intervalos
+no_es_posible_aplicar_leyenda_vacia=
+No_ha_sido_posible_realizar_la_operacion=
+No_mostrar=Non amosar a capa cando a escala
+No_mostrar_la_capa_cuando_la_escala=Non amosar a capa cando a escala
+no_se_pegaran_las_tablas=
+no_se_pegaran_las_vistas_del_conflicto=
+No_se_pudo_obtener_la_tabla_de_la_capa=Non se puido obter a t\u00e1boa da capa
+no_visibles=Non visibles
+nombre=Nome
+Nombre=Nome
+nombre_no_valido=
+Nombre_que_se_le_dara_al_zoom=Nome que se lle dar\u00e1 ao zoom
+nombre_sesion=Nome da sesi\u00f3n
+none=
+none_selected=Ning\u00fan seleccionado
+normal=Normal
+north=Norte
+Nueva_tabla=Nova t\u00e1boa
+nuevo=Novo
+Nuevo_conjunto=Novo conxunto
+nuevo_nombre_para_el_mapa=
+nuevo_proyecto=Novo proxecto
+nuevo_tooltip=Crea un novo proxecto
+num_bandas=N\u00famero de bandas
+num_columnas=N\u00famero de columnas
+num_filas=
+Num_intervalos=
+numero_decimales_mostrar=
+numero_incorrecto=
+ok=Aceptar
+opacidad=Opacidade
+operacion_cancelada=
+options.layout.paper_properties.landscaped=
+options.layout.paper_properties.paper_direction=
+options.layout.paper_properties.portrait=
+options.layout.paper_properties.title=
+options.view.default_map_overview_back_color=
+options.view.default_selection_color=
+options.view.default_view_back_color=
+options.view.invisible_new_layers=
+options.view.keep_scale_on_resizing=
+orientacion=Orientaci\u00f3n\:
+origen_de_datos=Origen de dades
+Origen_de_datos=Orixe dos datos
+Origen_de_Datos=Orixe dos datos\:
+owner=Propietario
+paste=Pegar
+paste_elements=
+path=Ruta
+pdf=
+pegar=
+pegar_mapas=
+pegar_vistas=
+Permite_etiquetar_los_elementos_del_mapa_con_el_valor_de_un_determinado_campo=Permite etiquetar os elementos do mapa c\u00f3 valor dun determinado campo
+Personalizado=Persoalizado
+personalizar_margenes=
+Pies=P\u00e9s
+pila_de_comandos=P\u00eda de comandos
+pixeles=p\u00edxeles
+pixels=pixels
+Plain=
+plantilla=
+please_insert_new_field_name=
+png=Arquivos png
+poligono=Pol\u00edgono
+polilinea=polili\u00f1a
+poner_capas_a=
+por_debajo_de=por debaixo de\:
+por_encima_de=por riba de\:
+Por_favor_active_la_capa=Por favor active a capa
+posicion_linea=Posici\u00f3n da li\u00f1a
+precision=
+preparar_pagina=Prepara p\u00e1xina
+Preparar_pagina=Prepara p\u00e1xina
+presentacion=Presentaci\u00f3n
+previsualizacion=Previsualizaci\u00f3n
+Previsualizacion=Previsualizaci\u00f3n
+Previsualizacion_de_simbolo=
+propiedad=
+propiedades=Propiedades
+propiedades_cajetin=Propiedades da cadro de rotulaci\u00f3n
+propiedades_capa=Propiedades da capa
+propiedades_de_la_capa=Propiedades da capa
+Propiedades_escala_grafica=Propiedades da escala gr\u00e1fica
+propiedades_grafico=Propiedades del gr\u00e1fico
+propiedades_mapa=Propiedades do mapa
+propiedades_marco_imagenes=Propiedades do marco de imaxes
+propiedades_marco_leyenda=Propiedades do marco de lenda
+propiedades_marco_vista=Propiedades do marco de vista
+propiedades_raster=Propiedades do raster
+propiedades_sesion=Propiedades da sesi\u00f3n
+propiedades_tabla=Propiedades da t\u00e1boa
+Propiedades_texto=Propiedades do texto
+propiedades_vista=Propiedades da vista
+Proyecciones=
+ps=
+puerto=Porto
+Pulgadas=Pulgadas
+punto=Punto
+quantile_intervals=Intervalos cuantiles
+quiere_continuar=Est\u00e1 seguro de que quere continuar?
+Quitar=Quitar
+Quitar_capa=Quitar capa
+quitar_enlaces=Quitar ligaz\u00f3ns
+Quitar_todos=Quitar todos
+quitar_uniones=Quitar uni\u00f3ns
+rango_de_escalas=Rango de escalas
+Rango_de_escalas=Rango de escalas
+realce=Realce
+realmente_desea_guardar=Realmente desexa gardar?
+recargar=
+recorte_colas=Recorte colas
+recorte_vista=Recorte a vista
+rectangulo=Rect\u00e1ngulo
+recuento=Reconto
+Recuperar_leyenda=Recuperar lenda
+Recuperar_y_eliminar_otros_zoom=Recuperar e eliminar outros zooms
+refrescar=Refrescar
+rehacer=Refacer
+rellenar_marco_vista=Rechear marco da vista
+relleno=Reenchido\:
+remove_elements=
+remove_fields=
+remove_row=Elimina fila
+remove_rows=
+rename_field=
+renombrar=Renomear
+reproyectar_aviso=A proxecci\u00f3n da capa non \u00e9 igual que a da vista\nAVISO\: Pode ser inexacto con algunhas transformaci\u00f3ns.\nPor favor, lea a documentaci\u00f3n
+reproyectar_pregunta=Desexa reproxectar?
+resolucion_resultado=Resoluci\u00f3n do resultado\:
+resto_valores=Resto de valores
+restore_palette=
+rotation_field=
+salir=Sa\u00edr
+salir_tooltip=Sa\u00edr
+salvar_raster=Gardar a raster xeoreferenciado
+Sample=Exemplo
+Se_superponen_a=Sobrep\u00f3\u00f1ense a
+Sean_disjuntos_a=sexan disxuntos a
+Sean_iguales_a=sexan iguais a
+seleccion=Selecci\u00f3n
+seleccion_fuente=Selecci\u00f3n de fonte
+Seleccion_por_capa=
+selecciona_sistema_de_referencia=
+Seleccionar=Seleccionar
+seleccionar_capas=Seleccionar capas
+seleccionar_capas_raster=
+Seleccionar_de_las_capas_activas_los_elementos_que=Seleccionar das capas activas os elementos que\:
+Seleccionar_del_conjunto=Seleccionar do conxunto
+Seleccionar_fichero=Seleccionar arquivo
+seleccionar_por_poligono=
+seleccionar_por_punto=Seleccionar por punto
+seleccionar_por_rectangulo=Seleccionar por rect\u00e1ngulo
+seleccionar_todos=Seleccionar todos
+seleccione_campo_enlace=Seleccionar o campo polo que ligar
+seleccione_el_campo_angulo_de_la_capa_de_anotaciones=
+seleccione_el_campo_color_de_la_capa_de_anotaciones=
+seleccione_el_campo_de_texto_que_desea_que_se_utilize_para_mostrar_la_nueva_capa_virtual=
+seleccione_el_campo_fuente_de_la_capa_de_anotaciones=
+seleccione_el_campo_tamano_de_la_capa_de_anotaciones=
+seleccione_fecha=Seleccione unha data...
+seleccione_tabla_a_enlazar=Seleccione a t\u00e1boa a ligar
+seleccione_tabla_origen=Selecciona a t\u00e1boa de orixe da join
+selection_color=Cor da selecci\u00f3n
+selection_up=
+separator=
+Servidor=Servidor
+Shapefile=Shapefile
+show_this_dialog_next_startup=
+si=
+siempre=
+simbolo=
+Simbolo=S\u00edmbolo
+Simbolo_unico=S\u00edmbolo \u00fanico
+Simbologia=Simbolox\u00eda
+simplificar_leyenda=
+simplify=
+sin_titulo=Sen t\u00edtulo
+sincronizar_color_borde_relleno=Sincronizar a cor do bordo coa de reenchido\:
+Size=
+sobre_la_barra=Sobre a barra
+Solo_para_capas_vectoriales=S\u00f3 para capas vectoriais
+start_edition=Comenzar edici\u00f3n
+statistics=Estat\u00edsticas
+stop_edition=Rematar edici\u00f3n
+Style=Estilo
+Subir_capa=Subir capa
+suma=Suma
+Superior=Superior
+symbol_selector=
+Tabla=T\u00e1boa
+Tabla_de_Atributos=T\u00e1boa de atributos
+tablas=T\u00e1boas
+Tablas=Taules
+tag=tag
+tamano=Tama\u00f1o\:
+tamano_metros=Tama\u00f1o en metros\:
+tamano_pagina=Tama\u00f1o da p\u00e1xina\:
+tamano_posicion=tama\u00f1o/posici\u00f3n
+tamanyo_borde=Tam\u00f1o do bordo
+tamanyo_fuente=Tama\u00f1o da fonte
+tamanyo_pagina=
+tamPixX=
+tamPixY=
+terminar=
+terminar_edicion=
+texto=Texto
+this_table_is_not_self_editable=
+tipo_dato=Tipo dato
+tipo_de_intervalo=Tipo de intervalo
+tipo_de_leyenda=Tipo de lenda
+tipo_fichero_proyecto=Arquivo de proxecto gvSIG (*.gvsproj)
+tipo_linea=Tipo de Li\u00f1a\:
+tipo_relleno=Tipo de Reenchido\:
+tipo_simbolo=Tipo de s\u00edmbolo\:
+tipos_de_documentos=Tipos de documentos
+titulo=Xestor de proxectos
+titulo_fframetext=T\u00edtulo do campo de texto
+to_annotation=Transforma a capa de anotaci\u00f3ns
+to_palette=
+tooltip_copiar_al_portapapeles=
+tooltip_cortar_al_portapapeles=
+tooltip_pegar_desde_el_portapapeles=
+Toquen=toquen
+transparencia=Transparencia
+Transparencia=Transparencia
+transparencia_pixel=Transparencia por p\u00edxel
+ungroup=Desagrupar
+unidades=Unidades\:
+Unidades=Unidades\:
+untitled=Sen t\u00edtulo
+url=
+Usar_indice_espacial=Usar \u00edndice espacial
+usar_marco=Empregar marco
+usar_titulo=Empregar t\u00edtulo
+usuario=Usuario
+utilizar_margenes_impresora=Empregar m\u00e1rxenes de impresora
+vacia=Baleira
+Valor=Valor
+Valores=Valores
+Valores_unicos=Valores \u00fanicos
+varianza=Varianza
+Ventana=Fiestra
+ventana_proyecto=Vent\u00e1 de proxecto
+Ver=Ver
+ver_error_capa=
+ver_tabla_atributos=Ver T\u00e1boa de atributos
+ver_tags=
+ver_tooltip=Amosa a vent\u00e1 de proxecto
+vertical=Vertical
+vertical_space=
+visible=Visible
+visibles=Vis\u00edbeis
+Vista=Vista
+vistas=Vistas
+visualizacion=Visualizaci\u00f3n
+Visualizacion=Visualizaci\u00f3n
+visualizar_cuadricula=Visualizar malla
+warning=Aviso
+xmax=xmax
+xmin=xmin
+Yardas=Yardas
+ymax=ymax
+ymin=ymin
+Zoom_a_la_capa=Zoom \u00e1 capa
+Zoom_Acercar=Zoom acercar
+Zoom_Alejar=Zoom afastar
+Zoom_Completo=Zoom completo
+Zoom_Completo_Vista=Zoom completo sobre a vista
+zoom_in_factor=
+Zoom_Mas=Zoom m\u00e1is
+Zoom_Mas_Vista=Zoom m\u00e1is sobre a vista
+Zoom_Menos=Zoom menos
+Zoom_Menos_Vista=Zoom menos sobre a vista
+zoom_out_factor=
+Zoom_pixel=Zoom pixel
+Zoom_Previo=Zoom previo
+Zoom_Real=Zoom 1\:1
+Zoom_Select=Zoom ao seleccionado

Property changes on: tags/v2_0_0_Build_2050/applications/appgvSIG/config/text_gl.properties
___________________________________________________________________
Added: svn:keywords
   + Author Date Id Revision
Added: svn:eol-style
   + native

Index: tags/v2_0_0_Build_2050/applications/appgvSIG/config/text_en.properties
===================================================================
--- tags/v2_0_0_Build_2050/applications/appgvSIG/config/text_en.properties	(revision 0)
+++ tags/v2_0_0_Build_2050/applications/appgvSIG/config/text_en.properties	(revision 38653)
@@ -0,0 +1,999 @@
+#Translations for language [en]
+#Mon Oct 30 09:38:21 CET 2006
+(escala_maxima)=(maximum scale)
+(escala_minima)=(minimum scale)
+1\:=
+_(Simbolo_unico)=(Unique symbols)
+__proyeccion_actual=Current projection\:
+__redimensionar_texto_escala=Resize the text to the view scale
+__seleccion_de_fuente=Font selection
+A0=A0
+A1=A1
+A2=A2
+A3=A3
+A4=A4
+abajo=Down
+abrir=Open
+abrir_plantilla=Open template
+abrir_proyecto=Open project
+abrir_tooltip=Open an existing project
+Abrir_una_capa=Open layer
+Accion_Predefinida=Predefined action
+aceptar=Accept
+Aceptar=Accept
+acerca_de=About...
+activar=Activate
+activar_regla=Activate ruler
+activos=Active
+add_delete_edit_fields=The fields can be added, deleted or renamed
+add_layer=Add layer
+add_rows=Add rows
+adjust_transparency=Set transparency
+agrupacion=Grouping
+agrupar=Group
+agrupar_capas=Group layers
+agrupar_graficos=Group graphics
+agrupar_linea=Group graphic line with graphics
+Ajustar_transparencia=Adjust transparency
+ajustes_linea_grafica=Graphic line settings
+Al_leer_la_leyenda=Reading legend
+alias=Alias
+align_center=Align center
+align_down=Align down
+align_left=Align left
+align_right=Align right
+align_to_layout_center=Align in the center of the layout
+align_to_layout_down=Align in the bottom of the layout
+align_to_layout_left=Align in the left of the layout
+align_to_layout_right=Align in the right of the layout
+align_to_layout_up=Alinear arriba del layout
+align_to_layout_vertical_center=Align in the vertical center of the layout
+align_up=Align top
+align_vertical_center=Align in the vertical center
+alineamiento=Alignment\:
+alinear=Align
+alinear_graficos=Align graphics
+alta=High
+alto=Height
+altura=Height\:
+Altura_fija_de_texto=Fixed text height
+ambito=Scope
+Anadir=Add
+Anadir_al_conjunto=Add to set
+Anadir_capa=Add layer
+Anadir_Capa=Add layer
+anadir_tag=Add tag
+Anadir_todos=Add all
+ancho=Width
+ancho_alto=Width x Height
+anchura=Width\:
+Aplicar=Apply
+Archivo=File
+arriba=Up
+ascending_order=Ascending order
+ascending_order_tooltip=Sort by selected field in ascending order
+Atributo=Attribute
+automatico=Automatic
+Ayuda=Help
+back=Previous
+background_color=Background color
+baja=Low
+Bajar_capa=Move layer down
+bandas=Bands
+barra=Bar\:
+base=base
+base_datos=Data base
+bmp=BMP files
+Bold=Bold
+borra_seleccion=Clear selection
+borrador=Draft
+borrar=Delete
+box=box
+brillo=Brightness
+brillo_y_contraste=Brightness and contrast
+browse=Browse
+cajetin=Box
+Calcular_intervalos=Compute intervals
+calidad=Quality
+cambiar_el_alto_de_los_elementos_seleccionados_hasta_coincidir_con_el_mas_alto=Change the selected elements' height to match the highest one.
+cambiar_el_ancho_de_los_elementos_seleccionados_hasta_coincidir_con_el_mas_ancho=Change the selected elements' width to match the widest one.
+cambiar_el_tamano_de_los_elementos_seleccionados_hasta_coincidir_con_el_mas_grande=Change the selected elements' size to match the biggest one.
+Cambio_Color=Change color
+cambio_nombre=Rename
+campo=Field
+Campo=Field
+campo_altura_texto=Text field heigth\:
+Campo_de_clasificacion=Classification field
+Campo_de_etiquetado=Labeling field
+Campos=Fields
+cancel=Cancel
+Cancel=Cancel
+cancelar=Cancel
+Cancelar=Cancel
+Capa=Layer
+Capas=Layers
+Capas_del_localizador=Locator layers
+Centimetros=Centimeters
+cerrar=Close
+Cerrar=Close
+change=Change
+change_before=Bring forward
+change_behind=Send backward
+change_height=Change height
+change_width=Change width
+choose_color=Choose color
+circulo=Circle
+clave=Code
+close=Close
+coincidir_tamanyo=Match size
+colocar_a_margenes=Place with reference to margins.
+colocar_alrededor_seleccionados=Place around the graphics selected.
+colocar_alrededor_todos=Place around all the graphics.
+colocar_delante=Bring to front
+colocar_detras=Place back
+color=Color\:
+Color_final=End color
+Color_inicio=Begin color
+color_texto=Text color\:
+comentarios=Comments
+comenzar_edicion=Start edition
+compleja=Complex
+configurar=Configure
+configurar_localizador=Configure locator map
+Configurar_localizador=Configure locator ...
+confirmar_borrar=The element will be removed. Are you sure?
+conflicto_de_nombres_de_mapas_al_pegar=You are trying to paste maps whose names already exist in the current project
+conflicto_de_nombres_de_tablas_al_pegar=You are trying to paste tables whose names already exist in the current project
+conflicto_de_nombres_de_vistas_al_pegar=You are trying to paste views whose names already exist in the current project
+conflito_de_nombres_de_tablas_al_pegar=Table name conflict when pasting
+conservar_escala_visualizacion=Maintain viewing scale
+consulta=Query
+Contengan=Contain
+contraste=Contrast
+coor_geograficas=Geographic coordinates
+copiar=Copy
+copy=Copy
+cortar=Cut
+creation_date=Creation date
+Crucen_con=Cross over
+cuando_activo=When active
+cut=Cut
+Dado_un_campo_de_atributos=Given a attribute field
+datum=Datum
+debera_introducir_nombres_para_las_vistas_a_pegar=You will need to write new names for the views
+debera_introducir_nombres_para_los_mapas_a_pegar=You will need to write new names for the maps
+default_projection=Default projection
+default_value=Default Value
+dehacer=Undo
+delete_field=Delete field
+Derecha=Right
+Derecho=Right
+desagrupar=Ungroup
+desagrupar_capas=Ungroup layers
+desagrupar_graficos=Ungroup graphics
+descending_order=Descending order
+descending_order_tooltip=Sort by selected field in descending order
+descripcion_de_configuracion_capa_de_anotaciones=<HTML>Keep the default values to use the values which are shared by all the attributes of the layer. Select the fields which store the values in order to customize the label aspect.</HTML>
+descripcion_de_crear_capa_de_anotaciones=<HTML>A new virtual layer can be created using this tool, based on an already existing layer which allows to perform advanced labeling. It changes the visualization of the<br> selected layer showing the value of one of its fields.</HTML>
+desde_arriba=From top\:
+desde_izquierda=From left\:
+desea_borrar_el_documento=\u00bfDo you really want to delete the selected documents?
+desea_borrar_la_capa=Do you really want to delete the active layers?
+desea_continuar=\u00bfDo you want to continue?
+deshacer=Undo
+desplaza_los_elementos_seleccionados_a_la_derecha=Shift the selected layers to the right
+desplaza_los_elementos_seleccionados_a_la_izquierda=Shift the selected layers to the left
+desplaza_los_elementos_seleccionados_al_centro_por_el_eje_x=Shift the selected elements to the center on the X axis.
+desplaza_los_elementos_seleccionados_al_centro_por_el_eje_y=Shit the selected elements to the center on the Y axis.
+desplaza_los_elementos_seleccionados_hacia_abajo=Shift the selected elements to the bottom.
+desplaza_los_elementos_seleccionados_hacia_arriba=Shift the selected elements to the top.
+Desplazamiento=Panning
+desviacion_tipica=Standard deviation
+distance_units=Measuring units
+distribuir=Distributing\:
+distribuir_elementos_sobre_todo_el_layout=Arrange the elements over the whole Layout
+distributes_down=Arrange from the bottom
+distributes_horizontal=Arrange elements horizontally
+distributes_left=Arrange from the left
+distributes_right=Arrange from the right
+distributes_to_layout_down=Arrange from the bottom of the layout
+distributes_to_layout_horizontal=Arrange horizontally the layout
+distributes_to_layout_left=Arrange from the left of the layout
+distributes_to_layout_right=Arrange from the right of the layout
+distributes_to_layout_up=Arrange from the top of the layout
+distributes_to_layout_vertical=Arrange vertically the layout
+distributes_up=Arrange from the top
+distributes_vertical=Arrange vertically
+distribuye_el_espacio_entre_los_elementos_en_horizontal=Arrange horizontally the space between elements.
+distribuye_el_espacio_entre_los_elementos_en_vertical=Arrange vertically the space between the elements.
+distribuye_los_elementos_seleccionados_de_forma_equidistante_de_abajo_hacia_arriba=Arrange the selected elements in an equidistant way from bottom to top.
+distribuye_los_elementos_seleccionados_de_forma_equidistante_de_arriba_hacia_abajo=Arrange the selected elements in an equidistant way from top to bottom.
+distribuye_los_elementos_seleccionados_de_forma_equidistante_de_derecha_a_izquierda=Arrange the selected elements in an equidistant way from right to left.
+distribuye_los_elementos_seleccionados_de_forma_equidistante_de_izquierda_a_derecha=Arrange the selected elements in an equidistant way from left to right.
+distribuye_los_elementos_seleccionados_de_forma_equidistante_y_horizontal=Arrange horizontally the selected elements in an equidistant way.
+distribuye_los_elementos_seleccionados_de_forma_equidistante_y_vertical=Arrange vertically the selected items in an equidistant way.
+divisiones_izquierda=Divisions to the left
+documento=Document
+documentos_existentes=Existing documents
+dont_find_the_file=File not found
+do_you_want_to_locate_the_file=Do you want to locate the file?
+draw_text_only=Draw text only
+driver=Driver
+driver_error=Driver error.
+Dxffiles=DXFFiles
+edicion=Edition
+editable=Editable
+Editar_leyenda=Edit style
+editar_vertices=Edit vertex
+el_numero_maximo_de_intervalos_para_este_campo_es=The maximum number of intervals for this field is
+Elegir_Color=Select color
+Elegir_Fuente=Select font
+elemento_ya_existe=The element already exists
+Elementos_seleccionados_de_la_capa=Selected items of a layer
+Eliminar=Delete
+eliminar_capa=Delete layer
+eliminar_columna=Remove column
+eliminar_extremos=Remove edges
+eliminar_fila=Remove row
+en_el_mapa=In the layout\:
+En_metros=In meters
+En_pixels=In pixels
+en_unidades=in units
+Encuadre=Zoom Manager
+Encuadre_Vista=View frame pan
+enlace_vivo=Active link
+Enlazar_a_fichero_de_texto=Link to text files
+Enlazar_a_ficheros_de_imagen=Link to image files
+equal_intervals=Equal intervals
+Error_exportando_SLD=Error exporting SLD
+Error_guardando_la_leyenda=Error saving legend
+Error_guardando_la_plantilla=Error saving the template
+escala=Scale
+Escala=Scale
+escala_desconocida=Unknown scale
+escala_maxima=Maximum scale
+Escala_Maxima=Maximum scale
+escala_minima=Minimum scale
+Escala_Minima=Minimum scale
+escala_usuario=Scale specified by the user
+espaciado_horizontal=Horizontal grid spacing
+espaciado_vertical=Vertical grid spacing
+espacio=Space\:
+estadisticas=Statistics
+este_por_debajo_de_=To be under
+este_por_encima_de=To be over
+Esten_contenidos_en=Contained in
+Etiqueta=Label
+Etiquetados=Labeling
+etiquetas=Lables\:
+Etiquetas_estandar=Standard labels
+Examinar=Browse
+export=Export
+exportar=Export
+exportar_pdf=Export to pdf
+exportar_ps=Export to ps
+expresion_error=Expresion error
+extension=Extension
+Extent=Extent
+extents_no_coincidentes=Extent of the selected image does not match with the origin image.
+factor_zoom_incorrecto=Incorrect zoom factor.
+fallo_capas=Layer access error.  The following layers will be deleted from the proyect.
+family=Family
+fichero=file
+Fichero=File
+fichero_existe=Selected file already exists as layer band
+fichero_incorrecto=Invalid file
+fichero_ya_existe_seguro_desea_guardarlo=The file already exists, do you want to continue?
+field_already_exists=Field already exists
+field_decimal_count=Decimal count
+field_default_value=Default value
+field_length=Length
+field_manager=Field Manager
+field_name=Field name
+field_type=Type
+filtro=Filter
+finish=Finish
+Font=Font
+formato=Format
+Formato_de_numero_erroneo=Incorrect number format
+formato_incorrecto=Invalid format
+fuente=Font
+General=General
+georeferenciado=Georeferenced
+gestion_encuadre=Zoom Manager
+grados=Degrees\:
+Grados=Degrees
+Graficos=Graphics
+grosor_linea=Line width\:
+group=Group
+group_graphic_line=Group graphic line
+grupo=group
+guardado=Saved in
+guardar=Save
+Guardar=Save
+guardar_cambios=Save changes?
+guardar_como=Save as...
+guardar_como_plantilla=Save as template
+Guardar_el_zoom_actual=Save current zoom
+Guardar_leyenda=Save legend
+guardar_proyecto=Save project
+guardar_tooltip=Save changes to project
+Habilitar_etiquetado=Enable labeling
+Hiperenlace=Hyperlink
+horizontal=Horizontal
+horizontal_space=Horizontal space
+Identificar_Resultados=Identify results
+Igual_que_la_impresora=Same as printer
+igual_todos_lados=Equal displacement for all sides.
+imagen=Image
+Implimir=Print
+importar=Import
+Imprimir=Print
+Indexando=Indexing...
+Indexando_espacialmente=Spatially indexing the layer
+indexar_campos=Index fields
+Inferior=Lower
+info=Information
+informacion=Information
+Informacion=Information
+Inicializando=Initializing
+initial_warning=<html><b>WARNING\!</b><br>Development version. It might have important errors and even provocate damages in the edited files.<br><br>The last stable version of gvSIG is recommended for daily work.</html>
+input_output_error=Input/Output error.
+insert_row=Insert row
+Insertar=Insert
+insertar_cajetin=Insert grid
+insertar_circulo=Insert circle
+insertar_columna=Insert column
+insertar_escala=Insert scale
+insertar_fila=Insert row
+insertar_imagen=Insert image
+insertar_leyenda=Insert legend
+insertar_linea=Insert line
+insertar_norte=Insert north
+insertar_poligono=Insert polygon
+insertar_polilinea=Insert polyline
+insertar_punto=Insert point
+insertar_rectangulo=Insert rectangle
+insertar_texto=Insert text
+insertar_vista=Insert view
+Intersecten_con=Intersected with
+Intervalo=Interval
+Intervalos=Intervals
+introduce_nombre=Type the new name
+introduzca_el_nombre_de_la_nueva_capa_de_anotaciones=Insert the name of the new annotation layer
+introduzca_nuevo_nombre_para_la_vista=Write the new name for the view
+invalid_value_for_gap=Invalid value for gap
+invert_selection=Invert selection
+Italic=Italic
+Izquierda=Left
+Izquierdo=Left
+join=Join
+jpg=JPEG files
+keep_the_order_of_values=Keep the order of values.
+kilometros=Kilometers
+Kilometros=Kilometers
+leyenda=Legend
+Leyenda=Legend
+leyenda_campo_unido=You are using a field of the union either in the legend or in the labeling. Please, change the legend before removing the union.
+Leyenda_Por_Defecto=Default legend
+linea=Line
+linea_grafica=Graphic line
+lineal_directo=Direct linear
+link=Link
+Link=Link
+localizador=Locator
+locked_element=Locked element
+locked_element_it_cannot_be_deleted=Locked element.\nIt cannot be deleted.
+locked_element_it_cannot_be_renamed=Locked element.\nIt cannot be removed.
+m/pixel=metros/pixel
+malla_activada=Active grid
+manage_fields=Manage fields
+mantener_intervalo=Keep interval
+map_units=Map units
+mapa=Map
+Mapa=Map
+mapas=Maps
+marco=Frame
+marco_vista=Framework of the view
+margenes=Margins\:
+mas_de_100_simbolos=More than 100 symbols usually do not give any information in a map
+max_length_is=Max length is
+maximo=Maximum
+MDIFrame.quiere_salir=Exit gvSIG?
+MDIFrame.salir=Exit
+media=Mean
+medir_area=Measure area
+medir_distancias=Measure distances
+metadatos=Metadatos
+metros=Meters
+Metros=Meters
+Milimetros=Milimeters
+Millas=Miles
+minimo=Minimum
+modificar=modify
+modification_date=Modification date
+mostrar_escala_numerica=Show numeric scale.
+Mostrar_siempre=To show always
+mostrar_unidades=Show units
+move_elements=Move elements
+Muestra_atributos=Show attributes of selected layers.
+muestra_los_elementos_de_la_capa_usando_un_simbolo_por_cada_valor_unico=Show the layers features using a each unique value symbol
+Muestra_los_elementos_de_la_capa_usando_una_gama_de_colores_en_funcion_del_valor_de_un_determinado_campo_de_atributos=Show the layers features using a range of color according to values of a attribute field
+Muestra_todos_los_elementos_de_una_capa_usando_el_mismo_simbolo=Show all the items of a layer using the same symbol
+natural_intervals=Natural intervals
+navegacion=Navigation
+navegacion_vista=Navegation in a view
+necesita_una_capa_activa=Needs an active layer
+necesita_una_capa_vectorial_activa=Needs an active vectorial layer
+new_field=New field
+new_field_properties=New field properties
+next=Next
+ninguna_capa_seleccionada=No layer selected
+ninguna_impresora_configurada=No printer set
+Nivel_de_transparencia=Transparency level
+no=No
+no_activos=Not active
+No_de_intervalos=Nr of intervals
+no_es_posible_aplicar_leyenda_vacia=It's imposible to apply empty legend.
+No_ha_sido_posible_realizar_la_operacion=Unable to perform operation.
+no_hay_campo_seleccionado=
+No_mostrar=Do not show the layer when the scale
+No_mostrar_la_capa_cuando_la_escala=Don't show the layer when the scale
+no_se_pegaran_las_tablas=There will not be any pasted table
+no_se_pegaran_las_vistas_del_conflicto=The conflicting views will not be pasted
+No_se_pudo_obtener_la_tabla_de_la_capa=It was not possible to retrieve from the layer
+no_visibles=Not visible
+nombre=Name
+Nombre=Name
+nombre_no_valido=Invalid name
+Nombre_que_se_le_dara_al_zoom=Name for the zoom
+nombre_sesion=Session name
+none=none
+none_selected=None selected
+normal=Normal
+north=North
+not_GVL_save_question=The selected format is not gvSIG native, it can be used to share legends with other software.\nIf you'd like, in the future, to import back this legend to gvSIG,\nwe recommend to use GVL format in order to avoid losing some of the original legend settings.
+Nueva_tabla=New table
+nuevo=New
+Nuevo_conjunto=New set
+nuevo_nombre_para_el_mapa=Write the new name for the layer
+nuevo_proyecto=New project
+nuevo_tooltip=Create a new project
+num_bandas=Band count
+num_columnas=Number of columns
+num_filas=Number of rows
+Num_intervalos=Number of Intervals
+numero_decimales_mostrar=Number of decimals
+numero_incorrecto=Invalid value
+ok=Ok
+opacidad=Opacity
+operacion_cancelada=Cancelled operation
+options.layout.paper_properties.landscaped=Lands scaped
+options.layout.paper_properties.paper_direction=Paper direction
+options.layout.paper_properties.portrait=Portrait
+options.layout.paper_properties.title=Properties
+options.view.default_map_overview_back_color=Default map overview back color
+options.view.default_selection_color=Default selection color
+options.view.default_view_back_color=Default view back color
+options.view.invisible_new_layers=Add new layers in invisible mode
+options.view.keep_scale_on_resizing=Keep scale on resizing
+orientacion=Orientation\:
+origen_de_datos=Data origin
+Origen_de_datos=Data origin
+Origen_de_Datos=Data origin\:
+owner=Owner
+parse_expresion_error=Parse expresion error.
+paste=Paste
+paste_elements=Paste elements
+path=Path
+pdf=Pdf
+pegar=Paste
+pegar_mapas=Pasta maps
+pegar_vistas=Paste views
+Permite_etiquetar_los_elementos_del_mapa_con_el_valor_de_un_determinado_campo=Allows to set label of the map elements with the value of a particular field
+Personalizado=Custom
+personalizar_margenes=Customize margins
+Pies=Feet
+pila_de_comandos=commands stack
+pixeles=pixels
+pixels=pixels
+Plain=Regular
+plantilla=template
+please_insert_new_field_name=Please insert new field name.
+png=PNG files
+poligono=Polygon
+polilinea=polyline
+poner_capas_a=Set layers as
+por_debajo_de=below\:
+por_encima_de=above\:
+Por_favor_active_la_capa=Please, activate the layer
+posicion_linea=Position of the line
+precision=Precision
+preparar_pagina=Prepare page
+Preparar_pagina=Prepare page
+presentacion=Presentation
+previsualizacion=Preview
+Previsualizacion=Preview
+Previsualizacion_de_simbolo=Symbol preview
+projection=Projection
+propiedad=Oroperty
+propiedades=Properties
+propiedades_cajetin=Box properties
+propiedades_capa=Layer properties
+propiedades_de_la_capa=Layer properties
+Propiedades_escala_grafica=Properties of the scale bar
+propiedades_grafico=Graphic properties
+propiedades_mapa=Map properties
+propiedades_marco_imagenes=Properties of Image framework
+propiedades_marco_leyenda=Properties of legend framework
+propiedades_marco_vista=Properties of view framework
+propiedades_raster=Raster properties
+propiedades_sesion=Session properties
+propiedades_tabla=Table properties
+Propiedades_texto=Properties of text
+propiedades_vista=View properties
+Proyecciones=Projections
+ps=Ps
+puerto=Port
+Pulgadas=Inches
+punto=Point
+quantile_intervals=Quantile interval
+quiere_continuar=Would you like to continue?
+Quitar=Remove
+Quitar_capa=Remove layer
+quitar_enlaces=Remove links
+Quitar_todos=Remove all
+quitar_uniones=Remove joins
+rango_de_escalas=Scale range
+Rango_de_escalas=Rank of scales
+realce=Enhance
+realmente_desea_guardar=Would you really like to save?
+recargar=Reload
+recorte_colas=Tail trimming
+recorte_vista=Cut to view
+rectangulo=Rectangle
+recuento=Recount
+Recuperar_leyenda=Load legend
+Recuperar_y_eliminar_otros_zoom=Recover and delete other zoom
+reference_system=Reference System
+refrescar=Refresh
+rehacer=Redo
+rellenar_marco_vista=Fill view framework
+relleno=Fill\:
+remove_elements=Remove elements
+remove_fields=Remove fields
+remove_row=Remove row
+remove_rows=Remove rows
+rename_field=Rename field
+renombrar=Rename
+reproyectar_aviso=The layer projection is not the same as the views projection.\nATENTION\: It can be unaccurate with some transformations.\nPlease read docs
+reproyectar_pregunta=Do you want to reproject?
+resolucion_resultado=Resolution of the result\:
+resto_valores=Other values
+restore_palette=Restore palette
+rotation_field=Rotation field
+salir=Exit
+salir_tooltip=Exit
+salvar_raster=Save as raster
+Sample=Sample
+Se_superponen_a=Over
+Sean_disjuntos_a=disjoint as
+Sean_iguales_a=same as
+seleccion=Selection
+seleccion_fuente=Font selection
+Seleccion_por_capa=Selection by Layer
+selecciona_sistema_de_referencia=Choose reference system
+Seleccionar=Select
+seleccionar_capas=Select Layers
+seleccionar_capas_raster=Select raster layers
+Seleccionar_de_las_capas_activas_los_elementos_que=Select items from active layers that are\:
+Seleccionar_del_conjunto=Select from set
+Seleccionar_fichero=Select file
+seleccionar_por_poligono=Select by polygon
+seleccionar_por_punto=Select by point
+seleccionar_por_rectangulo=Select by rectangle
+seleccionar_todos=Select all
+seleccione_campo_enlace=Select field to use for link
+seleccione_el_campo_angulo_de_la_capa_de_anotaciones=<HTML>Choose the field used to store the slope of the label\u0092s text</HTML>
+seleccione_el_campo_color_de_la_capa_de_anotaciones=<HTML>Choose the field used to store the label\u0092s color</HTML>
+seleccione_el_campo_de_texto_que_desea_que_se_utilize_para_mostrar_la_nueva_capa_virtual=<HTML>Choose the text field which should be used to show the new virtual layer.</HTML>
+seleccione_el_campo_fuente_de_la_capa_de_anotaciones=<HTML>Choose the field used to store the label\u0092s font</HTML>
+seleccione_el_campo_tamano_de_la_capa_de_anotaciones=<HTML>Choose the field used to store the label\u0092s height</HTML>
+seleccione_fecha=Select date...
+seleccione_tabla_a_enlazar=Select table to link
+seleccione_tabla_origen=Select origin table of the join
+selection_color=Color selection
+selection_up=Move selection to top
+semantic_expresion_error=Semantic expresion error.
+separator=Separator
+Servidor=Server
+Shapefile=Shapefile
+Show_grid=Show grid
+show_this_dialog_next_startup=Show this dialog on next startup
+si=yes
+siempre=Always
+simbolo=Symbol
+Simbolo=Symbol
+Simbolo_unico=Unique symbols
+Simbologia=Symbols
+simplificar_leyenda=Simplify legend
+simplify=Simplify
+sin_titulo=Untitled
+sincronizar_color_borde_relleno=Sincronize color of stroke and fill\:
+Size=Size
+sobre_la_barra=On the scale bar
+Solo_para_capas_vectoriales=Only for vector layers
+sorter=Sorter
+start_edition=Start edition
+statistics=Statistics
+stop_edition=Finish edition
+Style=Style
+Subir_capa=Move layer up
+suma=Sum
+Superior=Upper
+symbol_selector=Symbol selector
+Tabla=Table
+Tabla_de_Atributos=Table of attributes
+tablas=Tables
+Tablas=Tables
+tag=tag
+tamano=Size\:
+tamano_metros=Size in meters
+tamano_pagina=Page Size
+tamano_posicion=size/position
+tamanyo_borde=Border size
+tamanyo_fuente=Font size
+tamanyo_pagina=Page size
+tamPixX=Pixel size X
+tamPixY=Pixel size Y
+terminar=Terminate
+terminar_edicion=Terminate edition
+texto=Text
+this_table_is_not_self_editable=Table not editable
+tipo_dato=Data type
+tipo_de_intervalo=Interval type
+tipo_de_leyenda=Type of legend
+tipo_fichero_proyecto=gvSIG project file(*.gvsproj)
+tipo_linea=Stroke\:
+tipo_relleno=Fill\:
+tipo_simbolo=Type of symbol\:
+tipos_de_documentos=Document types
+titulo=Project manager
+titulo_fframetext=Text field title
+to_annotation=Transform to annotation layer
+to_palette=Change to palete
+tooltip_copiar_al_portapapeles=Copy to clipboard
+tooltip_cortar_al_portapapeles=Cut to clipboard
+tooltip_pegar_desde_el_portapapeles=Paste from clipboard
+Toquen=in contact with
+transparencia=Transparency
+Transparencia=Transparency
+transparencia_pixel=Transparency per pixel
+ungroup=Ungroup
+unidades=Units\:
+Unidades=Units\:
+untitled=Untitled
+url=url
+Usar_indice_espacial=Use spatial index
+usar_marco=Use frame
+usar_titulo=Use title
+usuario=User
+utilizar_margenes_impresora=Use printer margins
+vacia=Empty
+Valor=Value
+Valores=Values
+Valores_unicos=Unique values
+varianza=Variance
+Ventana=Window
+ventana_proyecto=Project window
+Ver=Show
+ver_error_capa=Show errors
+ver_tabla_atributos=See table of attributes
+ver_tags=Show tags
+ver_tooltip=Show project window
+vertical=Vertical
+vertical_space=Vertical space
+visible=Visible
+visibles=Visible
+Vista=View
+vistas=Views
+visualizacion=Viewing
+Visualizacion=Visualization
+visualizar_cuadricula=Visualize grid
+warning=Warning
+xmax=Maximum X
+xmin=Minimum X
+Yardas=Yards
+ymax=Maximum Y
+ymin=Minimum Y
+zone=Zone
+Zoom_a_la_capa=Zoom to layer
+Zoom_Acercar=Zoom in
+Zoom_Alejar=Zoom out
+Zoom_Completo=Full extent
+Zoom_Completo_Vista=View frame full extent
+zoom_in_factor=Zoom in factor
+Zoom_Mas=Zoom In
+Zoom_Mas_Vista=Zoom In view frame
+Zoom_Menos=Zoom out
+Zoom_Menos_Vista=View frame zoom out
+zoom_out_factor=Zoom out factor
+Zoom_pixel=Zoom to raster resolution
+Zoom_Previo=Previous zoom
+Zoom_Real=1\:1 Zoom
+Zoom_Select=Zoom to selection
+too_large_border=Too large border
+
+categories=Categories
+cannot_apply_to_a_non_polygon_layer=Cannot apply to a non-polygon layer
+looks_like_too_low_value_for_this_field_may_cause_system_to_run_slow=Looks like too low value for this field. May cause the system to run slow.
+in_layer=in layer
+could_not_setup_legend=Could not setup legend
+labeling_field=Labeling field
+dot_size=Dot size
+dot_value=Dot value
+outline_color=Border color
+densities=Densities
+high=High
+medium=Medium
+low=Low
+Defines_a_dot_density_symbol_based_on_a_field_value=Defines a dot density symbol based on the value of a field
+dot_density=Dot density
+features=Features
+preview=Preview
+quantities=Quantities
+choose_symbol=Choose symbol
+legend=Legend
+label_text_in_the_TOC=Label text that will appear in the TOC
+exception_cloning_legend=Exception cloning legend.
+character_marker=Character marker
+character_marker_symbol=Character marker symbol
+marker_fill=Marker fill
+choose_marker=Choose marker
+outline=Border
+grid=Grid
+Grid_settings=Grid settings
+random=Random
+fill_properties=Fill properties
+offset=Offset
+separation=Separation
+simple_fill=Simple fill
+fill_color=Fill color
+outline_width=Border width
+trying_to_add_a_non_TypeSymbolEditor_panel=Trying to add a non SymbolEditor panel.
+two_panels_with_the_same_name=Two panels with the same name.
+symbol_property_editor=Symbol property editor
+properties=Properties
+layers=Layers
+type=Type
+units=Units
+layer=Layers
+preview_not_available=Preview is not available
+point_symbols=Marker symbols
+line_symbols=Line symbols
+polygon_symbols=Polygon symbols
+shape_type_not_yet_supported=Shapetype not yet supported
+symbol_library=Symbol library
+could_not_find_symbol_directory=Could not find symbols directory
+options=Options
+new=New
+reset=Reset
+save=Save
+size=Size
+angle=Angle
+width=Width
+save_error=Save error
+marker_fill=Marker fill
+simple_line=Simple line
+simple_marker=Simple marker
+x_offset=X offset
+y_offset=Y offset
+simple_marker_symbol=Simple marker symbol
+enter_description=Enter description
+syntax_error=Syntax error
+error=Error
+label_expression_help=
+expression=Expression
+label_expression_editor=Label expression editor
+method=Method
+class=Class
+classes=Classes
+text_string=Text
+text_symbol=Text symbol
+font_color=Font color
+enable_labeling=Enable labeling
+visualization=Visualization
+label_styles=Label styles
+placement=Placement
+edit_expression=Edit expression
+SQL_query=SQL query
+remane_class=Rename class
+delete_class=Delete class
+add_class=Add class
+label_features_in_this_class=Label features in this class
+labeling=Labeling
+shape_type_error=Shape type error.
+enter_new_name=Enter new name
+placement_properties=Placement properties
+point_settings=Point settings
+line_settings=Line settings
+polygon_settings=Polygon settings
+position=Position
+orientation=Orientation
+parallel=Parallel
+following_line=Following the line
+perpedicular=Perpendicular
+duplicate_labels=Duplicate layers
+place_one_label_per_feature_part=Place one label per feature part
+place_one_label_per_feature=Place one label per feature
+remove_duplicate_labels=Remove duplicate labels
+label_features_in_the_same_way=Label features in the same way
+define_classes_of_features_and_label_each_differently=Define classes of features and label each differently
+label_only_when_selected=Label only when the feature is selected
+could_not_apply_legend=Could not apply legend
+quantity_by_category=Quantity by category
+graduated_symbols=Graduated symbols
+multiple_atributes=Multiple attribute
+too_large_border=Too large border
+file=File
+file_not_found=File not found
+file_corrupt=File corrupt
+unsupported_legend=Unsupported legend
+symbol=Symbol
+from=From
+to=To
+template=Template
+generating_intervals=Generating intervals
+draw_quantities_using_symbol_size_to_show_relative_values=Draws quantities using symbol size to show relative values.
+could_not_get_shape_type=Could not get shape type.
+general=General
+text_field=Text
+text_height_field=Text height field
+rotation_height=Rotation field
+accessing_file_structure=Acessing file structure
+could_not_restore_text_height_field=Could not restore text height field.
+could_not_restore_rotation_field=Could not restore rotation field.
+could_not_restore_text_field=Could not restore text field.
+font=Font
+usupported_layer_type=Unsupported layer type
+driver_exception=Driver exception
+legend_exception=Legend exception
+variation_by=Variation by
+color_ramp=Color ramp
+values_field=Value fields
+color_field=Color field
+symbol_field=Symbol field
+getting_layer_shape_type=Getting layer shape type
+draw_quantities_for_each_category=Draw quantities for each category.
+recovering_recordset=Recovering recordset.
+fields=fields
+user_defined_labels=User defined labels
+label_attributes_defined_in_table=Label attributes defined in table
+current=Current
+text_symbols=Text symbols
+label_expression_help=
+fixed_height=Fixed height
+location=Location
+location_along_the_lines=Location along the lines
+at_best=At best
+at_begin=At begin
+at_end=At end
+label-point-priority-help=Priority: 0 = Blocked, 1 = Highest, 3 = Lowest
+change_location=Change location
+offset_labels_on_top_of_the_points=Offset labels on top of the points
+offset_labels_horizontally=Offest labels horizontally around the point.
+always_straight=Always straight
+always_horizontal=Always horizontal
+orientation_system=Orientation system
+line=Line
+page=Page
+below=Below
+on_the_line=On the line
+above=Above
+getting_shape_type=Getting shape type
+confirmation_dialog=Confirmation dialog
+options.view.behavior.screen_refreshrate=Screen refresh rate
+options.view.behavior.screen_refreshrate.none=<html><b>None</b> (fastest drawing)</html>
+options.view.behavior.screen_refreshrate.half=<html><b>Half</b></html>
+options.view.behavior.screen_refreshrate.full=<html><b>Full</b> (real time response)</html>
+options.view.behavior.screen_refresh_rate.help=<html><b>Note:</b> the screen refresh rate allows to improve the map navigation experience by visually reducing the latency time between map drawings. This is specially interesting in edition time. However, the refresh is a task that slightly increases CPU processing time (&lt;15%). So, the greather refresh rate the more time is required to draw a map.</html>.
+warning_you_must_input_the_exact_name_this_difference_between_capital_letters_and_small_letters=<html>Warning: you must input the exact name (this difference between capital letters and small letters).</html>
+formato_del_campo_incorrecto=Incorrect format
+error_opening_the_document=Error opening the document
+height=Height
+field=Field
+gradient_fill=Gradient fill
+intervals=Intervals
+percentage=Percentage
+style=Style
+gradient_color=Gradient color
+gradient_fill_symbol=Gradient fill symbol
+buffered=Buffered
+lineal=Lineal
+circular=Circular
+rectangular=Rectangular
+bitmap_and_svg_image_files=Bitmaps and SVG image files
+picture_fill=Picture fill
+scale=Scale
+could_not_open_picture_file=Could not open picture file
+picture_fill_symbol=Picture fill symbol
+text=Text
+formatted=Formatted
+advanced=Advanced
+simple_text_symbol=Simple text symbol
+simple_fill_symbol=Simple fill symbol
+fill_opacity=Fill opacity
+use_outline=Use outline
+outline_opacity=Outline opacity
+failed_installing_symbol_editor=Failed installing symbol editor
+in_the_world=In the world
+in_the_paper=In the paper
+marker_fill_symbol=Marker fill symbol
+apply_visual_correction_to_glyph_for_precise_size_and_position=Apply visual correction to glyph for precise size and positioning
+arrow_decorator=Arrow decorator
+use_decorator=Use decorator
+arrow_sharpness=Arrow sharpness
+number_of_positions=Number of positions
+flip=Flip
+flip_all=Flip all
+flip_first=Flip first
+rotation=Rotation
+rotate_symbol_to_follow_line_angle=Rotate symbol to follow line angle
+keep_symbol_at_fixed_angle_to_page=Keep symbol at fixed angle to page
+no_desc=No description
+line_style=Line style
+mask=Mask
+halo=Halo
+line_fill=Line fill
+line_fill_symbol=Line fill symbol
+description=Description
+merge=Merge
+symbol_levels=Symbol levels
+draw_symbols_in_specified_order=Draw symbols in specified order
+default_view=Default view
+advanced_view=Advanced view
+marker_style=Marker style
+use_outline=Use outline
+select_a_color_scheme=Select a color scheme
+picture_line_symbol=Picture line symbol
+failed_accessing_file=Failed accessing file
+picture_file=Picture file
+selection_picture_file=Selection picture file
+picture_marker_symbol=Picture marker symbol
+style_library=Style library
+new_style=New style
+editing=Editing
+edit_style=Edit style
+tools=Tools
+add_text_area=Add text area
+offset_label=Offset label
+marker_line=Marker line
+marker_line_symbol=Marker line symbol
+undefined_for_StylePreviewer_use=Undefined for StylePreviewer use
+instead=instead
+marker=Marker
+fill=Fill
+behavior=Behavior
+line_properties=Line properties
+join_style=Join style
+join_bevel=Bevel
+join_miter=Miter
+join_round=Round
+end_style=End style
+cap_butt=Butt
+cap_round=Round
+cap_square=Square
+fill_pattern=Fill pattern
+unsupported_format=Unsupported format
+_Metadata=Metadata
+Central_point=Central point
+Final_point=Final point
+Insert_point=Insert point
+Intersection_point=Intersection point
+Medium_point=Middle point
+Nearest_point=Nearest point
+Perpendicular_point=Perpendicular point
+Pixel_point=Pixel-adjusted
+Quadrant_point=Quadrant-adjusted
+Tangent_point=Tangent point
+All_supported=All supported
\ No newline at end of file

Property changes on: tags/v2_0_0_Build_2050/applications/appgvSIG/config/text_en.properties
___________________________________________________________________
Added: svn:keywords
   + Author Date Id Revision
Added: svn:eol-style
   + native

Index: tags/v2_0_0_Build_2050/applications/appgvSIG/config/about.htm
===================================================================
--- tags/v2_0_0_Build_2050/applications/appgvSIG/config/about.htm	(revision 0)
+++ tags/v2_0_0_Build_2050/applications/appgvSIG/config/about.htm	(revision 38653)
@@ -0,0 +1,46 @@
+<html>
+<body>
+
+<img src="gvsig-logo1-association.jpg"><br>
+<h2>gvSIG desktop</h2>
+<p>
+A Geographic Information System (GIS) for desktop environments<br>
+<br>
+Version: %(version)<br>
+Build: %(build)<br>
+Java version: %(java.version)<br/>
+&copy; Copyright gvSIG Association. All rights reserved.<br>
+<br>
+For more information, contact:<a href="http://www.gvsig.com/contact-info">http://www.gvsig.com/contact-info</a><br>
+Or visit <a href="http://www.gvsig.org">http://www.gvsig.org</a>
+</p>
+<br>
+<br>
+<br>
+<font face="Arial, Helvetica, sans-serif"> 
+This program is free software; you can redistribute it and/or
+modify it under the terms of the GNU General Public License
+as published by the Free Software Foundation; either version 2
+of the License, or (at your option) any later version.
+<br>
+This program is distributed in the hope that it will be useful,
+but WITHOUT ANY WARRANTY; without even the implied warranty of
+MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+GNU General Public License for more details.<br>
+<br>
+You should have received a copy of the GNU General Public License
+along with this program; if not, write to the Free Software
+Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307,USA.
+<br>
+
+<p>With our most sincere thanks to:</p>
+<ul>
+	<li><a target="blank" href="http://www.gvsig.org/web/community/agradecimientos/traductores/">Traductores</a></li>
+	<li><a target="blank" href="http://www.gvsig.org/web/community/agradecimientos/testers/">Testers</a></li>
+	<li><a target="blank" href="http://www.gvsig.org/web/community/agradecimientos/otras-colaboraciones/">Otras colaboraciones</a></li>
+</ul>
+      
+
+</font>
+</body>
+</html>
\ No newline at end of file

Property changes on: tags/v2_0_0_Build_2050/applications/appgvSIG/config/about.htm
___________________________________________________________________
Added: svn:eol-style
   + native
Added: svn:keywords
   + Author Date Id Revision

Index: tags/v2_0_0_Build_2050/applications/appgvSIG/config/text_cs.properties
===================================================================
--- tags/v2_0_0_Build_2050/applications/appgvSIG/config/text_cs.properties	(revision 0)
+++ tags/v2_0_0_Build_2050/applications/appgvSIG/config/text_cs.properties	(revision 38653)
@@ -0,0 +1,706 @@
+#Translations for language [cs]
+#Mon Nov 06 09:04:31 CET 2006
+(escala_maxima)=(maxim\u00e1ln\u00ed m\u011b\u0159\u00edtko)
+(escala_minima)=(minim\u00e1ln\u00ed m\u011b\u0159\u00edtko)
+1\:=
+_(Simbolo_unico)=(Unik\u00e1tn\u00ed symboly)
+__proyeccion_actual=Aktu\u00e1ln\u00ed projekce\:
+__redimensionar_texto_escala=Zm\u011bna velikosti textu dle zobrazovac\u00edho m\u011b\u0159\u00edtka
+__seleccion_de_fuente=V\u00fdb\u011br p\u00edsma
+A0=A0
+A1=A1
+A2=A2
+A3=A3
+A4=A4
+abajo=Dol\u016f
+abrir=Otev\u0159\u00edt
+abrir_plantilla=Otev\u0159\u00edt \u0161ablonu
+abrir_proyecto=Otev\u0159\u00edt projekt
+abrir_tooltip=Otev\u0159\u00edt existuj\u00edc\u00ed projekt
+Abrir_una_capa=Otev\u0159\u00edt vrstvu
+Accion_Predefinida=P\u0159eddefinovan\u00e1 akce
+aceptar=Budi\u017e
+Aceptar=Budi\u017e
+acerca_de=O programu...
+activar=Activate
+activar_regla=Aktivace prav\u00edtka
+activos=Aktivn\u00ed
+add_delete_edit_fields=Atribut m\u016f\u017ee b\u00fdt vlo\u017een, smaz\u00e1n nebo p\u0159ejmenov\u00e1n.
+add_layer=P\u0159idat vrstvu
+add_rows=P\u0159idej z\u00e1znam
+adjust_transparency=Nastaven\u00ed pr\u016fhlednosti
+agrupacion=Seskupen\u00ed
+agrupar=Seskupit
+agrupar_capas=Seskupen\u00ed vrstev
+agrupar_graficos=Seskupen\u00ed prvk\u016f
+agrupar_linea=Seskupen\u00ed lini\u00ed s grafick\u00fdmi prvky
+Ajustar_transparencia=Nastavit pr\u016fhlednost
+ajustes_linea_grafica=Nastaven\u00ed lini\u00ed
+Al_leer_la_leyenda=na\u010d\u00edt\u00e1n\u00ed legendy
+alias=Alias
+align_center=Zarovnej na st\u0159ed
+align_down=Zarovnej dol\u016f
+align_left=Zarovnej vlevo
+align_right=Zarovnej vpravo
+align_to_layout_center=Zarovnej na st\u0159ed mapy
+align_to_layout_down=Zarovnej k spodn\u00edmu okraji mapy
+align_to_layout_left=Zarovnej k lev\u00e9mu okraji mapy
+align_to_layout_right=Zarovnej k prav\u00e9mu okraji mapy
+align_to_layout_up=Zarovnej k horn\u00edmu okraji mapy
+align_to_layout_vertical_center=Zarovnej na vektik\u00e1ln\u00ed st\u0159ed mapy
+align_up=Zarovnej nahoru
+align_vertical_center=Zarovnej na vektik\u00e1ln\u00ed st\u0159ed
+alineamiento=Zarovn\u00e1n\u00ed\:
+alinear=Zarovn\u00e1n\u00ed
+alinear_graficos=Zarovnat prvek
+alta=Vysok\u00fd
+alto=V\u00fd\u0161ka
+altura=V\u00fd\u0161ka\:
+Altura_fija_de_texto=Pevn\u00e1 v\u00fd\u0161ka textu
+ambito=Rozsah
+Anadir=P\u0159idat
+Anadir_al_conjunto=P\u0159idat do mno\u017einy
+Anadir_capa=P\u0159idat vrstvu
+Anadir_Capa=P\u0159idat vrstvu
+anadir_tag=P\u010didej tag
+Anadir_todos=P\u0159idat v\u0161e
+ancho=\u0160\u00ed\u0159ka
+ancho_alto=\u0160\u00ed\u0159ka X v\u00fd\u0161ka
+anchura=\u0160\u00ed\u0159ka\:
+Aplicar=Pou\u017e\u00edt
+Archivo=Soubor
+arriba=Nahoru
+ascending_order=Vzestupn\u00e9 po\u0159ad\u00ed
+ascending_order_tooltip=Se\u0159adit podle zvolen\u00e9 polo\u017eky vzestupn\u011b
+Atributo=Atribut
+automatico=Automaticky
+Ayuda=N\u00e1pov\u011bda
+back=P\u0159edchoz\u00ed
+background_color=Barva pozad\u00ed
+baja=Spodn\u00ed
+Bajar_capa=P\u0159esun vrstvy dol\u016f
+bandas=Okraje
+barra=Sloupec\:
+base=base
+base_datos=Datab\u00e1ze
+bmp=BMP soubory
+Bold=Tu\u010dn\u00fd
+borra_seleccion=Vymazat vybran\u00e9
+borrador=Koncept
+borrar=Smazat/Zru\u0161it
+box=box
+brillo=Jas
+brillo_y_contraste=Jas a kontrats
+browse=Vyhledej
+cajetin=Box
+Calcular_intervalos=V\u00fdpo\u010det intervalu
+calidad=Kvalita
+cambiar_el_alto_de_los_elementos_seleccionados_hasta_coincidir_con_el_mas_alto=Zm\u011b\u0148 v\u00fd\u0161ku vybran\u00e9ho elementu na v\u00fd\u0161ku nejvy\u0161\u0161\u00edho elementu.
+cambiar_el_ancho_de_los_elementos_seleccionados_hasta_coincidir_con_el_mas_ancho=Zm\u011b\u0148 \u0161\u00ed\u0159ku vybran\u00e9ho elementu na \u0161\u00ed\u0159ku nej\u0161i\u0159\u0161\u00edho elementu.
+cambiar_el_tamano_de_los_elementos_seleccionados_hasta_coincidir_con_el_mas_grande=Zm\u011b\u0148 velikost vybran\u00e9ho elementu na velikost nejv\u011bt\u0161\u00edho elementu.
+Cambio_Color=Zm\u011bna barvy
+cambio_nombre=Zm\u011bna n\u00e1zvu
+campo=Pole
+Campo=Pole
+campo_altura_texto=V\u00fd\u0161ka textov\u00e9ho pole\:
+Campo_de_clasificacion=Kl\u00ed\u010dov\u00e1 polo\u017eka
+Campo_de_etiquetado=Popisn\u00e9 pole
+Campos=Pole
+cancel=Zru\u0161it
+Cancel=Zru\u0161it
+cancelar=Zru\u0161it
+Cancelar=Zru\u0161it
+Capa=Vrstva
+Capas=Vrstvy
+Capas_del_localizador=Lokalizace vrstev
+Centimetros=Centimetry
+cerrar=Zav\u0159\u00edt
+Cerrar=Zav\u0159\u00edt
+change=
+change_before=P\u0159en\u00e9st do pop\u0159ed\u00ed
+change_behind=Poslad do pozad\u00ed
+change_height=Zm\u011bnit v\u00fd\u0161ku
+change_width=Zm\u011bnit \u0161\u00ed\u0159ku
+circulo=Kru\u017enice
+clave=K\u00f3d
+close=zav\u0159\u00edt
+coincidir_tamanyo=Srovnej velikost
+colocar_a_margenes=Um\u00edstit s referenc\u00ed k okraji
+colocar_alrededor_seleccionados=Um\u00edstit kolem vybran\u00e9 polo\u017eky
+colocar_alrededor_todos=Um\u00edstit kolem v\u0161ech polo\u017eek
+colocar_delante=P\u0159en\u00e9st dop\u0159edu
+colocar_detras=P\u0159en\u00e9st do pozad\u00ed
+color=Barva\:
+Color_final=Koncov\u00e1 barva
+Color_inicio=Po\u010d\u00e1te\u010dn\u00ed barva
+color_texto=Barva textu\:
+comentarios=Koment\u00e1\u0159e
+comenzar_edicion=Zahaj editaci
+compleja=
+configurar=Konfigurace
+configurar_localizador=Konfikurace mapy lok\u00e1toru
+Configurar_localizador=Konfigurace lok\u00e1toru
+confirmar_borrar=Prvek bude odstran\u011bn. Jste si jist\u00fd?
+conflicto_de_nombres_de_mapas_al_pegar=Pokou\u0161\u00edte se vlo\u017eit mapu jeji\u017e jm\u00e9no u\u017e v tomto projektu existuje
+conflicto_de_nombres_de_tablas_al_pegar=Pokou\u0161\u00edte se vlo\u017eit tabulku jeji\u017e jm\u00e9no u\u017e v tomto projektu existuje
+conflicto_de_nombres_de_vistas_al_pegar=Pokou\u0161\u00edte se vlo\u017eit pohled jeji\u017e jm\u00e9no u\u017e v tomto projektu existuje
+conflito_de_nombres_de_tablas_al_pegar=konflikt se jm\u00e9nem tabulek p\u0159i vkl\u00e1d\u00e1n\u00ed
+conservar_escala_visualizacion=Nastaven\u00ed zobrazovac\u00edho m\u011b\u0159\u00edtka
+consulta=Query
+Contengan=Obsahuje
+contraste=Contrast
+coor_geograficas=Geografick\u00e9 sou\u0159adnice
+copiar=Kop\u00edrovat
+copy=Kop\u00edrovat
+cortar=P\u0159esu\u0148
+creation_date=Datum vytvo\u0159en\u00ed
+Crucen_con=P\u0159ek\u0159\u00ed\u017een\u00fd s
+cuando_activo=Kdy\u017e je aktivn\u00ed
+cut=Vyst\u0159ihnout
+Dado_un_campo_de_atributos=Zadan\u00fd atribut
+debera_introducir_nombres_para_las_vistas_a_pegar=Mus\u00edte napsat nov\u00e9 n\u00e1zvy pohled\u016f
+debera_introducir_nombres_para_los_mapas_a_pegar=Mus\u00edte napsat nov\u00e9 n\u00e1zvy map
+default_projection=
+default_value=Implicitn\u00ed hodnota
+dehacer=Zp\u011bt
+delete_field=Smazat polo\u017eku
+Derecha=Prav\u00e1 strana
+Derecho=Prav\u00fd
+desagrupar=Odskupit
+desagrupar_capas=Odskupit vrstvy
+desagrupar_graficos=Odskupit prvky
+descending_order=Sestupn\u00e9 po\u0159ad\u00ed
+descending_order_tooltip=Se\u0159adit podle zvolen\u00e9 polo\u017eky sestupn\u011b
+descripcion_de_configuracion_capa_de_anotaciones=<HTML>Nechte implicitn\u00ed hodnoty, kter\u00e9 jsou sd\u00edlen\u00e9 v\u0161emi atributy vrstvy. Zvolte pole, kter\u00e1 obsahuj\u00ed hodnoty pro \u00fapavu popisu.</HTML>
+descripcion_de_crear_capa_de_anotaciones=<HTML>Nov\u00e1 virtu\u00e1ln\u00ed vrstva m\u016f\u017ee b\u00fdt vytvo\u0159ena pomoc\u00ed tohoto n\u00e1stroje na z\u00e1klad\u011b existuj\u00edc\u00ed vrstvy, kter\u00e1 umo\u017e\u0148uje pokro\u010dil\u00e9 popisy. Zm\u011bn\u00ed se zobrazen\u00ed <br> zvolen\u00e9 vrstvy na zobrazen\u00ed hodnot sv\u00fdch polo\u017eek.</HTML>
+desde_arriba=Shora\:
+desde_izquierda=Z leva\:
+desea_borrar_el_documento=Opravdu chcete smazat vybran\u00e9 dokumenty?
+desea_borrar_la_capa=Opravdu chcete smazat vybran\u00e9 vrstvy?
+desea_continuar=Chcete pokra\u010dovat?
+deshacer=Zp\u011bt
+desplaza_los_elementos_seleccionados_a_la_derecha=P\u0159esunout zvolen\u00e9 vrstvy doprava
+desplaza_los_elementos_seleccionados_a_la_izquierda=P\u0159esunout zvolen\u00e9 vrstvy doleva
+desplaza_los_elementos_seleccionados_al_centro_por_el_eje_x=P\u0159esunout zvolen\u00e9 prvky doprost\u0159ed osy X
+desplaza_los_elementos_seleccionados_al_centro_por_el_eje_y=P\u0159esunout zvolen\u00e9 prvky doprost\u0159ed osy Y
+desplaza_los_elementos_seleccionados_hacia_abajo=P\u0159esunout zvolen\u00e9 prvky dospodu
+desplaza_los_elementos_seleccionados_hacia_arriba=P\u0159esunout zvolen\u00e9 prvky nahoru
+Desplazamiento=P\u0159em\u00edst\u011bn\u00ed
+desviacion_tipica=Standardn\u00ed odchylka
+distance_units=Jednotky vzd\u00e1lenosti
+distribuir=Rozm\u00edstit\:
+distribuir_elementos_sobre_todo_el_layout=Uspo\u0159\u00e1dej elementy p\u0159es celou mapu.
+distributes_down=Uspo\u0159\u00e1dej ze spodu
+distributes_horizontal=Uspo\u0159\u00e1dej elementy horizont\u00e1ln\u011b
+distributes_left=Uspo\u0159\u00e1dej zleva
+distributes_right=Uspo\u0159\u00e1dej zprava
+distributes_to_layout_down=Uspo\u0159\u00e1dej ze spodu mapy
+distributes_to_layout_horizontal=Uspo\u0159\u00e1dej mapu horizont\u00e1ln\u011b
+distributes_to_layout_left=Uspo\u0159\u00e1dej mapu z leva
+distributes_to_layout_right=Uspo\u0159\u00e1dej mapu z prava
+distributes_to_layout_up=Uspo\u0159\u00e1dej mapu shora
+distributes_to_layout_vertical=Uspo\u0159\u00e1dej mapu vertik\u00e1ln\u011b
+distributes_up=Uspo\u0159\u00e1dej shora
+distributes_vertical=Uspo\u0159\u00e1dej vertik\u00e1ln\u011b
+distribuye_el_espacio_entre_los_elementos_en_horizontal=Uspo\u0159\u00e1dej horizont\u00e1ln\u011b mezery mezi elementy.
+distribuye_el_espacio_entre_los_elementos_en_vertical=Uspo\u0159\u00e1dej vertik\u00e1ln\u011b mezery mezi elementy.
+distribuye_los_elementos_seleccionados_de_forma_equidistante_de_abajo_hacia_arriba=Uspo\u0159\u00e1dej vybran\u00e9 elementy rovnom\u011brn\u011b ze spodu nahoru.
+distribuye_los_elementos_seleccionados_de_forma_equidistante_de_arriba_hacia_abajo=Uspo\u0159\u00e1dej vybran\u00e9 elementy rovnom\u011brn\u011b shora dolu.
+distribuye_los_elementos_seleccionados_de_forma_equidistante_de_derecha_a_izquierda=Uspo\u0159\u00e1dej vybran\u00e9 elementy rovnom\u011brn\u011b zprava do leva.
+distribuye_los_elementos_seleccionados_de_forma_equidistante_de_izquierda_a_derecha=Uspo\u0159\u00e1dej vybran\u00e9 elementy rovnom\u011brn\u011b zleva do prava.
+distribuye_los_elementos_seleccionados_de_forma_equidistante_y_horizontal=Uspo\u0159\u00e1dej rovnom\u011brn\u011b vybran\u00e9 elementy v horizont\u00e1ln\u00edm sm\u011bru.
+distribuye_los_elementos_seleccionados_de_forma_equidistante_y_vertical=Uspo\u0159\u00e1dej rovnom\u011brn\u011b vybran\u00e9 elementy ve vertik\u00e1\u00edln\u00edm sm\u011bru.
+divisiones_izquierda=D\u011blen\u00ed doleva
+documento=
+documentos_existentes=Existuj\u00edc\u00ed dokumenty
+draw_text_only=Vykresl\u00ed jenom text
+driver=Ovlada\u010d
+Dxffiles=DXF soubory
+edicion=Editace
+editable=Editovateln\u00fd
+Editar_leyenda=Upravit styl
+editar_vertices=Edituj vrchol
+el_numero_maximo_de_intervalos_para_este_campo_es=Maxim\u00e1ln\u00ed po\u010det interval\u016f pro tuto polo\u017eku je
+Elegir_Color=Select Barva
+Elegir_Fuente=Vybrat p\u00edsmo
+elemento_ya_existe=Element u\u017e existuje
+Elementos_seleccionados_de_la_capa=Vybran\u00e9 polo\u017eky z vrstvy
+Eliminar=Smazat
+eliminar_capa=Smazat vrstvu
+eliminar_columna=Odstra\u0148 sloupec
+eliminar_extremos=Odstranit hrany
+eliminar_fila=Odstra\u0148 z\u00e1znam
+en_el_mapa=Ve vrstv\u011b\:
+En_metros=V metrech
+En_pixels=V pixelech
+en_unidades=v jednotk\u00e1ch
+Encuadre=Zoom
+Encuadre_Vista=Zobrazit posunova\u010d
+enlace_vivo=Aktivn\u00ed odkaz
+Enlazar_a_fichero_de_texto=Odkaz na textov\u00e9 soubory
+Enlazar_a_ficheros_de_imagen=Odkaz na soubory s obr\u00e1zky
+equal_intervals=Shodn\u00e9 intervaly
+Error_exportando_SLD=Chyba p\u0159i exportu do SLD
+Error_guardando_la_leyenda=Chyba p\u0159i ukl\u00e1d\u00e1n\u00ed legendy
+Error_guardando_la_plantilla=Chyba p\u0159i ukl\u00e1d\u00e1n\u00ed \u0161ablony
+escala=M\u011b\u0159\u00edtko
+Escala=M\u011b\u0159\u00edtko
+escala_desconocida=Nezn\u00e1m\u00e9 m\u011b\u0159\u00edtko
+escala_maxima=Maxim\u00edln\u00ed m\u011b\u0159\u00edtko
+Escala_Maxima=Maxim\u00e1ln\u00ed m\u011b\u0159\u00edtko
+escala_minima=Minim\u00e1ln\u00ed m\u011b\u0159\u00edtko
+Escala_Minima=Minim\u00e1ln\u00ed m\u011b\u0159\u00edtko
+escala_usuario=M\u011b\u0159\u00edtko specifikov\u00e1no u\u017eivatelem
+espaciado_horizontal=Velikost horizont\u00e1ln\u00ed m\u0159\u00ed\u017eky
+espaciado_vertical=Velikost vertik\u00e1ln\u00ed m\u0159\u00ed\u017eky
+espacio=Mezera\:
+estadisticas=Statistika
+este_por_debajo_de_=B\u00fdt pod
+este_por_encima_de=B\u00fdt nad
+Esten_contenidos_en=Obsa\u017een\u00fd v
+Etiqueta=Popis
+Etiquetados=Popisov\u00e1n\u00ed
+etiquetas=Popisky\:
+Etiquetas_estandar=Standardn\u00ed popisky
+Examinar=Proch\u00e1zet
+export=Exportovat
+exportar=Exportovat
+exportar_pdf=Exportovat jako pdf
+exportar_ps=Exportovat jako ps
+extension=Roz\u0161\u00ed\u0159en\u00ed
+Extent=Oblast
+extents_no_coincidentes=Zvolen\u00e1 hranice nesouhlas\u00ed s p\u016fvodn\u00edm obr\u00e1zkem.
+factor_zoom_incorrecto=Chybn\u00e1 \u00farove\u0148 zv\u011bt\u0161en\u00ed.
+fallo_capas=Chyba  p\u0159\u00edstupu k vrstv\u011b.  N\u00e1sleduj\u00edc\u00ed vrstvy budou vymaz\u00e1ny z projektu.
+family=
+fichero=soubor
+Fichero=Soubor
+fichero_existe=Zvolen\u00fd soubor ji\u017e existuje jako vrstva
+fichero_incorrecto=Chybn\u00fd soubor
+fichero_ya_existe_seguro_desea_guardarlo=Soubor u\u017e existuje, chcete pokra\u010dovat?
+field_already_exists=Polo\u017eka ji\u017e existuje
+field_decimal_count=Des\u00edtkov\u00fd po\u010det
+field_default_value=Implicitn\u00ed hodnota
+field_length=D\u00e9lka
+field_manager=Spr\u00e1vce polo\u017eek
+field_name=N\u00e1zev polo\u017eky
+field_type=Typ
+filtro=Filtr
+finish=Konec
+Font=P\u00edsmo
+formato=Form\u00e1t
+Formato_de_numero_erroneo=Neplatn\u00e9 \u010d\u00edslo form\u00e1tu
+formato_incorrecto=Chybn\u00fd form\u00e1t
+fuente=P\u00edsmo
+General=Obecn\u00fd
+georeferenciado=Georeferencovan\u00fd
+gestion_encuadre=Spr\u00e1va z\u00e1znamu pracovn\u00edch oblast\u00ed
+grados=Stupn\u011b
+Grados=Stupn\u011b
+Graficos=Prvky
+grosor_linea=\u0161\u00ed\u0159ka \u010d\u00e1ry\:
+group=Seskupit
+group_graphic_line=Seskupit grafick\u00e9 linie
+grupo=skupina
+guardado=Ulo\u017een do
+guardar=Ulo\u017eit
+Guardar=Ulo\u017eit
+guardar_cambios=Ulo\u017eit zm\u011bny?
+guardar_como=Ulo\u017eit jako...
+guardar_como_plantilla=Ulo\u017eit jako \u0161ablonu
+Guardar_el_zoom_actual=Ulo\u017eit aktu\u00e1ln\u00ed v\u00fd\u0159ez
+Guardar_leyenda=Ulo\u017eit styl
+guardar_proyecto=Ulo\u017eit projekt
+guardar_tooltip=Ulo\u017eit zm\u011bny do projektu
+Habilitar_etiquetado=Povolit popisov\u00e1n\u00ed
+Hiperenlace=Hyperlink
+horizontal=Horizont\u00e1ln\u00ed
+horizontal_space=Horizont\u00e1ln\u00ed mezera
+Identificar_Resultados=Identifikovat v\u00fdsledky
+Igual_que_la_impresora=Stejn\u00e9 jako tisk\u00e1rna
+igual_todos_lados=Stejn\u00fd posun pro v\u0161echny strany
+imagen=Obr\u00e1zek
+Implimir=
+importar=Import
+Imprimir=Tisk
+Indexando=Indexing...
+Indexando_espacialmente=Prostorov\u00e1 indexace vrstvy
+indexar_campos=
+Inferior=Ni\u017e\u0161\u00ed
+info=Informace
+informacion=Informace
+Informacion=Informace
+Inicializando=Initializace
+initial_warning=<html><b>WAROV\u00c1N\u00cd\!</b>V\u00fdvojov\u00e1 verze. M\u016f\u017ee obsahovat z\u00e1va\u017en\u00e9 chyby a zp\u016fsobit po\u0161kozen\u00ed editovan\u00fdch soubor\u016f.<br><br>Pro b\u011b\u017enou pr\u00e1ci je doporu\u010dov\u00e1na posledn\u00ed stabiln\u00ed verze gvSIG.</html>
+insert_row=Vlo\u017e z\u00e1znam
+Insertar=Vlo\u017eit
+insertar_cajetin=Vlo\u017e grid
+insertar_circulo=Vlo\u017eit kru\u017enici
+insertar_columna=Vlo\u017e atribut
+insertar_escala=Vlo\u017eit m\u011b\u0159\u00edtko
+insertar_fila=Vlo\u017e \u0159\u00e1dek
+insertar_imagen=Vlo\u017eit obr\u00e1zek
+insertar_leyenda=Vlo\u017eit legendu
+insertar_linea=Vlo\u017eit linii
+insertar_norte=Vlo\u017eit sever
+insertar_poligono=Vlo\u017eit polygon
+insertar_polilinea=Vlo\u017e l\u00ednie
+insertar_punto=Vlo\u017eit bod
+insertar_rectangulo=Vlo\u017eit obd\u00e9ln\u00edk
+insertar_texto=Vlo\u017eit text
+insertar_vista=Vlo\u017eit pohled
+Intersecten_con=Protnut\u00e9 s
+Intervalo=Interval
+Intervalos=Intervaly
+introduce_nombre=Zadat nov\u00fd n\u00e1zev.
+introduzca_el_nombre_de_la_nueva_capa_de_anotaciones=Vlo\u017ete n\u00e1zev nov\u00e9 vrstvy pozn\u00e1mek
+introduzca_nuevo_nombre_para_la_vista=Napi\u0161te nov\u00fd n\u00e1zev pohledu
+invalid_value_for_gap=
+invert_selection=
+Italic=Kurz\u00edva
+Izquierda=Vlevo
+Izquierdo=Vlevo
+join=spojit
+jpg=JPEG soubor
+kilometros=Kilometr\u016f
+Kilometros=Kilometr\u016f
+leyenda=Legenda
+Leyenda=Legenda
+leyenda_campo_unido=Pou\u017e\u00edv\u00e1te stejnou polo\u017eku bu\u010f v legend\u011b nebo popisc\u00edch. Pros\u00edm zm\u011b\u0148te \nlegendu p\u0159ed odebr\u00e1n\u00edm spojen\u00ed.
+Leyenda_Por_Defecto=Implicitn\u00ed legenda
+linea=Linie
+linea_grafica=Linie
+lineal_directo=P\u0159\u00edmo line\u00e1rn\u00ed
+link=Propojit
+Link=Odkaz
+localizador=Locator
+locked_element=Uzam\u010den\u00fd element
+locked_element_it_cannot_be_deleted=Uzam\u010den\u00fd element.\nNelze smazat.
+locked_element_it_cannot_be_renamed=Uzam\u010den\u00fd element.\nNelze odstranit.
+m/pixel=metros/pixel
+malla_activada=Aktivovat grid
+manage_fields=Spravovat polo\u017eky
+mantener_intervalo=Zachovat interval
+map_units=Mapov\u00e9 jednotky
+mapa=Mapa
+Mapa=Mapa
+mapas=Mapy
+marco=R\u00e1mec
+marco_vista=Framework pro zobrazen\u00ed
+margenes=Okraje\:
+mas_de_100_simbolos=V\u00edce ne\u017e 100 symbol\u016f obvykle nevn\u00e1\u0161\u00ed do mapy \u017e\u00e1dn\u00e9 informace
+max_length_is=
+maximo=Maximum
+MDIFrame.quiere_salir=Ukon\u010dit gvSIG?
+MDIFrame.salir=Konec
+media=V\u00fdznam
+medir_area=M\u011b\u0159it plochy
+medir_distancias=M\u011b\u0159it vzd\u00e1lenosti
+metadatos=Metadatos
+metros=Metry
+Metros=Metry
+Milimetros=Milimetry
+Millas=M\u00edle
+minimo=Minimum
+modificar=upravit
+modification_date=Datum zm\u011bny
+mostrar_escala_numerica=Sobrazit \u010d\u00edselnou \u0159adu.
+Mostrar_siempre=Zobrazit v\u017edy
+mostrar_unidades=Zobrazen\u00ed jednotek
+move_elements=P\u0159esunout prvky
+Muestra_atributos=Zobrazit atributy vybran\u00fdch vrstev.
+muestra_los_elementos_de_la_capa_usando_un_simbolo_por_cada_valor_unico=Zobraz prvky vrstvy, kter\u00e9 maj\u00ed jedine\u010dnou hodnotu symbolu
+Muestra_los_elementos_de_la_capa_usando_una_gama_de_colores_en_funcion_del_valor_de_un_determinado_campo_de_atributos=Zobraz prvky vrstvy, kter\u00e9 maj\u00ed rozsah barev podle hodnot atribut\u016f
+Muestra_todos_los_elementos_de_una_capa_usando_el_mismo_simbolo=Zobraz v\u0161echny prvky vrstvy, kter\u00e9 maj\u00ed stejn\u00fd symbol
+natural_intervals=P\u0159irozen\u00e9 intervaly
+navegacion=Navigace
+navegacion_vista=Navigace v pohledu
+necesita_una_capa_activa=Aktivn\u00ed vrstva je pot\u0159ebn\u00e1
+necesita_una_capa_vectorial_activa=
+new_field=Nov\u00fd atribut
+new_field_properties=Vlastnosti nov\u00e9ho atributu
+next=Dal\u0161\u00ed
+ninguna_impresora_configurada=Nen\u00ed nastavena \u017e\u00e1dn\u00e1 tisk\u00e1rna
+Nivel_de_transparencia=\u00darov\u011b\u00f2 pr\u016fhlednosti
+no=No
+no_activos=Neaktivn\u00ed
+No_de_intervalos=Po\u010det interval\u016f
+no_es_posible_aplicar_leyenda_vacia=
+No_ha_sido_posible_realizar_la_operacion=Nen\u00ed mo\u017en\u00e9 vykonat operaci
+No_mostrar=Nezobrazit vrstvu v p\u0159\u00edpad\u011b m\u011b\u0159\u00edtka
+No_mostrar_la_capa_cuando_la_escala=Ezobrazovat vrstvu, kdy\u017e je m\u011b\u0159\u00edtko
+no_se_pegaran_las_tablas=Nebude vlo\u017eena \u017e\u00e1dn\u00e1 tabulka
+no_se_pegaran_las_vistas_del_conflicto=Pohled zp\u016fsobuj\u00edc\u00ed konflikt nebude vlo\u017een
+No_se_pudo_obtener_la_tabla_de_la_capa=Nebylo mo\u017en\u00e9 z\u00edskat z vrstvy
+no_visibles=Nevidiln\u00e9
+nombre=Jm\u00e9no
+Nombre=Jm\u00e9no
+nombre_no_valido=\u0160patn\u00e9 jm\u00e9no
+Nombre_que_se_le_dara_al_zoom=N\u00e1zev pro zoom
+nombre_sesion=N\u00e1zev sezen\u00ed
+none=
+none_selected=Nic nezvoleno
+normal=Normal
+north=Sever
+Nueva_tabla=Nov\u00e1 tabulka
+nuevo=Nov\u00fd
+Nuevo_conjunto=Nov\u00e1 skupina
+nuevo_nombre_para_el_mapa=Zadejte n\u00e1zev nov\u00e9 vrstvy
+nuevo_proyecto=Nov\u00fd projekt
+nuevo_tooltip=Vytvo\u0159it nov\u00fd projekt
+num_bandas=Okrajov\u00e9 hodnoty
+num_columnas=Po\u010det sloupc\u016f
+num_filas=Po\u010det \u0159\u00e1dk\u016f
+Num_intervalos=Po\u010det interval\u016f
+numero_decimales_mostrar=
+numero_incorrecto=Neplatn\u00e1 hodnota
+ok=Budi\u017e
+opacidad=Stupe\u0148 pr\u016fsvitnosti
+operacion_cancelada=Zru\u0161 operaci
+options.layout.paper_properties.landscaped=
+options.layout.paper_properties.paper_direction=
+options.layout.paper_properties.portrait=
+options.layout.paper_properties.title=
+options.view.default_map_overview_back_color=
+options.view.default_selection_color=
+options.view.default_view_back_color=
+options.view.invisible_new_layers=
+options.view.keep_scale_on_resizing=
+orientacion=Orientace\:
+origen_de_datos=P\u016fvod dat
+Origen_de_datos=P\u016fvod dat
+Origen_de_Datos=Vznik dat\:
+owner=Vlastn\u00edk
+paste=Paste
+paste_elements=Vlo\u017eit element
+path=Cesta
+pdf=
+pegar=Vlo\u017eit
+pegar_mapas=Vlo\u017eit mapy
+pegar_vistas=Vlo\u017eit podled
+Permite_etiquetar_los_elementos_del_mapa_con_el_valor_de_un_determinado_campo=Mo\u017en\u00ed nastavit popisek mapov\u00fdch prvk\u016f hodnotou jednotliv\u00fdch pol\u00ed
+Personalizado=U\u017eivatelsky
+personalizar_margenes=
+Pies=Stopy
+pila_de_comandos=z\u00e1sobn\u00edk p\u0159\u00edkaz\u016f
+pixeles=pixely
+pixels=pixels
+Plain=Pravideln\u00fd
+plantilla=\u0161ablona
+please_insert_new_field_name=Prosim vlo\u017ete nov\u00e9 jm\u00e9no atributu.
+png=PNG soubory
+poligono=Polygon
+polilinea=l\u00ednie
+poner_capas_a=Nastav  vrstvu jako
+por_debajo_de=pod\:
+por_encima_de=nad\:
+Por_favor_active_la_capa=
+posicion_linea=Pozice linie
+precision=P\u0159esnost
+preparar_pagina=P\u0159ipravit str\u00e1nku
+Preparar_pagina=P\u0159ipravit str\u00e1nku
+presentacion=Prezentace
+previsualizacion=Preview
+Previsualizacion=N\u00e1hled
+Previsualizacion_de_simbolo=N\u00e1hled symbol\u016f
+propiedad=Vlastnost
+propiedades=Vlastnosti
+propiedades_cajetin=
+propiedades_capa=Vlastnosti vrstvy
+propiedades_de_la_capa=Vlastnosti vrstvy
+Propiedades_escala_grafica=Vlastnosti m\u011b\u0159\u00edtka
+propiedades_grafico=Nastaven\u00ed grafiky
+propiedades_mapa=Nastaven\u00ed mapy
+propiedades_marco_imagenes=Vlastnosti obrazov\u00e9ho r\u00e1mu
+propiedades_marco_leyenda=Vlastnosti r\u00e1mu legendy
+propiedades_marco_vista=Vlastnosti r\u00e1mu pohledu
+propiedades_raster=Vlastnosti rastru
+propiedades_sesion=Vlastnosti sezen\u00ed
+propiedades_tabla=Vlastnosti tabulky
+Propiedades_texto=Vlastnosti textu
+propiedades_vista=Vlastnosti pohledu
+Proyecciones=Projekce
+ps=
+puerto=Port
+Pulgadas=Palce
+punto=Bod
+quantile_intervals=Interval kvantilu
+quiere_continuar=Chcete pokra\u010dovat?
+Quitar=Odstranit
+Quitar_capa=Odstranit vrstvu
+quitar_enlaces=Odebrat spojen\u00ed
+Quitar_todos=Odstranit v\u0161e
+quitar_uniones=odebrat spojen\u00ed
+rango_de_escalas=Rozsah m\u011b\u0159\u00edtka
+Rango_de_escalas=Velikost m\u011b\u0159\u00edtka
+realce=vylep\u0161en\u00ed
+realmente_desea_guardar=Upravdu si p\u0159ejete ulo\u017eit?
+recargar=Nahraj znovu
+recorte_colas=O\u0159ez fronty
+recorte_vista=Vy\u0159\u00edznout dle pohledu
+rectangulo=Obd\u00e9ln\u00edk
+recuento=p\u0159epo\u010det
+Recuperar_leyenda=Nahr\u00e1t legendu
+Recuperar_y_eliminar_otros_zoom=Obnovit a zru\u0161it p\u0159ibl\u00ed\u017een\u00ed
+refrescar=Obnovit
+rehacer=Znovu
+rellenar_marco_vista=Zaplnit r\u00e1m pohledu
+relleno=Zaplnit\:
+remove_elements=Odstra\u0148 element
+remove_fields=Odstra\u0148 atribut
+remove_row=Odstra\u0148 z\u00e1znam
+remove_rows=Odstra\u0148 z\u00e1znamy
+rename_field=P\u0159ejmenuj atribut
+renombrar=P\u0159ejmenovat
+reproyectar_aviso=Projekce vrstvy se neshoduje s projekc\u00ed pohledu.\nUpozorn\u011bn\u00ed\: N\u011bkter\u00e9 transformace mohou b\u00fdt nep\u0159esn\u00e9.\nPros\u00edm prostudujte dokumentaci
+reproyectar_pregunta=Chcete p\u0159ev\u00e9st projekci?
+resolucion_resultado=Rozli\u0161en\u00ed v\u00fdsledku\:
+resto_valores=Ostatn\u00ed hodnoty
+restore_palette=Obnov paletu
+rotation_field=Atribut oto\u010den\u00ed
+salir=Konec
+salir_tooltip=Konec
+salvar_raster=Ulo\u017eit jako rastr
+Sample=Vzor
+Se_superponen_a=P\u0159es
+Sean_disjuntos_a=rozpojit jako
+Sean_iguales_a=stejn\u00e9 jako
+seleccion=V\u00fdb\u011br
+seleccion_fuente=Vybrat font
+Seleccion_por_capa=V\u00fdb\u011br podle vrstvy
+selecciona_sistema_de_referencia=Vyber prostorov\u00fd referen\u010dn\u00ed syst\u00e9m
+Seleccionar=Vybrat
+seleccionar_capas=Vybrat vrstvu
+seleccionar_capas_raster=
+Seleccionar_de_las_capas_activas_los_elementos_que=Vybrat polo\u017eky z aktivn\u00edch vrstev kter\u00e9 jsou\:
+Seleccionar_del_conjunto=Vybrat ze sady
+Seleccionar_fichero=Vybrat soubor
+seleccionar_por_poligono=
+seleccionar_por_punto=Vybrat po bodech
+seleccionar_por_rectangulo=Vybrat obd\u00e9ln\u00edkem
+seleccionar_todos=Vybrat v\u0161e
+seleccione_campo_enlace=Zvolte propojovac\u00ed polo\u017eku
+seleccione_el_campo_angulo_de_la_capa_de_anotaciones=<HTML>Vyber atribut pou\u017e\u00edvan\u00fd pro ulo\u017een\u00ed \u00faklonu textov\u00e9ho popisku</HTML>
+seleccione_el_campo_color_de_la_capa_de_anotaciones=<HTML>Vyberte polo\u017eku pro ulo\u017een\u00ed barvy popisu</HTML>
+seleccione_el_campo_de_texto_que_desea_que_se_utilize_para_mostrar_la_nueva_capa_virtual=<HTML>Vyberte textov\u00e9 pole, kter\u00e9 by m\u011blo b\u00fdt pou\u017eito k zobrazen\u00ed nev\u00e9 virtu\u00e1ln\u00ed vrstvy.</HTML>
+seleccione_el_campo_fuente_de_la_capa_de_anotaciones=<HTML>Zvolte polo\u017eku pro ulo\u017een\u00ed fontu p\u00edsma.</HTML>
+seleccione_el_campo_tamano_de_la_capa_de_anotaciones=<HTML>Zvolte polo\u017eku pro ulo\u017een\u00ed velikosti popisu.</HTML>
+seleccione_fecha=Vybrat datum...
+seleccione_tabla_a_enlazar=Zvolte tabulku k propojen\u00ed
+seleccione_tabla_origen=Zvolte p\u016fvodn\u00ed tabulku spojen\u00ed
+selection_color=Vybrat barvu
+selection_up=P\u0159esu\u0148 v\u00fdb\u011br nahoru??? 
+separator=
+Servidor=Server
+Shapefile=Shapefile
+show_this_dialog_next_startup=Zobraz tento dialog p\u0159i dal\u0161\u00edm startu
+si=ano
+siempre=V\u017edy
+simbolo=Symbol
+Simbolo=Symbol
+Simbolo_unico=Jedine\u010dn\u00fd symbol
+Simbologia=Symboly
+simplificar_leyenda=Zjednodu\u0161 legendu
+simplify=Zjednodu\u0161
+sin_titulo=Nepojmenovan\u00fd
+sincronizar_color_borde_relleno=Sjednotit barvu obrysu a v\u00fdpln\u011b\:
+Size=Velikost
+sobre_la_barra=Na sloupci s m\u011b\u0159\u00edtkem
+Solo_para_capas_vectoriales=Jen pro vektory
+start_edition=Zahaj editaci
+statistics=Statistika
+stop_edition=Ukon\u010di editaci
+Style=Styl
+Subir_capa=P\u0159esunout vrstvu v\u00fd\u0161e
+suma=Sou\u010det
+Superior=Vy\u0161\u0161\u00ed
+symbol_selector=
+Tabla=Tabulka
+Tabla_de_Atributos=Tabulka atribut\u016f
+tablas=Tabulky
+Tablas=Tabulky
+tag=tag
+tamano=Velikost\:
+tamano_metros=Velikost v metrech
+tamano_pagina=Velikost str\u00e1nky
+tamano_posicion=Velikost a um\u00edst\u011bn\u00ed
+tamanyo_borde=Velikost okraje
+tamanyo_fuente=Velikost p\u00edsma
+tamanyo_pagina=Velikost str\u00e1nky
+tamPixX=Velikost pixlu X
+tamPixY=Velikost pixlu Y  
+terminar=Ukon\u010di
+terminar_edicion=Ukon\u010di editaci
+texto=Text
+this_table_is_not_self_editable=Tabulka nen\u00ed editovateln\u00e1
+tipo_dato=Datov\u00fd typ
+tipo_de_intervalo=Druh intervalu
+tipo_de_leyenda=Druh legendy
+tipo_fichero_proyecto=Soubor projektu gvSIG(*.gvsproj)
+tipo_linea=Druh obrysu\:
+tipo_relleno=V\u00fdpl\u0148\:
+tipo_simbolo=Druh symbolu\:
+tipos_de_documentos=Druhy dokument\u016f
+titulo=Spr\u00e1vce projektu
+titulo_fframetext=N\u00e1zev textov\u00e9ho pole
+to_annotation=Zm\u011b\u0148 na vrstvu popisk\u016f
+to_palette=Zm\u011b\u0148 na paletu
+tooltip_copiar_al_portapapeles=Zkop\u00edruj do schr\u00e1nky
+tooltip_cortar_al_portapapeles=P\u0159em\u00edsti do schr\u00e1nky
+tooltip_pegar_desde_el_portapapeles=Vlo\u017e ze schr\u00e1nky
+Toquen=dot\u00fdkaj\u00edc\u00ed se s
+transparencia=Pr\u016fhlednost
+Transparencia=Pr\u016fhlednost
+transparencia_pixel=Pr\u016fhlednost po pixlech
+ungroup=Odskupit
+unidades=Jednotky\:
+Unidades=Jednotky\:
+untitled=Nepojmenovan\u00fd
+url=url
+Usar_indice_espacial=Pou\u017e\u00edt prostorov\u00fd index
+usar_marco=Pou\u017e\u00edt r\u00e1mec
+usar_titulo=Pou\u017e\u00edt n\u00e1zev
+usuario=U\u017eivatel
+utilizar_margenes_impresora=Pou\u017e\u00edt okraje tisk\u00e1rny
+vacia=Pr\u00e1zdn\u00fd
+Valor=Hodnota
+Valores=Hodnoty
+Valores_unicos=Jednoduch\u00e9 hodnoty
+varianza=Odchylka
+Ventana=Okno
+ventana_proyecto=Okno projektu
+Ver=Pohled
+ver_error_capa=
+ver_tabla_atributos=Zkontrolujte tabulku atribut\u016f
+ver_tags=
+ver_tooltip=Uk\u00e1zat okno projektu
+vertical=Vertik\u00e1ln\u00ed
+vertical_space=Vertik\u00e1ln\u00ed mezera
+visible=Viditeln\u00fd
+visibles=Viditeln\u00fd
+Vista=Pohled
+vistas=Pohledy
+visualizacion=Zobrazit
+Visualizacion=Zobrazit
+visualizar_cuadricula=Zobrazit grid
+warning=Varov\u00e1n\u00ed
+xmax=maximum X
+xmin=minimum X
+Yardas=Yardy
+ymax=maximum Y
+ymin=minimum Y
+Zoom_a_la_capa=P\u0159ibli\u017e na vrstvu
+Zoom_Acercar=P\u0159ibl\u00ed\u017eit
+Zoom_Alejar=Odd\u00e1lit
+Zoom_Completo=Zobraz v\u0161e
+Zoom_Completo_Vista=Zobrazit r\u00e1m ve full extent
+zoom_in_factor=P\u0159ibl\u00ed\u017eit
+Zoom_Mas=Zoom In
+Zoom_Mas_Vista=Zoom in v r\u00e1mu pohledu
+Zoom_Menos=Odd\u00e1lit
+Zoom_Menos_Vista=Zoom out v r\u00e1mu pohledu
+zoom_out_factor=\u00darove\u0148 zv\u011bt\u0161en\u00ed
+Zoom_pixel=Zoom na rozli\u0161en\u00ed rastru
+Zoom_Previo=P\u0159edchoz\u00ed zoom
+Zoom_Real=1\:1 Zoom
+Zoom_Select=Zoom na v\u00fdb\u011br

Property changes on: tags/v2_0_0_Build_2050/applications/appgvSIG/config/text_cs.properties
___________________________________________________________________
Added: svn:keywords
   + Author Date Id Revision
Added: svn:eol-style
   + native

Index: tags/v2_0_0_Build_2050/applications/appgvSIG/config/config.xml
===================================================================
--- tags/v2_0_0_Build_2050/applications/appgvSIG/config/config.xml	(revision 0)
+++ tags/v2_0_0_Build_2050/applications/appgvSIG/config/config.xml	(revision 38653)
@@ -0,0 +1,871 @@
+<?xml version="1.0" encoding="ISO-8859-1"?>
+<plugin-config>
+  <icon src="gvsig-logo-icon" text="gvSIG"/>
+  <libraries library-dir="lib"/>
+  <resourceBundle name="text"/>
+  <label-set class-name="org.gvsig.app.project.documents.view.gui.DefaultViewPanel">
+    <label id="units" size="75"/>
+    <label id="x" size="120"/>
+    <label id="y" size="120"/>
+    <label id="4" size="110"/>
+    <label id="5" size="110"/>
+    <label id="distancearea" size="30"/>
+    <label id="projection" size="110"/>
+  </label-set>
+  
+  <popup-menus>
+    <popup-menu name="view.toc.context.menu">
+      <menu name="view-layer-add"/>
+    </popup-menu>
+  </popup-menus>
+  
+  <extensions>
+    <extension class-name="org.gvsig.app.extension.InitialWarningExtension"
+      description="Initial warning message"
+      active="true"
+      priority="1">
+    </extension>
+
+    <extension class-name="org.gvsig.app.extension.InitializeApplicationExtension"
+      description="Initialize application extension"
+      active="true"
+      priority="99999">
+    </extension>
+
+    <extension class-name="org.gvsig.app.extension.ProjectExtension"
+      description="Extensi�n encargada de gestionar los proyectos."
+      active="true"
+      priority="10">
+
+      <action 
+        name= "application-project-new"
+        label="nuevo_proyecto"
+        tooltip="_create_a_new_proyect"
+        action-command="application-project-new" 
+        icon="application-project-new"
+        position="100100000"
+        accelerator="Ctrl+N"
+        />
+      <action
+        name="application-project-open"
+        label="abrir_proyecto"
+        tooltip="_open_a_project"
+        action-command="application-project-open" 
+        icon="application-project-open"
+        position="100200000"
+        accelerator="Ctrl+O"
+        />
+      <action 
+        name="application-project-save"
+        label="guardar_proyecto"
+        tooltip="_save_the_current_project"
+        action-command="application-project-save" 
+        icon="application-project-save"
+        position="100300000"
+        accelerator="Ctrl+S"
+        />
+      <action 
+        name="application-project-saveas"
+        label="guardar_proyecto_como"
+        tooltip="_save_the_current_project_in_a_new_file"
+        action-command="application-project-save-as" 
+        icon="application-project-save-as"
+        position="100400000"
+        accelerator="Ctrl+Shift+S"
+        />
+      <action 
+        name="application-exit"
+        label="salir"
+        tooltip="_exit_of_application"
+        action-command="application-exit" 
+        icon="application-exit"
+        position="109000000"
+        accelerator="Ctrl+Q"
+        />
+
+
+      <menu text="File"
+        position="100000000"
+        is_separator="true"/>
+      <menu text="File/Export"
+        position="100900000"
+        is_separator="true"/>
+      <menu text="Edit"
+        position="200000000"
+        is_separator="true"/>
+      <menu text="Selection"
+        position="300000000"
+        is_separator="true"/>
+      <menu text="Show"
+        position="400000000"
+        is_separator="true"/>
+
+      <menu text="Layer"
+        position="600000000"
+        is_separator="true"/>
+      <menu text="Layer/Set_to"
+        position="600400000"
+        is_separator="true"/>
+
+      <menu text="View"
+        position="650000000"
+        is_separator="true"/>
+      <menu text="View/Navigation"
+        position="650100000"
+        is_separator="true"/>
+      <menu text="View/Query"
+        position="650700000"
+        is_separator="true"/>
+        
+      <menu text="tools"
+        position="900000000"
+        is_separator="true"/>
+      <menu text="tools/Development"
+        position="908500000" 
+        is_separator="true"/>
+      <menu text="tools/Development/Disposables"
+        position="908500200" 
+        is_separator="true"/>
+        
+        
+      <menu text="Window"
+        position="960000000"
+        is_separator="true"/>
+      <menu text="Help"
+        position="990000000"
+        is_separator="true"/>
+
+      <menu 
+        text="File/New_project"
+        name= "application-project-new"
+        />
+      <menu 
+        text="File/Open_project"
+        name="application-project-open"
+        />
+      <menu 
+        text="File/Save_project"
+        name="application-project-save"
+        />
+      <menu 
+        text="File/Save_project_as"
+        name="application-project-saveas"
+        />
+      <menu 
+        text="File/Exit"
+        name="application-exit"
+        />
+      <tool-bar name="project" position="1">
+        <action-tool name="application-project-new"/>
+        <action-tool name="application-project-open"/>
+        <action-tool name="application-project-save"/>
+      </tool-bar>
+    </extension>
+
+    <extension class-name="org.gvsig.app.extension.ViewProjectWindow"
+      description="Extensi�n encargada de abrir la ventana de gesti�n del proyecto."
+      active="true">
+
+      <action 
+        name="show-project-manager"
+        label="_Show_project"
+        tooltip="_Show_project_window"
+        action-command="show-project-manager" 
+        icon="show-project-manager"
+        position="400100000"
+        accelerator="Alt+P"
+        />
+
+      <menu 
+        text="Show/proyecto"
+        name="show-project-manager"
+        />
+    </extension>
+
+    <extension class-name="org.gvsig.app.extension.AddLayer"
+      description="Extensi�n encargada de abrir las diferentes capas."
+      active="true"
+      priority="20">
+      <action 
+        name="view-layer-add"
+        label="_add_layer"
+        tooltip="_Add_layer_to_view"
+        action-command="view-layer-add" 
+        icon="view-layer-add"
+        position="650300000"
+        accelerator="Alt+O"
+        />
+
+      <menu 
+        name="view-layer-add"
+        text="View/Add_layer" 
+        />
+      <tool-bar name="view" position="30010">
+        <action-tool name="view-layer-add"/>
+      </tool-bar>
+    </extension>
+
+    <extension class-name="org.gvsig.app.extension.BasicSymbologyExtension"
+      description="Enables the  symbology."
+      active="true"
+      priority="20">
+    </extension>
+
+    <extension class-name="org.gvsig.app.extension.ZoomPrev"
+      description="Extensi�n encargada de gestionar los zooms previos al actual."
+      active="true">
+      <action 
+        name="view-navigation-zoom-back"
+        label="_zoom_back"
+        tooltip="_zoom_back"
+        action-command="view-navigation-zoom-back" 
+        icon="view-navigation-zoom-back"
+        position="650100700"
+        accelerator=""
+        />
+
+      <menu 
+        name="view-navigation-zoom-back"
+        text="View/Navigation/Zoom_back"  
+        />
+      <tool-bar name="view_navigation" position ="3">
+        <action-tool name="view-navigation-zoom-back"/>
+      </tool-bar>
+    </extension>
+
+    <extension class-name="org.gvsig.app.extension.InfoToolExtension"
+      description="Extensi�n encargada de gestionar la herramienta de info."
+      active="true"
+      priority="29">
+      <action 
+        name="layer-info-by-point"
+        label="_point_information"
+        tooltip="_Show_point_information"
+        action-command="layer-info-by-point" 
+        icon="layer-info-by-point"
+        position="600200000"
+        accelerator=""
+        />
+      <menu 
+        name="layer-info-by-point"
+        text="View/Query/Information" 
+        />
+      <tool-bar name="view_tools_query" position="5">
+        <selectable-tool name="layer-info-by-point" />
+      </tool-bar>
+    </extension>
+    
+    
+    <extension class-name="org.gvsig.app.extension.MetadataPropertiesExtension"
+      description="Extensi�n encargada de mostrar los metadatos de la capa seleccionada."
+      active="true">
+    </extension>
+    
+
+    <extension class-name="org.gvsig.app.extension.ViewControls"
+      description="Extensi�n encargada de gestionar la vista."
+      active="true"
+      priority="30">
+      <combo-scale name="view-change-scale"
+        label="1:"
+        elements="1000;2000;5000;10000;25000;50000;100000;200000;500000;1000000;2000000;5000000"
+          value="10000"
+          action-command="view-change-scale" />
+         
+      <action 
+        name="view-change-scale"
+        label="_Change_scale" 
+        action-command="view-change-scale" 
+        />
+
+      <action 
+        name="view-navigation-zoom-in-topoint"
+        label="_Zoom_in_to_point" 
+        position="650100400" 
+        action-command="view-navigation-zoom-in-topoint" 
+        icon="view-navigation-zoom-in-topoint"
+        tooltip="_Zoom_in_to_point"
+        accelerator=""
+        />
+      <action 
+        name="view-navigation-zoom-out-topoint"
+        label="_Zoom_out_to_point" 
+        position="650100500" 
+        action-command="view-navigation-zoom-out-topoint" 
+        icon="view-navigation-zoom-out-topoint"
+        tooltip="_Zoom_out_to_point"
+        accelerator=""
+        />
+      <action 
+        name="view-navigation-zoom-all"
+        label="_Zoom_all" 
+        position="650100800" 
+        action-command="view-navigation-zoom-all" 
+        icon="view-navigation-zoom-all"
+        tooltip="_Zoom_all" 
+        accelerator=""
+        />
+      <action 
+        name="view-navigation-zoom-in-center"
+        label="_Zoom_in_center" 
+        position="650100200" 
+        action-command="view-navigation-zoom-in-center" 
+        tooltip="_Zoom_in_center" 
+        icon="view-navigation-zoom-in-center"
+        accelerator=""
+        />
+      <action 
+        name="view-navigation-zoom-out-center"
+        label="_Zoom_out_center" 
+        position="650100300" 
+        action-command="view-navigation-zoom-out-center" 
+        tooltip="_Zoom_out_center" 
+        icon="view-navigation-zoom-out-center"
+        accelerator=""
+        />
+      <action 
+        name="view-navigation-pan"
+        label="_Move_the_map" 
+        position="650100100" 
+        action-command="view-navigation-pan" 
+        icon="view-navigation-pan"
+        tooltip="_Move_the_map"
+        accelerator=""
+        />
+      <action 
+        name="view-navigation-frame-manager"
+        label="_Frame_manager" 
+        position="650109000" 
+        action-command="view-navigation-frame-manager" 
+        icon="view-navigation-frame-manager"
+        tooltip="_Show_frame_manager"
+        accelerator=""
+        />
+
+      
+      <action 
+        name="layer-set-visible"
+        label="_Show_layers" 
+        position="600400100" 
+        action-command="layer-set-visible"
+        icon="layer-set-visible"
+        tooltip="_Show_layers"
+        accelerator=""
+        />
+      <action 
+        name="layer-set-hide"
+        label="_Hide_layers" 
+        position="600400200"
+        action-command="layer-set-hide"
+        icon="layer-set-hide"
+        tooltip="_Hide_layers"
+        accelerator=""
+        />
+      <action 
+        name="layer-set-active"
+        label="_Set_Layers_active" 
+        position="600400300"
+        action-command="layer-set-active"
+        icon="layer-set-active"
+        tooltip="_Set_Layers_active"
+        accelerator=""
+        />
+      <action 
+        name="layer-set-inactive"
+        label="_Set_Layers_inactive" 
+        position="600400400" 
+        action-command="layer-set-inactive"
+        icon="layer-set-inactive"
+        tooltip="_Set_Layers_inactive"
+        accelerator=""
+        />
+
+      <action 
+        name="view-locator-setup"
+        label="_Locator_setup" 
+        position="658000000" 
+        action-command="view-locator-setup"
+        icon="view-locator-setup"
+        tooltip="_Locator_setup"
+        accelerator=""
+        />
+
+      <menu 
+        name="view-navigation-zoom-in-topoint"
+        text="View/Navigation/Zoom_in" 
+        />
+      <menu 
+        name="view-navigation-zoom-out-topoint"
+        text="View/Navigation/Zoom_out" 
+        />
+      <menu 
+        name="view-navigation-zoom-all"
+        text="View/Navigation/Zoom_all" 
+        />
+      <menu 
+        name="view-navigation-zoom-in-center"
+        text="View/Navigation/Zoom_in_to_center" 
+        />
+      <menu 
+        name="view-navigation-zoom-out-center"
+        text="View/Navigation/Zoom_out_to_center" 
+        />
+      <menu 
+        name="view-navigation-pan"
+        text="View/Navigation/Pan" 
+        />
+      <menu 
+        name="view-navigation-frame-manager"
+        text="View/Navigation/Frame_manager" 
+        />
+
+      
+      <menu 
+        name="layer-set-visible"
+        text="Layer/Set_to/visible" 
+        />
+      <menu 
+        name="layer-set-hide"
+        text="Layer/Set_to/Hidden" 
+        />
+      <menu 
+        name="layer-set-active"
+        text="Layer/Set_to/Active" 
+        />
+      <menu 
+        name="layer-set-inactive"
+        text="Layer/Set_to/Inactive" 
+        />
+
+      <menu 
+        name="view-locator-setup"
+        text="View/Locator_setup" 
+        />
+      
+      
+      <tool-bar name="view_navigation" position="3">
+        <selectable-tool name="view-navigation-zoom-in-topoint" is-default="true" />
+        <selectable-tool name="view-navigation-zoom-out-topoint" />
+        <action-tool name="view-navigation-zoom-all"  />
+        <action-tool name="view-navigation-zoom-in-center"  />
+        <action-tool name="view-navigation-zoom-out-center"  />
+      </tool-bar>
+      
+      <tool-bar name="view_navigation" position ="4">
+        <selectable-tool name="view-navigation-pan"/>
+        <action-tool name="view-navigation-frame-manager" />
+      </tool-bar>
+
+    </extension>
+
+    <extension class-name="org.gvsig.app.extension.MeasureExtension"
+      description="Extensi�n encargada de gestionar las operaciones de medir sobre la vista."
+      active="true"
+      priority="30">
+      <action 
+        name="view-query-distance"
+        label="_Query_distance" 
+        position="650700200" 
+        action-command="view-query-distance" 
+        icon="view-query-distance"
+        tooltip="_Query_distance" 
+        accelerator=""
+        />
+      <action 
+        name="view-query-area"
+        label="_Query_area" 
+        position="650700100" 
+        action-command="view-query-area" 
+        icon="view-query-area"
+        tooltip="_Query_area"
+        accelerator=""
+        />
+
+
+      <menu 
+        name="view-query-distance"
+        text="View/Query/Distance" 
+        />
+      <menu 
+        name="view-query-area"
+        text="View/Query/Area" 
+        />
+
+      <tool-bar name="view_tools_query" position="5">
+        <selectable-tool name="view-query-distance" />
+        <selectable-tool name="view-query-area" />
+      </tool-bar>
+
+    </extension>
+
+    <extension class-name="org.gvsig.app.extension.ViewSelectionControls"
+      description="Extensi�n encargada de gestionar la vista."
+      active="true"
+      priority="30">
+      <action 
+        name="selection-simple-select-view"
+        label="_Simple_select" 
+        position="300700000" 
+        action-command="selection-simple-select" 
+        icon="selection-simple-select"
+        tooltip="_Simple_select" 
+        accelerator=""
+        />
+      <action 
+        name="selection-select-by-rectangle-view"
+        label="_Select_by_rectangle" 
+        position="301200000" 
+        action-command="selection-select-by-rectangle-view" 
+        icon="selection-select-by-rectangle"
+        tooltip="_Select_by_rectangle" 
+        accelerator=""
+        />
+      <action
+        name="selection-select-by-polygon"
+        label="_Select_by_polygon" 
+        position="301300000" 
+        action-command="selection-select-by-polygon" 
+        icon="selection-select-by-polygon"
+        tooltip="_Select_by_polygon" 
+        accelerator=""
+        />
+
+
+      <menu 
+        name="selection-simple-select-view"
+        text="Selection/Simple" 
+        />
+      <menu 
+        name="selection-select-by-rectangle-view"
+        text="Selection/Select_by_rectangle" 
+        />
+      <menu 
+        name="selection-select-by-polygon"
+        text="Selection/Select_by_polygon" 
+        />
+
+      <tool-bar name="view_selection" position="6">
+        <selectable-tool name="selection-simple-select-view" />
+        <selectable-tool name="selection-select-by-rectangle-view" />
+        <selectable-tool name="selection-select-by-polygon" />
+      </tool-bar>
+
+    </extension>
+    
+    <extension class-name="org.gvsig.app.extension.ViewSelectionByTheme"
+      description="Extensi�n encargada de la selecci�n por tema."
+      active="true"
+      priority="30">
+      <action 
+        name="selection-select-by-layer"
+        position="301100000"
+        label="_Select_by_layer" 
+        action-command="selection-select-by-layer"
+        icon="selection-select-by-layer"
+        tooltip="_Select_by_layer" 
+        accelerator=""
+        />
+
+      <menu 
+        name="selection-select-by-layer"
+        text="Selection/Select_by_layer" 
+        />
+    </extension>
+        
+    <extension class-name="org.gvsig.app.extension.ViewInvertSelection"
+      description="Extensi�n encargada de hacer la selecci�n inversa."
+      active="true"
+      priority="30">
+      <action 
+        name="selection-reverse-view"
+        label="_Reverse_selection" 
+        position="300500000" 
+        action-command="selection-reverse-view" 
+        icon="selection-reverse"
+        tooltip="_Reverse_selection" 
+        accelerator=""
+        />
+
+      <menu 
+        name="selection-reverse-view"
+        text="Selection/Reverse" 
+        />
+
+      <tool-bar name="view_selection" position="6">
+          <action-tool name="selection-reverse-view" />
+      </tool-bar>
+
+    </extension>
+        
+    <extension class-name="org.gvsig.app.extension.ViewPropertiesExtension"
+      description="Extensi�n encargada de gestionar el di�logo de propiedades de la vista."
+      active="true">
+      <action 
+        name="view-properties"
+        label="_View_properties" 
+        position="659000000" 
+        action-command="view-properties"
+        icon="view-properties"
+        tooltip="_Show_view_properties" 
+        accelerator=""
+        />
+
+
+      <menu 
+        name="view-properties"
+        text="View/Properties" 
+        />
+
+    </extension>
+
+    <extension class-name="org.gvsig.app.extension.ZoomToSelectExtension"
+      description="Extensi�n encargada de gestionar los eventos realizados sobre una capa."
+      active="true">
+
+      <action 
+        name="view-navigation-zoom-to-selection"
+        label="_Zoom_to_selection" 
+        position="650100900" 
+        action-command="view-navigation-zoom-to-selection" 
+        icon="view-navigation-zoom-to-selection"
+        tooltip="_Zoom_to_selection" 
+        accelerator=""
+        />
+
+      <menu 
+        name="view-navigation-zoom-to-selection"
+        text="View/Navigation/Zoom_to_selection" 
+        />
+
+      <tool-bar name="view_navigation" position="3">
+        <action-tool name="view-navigation-zoom-to-selection" />
+      </tool-bar>
+
+    </extension>
+
+    <extension class-name="org.gvsig.app.extension.ClearSelectionExtension"
+      description="Extensi�n encargada de limpiar la selecci�n."
+      active="true">
+
+      <action 
+        name="selection-clear-view"
+        label="_Clear_selection" 
+        position="300300000" 
+        action-command="selection-clear-view" 
+        icon="edit-clear"
+        tooltip="_Clear_selection" 
+        accelerator=""
+        />
+
+      <menu 
+        name="selection-clear-view"
+        text="Selection/clear" 
+        />
+
+      <tool-bar name="view_selection" position="6">
+        <action-tool name="selection-clear-view" />
+      </tool-bar>
+
+    </extension>
+
+    <extension class-name="org.gvsig.app.extension.FiltroExtension"
+      description="Extensi�n encargada de abrir el di�logo para filtrar una vista."
+      active="true">
+
+      <action 
+        name="layer-filter"
+        label="_Filter_layer" 
+        position="600100000" 
+        icon="layer-filter" 
+        tooltip="_Filter_layer" 
+        action-command="layer-filter"
+        accelerator=""
+        />
+
+      <menu 
+        name="layer-filter"
+        text="Layer/Filter" 
+        />
+
+      <tool-bar name="layer_tools" position="12">
+        <action-tool name="layer-filter" />
+      </tool-bar>
+
+    </extension>
+
+    <extension class-name="org.gvsig.app.extension.dispose.DisposableManagementExtension"
+      description="Extensi�n con informaci�n sobre disposables."
+      active="true"
+      priority="1000">
+
+      <action 
+        name="tools-devel-disposables-show-pendings"
+        label="_Show_pendings_disposables" 
+        position="908500200"  
+        tooltip="_Show_pendings_disposables" 
+        action-command="tools-devel-disposables-show-pendings"
+        icon="tools-devel-disposables-show-pendings"
+        accelerator=""
+        />
+      <action 
+        name="tools-devel-disposables-free-all"
+        label="_Free_all_disposables" 
+        position="908500201" 
+        action-command="tools-devel-disposables-free-all"
+        icon="tools-devel-disposables-free-all"
+        tooltip="_Free_all_disposables" 
+        accelerator=""
+        />
+
+      <menu 
+        name="tools-devel-disposables-show-pendings"
+        text="tools/Development/Disposables/Show_pendings" 
+        />
+      <menu 
+        name="tools-devel-disposables-free-all"
+        text="tools/Development/Disposables/Free_all" 
+        />
+
+    </extension>
+
+    <extension class-name="org.gvsig.app.extension.ShowDevelInfoExtension"
+      description="Presenta informacion relevante para debug."
+      active="true"
+      priority="30">
+      <action 
+        name="tools-devel-show-persistencefactories"
+        label="_Show_persistence_factories" 
+        tooltip="_Show_persistence_factories" 
+        position="908500400" 
+        action-command="tools-devel-show-persistencefactories"
+        icon="tools-devel-show-persistencefactories"
+        accelerator=""
+        />
+      <action 
+        name="tools-devel-show-icontheme"
+        label="_Show_icon_theme_information" 
+        tooltip="_Show_icon_theme_information" 
+        position="908500300" 
+        action-command="tools-devel-show-icontheme"
+        icon="tools-devel-show-icontheme"
+        accelerator=""
+        />
+      <action 
+        name="tools-devel-show-actions"
+        label="_Show_actions_information" 
+        tooltip="_Show_actions_information" 
+        position="908500100" 
+        action-command="tools-devel-show-actions"
+        icon="tools-devel-show-actions"
+        accelerator=""
+        />
+      <action 
+        name="tools-devel-show-menus"
+        label="_Show_menu_information" 
+        tooltip="_Show_menu_information" 
+        position="908500200" 
+        action-command="tools-devel-show-menus"
+        icon="tools-devel-show-menus"
+        accelerator=""
+        />
+      <action 
+        name="tools-devel-show-menus-by-plugin"
+        label="_Show_menu_by_plugin_information" 
+        tooltip="_Show_menu_ordered_by_plugin_information" 
+        position="908500300" 
+        action-command="tools-devel-show-menus-by-plugin"
+        icon="tools-devel-show-menus-by-plugin"
+        accelerator=""
+        />
+      <menu 
+        name="tools-devel-show-persistencefactories"
+        text="tools/Development/Show persistence factories" 
+        />
+      <menu 
+        name="tools-devel-show-icontheme"
+        text="tools/Development/Show icon theme information" 
+        />
+      <menu 
+        name="tools-devel-show-actions"
+        text="tools/Development/Show actions information" 
+        />
+      <menu 
+        name="tools-devel-show-menus"
+        text="tools/Development/Show menu information" 
+        />
+      <menu 
+        name="tools-devel-show-menus-by-plugin"
+        text="tools/Development/Show menu by plugin information" 
+        />
+
+    </extension>
+
+
+    <extension class-name="org.gvsig.app.extension.PaletteViewInfoExtension"
+      description="Extensi�n encargada transformar la ventana activa en palette."
+      active="true">
+
+      <action 
+        name="window-convert-to-tool"
+        label="_Convert_to_tool" 
+        tooltip="_Convert_regular_window_to_tool_window" 
+        position="960300000" 
+        action-command="window-convert-to-tool"
+        icon="window-convert-to-tool"
+        accelerator=""
+        />
+
+      <menu 
+        name="window-convert-to-tool"
+        text="Window/Convert_to_tool" 
+        />
+
+    </extension>
+
+    <extension class-name="org.gvsig.app.extension.RestoreViewInfoExtension"
+      description="Extensi�n encargada transformar la ventana palette en su original."
+      active="true">
+
+      <action
+        name="window-restore-from-tool"
+        label="_Restore_tool" 
+        tooltip="_Restore_tool_window_to_regular_window" 
+        position="960400000" 
+        action-command="window-restore-from-tool"
+        icon="window-restore-from-tool"
+        accelerator=""
+        />
+
+
+      <menu 
+        name="window-restore-from-tool"
+        text="Windows/Restore_from_tool" 
+        />
+
+    </extension>
+
+    <extension class-name="org.gvsig.app.extension.About"
+      description="Extensi�n encargada de abrir una ventana con la informaci�n relativa al programa."
+      active="true"
+      priority="90090">
+
+      <action
+        name="help-about"
+        label="_About" 
+        tooltip="_Show_about" 
+        position="999000000" 
+        action-command="help-about"
+        icon="help-about"
+        accelerator=""
+        />
+
+      <menu 
+        name="help-about"
+        text="Help/About" 
+        />
+
+    </extension>
+
+  </extensions>
+
+</plugin-config>

Property changes on: tags/v2_0_0_Build_2050/applications/appgvSIG/config/config.xml
___________________________________________________________________
Added: svn:keywords
   + Author Date Id Revision
Added: svn:eol-style
   + native

Index: tags/v2_0_0_Build_2050/applications/appgvSIG/config/text_fr.properties
===================================================================
--- tags/v2_0_0_Build_2050/applications/appgvSIG/config/text_fr.properties	(revision 0)
+++ tags/v2_0_0_Build_2050/applications/appgvSIG/config/text_fr.properties	(revision 38653)
@@ -0,0 +1,706 @@
+#Translations for language [fr]
+#Mon Oct 30 09:38:21 CET 2006
+(escala_maxima)=(\u00e9chelle maximum)
+(escala_minima)=(\u00e9chelle maximum)
+1\:=
+_(Simbolo_unico)=(Symbole unique)
+__proyeccion_actual=Projection actuelle\:
+__redimensionar_texto_escala=Redimensionner le texte suivant l'\u00e9chelle de la vue
+__seleccion_de_fuente=S\u00e9lection d'une fonte
+A0=A0
+A1=A1
+A2=A2
+A3=A3
+A4=A4
+abajo=Descendre
+abrir=Ouvrir
+abrir_plantilla=Ouvrir police
+abrir_proyecto=Ouvrir un projet
+abrir_tooltip=Ouvrir un projet existant
+Abrir_una_capa=Ouvrir une couche
+Accion_Predefinida=Action pr\u00e9d\u00e9finie
+aceptar=Accepter
+Aceptar=Accepter
+acerca_de=A propos de...
+activar=Activate
+activar_regla=Afficher la r\u00e8gle
+activos=Toutes actives
+add_delete_edit_fields=
+add_layer=Ajouter une couche
+add_rows=
+adjust_transparency=Ajuster la transparence
+agrupacion=
+agrupar=Grouper
+agrupar_capas=Grouper les couches
+agrupar_graficos=Grouper les graphiques
+agrupar_linea=Grouper les lignes graphiques
+Ajustar_transparencia=Ajuster la transparence
+ajustes_linea_grafica=Ajuster la ligne graphique
+Al_leer_la_leyenda=A la lecture de la l\u00e9gende
+alias=Alias
+align_center=
+align_down=
+align_left=
+align_right=
+align_to_layout_center=
+align_to_layout_down=
+align_to_layout_left=
+align_to_layout_right=
+align_to_layout_up=
+align_to_layout_vertical_center=
+align_up=
+align_vertical_center=
+alineamiento=Alignement
+alinear=Aligner
+alinear_graficos=Aligner les graphiques
+alta=Hauteur
+alto=Hauteur
+altura=Hauteur
+Altura_fija_de_texto=Fixe la hauteur du texte
+ambito=Cadre
+Anadir=Ajouter
+Anadir_al_conjunto=Ajouter \u00e0 la s\u00e9lection
+Anadir_capa=Ajouter une couche g\u00e9ographique
+Anadir_Capa=Ajouter une couche g\u00e9ographique
+anadir_tag=
+Anadir_todos=Tout ajouter
+ancho=Largeur
+ancho_alto=Largeur X hauteur
+anchura=Largeur\:
+Aplicar=Appliquer
+Archivo=Fichier
+arriba=Monter
+ascending_order=Ordre ascendant
+ascending_order_tooltip=Classe le champs s\u00e9lectionn\u00e9 par ordre ascendant
+Atributo=Attribut
+automatico=Automatique
+Ayuda=Aide
+back=Pr\u00e9c\u00e9dent
+background_color=Colour d'arri\u00e8re plan
+baja=Basse
+Bajar_capa=Descendre la couche
+bandas=Bandes
+barra=Barre
+base=Base
+base_datos=Base de donn\u00e9es
+bmp=Fichiers BMP
+Bold=Gras
+borra_seleccion=Effacer une s\u00e9lection
+borrador=Brouillon
+borrar=Supprimer
+box=rectangle
+brillo=Luminosit\u00e9
+brillo_y_contraste=Luminosit\u00e9 et contrate
+browse=
+cajetin=
+Calcular_intervalos=Calculer les intervalles
+calidad=Qualit\u00e9
+cambiar_el_alto_de_los_elementos_seleccionados_hasta_coincidir_con_el_mas_alto=
+cambiar_el_ancho_de_los_elementos_seleccionados_hasta_coincidir_con_el_mas_ancho=
+cambiar_el_tamano_de_los_elementos_seleccionados_hasta_coincidir_con_el_mas_grande=
+Cambio_Color=Changer la couleur
+cambio_nombre=Changement de nom
+campo=Champ
+Campo=Champ
+campo_altura_texto=Taille du champ textuel\:
+Campo_de_clasificacion=Champ de classification
+Campo_de_etiquetado=Etiqueter \u00e0 partir d'un champ
+Campos=Champs
+cancel=Annuler
+Cancel=Annuler
+cancelar=Annuler
+Cancelar=Annuler
+Capa=Couche
+Capas=Couches g\u00e9ographiques
+Capas_del_localizador=Couches de localisation
+Centimetros=Centim\u00e8tres
+cerrar=Fermer
+Cerrar=Fermer
+change=
+change_before=
+change_behind=
+change_height=
+change_width=
+circulo=Cercle
+clave=Clef
+close=Fermer
+coincidir_tamanyo=
+colocar_a_margenes=Positionner par rapport aux marges.
+colocar_alrededor_seleccionados=Positionner autour des graphiques s\u00e9lectionn\u00e9s.
+colocar_alrededor_todos=Positionner autour de tous les graphiques.
+colocar_delante=Avant
+colocar_detras=Apr\u00e8s
+color=Couleur \:
+Color_final=Couleur d'arriv\u00e9e
+Color_inicio=Couleur de d\u00e9part
+color_texto=Couleur du texte\:
+comentarios=Commentaires
+comenzar_edicion=
+compleja=
+configurar=Configurer
+configurar_localizador=Configurer la vue d'ensemble
+Configurar_localizador=Configurer la vue d'ensemble...
+confirmar_borrar=Confirmer la suppression ?
+conflicto_de_nombres_de_mapas_al_pegar=
+conflicto_de_nombres_de_tablas_al_pegar=
+conflicto_de_nombres_de_vistas_al_pegar=
+conflito_de_nombres_de_tablas_al_pegar=
+conservar_escala_visualizacion=Conserver l'\u00e9chelle de la vue
+consulta=Requ\u00eate
+Contengan=Contiennent
+contraste=Contraste
+coor_geograficas=Coordonn\u00e9es g\u00e9ographiques
+copiar=
+copy=Copier
+cortar=
+creation_date=Date de cr\u00e9ation
+Crucen_con=Croisent avec
+cuando_activo=Quand active
+cut=Couper
+Dado_un_campo_de_atributos=Champs d'attributs donn\u00e9
+debera_introducir_nombres_para_las_vistas_a_pegar=
+debera_introducir_nombres_para_los_mapas_a_pegar=
+default_projection=
+default_value=
+dehacer=d\u00e9faire
+delete_field=Supprimer une colonne
+Derecha=Droite
+Derecho=Droit
+desagrupar=Dissocier
+desagrupar_capas=
+desagrupar_graficos=Dissocier les graphiques
+descending_order=Ordre descendant
+descending_order_tooltip=Classe le champs s\u00e9lectionn\u00e9 par ordre descendant
+descripcion_de_configuracion_capa_de_anotaciones=
+descripcion_de_crear_capa_de_anotaciones=
+desde_arriba=Depuis le haut\:
+desde_izquierda=Depuis la gauche\:
+desea_borrar_el_documento=
+desea_borrar_la_capa=
+desea_continuar=
+deshacer=d\u00e9faire
+desplaza_los_elementos_seleccionados_a_la_derecha=
+desplaza_los_elementos_seleccionados_a_la_izquierda=
+desplaza_los_elementos_seleccionados_al_centro_por_el_eje_x=
+desplaza_los_elementos_seleccionados_al_centro_por_el_eje_y=
+desplaza_los_elementos_seleccionados_hacia_abajo=
+desplaza_los_elementos_seleccionados_hacia_arriba=
+Desplazamiento=D\u00e9placer
+desviacion_tipica=Ecart type
+distance_units=Unit\u00e9s de distance
+distribuir=Distribuer \:
+distribuir_elementos_sobre_todo_el_layout=
+distributes_down=
+distributes_horizontal=
+distributes_left=
+distributes_right=
+distributes_to_layout_down=
+distributes_to_layout_horizontal=
+distributes_to_layout_left=Distribuye izquierda del layout
+distributes_to_layout_right=
+distributes_to_layout_up=
+distributes_to_layout_vertical=
+distributes_up=
+distributes_vertical=
+distribuye_el_espacio_entre_los_elementos_en_horizontal=
+distribuye_el_espacio_entre_los_elementos_en_vertical=
+distribuye_los_elementos_seleccionados_de_forma_equidistante_de_abajo_hacia_arriba=
+distribuye_los_elementos_seleccionados_de_forma_equidistante_de_arriba_hacia_abajo=
+distribuye_los_elementos_seleccionados_de_forma_equidistante_de_derecha_a_izquierda=
+distribuye_los_elementos_seleccionados_de_forma_equidistante_de_izquierda_a_derecha=
+distribuye_los_elementos_seleccionados_de_forma_equidistante_y_horizontal=
+distribuye_los_elementos_seleccionados_de_forma_equidistante_y_vertical=
+divisiones_izquierda=Divisions \u00e0 partir de la gauche
+documento=
+documentos_existentes=Documents existants
+draw_text_only=
+driver=Driver
+Dxffiles=Fichiers DXF
+edicion=\u00e9dition
+editable=
+Editar_leyenda=Editer la l\u00e9gende
+editar_vertices=\u00e9diter les sommets
+el_numero_maximo_de_intervalos_para_este_campo_es=Le nombre maximum d'intervalles pour ce champ est
+Elegir_Color=Selectionner la couleur
+Elegir_Fuente=Choisir la fonte
+elemento_ya_existe=
+Elementos_seleccionados_de_la_capa=Entit\u00e9s s\u00e9lectionn\u00e9es de la couches
+Eliminar=Supprimer
+eliminar_capa=Supprimer une couche
+eliminar_columna=
+eliminar_extremos=Eliminer les extr\u00eames
+eliminar_fila=
+en_el_mapa=Dans la carte\:
+En_metros=En m\u00e8tres
+En_pixels=En pixels
+en_unidades=
+Encuadre=Zooms
+Encuadre_Vista=D\u00e9placer
+enlace_vivo=Lien dynamique
+Enlazar_a_fichero_de_texto=Lier \u00e0 un fichier texte
+Enlazar_a_ficheros_de_imagen=Lier \u00e0 un fichier image
+equal_intervals=Intervalles \u00e9gaux
+Error_exportando_SLD=
+Error_guardando_la_leyenda=Erreur en sauvegardant la l\u00e9gende
+Error_guardando_la_plantilla=
+escala=Echelle
+Escala=Echelle
+escala_desconocida=
+escala_maxima=Echelle maximum
+Escala_Maxima=Echelle maximum
+escala_minima=echelle minimum
+Escala_Minima=Echelle minimum
+escala_usuario=Echelle d\u00e9finie par l'utilisateur
+espaciado_horizontal=Pas horizontal de la grille
+espaciado_vertical=Pas vertical de la grille
+espacio=Espace\:
+estadisticas=Statistiques
+este_por_debajo_de_=Soit en dessous de
+este_por_encima_de=Soit au dessus de
+Esten_contenidos_en=Sont contenus dans
+Etiqueta=Etiquette
+Etiquetados=Etiquettages
+etiquetas=Etiquettes\:
+Etiquetas_estandar=Etiquettes standard
+Examinar=Parcourir
+export=Exporter
+exportar=Exporter
+exportar_pdf=Exporter en pdf
+exportar_ps=Exportar a ps
+extension=Extension
+Extent=Extension
+extents_no_coincidentes=Les dimmensions de l'image selectionn\u00e9e ne co\u00efncident pas avec celles de l'image d'origine.
+factor_zoom_incorrecto=
+fallo_capas=Erreurs d'acc\u00e8s aux couches. Les couches suivantes seront supprim\u00e9es du projet.
+family=
+fichero=
+Fichero=Fichier
+fichero_existe=Le fichier selectionn\u00e9 existe d\u00e9j\u00e0
+fichero_incorrecto=Fichier incorrect
+fichero_ya_existe_seguro_desea_guardarlo=
+field_already_exists=
+field_decimal_count=
+field_default_value=
+field_length=
+field_manager=
+field_name=
+field_type=
+filtro=Filtre
+finish=Finaliser
+Font=Fonte
+formato=Format
+Formato_de_numero_erroneo=
+formato_incorrecto=Format incorrect
+fuente=Fonte
+General=G\u00e9n\u00e9ral
+georeferenciado=
+gestion_encuadre=Gestionnaire de positionnement
+grados=Degr\u00e9es\:
+Grados=Degr\u00e9es
+Graficos=Graphiques
+grosor_linea=Largeur de la ligne
+group=Grouper
+group_graphic_line=
+grupo=
+guardado=Enregister sous
+guardar=Enregistrer
+Guardar=Enregistrer
+guardar_cambios=Enregistrer les changements ?
+guardar_como=Enregistrer comme...
+guardar_como_plantilla=Garder comme police
+Guardar_el_zoom_actual=Enregistrer le zoom actif
+Guardar_leyenda=Enregistrer une l\u00e9gende
+guardar_proyecto=Enregistrer un projet
+guardar_tooltip=Enregistrer le projet
+Habilitar_etiquetado=Etiqueter
+Hiperenlace=Hyperlien
+horizontal=Horizontal
+horizontal_space=
+Identificar_Resultados=Identifier les r\u00e9sultats
+Igual_que_la_impresora=Identique que l'impression
+igual_todos_lados=Equal displacement for all sides.
+imagen=Image
+Implimir=
+importar=Importer
+Imprimir=Imprimer
+Indexando=Indexation...
+Indexando_espacialmente=Indexation spatiale de la couche g\u00e9ographique
+indexar_campos=
+Inferior=Inf\u00e9rieur
+info=Information
+informacion=Propri\u00e9t\u00e9s de l'entit\u00e9 cliqu\u00e9e
+Informacion=
+Inicializando=Initialisation
+initial_warning=
+insert_row=Ins\u00e9rer une ligne
+Insertar=Ins\u00e9rer
+insertar_cajetin=insertar cajetin
+insertar_circulo=Ins\u00e9rer un cercle
+insertar_columna=
+insertar_escala=Ins\u00e9rer une \u00e9chelle
+insertar_fila=
+insertar_imagen=Ins\u00e9rer une image
+insertar_leyenda=Ins\u00e9rer une l\u00e9gende
+insertar_linea=Ins\u00e9rer une ligne
+insertar_norte=Ins\u00e9rer  nord
+insertar_poligono=Ins\u00e9rer un polygone
+insertar_polilinea=Ins\u00e9rer une polyligne
+insertar_punto=Ins\u00e9rer un point
+insertar_rectangulo=Ins\u00e9rer un rectangle
+insertar_texto=Ins\u00e9rer du texte
+insertar_vista=Ins\u00e9rer une vue
+Intersecten_con=S\u2019intersectent avec
+Intervalo=Intervalle
+Intervalos=Intervalles
+introduce_nombre=Nouveau type
+introduzca_el_nombre_de_la_nueva_capa_de_anotaciones=
+introduzca_nuevo_nombre_para_la_vista=
+invalid_value_for_gap=
+invert_selection=
+Italic=Italique
+Izquierda=Gauche
+Izquierdo=Gauche
+join=Joindre
+jpg=Fichiers JPEG
+kilometros=Kilom\u00e8tres
+Kilometros=Kilom\u00e8tres
+leyenda=L\u00e9gende
+Leyenda=L\u00e9gende
+leyenda_campo_unido=Un champs d'une table en jointure est utilis\u00e9  dans la l\u00e9gende (et /ou l'\u00e9tiquetage). Changez la l\u00e9gende avant d'enlever la jointure svp.
+Leyenda_Por_Defecto=L\u00e9gende par d\u00e9faut
+linea=Ligne
+linea_grafica=Ligne graphique
+lineal_directo=Lin\u00e9aire direct
+link=Lien
+Link=Lien
+localizador=Localisateur
+locked_element=
+locked_element_it_cannot_be_deleted=
+locked_element_it_cannot_be_renamed=
+m/pixel=metros/pixel
+malla_activada=Activer la grille
+manage_fields=
+mantener_intervalo=Maintenir l'intervalle
+map_units=Unit\u00e9s de la carte
+mapa=carte
+Mapa=Carte
+mapas=Mises en page
+marco=Cadre
+marco_vista=Espace de travail de la vue
+margenes=Marges\:
+mas_de_100_simbolos=Plus de 100  symboles n'apportent plus d'information dans un plan
+max_length_is=
+maximo=Maximum
+MDIFrame.quiere_salir=Voulez-vous vraiment quitter gvSIG?
+MDIFrame.salir=Quitter
+media=Moyenne
+medir_area=Mesurer une surface
+medir_distancias=Mesurer les distances
+metadatos=Metadatos
+metros=M\u00e8tres
+Metros=M\u00e8tres
+Milimetros=Millim\u00e8tres
+Millas=Miles
+minimo=Minimum
+modificar=
+modification_date=Date de modification
+mostrar_escala_numerica=
+Mostrar_siempre=Tout afficher
+mostrar_unidades=Montrer unit\u00e9s
+move_elements=
+Muestra_atributos=Afficher les attributs de la couche s\u00e9lectionn\u00e9e.
+muestra_los_elementos_de_la_capa_usando_un_simbolo_por_cada_valor_unico=Afficher les \u00e9l\u00e9ments de la couche en utilisant un symbole pour chaque valeur unique
+Muestra_los_elementos_de_la_capa_usando_una_gama_de_colores_en_funcion_del_valor_de_un_determinado_campo_de_atributos=Afficher les \u00e9l\u00e9ments de la couche en utilisant une gamme de couleurs en fonction de la valeur d'un champs d'attributs d\u00e9termin\u00e9
+Muestra_todos_los_elementos_de_una_capa_usando_el_mismo_simbolo=Afficher tous les \u00e9l\u00e9ments d'une couche en utilisant le m\u00eame symbole
+natural_intervals=Intervalles naturels
+navegacion=Navigation
+navegacion_vista=Navigation vue
+necesita_una_capa_activa=N\u00e9cessite une couche g\u00e9ographique active
+necesita_una_capa_vectorial_activa=N\u00e9cessite une couche g\u00e9ographique vectorielle active
+new_field=Nouvelle colonne
+new_field_properties=
+next=Suivant
+ninguna_impresora_configurada=Aucune imprimante configur\u00e9e
+Nivel_de_transparencia=Niveau de transparence
+no=Non
+no_activos=Toutes inactives
+No_de_intervalos=Nombre d'intervalles
+no_es_posible_aplicar_leyenda_vacia=
+No_ha_sido_posible_realizar_la_operacion=
+No_mostrar=Ne pas afficher la couche lorsque l'\u00e9chelle est
+No_mostrar_la_capa_cuando_la_escala=Ne pas afficher la couche lorsque l'\u00e9chelle
+no_se_pegaran_las_tablas=
+no_se_pegaran_las_vistas_del_conflicto=
+No_se_pudo_obtener_la_tabla_de_la_capa=Impossible d'obtenir la table de la couche g\u00e9ographiqueS
+no_visibles=Toutes invisibles
+nombre=Nom
+Nombre=Nom
+nombre_no_valido=
+Nombre_que_se_le_dara_al_zoom=Nom pour le zoom
+nombre_sesion=Nom du projet
+none=
+none_selected=Aucune selection
+normal=Normal
+north=Nord
+Nueva_tabla=Nouvelle table
+nuevo=Nouveau
+Nuevo_conjunto=Nouvelle s\u00e9lection
+nuevo_nombre_para_el_mapa=
+nuevo_proyecto=Nouveau projet
+nuevo_tooltip=Cr\u00e9er un nouveau projet
+num_bandas=Nombre de bandes
+num_columnas=Nombre de colonnes
+num_filas=Nombres de lignes
+Num_intervalos=
+numero_decimales_mostrar=
+numero_incorrecto=
+ok=Accepter
+opacidad=Opacit\u00e9
+operacion_cancelada=
+options.layout.paper_properties.landscaped=
+options.layout.paper_properties.paper_direction=
+options.layout.paper_properties.portrait=
+options.layout.paper_properties.title=
+options.view.default_map_overview_back_color=
+options.view.default_selection_color=
+options.view.default_view_back_color=
+options.view.invisible_new_layers=
+options.view.keep_scale_on_resizing=
+orientacion=Orientation\:
+origen_de_datos=Origine des donn\u00e9es
+Origen_de_datos=Origine des donn\u00e9es
+Origen_de_Datos=Origine des donn\u00e9es\:
+owner=Propri\u00e9taire
+paste=Copier
+paste_elements=
+path=Chemin
+pdf=
+pegar=
+pegar_mapas=
+pegar_vistas=
+Permite_etiquetar_los_elementos_del_mapa_con_el_valor_de_un_determinado_campo=Permet d'\u00e9tiquetter les \u00e9l\u00e9ments de la carte avec la valeur d'un champs d\u00e9termin\u00e9
+Personalizado=Personnalisation
+personalizar_margenes=
+Pies=Pieds
+pila_de_comandos=historique des commandes
+pixeles=pixels
+pixels=pixels
+Plain=Normal
+plantilla=
+please_insert_new_field_name=
+png=Fichiers PNG
+poligono=Polygone
+polilinea=polyligne
+poner_capas_a=Ajouter les couches ...
+por_debajo_de=en dessous de\:
+por_encima_de=au del\u00e0 de\:
+Por_favor_active_la_capa=Veuillez activer la couche
+posicion_linea=Position de la ligne
+precision=
+preparar_pagina=Pr\u00e9parer la page
+Preparar_pagina=Pr\u00e9parer la page
+presentacion=Pr\u00e9sentation
+previsualizacion=Pr\u00e9visualisation.
+Previsualizacion=Pr\u00e9visualisation
+Previsualizacion_de_simbolo=Pr\u00e9visualisation du symbole
+propiedad=
+propiedades=Propri\u00e9t\u00e9s
+propiedades_cajetin=Propri\u00e9t\u00e9s du cadre
+propiedades_capa=Propri\u00e9t\u00e9s de la couche
+propiedades_de_la_capa=Propri\u00e9t\u00e9s de la couche\n
+Propiedades_escala_grafica=Propri\u00e9t\u00e9s de la barre d'\u00e9chelle
+propiedades_grafico=Propri\u00e9t\u00e9s du graphique
+propiedades_mapa=Propri\u00e9t\u00e9s de la carte
+propiedades_marco_imagenes=Propri\u00e9t\u00e9s du bloc image
+propiedades_marco_leyenda=Propri\u00e9t\u00e9s du bloc de l\u00e9gende
+propiedades_marco_vista=Propri\u00e9t\u00e9s du bloc de vue
+propiedades_raster=Propri\u00e9t\u00e9s du raster
+propiedades_sesion=Propri\u00e9t\u00e9s du project
+propiedades_tabla=Propri\u00e9t\u00e9s de la table
+Propiedades_texto=Propri\u00e9t\u00e9s du texte
+propiedades_vista=Propri\u00e9t\u00e9s de la vue
+Proyecciones=
+ps=
+puerto=Port
+Pulgadas=Pouces
+punto=Point
+quantile_intervals=Intervalles quantiles
+quiere_continuar=S\u00fbr de vouloir continuer?
+Quitar=Quitter
+Quitar_capa=Supprimer une couche
+quitar_enlaces=Enlever liens
+Quitar_todos=Tout supprimer
+quitar_uniones=Enlever unions
+rango_de_escalas=Niveau d'\u00e9chelle
+Rango_de_escalas=Classes d'\u00e9chelles
+realce=R\u00e9heussement
+realmente_desea_guardar=Voulez-vous sauvegarder ?
+recargar=
+recorte_colas=Couper les r\u00e9sidus
+recorte_vista=Couper la vue
+rectangulo=Rectangle
+recuento=Recomptage
+Recuperar_leyenda=Charger une l\u00e9gende
+Recuperar_y_eliminar_otros_zoom=R\u00e9cuperer et \u00e9liminer les autres zooms
+refrescar=Rafra\u00eechir
+rehacer=refaire
+rellenar_marco_vista=Remplir le cadre de la vue
+relleno=Remplir \:
+remove_elements=
+remove_fields=
+remove_row=Supprimer une ligne
+remove_rows=
+rename_field=
+renombrar=Renomer
+reproyectar_aviso=Le syst\u00e8me de projection de la couche est diff\u00e9rent de la vue.\nAVISO\: \=Des probl\u00e8mes peuvent \u00eatre rencontr\u00e9s avec certaines projections. Lisez la documentation
+reproyectar_pregunta=Souhaitez-vous reprojeter ?
+resolucion_resultado=R\u00e9solution du r\u00e9sultat\:
+resto_valores=Reste des valeurs
+restore_palette=
+rotation_field=
+salir=Quitter
+salir_tooltip=Quitter
+salvar_raster=Enregistrer le raster g\u00e9or\u00e9f\u00e9renc\u00e9.
+Sample=Exemple
+Se_superponen_a=Se superposent \u00e0
+Sean_disjuntos_a=sont disjoints de
+Sean_iguales_a=sont identiques \u00e0
+seleccion=S\u00e9lection
+seleccion_fuente=S\u00e9lection d'une fonte
+Seleccion_por_capa=S\u00e9lection par couche
+selecciona_sistema_de_referencia=
+Seleccionar=S\u00e9lectionner
+seleccionar_capas=S\u00e9lectionner des couches
+seleccionar_capas_raster=
+Seleccionar_de_las_capas_activas_los_elementos_que=S\u00e9lectionner dans la couche active les entit\u00e9s qui\:
+Seleccionar_del_conjunto=Mettre ce texte sur plusieurs lignes
+Seleccionar_fichero=S\u00e9lectionner un fichier
+seleccionar_por_poligono=
+seleccionar_por_punto=S\u00e9lection
+seleccionar_por_rectangulo=S\u00e9lection \u00e0 partir d'un rectangle
+seleccionar_todos=Tout s\u00e9lectionner
+seleccione_campo_enlace=S\u00e9lectionner le champs \u00e0 relier
+seleccione_el_campo_angulo_de_la_capa_de_anotaciones=
+seleccione_el_campo_color_de_la_capa_de_anotaciones=
+seleccione_el_campo_de_texto_que_desea_que_se_utilize_para_mostrar_la_nueva_capa_virtual=
+seleccione_el_campo_fuente_de_la_capa_de_anotaciones=
+seleccione_el_campo_tamano_de_la_capa_de_anotaciones=
+seleccione_fecha=S\u00e9lection d'une date...
+seleccione_tabla_a_enlazar=S\u00e9lectionner la table a relier
+seleccione_tabla_origen=S\u00e9lectionner la  origine de la jointure
+selection_color=Couleur de s\u00e9lection
+selection_up=
+separator=
+Servidor=Serveur
+Shapefile=Shapefile
+show_this_dialog_next_startup=
+si=
+siempre=Toujours
+simbolo=
+Simbolo=Symbole
+Simbolo_unico=Symbole unique
+Simbologia=Symbologie
+simplificar_leyenda=
+simplify=
+sin_titulo=Sans titre
+sincronizar_color_borde_relleno=Synchroniser la couleur de contour avec le fond \:
+Size=Taille
+sobre_la_barra=Sur la barre
+Solo_para_capas_vectoriales=Seulement pour les couches vectorielles
+start_edition=Commencer l'\u00e9dition
+statistics=Statistiques
+stop_edition=Terminer l'\u00e9dition
+Style=Style
+Subir_capa=Monter une couche
+suma=Somme
+Superior=Sup\u00e9rieure
+symbol_selector=
+Tabla=Table
+Tabla_de_Atributos=Table d'attributs
+tablas=Tables
+Tablas=Tables
+tag=tag
+tamano=Taille\:
+tamano_metros=Taille en m\u00e8tres
+tamano_pagina=Taille de la page\:
+tamano_posicion=Taille et position
+tamanyo_borde=Taille du bord
+tamanyo_fuente=Taille de la source
+tamanyo_pagina=
+tamPixX=
+tamPixY=
+terminar=
+terminar_edicion=
+texto=Texte
+this_table_is_not_self_editable=
+tipo_dato=Type de donn\u00e9e
+tipo_de_intervalo=Type d'intervalle
+tipo_de_leyenda=Type de l\u00e9gende
+tipo_fichero_proyecto=Fichier de projet gvSIG (*.gvsproj)
+tipo_linea=Type de Ligne\:
+tipo_relleno=Remplir\:
+tipo_simbolo=Type de symbole\:
+tipos_de_documentos=Type de documents
+titulo=Gestionnaire de projet
+titulo_fframetext=Titre du champs texte
+to_annotation=Transformer la couche en etiquettes
+to_palette=Changer la palette
+tooltip_copiar_al_portapapeles=
+tooltip_cortar_al_portapapeles=
+tooltip_pegar_desde_el_portapapeles=
+Toquen=touchent
+transparencia=Transparence
+Transparencia=Transparence
+transparencia_pixel=Transparence des pixels
+ungroup=Dissocier
+unidades=Unit\u00e9s\:
+Unidades=Unit\u00e9s\:
+untitled=Sans titre
+url=
+Usar_indice_espacial=Utiliser indice spatial
+usar_marco=Utiliser le cadre
+usar_titulo=Utiliser titre
+usuario=Utilisateur
+utilizar_margenes_impresora=Utiliser les marges de l'imprimante.
+vacia=Vide
+Valor=Valeur
+Valores=Valeurs
+Valores_unicos=Valeurs uniques
+varianza=Variance
+Ventana=Fen\u00eatre
+ventana_proyecto=Fen\u00eatre de projet
+Ver=Afficher
+ver_error_capa=
+ver_tabla_atributos=Voir la table des attributs
+ver_tags=
+ver_tooltip=Afficher la fen\u00eatre de projet
+vertical=Vertical
+vertical_space=
+visible=Visible
+visibles=Toutes visibles
+Vista=Vue
+vistas=Vues
+visualizacion=Vues
+Visualizacion=Visualiser
+visualizar_cuadricula=Afficher la grille
+warning=
+xmax=X minimum
+xmin=X minimum
+Yardas=Yards
+ymax=Y minimum
+ymin=Y minimum
+Zoom_a_la_capa=Zoom \u00e0 la couche
+Zoom_Acercar=Zoom rapprocher
+Zoom_Alejar=Zoom \u00e9loigner
+Zoom_Completo=Vue g\u00e9n\u00e9rale
+Zoom_Completo_Vista=Zoom complet dans le cadre
+zoom_in_factor=
+Zoom_Mas=Zoom avant.
+Zoom_Mas_Vista=Zoom arri\u00e8re dans le cadre
+Zoom_Menos=Zoom avant
+Zoom_Menos_Vista=Zoom avant dans le cadre
+zoom_out_factor=
+Zoom_pixel=Zoom a la r\u00e9solution du raster
+Zoom_Previo=Zoom pr\u00e9c\u00e9dent
+Zoom_Real=Zoom 1\:1
+Zoom_Select=Zoom \u00e0 la s\u00e9lection

Property changes on: tags/v2_0_0_Build_2050/applications/appgvSIG/config/text_fr.properties
___________________________________________________________________
Added: svn:keywords
   + Author Date Id Revision
Added: svn:eol-style
   + native

Index: tags/v2_0_0_Build_2050/applications/appgvSIG/config/scolab.html
===================================================================
--- tags/v2_0_0_Build_2050/applications/appgvSIG/config/scolab.html	(revision 0)
+++ tags/v2_0_0_Build_2050/applications/appgvSIG/config/scolab.html	(revision 38653)
@@ -0,0 +1,12 @@
+<html>
+<body>
+
+<img src="scolab-logo.png"><br>
+
+<h2>Software Colaborativo</h2>
+<br>
+
+<p>EN CONSTRUCCION</p>
+
+</body>
+</html>
\ No newline at end of file

Property changes on: tags/v2_0_0_Build_2050/applications/appgvSIG/config/scolab.html
___________________________________________________________________
Added: svn:mime-type
   + text/plain

Index: tags/v2_0_0_Build_2050/applications/appgvSIG/config/text_eu.properties
===================================================================
--- tags/v2_0_0_Build_2050/applications/appgvSIG/config/text_eu.properties	(revision 0)
+++ tags/v2_0_0_Build_2050/applications/appgvSIG/config/text_eu.properties	(revision 38653)
@@ -0,0 +1,706 @@
+#Translations for language [eu]
+#Mon Oct 30 09:38:21 CET 2006
+(escala_maxima)=(eskala handiena)
+(escala_minima)=(eskala txikiena)
+1\:=
+_(Simbolo_unico)=(Ikur bakarra)
+__proyeccion_actual=Egungo proiekzioa\:
+__redimensionar_texto_escala=Testua bistaren eskalara egokitu.
+__seleccion_de_fuente=Letra-tipoa aukeratu
+A0=A0
+A1=A1
+A2=A2
+A3=A3
+A4=A4
+abajo=Behera
+abrir=Ireki
+abrir_plantilla=Ireki txantiloia
+abrir_proyecto=Proiektua ireki
+abrir_tooltip=Aurreko proiektu bat irekitzen du
+Abrir_una_capa=
+Accion_Predefinida=Aurretik zehaztutako ekintza
+aceptar=Ados
+Aceptar=Ados
+acerca_de=Honi buruz\:
+activar=Activate
+activar_regla=Erregela aktibatu
+activos=Aktiboak
+add_delete_edit_fields=
+add_layer=Gehitu geruza
+add_rows=
+adjust_transparency=Doitu gardentasuna
+agrupacion=
+agrupar=Multzokatu
+agrupar_capas=Multzokatu geruzak
+agrupar_graficos=Multzokatu grafikoak
+agrupar_linea=Lerro grafikoa grafikoekin multzokatu.
+Ajustar_transparencia=Doitu gardentasuna
+ajustes_linea_grafica=Lerro grafikoaren doitzeak
+Al_leer_la_leyenda=Legenda irakurtzean
+alias=Ezizena
+align_center=
+align_down=
+align_left=
+align_right=
+align_to_layout_center=
+align_to_layout_down=
+align_to_layout_left=
+align_to_layout_right=
+align_to_layout_up=
+align_to_layout_vertical_center=
+align_up=
+align_vertical_center=
+alineamiento=Lerrokadura
+alinear=Lerrokatu
+alinear_graficos=Grafikoak lerrokatu
+alta=Goi
+alto=Goi
+altura=Altura\:
+Altura_fija_de_texto=Testuaren altura finkoa
+ambito=Esparrua
+Anadir=Gehitu
+Anadir_al_conjunto=Gehitu multzoari
+Anadir_capa=Gehitu geruza
+Anadir_Capa=Gehitu geruza
+anadir_tag=
+Anadir_todos=Gehitu guztiak
+ancho=Zabalera
+ancho_alto=Zabalera altuera
+anchura=Zabalera\:
+Aplicar=Aplikatu
+Archivo=Fitxategia
+arriba=Gora
+ascending_order=Goranzko hurrenkera
+ascending_order_tooltip=Ordenatu hautatutako eremua goranzko hurrenkeran
+Atributo=Atributua
+automatico=Automatikoa
+Ayuda=Laguntza
+back=Aurrekoa
+background_color=Atzeko kolorea
+baja=Behe
+Bajar_capa=Jaitsi geruza
+bandas=Bandak
+barra=Barra\:
+base=base
+base_datos=Datu-baseak
+bmp=BMP motako fitxategiak
+Bold=
+borra_seleccion=Ezabatu aukeraketa
+borrador=Zirriborroa
+borrar=Ezabatu
+box=
+brillo=Distira
+brillo_y_contraste=Distira eta kontrastea
+browse=Aztertu
+cajetin=
+Calcular_intervalos=Kalkulatu bitarteak
+calidad=Kalitatea
+cambiar_el_alto_de_los_elementos_seleccionados_hasta_coincidir_con_el_mas_alto=
+cambiar_el_ancho_de_los_elementos_seleccionados_hasta_coincidir_con_el_mas_ancho=
+cambiar_el_tamano_de_los_elementos_seleccionados_hasta_coincidir_con_el_mas_grande=
+Cambio_Color=Kolore aldaketa
+cambio_nombre=Izen aldaketa
+campo=Eremua
+Campo=Eremua
+campo_altura_texto=Testuaren altura eremua\:
+Campo_de_clasificacion=Sailkapen eremua
+Campo_de_etiquetado=Etiketatze eremua
+Campos=Eremuak
+cancel=Utzi
+Cancel=Utzi
+cancelar=Utzi
+Cancelar=Utzi
+Capa=Geruza
+Capas=Geruzak
+Capas_del_localizador=Bilagailuaren geruzak
+Centimetros=Zentimetroak
+cerrar=Itxi
+Cerrar=Itxi
+change=
+change_before=
+change_behind=
+change_height=
+change_width=
+circulo=Zirkulua
+clave=Gakoa
+close=Itxi
+coincidir_tamanyo=
+colocar_a_margenes=Jarri marjinak kontuan hartuta.
+colocar_alrededor_seleccionados=Jarri hautatutako grafikoen inguruan.
+colocar_alrededor_todos=Jarri grafiko guztien inguruan.
+colocar_delante=Jarri aurrean
+colocar_detras=Jarri atzean
+color=Kolorea\:
+Color_final=Amaierako kolorea
+Color_inicio=Hasierako kolorea
+color_texto=Testuaren kolorea\:
+comentarios=Iruzkinak
+comenzar_edicion=
+compleja=
+configurar=Konfiguratu
+configurar_localizador=Konfiguratu bilagailua
+Configurar_localizador=Konfiguratu bilagailua...
+confirmar_borrar=Ziur al zaude osagaia ezabatu nahi duzula?
+conflicto_de_nombres_de_mapas_al_pegar=
+conflicto_de_nombres_de_tablas_al_pegar=
+conflicto_de_nombres_de_vistas_al_pegar=
+conflito_de_nombres_de_tablas_al_pegar=
+conservar_escala_visualizacion=Gorde bistaratze eskala
+consulta=Kontsulta
+Contengan=Honakoak dituztenak
+contraste=Kontrastea
+coor_geograficas=Koordenatu geografikoak
+copiar=
+copy=Kopiatu
+cortar=
+creation_date=Sortze data
+Crucen_con=Hauekin gurutzatzen direnak
+cuando_activo=Aktibo dagoenean
+cut=Ebaki
+Dado_un_campo_de_atributos=Atributu eremua emanda dago
+debera_introducir_nombres_para_las_vistas_a_pegar=
+debera_introducir_nombres_para_los_mapas_a_pegar=
+default_projection=
+default_value=
+dehacer=Desegin
+delete_field=Ezabatu eremua
+Derecha=Eskuina
+Derecho=Eskuina
+desagrupar=Desegin multzoak
+desagrupar_capas=
+desagrupar_graficos=Desegin grafikoen multzoak
+descending_order=Beheranzko hurrenkera
+descending_order_tooltip=Ordenatu hautatutako eremua beheranzko hurrenkeran
+descripcion_de_configuracion_capa_de_anotaciones=
+descripcion_de_crear_capa_de_anotaciones=
+desde_arriba=Goitik\:
+desde_izquierda=Ezkerretik\:
+desea_borrar_el_documento=
+desea_borrar_la_capa=
+desea_continuar=
+deshacer=Desegin
+desplaza_los_elementos_seleccionados_a_la_derecha=
+desplaza_los_elementos_seleccionados_a_la_izquierda=
+desplaza_los_elementos_seleccionados_al_centro_por_el_eje_x=
+desplaza_los_elementos_seleccionados_al_centro_por_el_eje_y=
+desplaza_los_elementos_seleccionados_hacia_abajo=
+desplaza_los_elementos_seleccionados_hacia_arriba=
+Desplazamiento=Lekualdaketa
+desviacion_tipica=Ohiko desbideratzea
+distance_units=Neurri unitateak
+distribuir=Banatu\:
+distribuir_elementos_sobre_todo_el_layout=
+distributes_down=
+distributes_horizontal=
+distributes_left=
+distributes_right=
+distributes_to_layout_down=
+distributes_to_layout_horizontal=
+distributes_to_layout_left=Distribuye izquierda del layout
+distributes_to_layout_right=
+distributes_to_layout_up=
+distributes_to_layout_vertical=
+distributes_up=
+distributes_vertical=
+distribuye_el_espacio_entre_los_elementos_en_horizontal=
+distribuye_el_espacio_entre_los_elementos_en_vertical=
+distribuye_los_elementos_seleccionados_de_forma_equidistante_de_abajo_hacia_arriba=
+distribuye_los_elementos_seleccionados_de_forma_equidistante_de_arriba_hacia_abajo=
+distribuye_los_elementos_seleccionados_de_forma_equidistante_de_derecha_a_izquierda=
+distribuye_los_elementos_seleccionados_de_forma_equidistante_de_izquierda_a_derecha=
+distribuye_los_elementos_seleccionados_de_forma_equidistante_y_horizontal=
+distribuye_los_elementos_seleccionados_de_forma_equidistante_y_vertical=
+divisiones_izquierda=Zatiketak ezkerrean
+documento=
+documentos_existentes=Aurretik dauden dokumentuak
+draw_text_only=
+driver=Driver
+Dxffiles=.DFX fitxategiak
+edicion=Edizioa
+editable=Editagarria
+Editar_leyenda=Editatu legenda
+editar_vertices=Editatu erpinak
+el_numero_maximo_de_intervalos_para_este_campo_es=Eremu honek izan dezakeen tarte kopuru handiena hau da
+Elegir_Color=Hautatu kolorea
+Elegir_Fuente=Hautatu letra-tipoa
+elemento_ya_existe=
+Elementos_seleccionados_de_la_capa=Geruzatik hautatu diren osagaiak
+Eliminar=Ezabatu
+eliminar_capa=Ezabatu geruza
+eliminar_columna=
+eliminar_extremos=Ezabatu muturrak
+eliminar_fila=
+en_el_mapa=Mapan\:
+En_metros=Metrotan
+En_pixels=Pixeletan
+en_unidades=
+Encuadre=Enkoadraketa
+Encuadre_Vista=Bistaren gaineko enkoadraketa
+enlace_vivo=Lotura bizia
+Enlazar_a_fichero_de_texto=Testu fitxategietara estekatu
+Enlazar_a_ficheros_de_imagen=Irudi fitxategietara estekatu
+equal_intervals=Tarte berdinak
+Error_exportando_SLD=
+Error_guardando_la_leyenda=Errorea legenda gordetzean
+Error_guardando_la_plantilla=
+escala=Eskala
+Escala=Eskala
+escala_desconocida=
+escala_maxima=Eskala handiena
+Escala_Maxima=Eskala handiena
+escala_minima=Eskala txikiena
+Escala_Minima=Eskala txikiena
+escala_usuario=Erabiltzaileak zehaztutako eskala
+espaciado_horizontal=Sarearen tarte horizontala
+espaciado_vertical=Sarearen tarte bertikala
+espacio=Espazioa\:
+estadisticas=Estatistikak
+este_por_debajo_de_=Honen azpitik egotea\:
+este_por_encima_de=Honen gainetik egotea\:
+Esten_contenidos_en=Hemen daudenak
+Etiqueta=Etiketa
+Etiquetados=Etiketatuak
+etiquetas=Etiketak\:
+Etiquetas_estandar=Etiketa estandarrak
+Examinar=Aztertu
+export=Esportatu
+exportar=Esportatu
+exportar_pdf=Esportatu pdf batera
+exportar_ps=Exportar a ps
+extension=Luzapena
+Extent=Extent
+extents_no_coincidentes=Hedadurak ez datoz bat
+factor_zoom_incorrecto=
+fallo_capas=Hutsegitea geruzetara iristean. Hurrengo geruzak proiektutik ezabatuko dira
+family=
+fichero=
+Fichero=Fitxategia
+fichero_existe=Fitxategia badago
+fichero_incorrecto=Fitxategia ez da zuzena
+fichero_ya_existe_seguro_desea_guardarlo=
+field_already_exists=
+field_decimal_count=
+field_default_value=
+field_length=
+field_manager=
+field_name=
+field_type=
+filtro=Iragazkia
+finish=Bukatu
+Font=Letra-tipoa
+formato=Formatua
+Formato_de_numero_erroneo=
+formato_incorrecto=Formatoa ez da zuzena
+fuente=Letra-tipoa
+General=Orokorra
+georeferenciado=
+gestion_encuadre=Enkoadraketen kudeaketa
+grados=Graduak\:
+Grados=Graduak
+Graficos=Grafikoak
+grosor_linea=Lerroaren lodiera\:
+group=Multzokatu
+group_graphic_line=
+grupo=
+guardado=Hemen gorde da\:
+guardar=Gorde
+Guardar=Gorde
+guardar_cambios=Aldaketak gorde nahi dituzu?
+guardar_como=Gorde honela\:
+guardar_como_plantilla=Gorde txantiloi moduan
+Guardar_el_zoom_actual=Gorde zooma
+Guardar_leyenda=Gorde legenda
+guardar_proyecto=Gorde proiektua
+guardar_tooltip=Gorde proiektuaren aldaketak
+Habilitar_etiquetado=Gaitu etiketak
+Hiperenlace=Hiperesteka
+horizontal=Horizontala
+horizontal_space=
+Identificar_Resultados=Identifikatu emaitzak
+Igual_que_la_impresora=Inprimagailuaren neurrira
+igual_todos_lados=Alde guztietatik berdin mugitzea.
+imagen=Irudia
+Implimir=
+importar=Inportatu
+Imprimir=Inprimatu
+Indexando=Indexatzen...
+Indexando_espacialmente=Geruza espazioan indexatzen ari da
+indexar_campos=
+Inferior=Behean
+info=Informazioa
+informacion=Informazioa
+Informacion=Informazioa
+Inicializando=Hasten
+initial_warning=
+insert_row=Txertatu ilara
+Insertar=Txertatu
+insertar_cajetin=Txertatu inskripzio-laukia
+insertar_circulo=Txertatu zirkulua
+insertar_columna=
+insertar_escala=Txertatu eskala
+insertar_fila=
+insertar_imagen=Txertatu irudia
+insertar_leyenda=Txertatu legenda
+insertar_linea=Txertatu lerroa
+insertar_norte=Iparraldea txertatu
+insertar_poligono=Txertatu poligonoa
+insertar_polilinea=Txertatu polilinea
+insertar_punto=Txertatu puntua
+insertar_rectangulo=Txertatu laukizuzena
+insertar_texto=Txertatu testua
+insertar_vista=Txertatu bista
+Intersecten_con=Hauekin ebakitzen direnak
+Intervalo=Tartea
+Intervalos=Tarteak
+introduce_nombre=Sartu izen berria
+introduzca_el_nombre_de_la_nueva_capa_de_anotaciones=
+introduzca_nuevo_nombre_para_la_vista=
+invalid_value_for_gap=
+invert_selection=
+Italic=
+Izquierda=Ezkerra
+Izquierdo=Ezkerra
+join=Lotu
+jpg=JPEG fitxategiak
+kilometros=Kilometroak
+Kilometros=Kilometroak
+leyenda=Legenda
+Leyenda=Legenda
+leyenda_campo_unido=Legendan (eta/edo etiketan)loturaren eremu bat erabiltzen ari zara. Mesedez, aldatu legenda lotunea kendu aurretik.
+Leyenda_Por_Defecto=Legenda lehenetsia
+linea=Lerroa
+linea_grafica=Lerro grafikoa
+lineal_directo=Zuzeneko lineala
+link=Lotura
+Link=Lotura
+localizador=Bilagailua
+locked_element=
+locked_element_it_cannot_be_deleted=
+locked_element_it_cannot_be_renamed=
+m/pixel=metros/pixel
+malla_activada=Sarea aktibatuta
+manage_fields=
+mantener_intervalo=Tartea mantendu
+map_units=Maparen unitateak
+mapa=
+Mapa=Mapa
+mapas=Mapak
+marco=Markoa
+marco_vista=Bista-eremua
+margenes=Marjinak
+mas_de_100_simbolos=100 sinbolo baino gehiagok ez diote planoari informaziorik eransten.
+max_length_is=
+maximo=Gehienez
+MDIFrame.quiere_salir=Ziur zaude irten nahi duzula?
+MDIFrame.salir=Irten
+media=Batez beste
+medir_area=Azalera neurtu
+medir_distancias=Distantziak neurtu
+metadatos=Metadatos
+metros=Metroak
+Metros=Metroak
+Milimetros=Milimetroak
+Millas=Miliak
+minimo=Gutxienez
+modificar=
+modification_date=Aldatu zen azken eguna
+mostrar_escala_numerica=
+Mostrar_siempre=Erakutsi beti
+mostrar_unidades=Bistaratu unitateak
+move_elements=
+Muestra_atributos=Hautatutako geruzen atributuak erakusten ditu.
+muestra_los_elementos_de_la_capa_usando_un_simbolo_por_cada_valor_unico=Geruzaren osagaiak balio bakoitzerako ikur bat erabiliz erakusten ditu
+Muestra_los_elementos_de_la_capa_usando_una_gama_de_colores_en_funcion_del_valor_de_un_determinado_campo_de_atributos=Geruzaren elementuak atributu eremu jakin bateko koloreak erabiliz erakusten ditu
+Muestra_todos_los_elementos_de_una_capa_usando_el_mismo_simbolo=Geruza baten osagai guztiak ikur berdina erabiliz erakusten ditu
+natural_intervals=Tarte naturalak
+navegacion=Nabigazioa
+navegacion_vista=Nabigazio Ikuspegia
+necesita_una_capa_activa=Geruza bat aktibo egon behar da
+necesita_una_capa_vectorial_activa=Bektore-geruza bat aktibo egon behar da
+new_field=Eremu berria
+new_field_properties=
+next=Hurrengoa
+ninguna_impresora_configurada=Ez dago konfiguratutako inprimagailurik
+Nivel_de_transparencia=Gardentasun maila
+no=Ez
+no_activos=Ez daude aktibo
+No_de_intervalos=Tarte kop.
+no_es_posible_aplicar_leyenda_vacia=
+No_ha_sido_posible_realizar_la_operacion=
+No_mostrar=Ez erakutsi geruza eskala horrelakoa bada
+No_mostrar_la_capa_cuando_la_escala=Ez erakutsi geruza eskala horrelakoa bada\:
+no_se_pegaran_las_tablas=
+no_se_pegaran_las_vistas_del_conflicto=
+No_se_pudo_obtener_la_tabla_de_la_capa=Ezin izan da geruzaren taula eskuratu
+no_visibles=Ez dago ikusgai
+nombre=Izena
+Nombre=Izena
+nombre_no_valido=
+Nombre_que_se_le_dara_al_zoom=Zoomari emango zaion izena
+nombre_sesion=Saioaren izena
+none=
+none_selected=Ez da bat ere ez hautatu
+normal=Normala
+north=Iparraldea
+Nueva_tabla=Taula berria
+nuevo=Berria
+Nuevo_conjunto=Multzo berria
+nuevo_nombre_para_el_mapa=
+nuevo_proyecto=Proiektu berria
+nuevo_tooltip=Beste proiektu bat sortu
+num_bandas=Banda kopurua
+num_columnas=Zutabe kopurua
+num_filas=Lerro kopurua
+Num_intervalos=
+numero_decimales_mostrar=
+numero_incorrecto=Zenbakia ez da zuzena
+ok=Ados
+opacidad=Opakotasuna
+operacion_cancelada=
+options.layout.paper_properties.landscaped=
+options.layout.paper_properties.paper_direction=
+options.layout.paper_properties.portrait=
+options.layout.paper_properties.title=
+options.view.default_map_overview_back_color=
+options.view.default_selection_color=
+options.view.default_view_back_color=
+options.view.invisible_new_layers=
+options.view.keep_scale_on_resizing=
+orientacion=Orientazioa\:
+origen_de_datos=Datu-iturburua
+Origen_de_datos=Datu-iturburua
+Origen_de_Datos=Datu-iturburua\:
+owner=Jabea
+paste=Itsatsi
+paste_elements=
+path=Bidea
+pdf=
+pegar=
+pegar_mapas=
+pegar_vistas=
+Permite_etiquetar_los_elementos_del_mapa_con_el_valor_de_un_determinado_campo=Mapako elementuak eremu jakin baten balioarekin etiketatzea ahalbidetzen du
+Personalizado=Pertsonalizatua
+personalizar_margenes=
+Pies=Oinak
+pila_de_comandos=Komando-pila
+pixeles=pixelak
+pixels=pixels
+Plain=
+plantilla=
+please_insert_new_field_name=
+png=png fitxategiak
+poligono=Poligonoa
+polilinea=polilinea
+poner_capas_a=Jarri geruzak hemen\:
+por_debajo_de=Honen azpitik\:
+por_encima_de=Honen gainetik\:
+Por_favor_active_la_capa=Mesedez, aktibatu geruza
+posicion_linea=Lerroaren kokalekua
+precision=
+preparar_pagina=Prestatu orria
+Preparar_pagina=Prestatu orria
+presentacion=Aurkezpena
+previsualizacion=Aurrebista
+Previsualizacion=Aurrebista
+Previsualizacion_de_simbolo=Ikurraren aurrebista
+propiedad=
+propiedades=Ezaugarriak
+propiedades_cajetin=Inskripzio-laukiaren ezaugarriak
+propiedades_capa=Geruzaren ezaugarriak
+propiedades_de_la_capa=Geruzaren ezaugarriak
+Propiedades_escala_grafica=Eskala grafikoaren ezaugarriak
+propiedades_grafico=Grafikoaren ezaugarriak
+propiedades_mapa=Maparen ezaugarriak
+propiedades_marco_imagenes=Irudi-markoaren ezaugarriak
+propiedades_marco_leyenda=Legenda-markoaren ezaugarriak
+propiedades_marco_vista=Bista-markoaren ezaugarriak
+propiedades_raster=Raster-aren ezaugarriak
+propiedades_sesion=Saioaren ezaugarriak
+propiedades_tabla=Taularen ezaugarriak
+Propiedades_texto=Testuaren ezaugarriak
+propiedades_vista=Bistaren ezaugarriak
+Proyecciones=
+ps=
+puerto=Ataka
+Pulgadas=Hazbeteak
+punto=Puntua
+quantile_intervals=Tarte koantilak
+quiere_continuar=Ziur zaude irten nahi duzula?
+Quitar=Kendu
+Quitar_capa=Kendu geruza
+quitar_enlaces=Kendu lotuneak
+Quitar_todos=Kendu denak
+quitar_uniones=Kendu loturak
+rango_de_escalas=Eskala-maila
+Rango_de_escalas=Eskala-maila
+realce=Irtengunea
+realmente_desea_guardar=Ziur zaude gorde nahi duzula?
+recargar=
+recorte_colas=Ilarak ebaki
+recorte_vista=Bistarako murrizketa
+rectangulo=Laukizuzena
+recuento=Zenbaketa
+Recuperar_leyenda=Berreskuratu legenda
+Recuperar_y_eliminar_otros_zoom=Beste zoom batzuk berreskuratu eta ezabatu
+refrescar=Eguneratu
+rehacer=Berregin
+rellenar_marco_vista=Bete bista-eremua
+relleno=Betegarria\:
+remove_elements=
+remove_fields=
+remove_row=Ezabatu lerroa
+remove_rows=
+rename_field=
+renombrar=Berriro izendatu
+reproyectar_aviso=Geruzaren proiekzioa ez da bistaren proiekzioaren berdina. OHARRA\: Zehaztugabea izan daiteke aldaketa batzuekin. Mesedez, irakurri dokumentazioa.
+reproyectar_pregunta=Berriro proiektatu nahi duzu?
+resolucion_resultado=Emaitzaren ebazpena\:
+resto_valores=Gainerako balioak
+restore_palette=
+rotation_field=
+salir=Irten
+salir_tooltip=Irten
+salvar_raster=Gorde raster geoerreferentziatuan.
+Sample=Adibidea
+Se_superponen_a=Honakoei gainjartzen zaizkienak
+Sean_disjuntos_a=honen disjuntu direnak
+Sean_iguales_a=honen berdinak direnak
+seleccion=Hautaketa
+seleccion_fuente=Letra-tipoa aukeratu
+Seleccion_por_capa=Hautatu geruzaka
+selecciona_sistema_de_referencia=
+Seleccionar=Hautatu
+seleccionar_capas=Hautatu geruzak
+seleccionar_capas_raster=
+Seleccionar_de_las_capas_activas_los_elementos_que=Geruza aktiboetatik baldintza hauek betetzen dituzten osagaiak hautatu\:
+Seleccionar_del_conjunto=Multzotik hautatu
+Seleccionar_fichero=Hautatu fitxategia
+seleccionar_por_poligono=
+seleccionar_por_punto=Puntuka hautatu
+seleccionar_por_rectangulo=Laukizuzenka hautatu
+seleccionar_todos=Hautatu guztiak
+seleccione_campo_enlace=Hautatu lotzeko erabiliko den eremua
+seleccione_el_campo_angulo_de_la_capa_de_anotaciones=
+seleccione_el_campo_color_de_la_capa_de_anotaciones=
+seleccione_el_campo_de_texto_que_desea_que_se_utilize_para_mostrar_la_nueva_capa_virtual=
+seleccione_el_campo_fuente_de_la_capa_de_anotaciones=
+seleccione_el_campo_tamano_de_la_capa_de_anotaciones=
+seleccione_fecha=Hautatu data bat...
+seleccione_tabla_a_enlazar=Hautatu lotu beharreko taula
+seleccione_tabla_origen=Hautatu join-aren sorburu-taula
+selection_color=Hautaketaren kolorea
+selection_up=
+separator=
+Servidor=Zerbitzaria
+Shapefile=Shapefile
+show_this_dialog_next_startup=
+si=
+siempre=Beti
+simbolo=
+Simbolo=Ikurra
+Simbolo_unico=Ikur bakarra
+Simbologia=Sinbologia
+simplificar_leyenda=
+simplify=
+sin_titulo=Titulurik gabe
+sincronizar_color_borde_relleno=Ertzaren kolorea eta betegarriarena sinkronizatu\:
+Size=
+sobre_la_barra=Barran
+Solo_para_capas_vectoriales=Bektore-geruzetarako bakarrik
+start_edition=Hasi edizioa
+statistics=Estatistikak
+stop_edition=Amaitu edizioa
+Style=Estiloa
+Subir_capa=Igo geruza
+suma=Batura
+Superior=Goian
+symbol_selector=
+Tabla=Taula
+Tabla_de_Atributos=Atributuen taula
+tablas=Taulak
+Tablas=Taulak
+tag=tag
+tamano=Tamaina\:
+tamano_metros=Tamaina metrotan
+tamano_pagina=Orrialde-tamaina\:
+tamano_posicion=tamaina/kokalekua
+tamanyo_borde=Ertzaren tamaina
+tamanyo_fuente=Iturri-tamaina
+tamanyo_pagina=
+tamPixX=
+tamPixY=
+terminar=
+terminar_edicion=
+texto=Testua
+this_table_is_not_self_editable=
+tipo_dato=Datu mota
+tipo_de_intervalo=Tarte mota
+tipo_de_leyenda=Legenda-mota
+tipo_fichero_proyecto=gvSIG (*.gvsproj) proiektu fitxategia
+tipo_linea=Lerro mota\:
+tipo_relleno=Betegarri-mota\:
+tipo_simbolo=Ikur-mota\:
+tipos_de_documentos=Agiri-motak
+titulo=Proiektuen kudeatzailea
+titulo_fframetext=Testu eremuaren titulua
+to_annotation=Bihurtu oharpen-geruza
+to_palette=Aldatu paletara
+tooltip_copiar_al_portapapeles=
+tooltip_cortar_al_portapapeles=
+tooltip_pegar_desde_el_portapapeles=
+Toquen=hauek ukitzen dituztenak
+transparencia=Gardentasuna
+Transparencia=Gardentasuna
+transparencia_pixel=Gardentasuna pixel bakoitzeko
+ungroup=Desegin multzoak
+unidades=Unitateak\:
+Unidades=Unitateak\:
+untitled=Titulurik gabe
+url=
+Usar_indice_espacial=Espazio-indizea erabili
+usar_marco=Erabili markoa
+usar_titulo=Erabili titulua
+usuario=Erabiltzailea
+utilizar_margenes_impresora=Erabili inprimagailuaren marjinak.
+vacia=Hutsik
+Valor=Balioa
+Valores=Balioak
+Valores_unicos=Balio bakarrak
+varianza=Bariantza
+Ventana=Leihoa
+ventana_proyecto=Proiektuaren leihoa
+Ver=Ikusi
+ver_error_capa=
+ver_tabla_atributos=Ikusi atributuen taula
+ver_tags=
+ver_tooltip=Proiektuaren leihoa erakusten du
+vertical=Bertikala
+vertical_space=
+visible=Ikusgai
+visibles=Ikusgai
+Vista=Bista
+vistas=Bista
+visualizacion=Bistaratzea
+Visualizacion=Bistaratzea
+visualizar_cuadricula=Bistaratu sarea
+warning=Oharra
+xmax=xmax
+xmin=xmin
+Yardas=Yardak
+ymax=ymax
+ymin=ymin
+Zoom_a_la_capa=Zooma geruzari
+Zoom_Acercar=Hurbiltzeko zooma
+Zoom_Alejar=Urruntzeko zooma
+Zoom_Completo=Zooma osorik
+Zoom_Completo_Vista=Zooma osorik bistaren gainean
+zoom_in_factor=
+Zoom_Mas=Zoom handiagoa
+Zoom_Mas_Vista=Zoom handiagoa bistaren gainean
+Zoom_Menos=Zoom txikiagoa
+Zoom_Menos_Vista=Zoom txikiagoa bistaren gainean
+zoom_out_factor=
+Zoom_pixel=Pixelaren zooma
+Zoom_Previo=Aurretiko zooma
+Zoom_Real=1\:1 zooma
+Zoom_Select=Zooma hautatutakoari

Property changes on: tags/v2_0_0_Build_2050/applications/appgvSIG/config/text_eu.properties
___________________________________________________________________
Added: svn:eol-style
   + native
Added: svn:keywords
   + Author Date Id Revision

Index: tags/v2_0_0_Build_2050/applications/appgvSIG/config/iver.html
===================================================================
--- tags/v2_0_0_Build_2050/applications/appgvSIG/config/iver.html	(revision 0)
+++ tags/v2_0_0_Build_2050/applications/appgvSIG/config/iver.html	(revision 38653)
@@ -0,0 +1,12 @@
+<html>
+<body>
+
+<img src="iver-logo.png"><br>
+
+<h2>IVER</h2>
+<br>
+
+<p>EN CONSTRUCCION</p>
+
+</body>
+</html>
\ No newline at end of file

Property changes on: tags/v2_0_0_Build_2050/applications/appgvSIG/config/iver.html
___________________________________________________________________
Added: svn:mime-type
   + text/plain

Index: tags/v2_0_0_Build_2050/applications/appgvSIG/config/text_it.properties
===================================================================
--- tags/v2_0_0_Build_2050/applications/appgvSIG/config/text_it.properties	(revision 0)
+++ tags/v2_0_0_Build_2050/applications/appgvSIG/config/text_it.properties	(revision 38653)
@@ -0,0 +1,706 @@
+#Translations for language [it]
+#Tue Nov 07 12:30:01 CET 2006
+(escala_maxima)=(scala massima)
+(escala_minima)=(scala minima)
+1\:=
+_(Simbolo_unico)=(Simbolo unico)
+__proyeccion_actual=Proiezione attuale\:
+__redimensionar_texto_escala=Ridimensiona il testo alla scala della vista
+__seleccion_de_fuente=Seleziona carattere
+A0=A0
+A1=A1
+A2=A2
+A3=A3
+A4=A4
+abajo=Basso
+abrir=Apri
+abrir_plantilla=Apri Tavola
+abrir_proyecto=Apri Progetto
+abrir_tooltip=Apri Progetto esistente
+Abrir_una_capa=Apri Layer
+Accion_Predefinida=Azione predefinita
+aceptar=Accetta
+Aceptar=Accetta
+acerca_de=Cerca...
+activar=Attiva
+activar_regla=Attiva regola
+activos=Attivi
+add_delete_edit_fields=I campi possono essere aggiunti, cancellati o rinominati.
+add_layer=Aggiungi Layer
+add_rows=Aggiungi righe
+adjust_transparency=Regola transparenza
+agrupacion=Raggruppamento
+agrupar=Raggruppa
+agrupar_capas=Raggruppa layers
+agrupar_graficos=Raggruppa grafici
+agrupar_linea=Raggruppa riquadro di contorno con i grafici 
+Ajustar_transparencia=Regola trasparenza
+ajustes_linea_grafica=Regola spessore linea
+Al_leer_la_leyenda=Leggendo la legenda
+alias=Alias
+align_center=Allinea al centro
+align_down=Allinea in basso
+align_left=Allinea a sinistra
+align_right=Allinea a destra
+align_to_layout_center=Allinea al centro del layout
+align_to_layout_down=Allinea in basso nel layout
+align_to_layout_left=Allinea a sinistra del layout
+align_to_layout_right=Allinea a destra del layout
+align_to_layout_up=Allinea in alto nel layout
+align_to_layout_vertical_center=Allinea al centro del layout verticalmente
+align_up=Allinea in alto
+align_vertical_center=Allinea al centro della verticale
+alineamiento=Allineamento
+alinear=Allinea
+alinear_graficos=Allinea grafici
+alta=Alta
+alto=Alto
+altura=Altezza\:
+Altura_fija_de_texto=Altezza fissa del testo
+ambito=Ambito
+Anadir=Aggiungi
+Anadir_al_conjunto=Aggiungi all'insieme
+Anadir_capa=Aggiungi layer
+Anadir_Capa=Aggiungi layer
+anadir_tag=Aggiungi tag
+Anadir_todos=Aggiungi tutto
+ancho=Larghezza\:
+ancho_alto=Larghezza X Altezza
+anchura=Larghezza\:
+Aplicar=Applica
+Archivo=File
+arriba=Alto
+ascending_order=Ordine crescente
+ascending_order_tooltip=Ordina il campo selezionato in ordine crescente
+Atributo=Attributo
+automatico=Automatico
+Ayuda=Aiuto
+back=Precedente
+background_color=Colore sfondo
+baja=Basso
+Bajar_capa=Abbassa layer
+bandas=Bande
+barra=Barra\:
+base=base
+base_datos=DataBases
+bmp=BMP files
+Bold=Grasseto
+borra_seleccion=Annulla/Elimina selezione
+borrador=Bozza
+borrar=Rimuovi
+box=Riquadro
+brillo=Luminosit\u00e1
+brillo_y_contraste=Luminosit\u00e0 e Contrasto
+browse=Sfoglia
+cajetin=Riquadro
+Calcular_intervalos=Calcola intervalli
+calidad=Qualit\u00e1
+cambiar_el_alto_de_los_elementos_seleccionados_hasta_coincidir_con_el_mas_alto=Adatta altezza degli elementi selezionati al pi\u00f9 alto.
+cambiar_el_ancho_de_los_elementos_seleccionados_hasta_coincidir_con_el_mas_ancho=Adatta larghezza degli elementi selezionati al pi\u00f9 largo.
+cambiar_el_tamano_de_los_elementos_seleccionados_hasta_coincidir_con_el_mas_grande=Adatta la dimensione degli elementi selezionati al maggiore.
+Cambio_Color=Cambio di colore
+cambio_nombre=Cambio di nome
+campo=Campo
+Campo=Campo
+campo_altura_texto=Campo di altezza del testo\:
+Campo_de_clasificacion=Campo di classificazione
+Campo_de_etiquetado=Campo di etichetta
+Campos=Campi
+cancel=Cancella
+Cancel=Cancella
+cancelar=Cancella
+Cancelar=Cancella
+Capa=Layer
+Capas=Layers
+Capas_del_localizador=Layers del localizzatore
+Centimetros=Centimetri
+cerrar=Chiudi
+Cerrar=Chiudi
+change=Modifica
+change_before=Porta avanti
+change_behind=Porta indietro
+change_height=Modifica altezza
+change_width=Modifica larghezza
+circulo=Cerchio
+clave=Password
+close=Chiudi
+coincidir_tamanyo=Adatta dimensione
+colocar_a_margenes=Colloca al margine
+colocar_alrededor_seleccionados=Colloca intorno a quanto selezionato
+colocar_alrededor_todos=Colloca intorno a tutto
+colocar_delante=Colloca davanti
+colocar_detras=Colloca dietro
+color=Colore\:
+Color_final=Colore finale
+Color_inicio=Colore iniziale
+color_texto=Colore testo\:
+comentarios=Commenti
+comenzar_edicion=Inizia modifica
+compleja=
+configurar=Configura
+configurar_localizador=Configura localizzatore
+Configurar_localizador=Configura localizzatore ...
+confirmar_borrar=Gli elementi saranno rimossi. Sei sicuro?
+conflicto_de_nombres_de_mapas_al_pegar=Si sta tentando di incollare mappe i cui nomi sono gi\u00e0 presenti nel progetto corrente.
+conflicto_de_nombres_de_tablas_al_pegar=Si sta tentando di incollare tabelle i cui nomi sono gi\u00e0 presenti nel progetto corrente.
+conflicto_de_nombres_de_vistas_al_pegar=Si sta tentando di incollare Viste i cui nomi sono gi\u00e0 presenti nel progetto corrente.
+conflito_de_nombres_de_tablas_al_pegar=Conflitto nei nomi delle tabelle durante la copia.
+conservar_escala_visualizacion=Mantieni scala di visualizzazione
+consulta=Consulta
+Contengan=Contengono
+contraste=Contrasto
+coor_geograficas=Coordinate geografiche
+copiar=Copia
+copy=Copia
+cortar=Taglia
+creation_date=Data creazione
+Crucen_con=Si incrociano con
+cuando_activo=Quando attivo
+cut=Taglia
+Dado_un_campo_de_atributos=Dato un campo di attributi
+debera_introducir_nombres_para_las_vistas_a_pegar=E' necessario inserire nuovi nomi per le viste.
+debera_introducir_nombres_para_los_mapas_a_pegar=E' necessario inserire nuovi nomi per le mappe.
+default_projection=Proiezione predefinita
+default_value=Valore predefinito
+dehacer=Annulla
+delete_field=Elimina campo
+Derecha=Destra
+Derecho=Destro
+desagrupar=Separa
+desagrupar_capas=Separa layers
+desagrupar_graficos=Separa grafici
+descending_order=Ordine decrescente
+descending_order_tooltip=Ordina il campo selezionato in ordine decrescente
+descripcion_de_configuracion_capa_de_anotaciones=<HTML>Per utilizzare valori comuni per tutti i campi del layer lasciare i valori di default. Per personalizzare l'aspetto delle etichette selezionare i campi che contengono i valori corrispondenti.</HTML>
+descripcion_de_crear_capa_de_anotaciones=<HTML>Con questo strumento \u00e8 possibile creare un layer virtuale basato su un layer esistente che permetta di realizzare un'etichettatura avanzata. Modifica la visualizzazione del layer mostrando il valore di uno dei suoi campi.</HTML>
+desde_arriba=Dall'alto\:
+desde_izquierda=Da sinistra\:
+desea_borrar_el_documento=Eliminare i domumenti selezionati?
+desea_borrar_la_capa=Eliminare i layers attivi?
+desea_continuar=Continuare?
+deshacer=Annulla
+desplaza_los_elementos_seleccionados_a_la_derecha=Sposta gli elementi selezionati a destra.
+desplaza_los_elementos_seleccionados_a_la_izquierda=Sposta gli elementi selezionati a sinistra.
+desplaza_los_elementos_seleccionados_al_centro_por_el_eje_x=Sposta gli elementi selezionati al centro dell'asse X.
+desplaza_los_elementos_seleccionados_al_centro_por_el_eje_y=Sposta gli elementi selezionati al centro dell'asse Y.
+desplaza_los_elementos_seleccionados_hacia_abajo=Sposta gli elementi selezionati in basso.
+desplaza_los_elementos_seleccionados_hacia_arriba=Sposta gli elementi selezionati in alto.
+Desplazamiento=Spostamento
+desviacion_tipica=Deviazione standard
+distance_units=Unit\u00e1 di misura
+distribuir=Distribuisci\:
+distribuir_elementos_sobre_todo_el_layout=Disponi elementi sull'intero layout
+distributes_down=Disponi dal basso
+distributes_horizontal=Disponi orizzontalmente
+distributes_left=Disponi a sinistra
+distributes_right=Disponi a destra
+distributes_to_layout_down=Disponi dalla parte inferiore del layout
+distributes_to_layout_horizontal=Disponi orizzontalmente nel layout
+distributes_to_layout_left=Distibuisci a sinistra nel layout
+distributes_to_layout_right=Disponi dalla destra del layout
+distributes_to_layout_up=Disponi dalla parte superiore del layout
+distributes_to_layout_vertical=Disponi verticalmente nel layout
+distributes_up=Disponi dall'alto
+distributes_vertical=Disponi verticalmente
+distribuye_el_espacio_entre_los_elementos_en_horizontal=Equidistanzia in orizzontale.
+distribuye_el_espacio_entre_los_elementos_en_vertical=Equidistanzia in verticale.
+distribuye_los_elementos_seleccionados_de_forma_equidistante_de_abajo_hacia_arriba=Distribuisci uniformemente gli elementi selezionati dal basso verso l'alto.
+distribuye_los_elementos_seleccionados_de_forma_equidistante_de_arriba_hacia_abajo=Distribuisci uniformemente gli elementi selezionati dall'alto verso il basso.
+distribuye_los_elementos_seleccionados_de_forma_equidistante_de_derecha_a_izquierda=Distribuisci uniformemente gli elementi selezionati da destra a sinistra.
+distribuye_los_elementos_seleccionados_de_forma_equidistante_de_izquierda_a_derecha=Distribuisci uniformemente gli elementi selezionati da sinistra a destra.
+distribuye_los_elementos_seleccionados_de_forma_equidistante_y_horizontal=Distribuisci uniformemente gli elementi selezionati in orizzontale.
+distribuye_los_elementos_seleccionados_de_forma_equidistante_y_vertical=Distribuisci uniformemente gli elementi selezionati in verticale.
+divisiones_izquierda=Separazioni a sinistra
+documento=
+documentos_existentes=Documento esistente
+draw_text_only=Disegna il solo testo
+driver=Driver
+Dxffiles=DXF Files
+edicion=Modifica
+editable=Modificabile
+Editar_leyenda=Modifica legenda
+editar_vertices=Modifica vertici
+el_numero_maximo_de_intervalos_para_este_campo_es=Il numero massimo di intervalli per questo campo \u00e8
+Elegir_Color=Seleziona Colore
+Elegir_Fuente=Seleziona Font
+elemento_ya_existe=L'elemento esiste gi\u00e0
+Elementos_seleccionados_de_la_capa=Gli elementi selezionati nel presente layer
+Eliminar=Elimina
+eliminar_capa=Elimina layer
+eliminar_columna=Elimina colonna
+eliminar_extremos=Elimina gli estremi
+eliminar_fila=Elimina riga
+en_el_mapa=Nella mappa\:
+En_metros=In metri
+En_pixels=In pixels
+en_unidades=in unit\u00e0
+Encuadre=Zoom
+Encuadre_Vista=Zoom vista
+enlace_vivo=Collegamento attivo
+Enlazar_a_fichero_de_texto=Collegamento a documento di testo
+Enlazar_a_ficheros_de_imagen=Collegamento a files d'immagine
+equal_intervals=Intevalli uguali
+Error_exportando_SLD=Errore d'esportazione SLD
+Error_guardando_la_leyenda=Errore nel salvare la legenda
+Error_guardando_la_plantilla=Errore nel salvare la tavola
+escala=Scala
+Escala=Scala
+escala_desconocida=Scala sconosciuta
+escala_maxima=Scala massima
+Escala_Maxima=Scala massima
+escala_minima=Scala minima
+Escala_Minima=Scala minima
+escala_usuario=Scala specificata dall'utente
+espaciado_horizontal=Spazitura orizzontale
+espaciado_vertical=Spaziatura verticale
+espacio=Spazio\:
+estadisticas=Statistiche
+este_por_debajo_de_=Al di sotto di
+este_por_encima_de=Al di sopra di
+Esten_contenidos_en=Sono contenuti in
+Etiqueta=Etichetta
+Etiquetados=Etichettati
+etiquetas=Etichette\:
+Etiquetas_estandar=Etichette standard
+Examinar=Cerca...
+export=Esporta
+exportar=Esporta
+exportar_pdf=Esporta come pdf
+exportar_ps=Exporta come ps
+extension=Estensione
+Extent=Estensione
+extents_no_coincidentes=L'estensione della immagine selezionata non coincide con la immagine di origine.
+factor_zoom_incorrecto=Fattore di zoom errato
+fallo_capas=Errore nell'accedere al layer. I layers seguenti saranno eliminati dal progetto
+family=
+fichero=file
+Fichero=File
+fichero_existe=Il file selezionato esiste gi\u00e1 come banda del layer
+fichero_incorrecto=File non corretto
+fichero_ya_existe_seguro_desea_guardarlo=Il file esiste gi\u00e0, continuare?
+field_already_exists=Il campo esiste gi\u00e0
+field_decimal_count=Precisione decimale
+field_default_value=Valore predefinito
+field_length=Lunghezza
+field_manager=Editor dei campi
+field_name=Nome del campo
+field_type=Tipo
+filtro=Filtro
+finish=Termina
+Font=Font
+formato=Formato
+Formato_de_numero_erroneo=Formato del numero errato
+formato_incorrecto=Formato non corretto
+fuente=Font
+General=Generale
+georeferenciado=Georeferenziando
+gestion_encuadre=Gestione zoom
+grados=Gradi\:
+Grados=Gradi
+Graficos=Grafici
+grosor_linea=Spessore linea\:
+group=Raggruppa
+group_graphic_line=Raggruppa bordi grafici
+grupo=Gruppo
+guardado=Salvato
+guardar=Salva
+Guardar=Salvare
+guardar_cambios=Salvare le modifiche
+guardar_como=Salva come...
+guardar_como_plantilla=Salva come tavola
+Guardar_el_zoom_actual=Salva lo zoom attuale
+Guardar_leyenda=Salva legenda
+guardar_proyecto=Salva progetto
+guardar_tooltip=Salva progetto
+Habilitar_etiquetado=Attiva etichetta
+Hiperenlace=Collegamento
+horizontal=Orizzontale
+horizontal_space=Spazio orizzontale
+Identificar_Resultados=Identifica risultati
+Igual_que_la_impresora=Uguale alla stampante
+igual_todos_lados=Uguale per tutti i lati
+imagen=Immagine
+Implimir=
+importar=Importa
+Imprimir=Stampa
+Indexando=Indicizzando...
+Indexando_espacialmente=Indicizzazione spaziale del layer
+indexar_campos=Indicizzare campi
+Inferior=Inferiore
+info=Informazione
+informacion=Informazione
+Informacion=Informazione
+Inicializando=Inizializzando
+initial_warning=<html><b>ATTENZIONE\!</b><br>Versione in via di sviluppo. Pu\u00f2 contenere errori significativi e provocare la corruzione dei file modificati.<br><br>Si consiglia l'uso di una versione stabile di gvSIG per il lavoro quotidiano.</html>
+insert_row=Inserisci riga
+Insertar=Inserisci
+insertar_cajetin=Inserisci griglia
+insertar_circulo=Inserisci Cerchio
+insertar_columna=Inserisci colonna
+insertar_escala=Inserisci Scala
+insertar_fila=Inserisci riga
+insertar_imagen=Inserisci Immagine
+insertar_leyenda=Inserisci Legenda
+insertar_linea=Inserisci Linea
+insertar_norte=Inserire Nord
+insertar_poligono=Inserisci Poligono
+insertar_polilinea=Inserisci polilinea
+insertar_punto=Inserisci Punto
+insertar_rectangulo=Inserisci Rettangolo
+insertar_texto=Inserisci Testo
+insertar_vista=Inserisci Vista
+Intersecten_con=Intersecano con
+Intervalo=Intervallo
+Intervalos=Intervalli
+introduce_nombre=Inserisci nome
+introduzca_el_nombre_de_la_nueva_capa_de_anotaciones=Inserire il nome del nuovo layer di annotazioni
+introduzca_nuevo_nombre_para_la_vista=Inserire il nuovo nome della vista
+invalid_value_for_gap=
+invert_selection=Inverti selezione
+Italic=Corsivo
+Izquierda=Sinistra
+Izquierdo=Sinistro
+join=Unisci
+jpg=JPEG files
+kilometros=Chilometri
+Kilometros=Chilometri
+leyenda=Legenda
+Leyenda=Legenda
+leyenda_campo_unido=Si sta utilizzando un campo dell'unione nella legenda (e/o etichettato). Cambia le legenda prima di togliere l'unione.
+Leyenda_Por_Defecto=Legenda standard
+linea=Linea
+linea_grafica=Bordo grafico
+lineal_directo=Lineare diretto
+link=Collegamento
+Link=Collegamento
+localizador=Localizzatore
+locked_element=Elemento bloccato
+locked_element_it_cannot_be_deleted=Elemento bloccato.\nNon pu\u00f2 essere eliminato.
+locked_element_it_cannot_be_renamed=Elemento bloccato.\nNon pu\u00f2 essere rimosso.
+m/pixel=metri/pixel
+malla_activada=Rete attivata
+manage_fields=Modifica struttura della tabella
+mantener_intervalo=Mantieni intervallo
+map_units=Unit\u00e1 di mappa
+mapa=Mappa
+Mapa=Mappa
+mapas=Mappe
+marco=Bordo
+marco_vista=Bordo vista
+margenes=Margini\:
+mas_de_100_simbolos=Pi\u00fa di 100 simboli non apportano informazioni al piano
+max_length_is=La lunghezza massima \u00e8
+maximo=Massimo
+MDIFrame.quiere_salir=Sei sicuro di voler uscire?
+MDIFrame.salir=Uscire
+media=Media
+medir_area=Misura area
+medir_distancias=Misura distanze
+metadatos=Metadati
+metros=Metri
+Metros=Metri
+Milimetros=Millimetri
+Millas=Miglia
+minimo=Minimo
+modificar=Modifica
+modification_date=Modifica dati
+mostrar_escala_numerica=Mostra scala numerica
+Mostrar_siempre=Mostra sempre
+mostrar_unidades=Mostra unit\u00e1
+move_elements=Sposta elementi
+Muestra_atributos=Mostra gli attributi dei layers selezionati
+muestra_los_elementos_de_la_capa_usando_un_simbolo_por_cada_valor_unico=Mostra gli elementi del layer usando un simbolo per ogni valore unico
+Muestra_los_elementos_de_la_capa_usando_una_gama_de_colores_en_funcion_del_valor_de_un_determinado_campo_de_atributos=Mostra gli elementi del layer usando una gamma di colori in funzione del valore di un determinato campo di attributi
+Muestra_todos_los_elementos_de_una_capa_usando_el_mismo_simbolo=Mostra tutti gli elementi di un layer usando lo stesso simbolo
+natural_intervals=Intervalli naturali
+navegacion=Navigazione
+navegacion_vista=Vista navigazione
+necesita_una_capa_activa=Necessario un layer attivo
+necesita_una_capa_vectorial_activa=Necessario un layer vettoriale attivo
+new_field=Nuovo campo
+new_field_properties=Propriet\u00e0 del nuovo campo
+next=Successivo
+ninguna_impresora_configurada=Nessuna stampante individuata
+Nivel_de_transparencia=Livello di trasparenza
+no=No
+no_activos=Non attivi
+No_de_intervalos=No intervalli
+no_es_posible_aplicar_leyenda_vacia=
+No_ha_sido_posible_realizar_la_operacion=Impossibile terminare l'operazione
+No_mostrar=Non mostrare
+No_mostrar_la_capa_cuando_la_escala=Non mostrare il layer quando la scala
+no_se_pegaran_las_tablas=Non verr\u00e0 incollata alcuna tabella
+no_se_pegaran_las_vistas_del_conflicto=Le viste in conflitto nonsaranno incollate
+No_se_pudo_obtener_la_tabla_de_la_capa=Impossibile ottenere la tabella dal layer
+no_visibles=Non visibili
+nombre=Nome
+Nombre=Nome
+nombre_no_valido=Nome non valido
+Nombre_que_se_le_dara_al_zoom=Nome per lo zoom
+nombre_sesion=Nome sessione
+none=
+none_selected=Nessuna selezione
+normal=Normale
+north=Nord
+Nueva_tabla=Nuova tabella
+nuevo=Nuovo
+Nuevo_conjunto=Nuovo insieme
+nuevo_nombre_para_el_mapa=Scrivere il nuovo nome per il layer
+nuevo_proyecto=Nuovo progetto
+nuevo_tooltip=Crea nuovo progetto
+num_bandas=Numero delle bande
+num_columnas=Numero di colonne
+num_filas=Numero di righe
+Num_intervalos=Numero di intervalli
+numero_decimales_mostrar=Numero decimali
+numero_incorrecto=Numero non corretto
+ok=Accetta
+opacidad=Opacit\u00e1
+operacion_cancelada=Operazione cancellata
+options.layout.paper_properties.landscaped=
+options.layout.paper_properties.paper_direction=
+options.layout.paper_properties.portrait=
+options.layout.paper_properties.title=
+options.view.default_map_overview_back_color=
+options.view.default_selection_color=
+options.view.default_view_back_color=
+options.view.invisible_new_layers=
+options.view.keep_scale_on_resizing=
+orientacion=Orientamento\:
+origen_de_datos=Origine dei dati
+Origen_de_datos=Origine dei dati
+Origen_de_Datos=Origine dei Dati\:
+owner=Proprietario
+paste=Incolla
+paste_elements=Inolla elementi
+path=Percorso
+pdf=
+pegar=Incolla
+pegar_mapas=Incolla mappe
+pegar_vistas=Incolla viste
+Permite_etiquetar_los_elementos_del_mapa_con_el_valor_de_un_determinado_campo=Permette di etichettare gli elementi della mappa con il valore di un determinato campo
+Personalizado=Personalizzato
+personalizar_margenes=Personalizza margini
+Pies=Piedi
+pila_de_comandos=Lista dei comandi
+pixeles=Pixels
+pixels=Pixels
+Plain=Normale
+plantilla=Tavola
+please_insert_new_field_name=Inserire nuovo nome del campo
+png=PNG files
+poligono=Poligono
+polilinea=Polilinea
+poner_capas_a=Poini Layers come...
+por_debajo_de=dal basso\:
+por_encima_de=dall'alto\:
+Por_favor_active_la_capa=Attivare il layer
+posicion_linea=Posiziona della linea
+precision=Precisione
+preparar_pagina=Imposta pagina
+Preparar_pagina=Imposta pagina
+presentacion=Presentazione definitiva
+previsualizacion=Anteprima
+Previsualizacion=Anteprima
+Previsualizacion_de_simbolo=Anteprima simbolo
+propiedad=Propriet\u00e0
+propiedades=Propriet\u00e1
+propiedades_cajetin=Propriet\u00e0 riquadro
+propiedades_capa=Propriet\u00e0 del layer
+propiedades_de_la_capa=Propriet\u00e0 del layer
+Propiedades_escala_grafica=Propriet\u00e1 della scala
+propiedades_grafico=Propriet\u00e1 del grafico
+propiedades_mapa=Propriet\u00e1 della mappa
+propiedades_marco_imagenes=Propriet\u00e1 del bordo dell'Immagine
+propiedades_marco_leyenda=Propriet\u00e1 del bordo della legenda
+propiedades_marco_vista=Propriet\u00e1 del bordo della vista
+propiedades_raster=Propriet\u00e1 del raster
+propiedades_sesion=Propriet\u00e1 di sessione
+propiedades_tabla=Propriet\u00e1 tabella
+Propiedades_texto=Propriet\u00e1 del testo
+propiedades_vista=Propriet\u00e1 della vista
+Proyecciones=Proiezioni
+ps=
+puerto=Porta
+Pulgadas=Pollici
+punto=Punto
+quantile_intervals=Intervalli quantili
+quiere_continuar=Sei sicuro di voler continuare?
+Quitar=Rimuovi
+Quitar_capa=Elimina layer
+quitar_enlaces=Elimina collegamenti
+Quitar_todos=Elimina tutto
+quitar_uniones=Elimina unioni
+rango_de_escalas=Classe delle scale
+Rango_de_escalas=Classe delle scale
+realce=Ottimizzazione
+realmente_desea_guardar=Si vuole salvare realmente?
+recargar=Ricarica
+recorte_colas=Ritaglio degli estremi
+recorte_vista=Ritaglio della vista
+rectangulo=Rettangolo
+recuento=Riconto
+Recuperar_leyenda=Recupera legenda
+Recuperar_y_eliminar_otros_zoom=Recupera ed elimina gli altri zoom
+refrescar=Aggiorna
+rehacer=Ripeti
+rellenar_marco_vista=Riempi il bordo della vista
+relleno=Riempi\:
+remove_elements=Rimuovi elementi
+remove_fields=Rimuovi campi
+remove_row=Rimuovi riga
+remove_rows=Rimuovi righe
+rename_field=Rinomina campo
+renombrar=Rinomina
+reproyectar_aviso=La proiezione del Layer non s' la stessa della Vista.\nAVVISO\: Puo' essere incorretto in alcune trasformazioni.\nLeggere la documentazione.
+reproyectar_pregunta=Riproiettare?
+resolucion_resultado=Qualit\u00e1 di stampa\:
+resto_valores=Resto dei valori
+restore_palette=Ripristina layout di visualizzazione
+rotation_field=Campo di rotazione
+salir=Esci
+salir_tooltip=Esci
+salvar_raster=Salva raster
+Sample=Esempio
+Se_superponen_a=Si sovrappongono a
+Sean_disjuntos_a=Sono diversi da
+Sean_iguales_a=Sono uguali a
+seleccion=Selezione
+seleccion_fuente=Seleziona carattere
+Seleccion_por_capa=Selezione per layer
+selecciona_sistema_de_referencia=Seleziona sistema di riferimento
+Seleccionar=Seleziona
+seleccionar_capas=Seleziona layers
+seleccionar_capas_raster=Seleziona layer raster
+Seleccionar_de_las_capas_activas_los_elementos_que=Selezionare dai layers attivi gli elementi che\:
+Seleccionar_del_conjunto=Seleziona dall'insieme
+Seleccionar_fichero=Seleziona file
+seleccionar_por_poligono=Seleziona con poligono
+seleccionar_por_punto=Seleziona con punto
+seleccionar_por_rectangulo=Seleziona con rettangolo
+seleccionar_todos=Seleziona tutto
+seleccione_campo_enlace=Seleziona il campo da collegare
+seleccione_el_campo_angulo_de_la_capa_de_anotaciones=<HTML>Selezionare il campo contenente il valore d'inclinazione per la rappresentazione delle eichette</HTML>
+seleccione_el_campo_color_de_la_capa_de_anotaciones=<HTML>Selezionare il campo contenente il valore di colore per la rappresentazione delle eichette</HTML>
+seleccione_el_campo_de_texto_que_desea_que_se_utilize_para_mostrar_la_nueva_capa_virtual=<HTML>Selezionare il campo contenente il testo per la rappresentazione delle eichette</HTML>
+seleccione_el_campo_fuente_de_la_capa_de_anotaciones=<HTML>Selezionare il campo contenente il font per la rappresentazione delle eichette</HTML>
+seleccione_el_campo_tamano_de_la_capa_de_anotaciones=<HTML>Selezionare il campo contenente il valore di dimensione del testo per la rappresentazione delle eichette</HTML>
+seleccione_fecha=Seleziona data
+seleccione_tabla_a_enlazar=Seleziona la tabella da collegare
+seleccione_tabla_origen=Seleziona la tabella di origine della unione
+selection_color=Seleziona colore
+selection_up=Sposta selezione in alto
+separator=Separatore
+Servidor=Server
+Shapefile=Shapefile
+show_this_dialog_next_startup=Mostra questa finestra al prossimo avvio
+si=si
+siempre=Sempre
+simbolo=Simbolo
+Simbolo=Simbolo
+Simbolo_unico=Simbolo unico
+Simbologia=Simbologia
+simplificar_leyenda=Semplifica legenda
+simplify=Semplifica
+sin_titulo=Senza titolo
+sincronizar_color_borde_relleno=Sincronizza il colore del bordo pieno\:
+Size=Dimensiona
+sobre_la_barra=Sopra la barra
+Solo_para_capas_vectoriales=Solo per layers vettoriali
+start_edition=Inizia Editing
+statistics=Statistica
+stop_edition=Termina Editing
+Style=Stile
+Subir_capa=Layer s\u00fa
+suma=Somma
+Superior=Superiore
+symbol_selector=
+Tabla=Tabella
+Tabla_de_Atributos=Tabella degli attributi
+tablas=Tabelle
+Tablas=Tabelle
+tag=Tag
+tamano=Dimensione\:
+tamano_metros=Dimensione in metri
+tamano_pagina=Dimensione della pagina
+tamano_posicion=Dimensione e posizione
+tamanyo_borde=Dimensione del margine
+tamanyo_fuente=Dimensione del font
+tamanyo_pagina=Dimensioni della pagina
+tamPixX=Dimensione pixel X
+tamPixY=Dimensione pixel Y
+terminar=Termina
+terminar_edicion=Termina Editing
+texto=Testo
+this_table_is_not_self_editable=Tabella non modificabile
+tipo_dato=Tipo di Dato
+tipo_de_intervalo=Tipo intervallo
+tipo_de_leyenda=Tipo legenda
+tipo_fichero_proyecto=tipo di file di progetto(*.gvsproj)
+tipo_linea=Tipo di linea\:
+tipo_relleno=Tipo di riempimento\:
+tipo_simbolo=Tipo di simbolo\:
+tipos_de_documentos=Tipo di documento
+titulo=Gestore di progetto
+titulo_fframetext=Titolo del campo di testo
+to_annotation=Trasforma in layer annotazioni
+to_palette=Modifica layout visualizzazione
+tooltip_copiar_al_portapapeles=Copia nella clipboard
+tooltip_cortar_al_portapapeles=Taglia nella clipboard
+tooltip_pegar_desde_el_portapapeles=Incolla dalla clipboard
+Toquen=Toccano
+transparencia=Transparenza
+Transparencia=Transparenza
+transparencia_pixel=Trasparenza per pixel
+ungroup=Separa
+unidades=Unit\u00e1\:
+Unidades=Unita'
+untitled=Senza titolo
+url=url
+Usar_indice_espacial=Usa indice spaziale
+usar_marco=Usa margine
+usar_titulo=Usa titolo
+usuario=Utente
+utilizar_margenes_impresora=Utilizza i margini della stampante.
+vacia=Vuota
+Valor=Valore
+Valores=Valori
+Valores_unicos=Valori unici
+varianza=Varianza
+Ventana=Finestra
+ventana_proyecto=Finestra di progetto
+Ver=Mostra
+ver_error_capa=
+ver_tabla_atributos=Mostra tabella degli attributi
+ver_tags=Mostra tags
+ver_tooltip=Mostra la finestra di progetto
+vertical=Verticale
+vertical_space=Spazio verticale
+visible=Visibile
+visibles=Visibili
+Vista=Vista
+vistas=Viste
+visualizacion=Visualizza
+Visualizacion=Visualizza
+visualizar_cuadricula=Visualizza maglia
+warning=Attenzione
+xmax=X massima
+xmin=X minima
+Yardas=Yarde
+ymax=Y massima
+ymin=Y minima
+Zoom_a_la_capa=Zoom al layer
+Zoom_Acercar=Zoom\: avvicina
+Zoom_Alejar=Zoom\: allontana
+Zoom_Completo=Zoom completo
+Zoom_Completo_Vista=Zoom completo della vista
+zoom_in_factor=Fattore di Zoom-in
+Zoom_Mas=Aumenta zoom
+Zoom_Mas_Vista=Aumenta zoom Vista
+Zoom_Menos=Disminuisci zoom
+Zoom_Menos_Vista=Disminuisci zoom vista
+zoom_out_factor=Fattore di Zoom-out
+Zoom_pixel=Zoom a la risoluzione del raster
+Zoom_Previo=Zoom precedente
+Zoom_Real=Zoom 1\:1
+Zoom_Select=Zoom selezionato

Property changes on: tags/v2_0_0_Build_2050/applications/appgvSIG/config/text_it.properties
___________________________________________________________________
Added: svn:eol-style
   + native
Added: svn:keywords
   + Author Date Id Revision

Index: tags/v2_0_0_Build_2050/applications/appgvSIG/config/disid-logo.jpeg
===================================================================
Cannot display: file marked as a binary type.
svn:mime-type = application/octet-stream

Property changes on: tags/v2_0_0_Build_2050/applications/appgvSIG/config/disid-logo.jpeg
___________________________________________________________________
Added: svn:mime-type
   + application/octet-stream

Index: tags/v2_0_0_Build_2050/applications/appgvSIG/config/text.properties
===================================================================
--- tags/v2_0_0_Build_2050/applications/appgvSIG/config/text.properties	(revision 0)
+++ tags/v2_0_0_Build_2050/applications/appgvSIG/config/text.properties	(revision 38653)
@@ -0,0 +1,1078 @@
+#Translations for language [es]
+#Mon Oct 30 09:38:21 CET 2006
+(escala_maxima)=(escala m\u00e1xima)
+(escala_minima)=(escala m\u00ednima)
+1\:=1
+_(Simbolo_unico)=(S\u00edmbolo \u00fanico)
+__proyeccion_actual=Proyecci\u00f3n actual\:
+__redimensionar_texto_escala=Redimensionar el texto a escala con la vista.
+__seleccion_de_fuente=Selecci\u00f3n de fuente
+A0=A0
+A1=A1
+A2=A2
+A3=A3
+A4=A4
+abajo=Abajo
+abrir=Abrir
+abrir_gestor_de_orig_db=Abrir gestor de origen base de datos
+abrir_plantilla=Abrir plantilla
+abrir_proyecto=Abrir proyecto
+abrir_tooltip=Abre un proyecto existente
+Abrir_una_capa=Abrir una capa
+Accion_Predefinida=Acci\u00f3n predefinida
+aceptar=Aceptar
+Aceptar=Aceptar
+acerca_de=Acerca de...
+activar=Activar
+activar_regla=Activar regla
+activos=Activos
+add_connection=A�adir conexi�n
+add_delete_edit_fields=Puede a\u00f1adir, borrar o renombrar los campos
+add_layer=A\u00f1adir capa
+add_rows=A\u00f1adir filas
+adjust_transparency=Ajustar transparencia
+agrupacion=Agrupaci\u00f3n
+agrupar=Agrupar
+agrupar_capas=Agrupar capas
+agrupar_graficos=Agrupar gr\u00e1ficos
+agrupar_linea=Agrupar l\u00ednea gr\u00e1fica con gr\u00e1ficos
+Ajustar_transparencia=Ajustar transparencia
+ajustes_linea_grafica=Ajustes de l\u00ednea gr\u00e1fica
+Al_leer_la_leyenda=Al leer la leyenda
+alias=Alias
+align_center=Alinear centro
+align_down=Alinear bajo
+align_left=Alinear izquierda
+align_right=Alinear derecha
+align_to_layout_center=Alinear centro del layout
+align_to_layout_down=Alinear bajo del layout
+align_to_layout_left=Alinear izquierda del layout
+align_to_layout_right=Alinear derecha del layout
+align_to_layout_up=Alinear arriba del layout
+align_to_layout_vertical_center=Alinear centro del layout verticalmente
+align_up=Alinear arriba
+align_vertical_center=Alinear centro de la vertical
+alineamiento=Alineamiento\:
+alinear=Alinear
+alinear_graficos=Alinear gr\u00e1ficos
+all=Todos
+alta=Alta
+alto=Alto
+altura=Altura\:
+Altura_fija_de_texto=Altura fija de texto
+ambito=\u00c1mbito
+Anadir=A\u00f1adir
+Anadir_al_conjunto=A\u00f1adir al conjunto
+Anadir_capa=A\u00f1adir capa
+Anadir_Capa=A\u00f1adir capa
+anadir_tag=A\u00f1adir etiqueta
+Anadir_todos=A\u00f1adir todos
+ancho=Ancho
+ancho_alto=Ancho x Alto
+anchura=Anchura\:
+Aplicar=Aplicar
+Archivo=Archivo
+arriba=Arriba
+ascending_order=Orden ascendente
+ascending_order_tooltip=Ordena por el campo seleccionado en orden ascendente
+Atributo=Atributo
+automatico=Autom\u00e1tico
+Ayuda=Ayuda
+back=Anterior
+background_color=Color de fondo
+baja=Baja
+Bajar_capa=Bajar capa
+bandas=Bandas
+barra=Barra\:
+base=base
+base_datos=Base de datos
+bmp=Ficheros de tipo bmp
+Bold=Negrita
+borra_seleccion=Borra selecci\u00f3n
+borrador=Borrador
+borrar=Borrar
+box=Cajet\u00edn
+brillo=Brillo
+brillo_y_contraste=Brillo y Contraste
+browse=Examinar
+cajetin=Cajet\u00edn
+Calcular_intervalos=Calcular intervalos
+calidad=Calidad
+cambiar_el_alto_de_los_elementos_seleccionados_hasta_coincidir_con_el_mas_alto=Cambiar el alto de los elementos seleccionados hasta coincidir con el m\u00e1s alto.
+cambiar_el_ancho_de_los_elementos_seleccionados_hasta_coincidir_con_el_mas_ancho=Cambiar el ancho de los elementos seleccionados hasta coincidir con el m\u00e1s ancho.
+cambiar_el_tamano_de_los_elementos_seleccionados_hasta_coincidir_con_el_mas_grande=Cambiar el tama\u00f1o de los elementos seleccionados hasta coincidir con el m\u00e1s grande.
+Cambio_Color=Cambio color
+cambio_nombre=Cambio de nombre
+campo=Campo
+Campo=Campo
+campo_altura_texto=Campo de altura de texto\:
+Campo_de_clasificacion=Campo de clasificaci\u00f3n
+Campo_de_etiquetado=Campo de etiquetado
+Campos=Campos
+cancel=Cancelar
+Cancel=Cancelar
+cancelar=Cancelar
+Cancelar=Cancelar
+Capa=Capa
+Capas=Capas
+Capas_del_localizador=Capas del localizador
+Centimetros=Cent\u00edmetros
+cerrar=Cerrar
+Cerrar=Cerrar
+change=Cambiar
+change_before=Posicionar delante
+change_behind=Posicionar detr\u00e1s
+change_height=Cambiar altura
+change_width=Cambiar anchura
+choose_connection=Elija conexi�n
+choose_color=Seleccionar color
+choose_table=Elija tabla
+circulo=C\u00edrculo
+clave=Clave
+close=Cerrar
+coincidir_tamanyo=Coincidir tama\u00f1o
+colocar_a_margenes=Colocar con referencia a margenes.
+colocar_alrededor_seleccionados=Colocar alrededor de los gr\u00e1ficos seleccionados.
+colocar_alrededor_todos=Colocar alrededor de todos los gr\u00e1ficos.
+colocar_delante=Colocar delante
+colocar_detras=Colocar detr\u00e1s
+color=Color\:
+Color_final=Color final
+Color_inicio=Color de inicio
+color_texto=Color del texto\:
+comentarios=Comentarios
+comenzar_edicion=Comenzar edici\u00c3\u00b3n
+compleja=Compleja
+conectar_db=Est� intentando conectar a la base de datos cuyos par�metros son
+configurar=Configurar
+configurar_localizador=Configurar localizador
+Configurar_localizador=Configurar localizador ...
+confirm_remove=�Est� seguro que quiere eliminarlo?
+confirmar_borrar=\u00bfSeguro que desea borrar el elemento?
+conflicto_de_nombres_de_mapas_al_pegar=Se est\u00e1 intentando pegar mapas cuyos nombres ya existen en el proyecto actual
+conflicto_de_nombres_de_tablas_al_pegar=Se est\u00e1 intentando pegar tablas cuyos nombres ya existen en el proyecto actual
+conflicto_de_nombres_de_vistas_al_pegar=Se est\u00e1 intentando pegar vistas cuyos nombres ya existen en el proyecto actual
+conflito_de_nombres_de_tablas_al_pegar=Conflicto de nombres de tablas al pegar
+connect=Conectar
+connected=Conectado
+connection_error=Error de conexi�n
+connection_name=Nombre de la conexi\u00f3n
+connection_parameters=Par�metros de la conexi�n
+connection_params=Par�metros de la conexi�n
+conservar_escala_visualizacion=Conservar escala de visualizaci\u00f3n
+consulta=Consulta
+Contengan=Contengan
+contraste=Contraste
+coor_geograficas=Coordenadas geogr\u00e1ficas
+copiar=Copiar
+copy=Copiar
+cortar=Cortar
+creation_date=Fecha de creaci\u00f3n
+Crucen_con=Crucen con
+cuando_activo=Cuando activo
+cut=Cortar
+Dado_un_campo_de_atributos=Dado un campo de atributos
+database_name=Nombre de BD
+datum=Datum
+debera_introducir_nombres_para_las_vistas_a_pegar=Deber\u00e1 introducir nombres nuevos para las vistas
+debera_introducir_nombres_para_los_mapas_a_pegar=Deber\u00e1 introducir nombres nuevos para los mapas
+default_projection=Proyecci\u00f3n por defecto
+default_value=Valor por defecto
+dehacer=Deshacer
+delete_field=Borrar campo
+Derecha=Derecha
+Derecho=Derecho
+desagrupar=Desagrupar
+desagrupar_capas=Desagrupar capas
+desagrupar_graficos=Desagrupar gr\u00e1ficos
+descending_order=Orden descendente
+descending_order_tooltip=Ordena por el campo seleccionado en orden descendente
+descripcion_de_configuracion_capa_de_anotaciones=<HTML>Si desea utilizar valores comunes a todos los atributos de la capa deje los valores por defecto. Si desea personalizar como se muestran la etiquetas seleccione los campos que almacenan los valores.</HTML>
+descripcion_de_crear_capa_de_anotaciones=<HTML>Con esta herramienta puede crear una capa virtual basada en una capa ya existente que le permita realizar un etiquetado avanzado. Cambia la visualizaci\u00c3\u00b3n de la capa seleccionada mostrando el valor<br> de uno de sus campos.</HTML>
+desde_arriba=Desde arriba\:
+desde_izquierda=Desde la izquierda\:
+desea_borrar_el_documento=\u00bfEst\u00e1 seguro de que desea borrar los documentos seleccionados?
+desea_borrar_la_capa=\u00bfEst\u00e1 seguro de que desea borrar las capas activas?
+desea_continuar=\u00bfDesea continuar?
+deshacer=Deshacer
+desplaza_los_elementos_seleccionados_a_la_derecha=Desplaza los elementos seleccionados a la derecha.
+desplaza_los_elementos_seleccionados_a_la_izquierda=Desplaza los elementos seleccionados a la izquierda.
+desplaza_los_elementos_seleccionados_al_centro_por_el_eje_x=Desplaza los elementos seleccionados al centro por el eje X.
+desplaza_los_elementos_seleccionados_al_centro_por_el_eje_y=Desplaza los elementos seleccionados al centro por el eje Y.
+desplaza_los_elementos_seleccionados_hacia_abajo=Desplaza los elementos seleccionados hacia abajo.
+desplaza_los_elementos_seleccionados_hacia_arriba=Desplaza los elementos seleccionados hacia arriba.
+Desplazamiento=Desplazamiento
+desviacion_tipica=Desviaci\u00f3n t\u00edpica
+disconnect=Desconectar
+distance_units=Unidades de medida
+distribuir=Distribuir\:
+distribuir_elementos_sobre_todo_el_layout=Distribuir los elementos sobre todo el Layout.
+distributes_down=Distribuye desde abajo
+distributes_horizontal=Distribuye horizontalmente
+distributes_left=Distribuye a la izquierda
+distributes_right=Distribuye a la derecha
+distributes_to_layout_down=Distribuye desde abajo del layout
+distributes_to_layout_horizontal=Distribuye layout horizontalmente
+distributes_to_layout_left=Distribuye izquierda del layout
+distributes_to_layout_right=Distribuye derecha del layout
+distributes_to_layout_up=Distribuye desde arriba del Layout
+distributes_to_layout_vertical=Distribuye layout verticalmente
+distributes_up=Distribuye desde arriba
+distributes_vertical=Distribuye verticalmente
+distribuye_el_espacio_entre_los_elementos_en_horizontal=Distribuye el espacio entre los elementos en horizontal.
+distribuye_el_espacio_entre_los_elementos_en_vertical=Distribuye el espacio entre los elementos en vertical.
+distribuye_los_elementos_seleccionados_de_forma_equidistante_de_abajo_hacia_arriba=Distribuye los elementos seleccionados de forma equidistante de abajo hacia arriba.
+distribuye_los_elementos_seleccionados_de_forma_equidistante_de_arriba_hacia_abajo=Distribuye los elementos seleccionados de forma equidistante de arriba hacia abajo.
+distribuye_los_elementos_seleccionados_de_forma_equidistante_de_derecha_a_izquierda=Distribuye los elementos seleccionados de forma equidistante de derecha a izquierda.
+distribuye_los_elementos_seleccionados_de_forma_equidistante_de_izquierda_a_derecha=Distribuye los elementos seleccionados de forma equidistante de izquierda a derecha.
+distribuye_los_elementos_seleccionados_de_forma_equidistante_y_horizontal=Distribuye los elementos seleccionados de forma equidistante y horizontal.
+distribuye_los_elementos_seleccionados_de_forma_equidistante_y_vertical=Distribuye los elementos seleccionados de forma equidistante y vertical.
+divisiones_izquierda=Divisiones a la izquierda
+documento=Documento
+documentos_existentes=Documentos existentes
+dont_find_the_file=No puedo encontrar el archivo
+do_you_want_to_locate_the_file=\u00bfDesea localizar el archivo?
+draw_text_only=Dibujar s\u00f3lo el texto
+driver=Driver
+driver_error=Error en los drivers.
+Dxffiles=Ficheros .DXF
+edicion=Edici\u00f3n
+edit_settings=Modificar
+editable=Editable
+Editar_leyenda=Editar leyenda
+editar_vertices=Editar V\u00e9rtices
+el_numero_maximo_de_intervalos_para_este_campo_es=El n\u00famero m\u00e1ximo de intervalos para este campo es
+Elegir_Color=Elegir color
+Elegir_Fuente=Elegir fuente
+elemento_ya_existe=El elemento ya existe
+Elementos_seleccionados_de_la_capa=Elementos seleccionados de la capa
+Eliminar=Eliminar
+eliminar_capa=Eliminar capa
+eliminar_columna=Eliminar columna
+eliminar_extremos=Eliminar extremos
+eliminar_fila=Eliminar fila
+en_el_mapa=En el mapa\:
+En_metros=En metros
+En_pixels=En pixels
+en_unidades=en unidades
+Encuadre=Encuadre
+Encuadre_Vista=Encuadre sobre la vista
+enlace_vivo=Enlace vivo
+Enlazar_a_fichero_de_texto=Enlazar a ficheros de texto
+Enlazar_a_ficheros_de_imagen=Enlazar a ficheros de imagen
+Enlazar_a_documento_PDF=Enlazar a documento PDF
+Enlazar_a_imagen_SVG=Enlazar a imagen SVG
+equal_intervals=Intervalos iguales
+Error_exportando_SLD=Error exportando SLD
+Error_guardando_la_leyenda=Error guardando la leyenda
+Error_guardando_la_plantilla=Error guardando la plantilla
+error_saving_table=Error guardando la tabla
+escala=Escala
+Escala=Escala
+escala_desconocida=Escala desconocida
+escala_maxima=Escala m\u00e1xima
+Escala_Maxima=Escala m\u00e1xima
+escala_minima=Escala m\u00ednima
+Escala_Minima=Escala m\u00ednima
+escala_usuario=Escala especificada por el usuario
+espaciado_horizontal=Espaciado horizontal de la malla
+espaciado_vertical=Espaciado vertical de la malla
+espacio=Espacio\:
+estadisticas=Estad\u00edsticas
+este_por_debajo_de_=Est\u00e9 por debajo de
+este_por_encima_de=Est\u00e9 por encima de
+Esten_contenidos_en=Est\u00e9n contenidos en
+Etiqueta=Etiqueta
+Etiquetados=Etiquetados
+etiquetas=Etiquetas\:
+Etiquetas_estandar=Etiquetas est\u00e1ndar
+Examinar=Examinar
+export=Exportar
+exportar=Exportar
+exportar_pdf=Exportar a pdf
+exportar_ps=Exportar a ps
+expresion_error=Error en la expresi�n
+extension=Extensi\u00f3n
+Extent=Extensi\u00f3n
+extents_no_coincidentes=Extensiones no coincidentes
+factor_zoom_incorrecto=Factor de zoom incorrecto.
+fallo_capas=Fallo accediendo a las capas. Las siguientes capas van a ser eliminadas del proyecto
+family=Familia
+fichero=Archivo
+Fichero=Archivo
+fichero_existe=Fichero existe
+fichero_incorrecto=Fichero incorrecto
+fichero_ya_existe_seguro_desea_guardarlo=El fichero ya existe, \u00bfdesea continuar?
+field_already_exists=El campo ya existe
+field_decimal_count=Precisi\u00f3n decimal
+field_default_value=Valor por defecto
+field_length=Tama\u00f1o
+field_manager=Editor de campos
+field_name=Nombre del campo
+field_type=Tipo
+filtro=Filtro
+finish=Finalizar
+Font=Fuente
+formato=Formato
+Formato_de_numero_erroneo=Formato de n\u00famero incorrecto
+formato_incorrecto=Formato incorrecto
+fuente=Fuente
+General=General
+geo_field=Campo geom�trico
+geo_field_not_available=Hubo un problema al obtener campos con geometr�as v�lidos
+geo_field_error=Error con los campos geom�tricos
+geodb_connections=Conexiones a BD espaciales
+geoloc=Geolocalizar
+georeferenciado=Georeferenciado
+gestion_encuadre=Gesti\u00f3n de Encuadres
+gestor_db=Gestor de conexiones a BD espaciales
+get_view=Capturar vista
+grados=Grados\:
+Grados=Grados
+Graficos=Gr\u00e1ficos
+grosor_linea=Grosor de l\u00ednea\:
+group=Agrupar
+group_graphic_line=Agrupar l\u00ednea gr\u00e1fica
+grupo=grupo
+guardado=Guardado en
+guardar=Guardar
+Guardar=Guardar
+guardar_cambios=\u00bfQuiere guardar los cambios?
+guardar_como=Guardar como...
+guardar_como_plantilla=Guardar como plantilla
+Guardar_el_zoom_actual=Guardar el zoom
+Guardar_leyenda=Guardar leyenda
+guardar_proyecto=Guardar proyecto
+guardar_tooltip=Guarda los cambios del proyecto
+Habilitar_etiquetado=Habilitar etiquetado
+Hiperenlace=Hiperenlace
+horizontal=Horizontal
+horizontal_space=Espacio horizontal
+host=M\u00e1quina
+id_error=Error con ID
+id_field=Campo con ID
+id_not_available=ID no disponible
+Identificar_Resultados=Identificar resultados
+Igual_que_la_impresora=Igual que la impresora
+igual_todos_lados=Desplazamiento igual por todos lados.
+imagen=Imagen
+Implimir=Imprimir
+importar=Importar
+Imprimir=Imprimir
+Indexando=Indexando...
+Indexando_espacialmente=Indexando espacialmente la capa
+indexar_campos=Indexar campos
+Inferior=Inferior
+info=Informaci\u00f3n
+informacion=Informaci\u00f3n
+Informacion=Informaci\u00f3n
+Inicializando=Inicializando
+initial_warning=<html><b>\u00a1ATENCI\u00d3N\!</b><br>Versi\u00f3n en desarrollo. Puede contener errores importantes e incluso provocar da\u00f1os en los ficheros editados.<br><br>Si desea trabajar de forma normal con gvSIG, le recomendamos que utilice la \u00faltima versi\u00f3n estable.</html>
+input_output_error=Error de entrada/salida.
+insert_row=Insertar fila
+Insertar=Insertar
+insertar_cajetin=Insertar cajet\u00edn
+insertar_circulo=Insertar c\u00edrculo
+insertar_columna=Insertar columna
+insertar_escala=Insertar escala
+insertar_fila=Insertar fila
+insertar_imagen=Insertar imagen
+insertar_leyenda=Insertar leyenda
+insertar_linea=Insertar l\u00ednea
+insertar_norte=Insertar norte
+insertar_poligono=Insertar Pol\u00edgono
+insertar_polilinea=Insertar polil\u00ednea
+insertar_punto=Insertar punto
+insertar_rectangulo=Insertar rect\u00e1ngulo
+insertar_texto=Insertar texto
+insertar_vista=Insertar vista
+Intersecten_con=Intersecten con
+Intervalo=Intervalo
+Intervalos=Intervalos
+introduce_nombre=Introduce el nuevo nombre
+introduzca_el_nombre_de_la_nueva_capa_de_anotaciones=Introduzca el nombre para la nueva capa de anotaciones
+introduzca_nuevo_nombre_para_la_vista=Introduzca el nuevo nombre para la vista
+invalid_value_for_gap=Valor inv\u00c3\u00a1lido para el intervalo
+invert_selection=Invertir selecci\u00f3n
+Italic=Cursiva
+Izquierda=Izquierda
+Izquierdo=Izquierdo
+join=Unir
+jpg=Ficheros JPEG
+keep_the_order_of_values=Mantener ordenados los valores.
+kilometros=Kil\u00f3metros
+Kilometros=Kil\u00f3metros
+leyenda=Leyenda
+Leyenda=Leyenda
+leyenda_campo_unido=Se est\u00e1 utilizando un campo de la uni\u00f3n en la leyenda (y/o etiquetado). Cambie la leyenda antes de quitar la uni\u00f3n, por favor.
+Leyenda_Por_Defecto=Leyenda por defecto
+linea=L\u00ednea
+linea_grafica=L\u00ednea gr\u00e1fica
+lineal_directo=Lineal directo
+link=Enlace
+Link=Enlace
+localizador=Localizador
+Localizador=Localizador
+locked_element=Elemento bloqueado
+locked_element_it_cannot_be_deleted=Elemento bloqueado.\nNo puede ser borrado.
+locked_element_it_cannot_be_renamed=Elemento bloqueado.\nNo puede ser renombrado.
+m/pixel=metros/pixel
+malla_activada=Malla activada
+manage_fields=Modificar estructura de tabla
+mantener_intervalo=Mantener intervalo
+map_units=Unidades de mapa
+mapa=Mapa
+Mapa=Mapa
+mapas=Mapas
+marco=Marco
+marco_vista=Marco de la vista
+margenes=M\u00e1rgenes\:
+mas_de_100_simbolos=M\u00e1s 100 de s\u00edmbolos no suelen aportar informaci\u00f3n en un plano.
+max_length_is=La longitud m\u00e1xima es
+maximo=M\u00e1ximo
+MDIFrame.quiere_salir=\u00bfEst\u00e1 seguro de que quiere salir?
+MDIFrame.salir=Salir
+media=Media
+medir_area=Medir \u00e1rea
+medir_distancias=Medir distancias
+metadatos=Metadatos
+metros=Metros
+Metros=Metros
+Milimetros=Mil\u00edmetros
+Millas=Millas
+minimo=M\u00ednimo
+modificar=modificar
+modification_date=\u00daltima fecha de modificaci\u00f3n
+mostrar_escala_numerica=Mostrar escala num\u00e9rica
+Mostrar_siempre=Mostrar siempre
+mostrar_unidades=Mostrar unidades
+move_elements=Desplazar elementos
+Muestra_atributos=Muestra los atributos de las capas seleccionadas.
+muestra_los_elementos_de_la_capa_usando_un_simbolo_por_cada_valor_unico=Muestra los elementos de la capa usando un s\u00edmbolo por cada valor \u00fanico
+Muestra_los_elementos_de_la_capa_usando_una_gama_de_colores_en_funcion_del_valor_de_un_determinado_campo_de_atributos=Muestra los elementos de la capa usando una gama de colores en funci\u00f3n del valor de un determinado campo de atributos
+Muestra_todos_los_elementos_de_una_capa_usando_el_mismo_simbolo=Muestra todos los elementos de una capa usando el mismo s\u00edmbolo
+natural_intervals=Intervalos naturales
+navegacion=Navegaci\u00f3n
+navegacion_vista=Navegaci\u00f3n vista
+necesita_una_capa_activa=Necesita una capa activa
+necesita_una_capa_vectorial_activa=Necesita una capa vectorial activa
+new_field=Nuevo campo
+new_field_properties=Propiedades del campo nuevo
+next=Siguiente
+ninguna_capa_seleccionada=Ninguna capa seleccionada
+ninguna_impresora_configurada=Ninguna impresora configurada
+Nivel_de_transparencia=Nivel de transparencia
+no=No
+no_activos=No activos
+No_de_intervalos=N\u00ba de intervalos
+no_es_posible_aplicar_leyenda_vacia=No es posible aplicar la leyenda vac\u00eda.
+no_hay_campo_seleccionado=No hay ning�n campo de clasificaci�n seleccionado
+No_ha_sido_posible_realizar_la_operacion=No ha sido posible realizar la operaci\u00f3n
+no_hay_campo_seleccionado=No hay ning\u00fan campo de clasificaci\u00f3n seleccionado
+No_mostrar=No mostrar la capa cuando la escala
+No_mostrar_la_capa_cuando_la_escala=No mostrar la capa cuando la escala
+no_se_pegaran_las_tablas=No se pegar\u00e1 ninguna tabla
+no_se_pegaran_las_vistas_del_conflicto=No se pegar\u00e1n las vistas con conflicto
+No_se_pudo_obtener_la_tabla_de_la_capa=No se pudo obtener la tabla de la capa
+no_visibles=No visibles
+nombre=Nombre
+Nombre=Nombre
+nombre_no_valido=Nombre no v\u00e1lido
+Nombre_que_se_le_dara_al_zoom=Nombre que se le dar\u00e1 al zoom
+nombre_sesion=Nombre de la sesi\u00f3n
+none=None
+none2=Ninguno
+none_selected=Ninguno seleccionado
+normal=Normal
+north=Norte
+not_GVL_save_question=El formato que ha seleccionado no es propio de gvSIG, se puede utilizar para compartir leyendas con otros programas.\nSi, posteriormente, desea importar de nuevo esta leyenda a gvSIG, le recomendamos que utilice el formato GVL\n o de lo contrario podr�a perder alguna de las caracter�sticas de la leyenda original.
+Nueva_tabla=Nueva tabla
+nuevo=Nuevo
+Nuevo_conjunto=Nuevo conjunto
+nuevo_nombre_para_el_mapa=Introduzca el nuevo nombre para la capa
+nuevo_proyecto=Nuevo proyecto
+nuevo_tooltip=Crea un nuevo proyecto
+num_bandas=N\u00famero de bandas
+num_columnas=N\u00famero de columnas
+num_filas=N\u00famero de filas
+Num_intervalos=N\u00famero de intervalos
+numero_decimales_mostrar=N\u00famero decimales
+numero_incorrecto=N\u00famero incorrecto
+ok=Aceptar
+opacidad=Opacidad
+operacion_cancelada=Operaci\u00f3n cancelada
+options.layout.paper_properties.landscaped=Apaisado
+options.layout.paper_properties.paper_direction=Orientaci\u00f3n del papel
+options.layout.paper_properties.portrait=Normal
+options.layout.paper_properties.title=Propiedades y tama\u00f1o del papel
+options.view.default_map_overview_back_color=Color de fondo del localizador por defecto
+options.view.default_selection_color=Color de la selecci\u00f3n por defecto
+options.view.default_view_back_color=Color de fondo de la vista por defecto
+options.view.invisible_new_layers=A\u00f1adir nuevas capas en modo invisible
+options.view.keep_scale_on_resizing=Mantener escala al redimensionar
+orientacion=Orientaci\u00f3n\:
+origen_de_datos=Origen de datos
+Origen_de_datos=Origen de datos
+Origen_de_Datos=Origen de datos\:
+owner=Propietario
+parse_expresion_error=Error al evaluar la expresi�n.
+paste=Pegar
+paste_elements=Pegar elementos
+path=Ruta
+pdf=Pdf
+pegar=Pegar
+pegar_mapas=Pegar mapas
+pegar_vistas=Pegar vistas
+Permite_etiquetar_los_elementos_del_mapa_con_el_valor_de_un_determinado_campo=Permite etiquetar los elementos del mapa con el valor de un determinado campo
+Personalizado=Personalizado
+personalizar_margenes=Personalizar m\u00e1rgenes
+Pies=Pies
+pila_de_comandos=Pila de comandos
+pixeles=p\u00edxeles
+pixels=p\u00edxeles
+Plain=Normal
+plantilla=plantilla
+please_insert_new_field_name=Por favor inserte nuevo nombre de campo.
+png=Ficheros png
+poligono=Pol\u00edgono
+polilinea=polil\u00ednea
+poner_capas_a=Poner capas a ...
+por_debajo_de=por debajo de\:
+por_encima_de=por encima de\:
+Por_favor_active_la_capa=Por favor active la capa
+port=Puerto
+posicion_linea=Posici\u00f3n de la l\u00ednea
+precision=Precisi\u00f3n
+preparar_pagina=Preparar p\u00e1gina
+Preparar_pagina=Preparar p\u00e1gina
+presentacion=Presentaci\u00f3n
+previsualizacion=Previsualizaci\u00f3n
+Previsualizacion=Previsualizaci\u00f3n
+Previsualizacion_de_simbolo=Previsualizaci\u00f3n de s\u00edmbolo
+projection=Proyecci\u00f3n
+propiedad=Propiedad
+propiedades=Propiedades
+propiedades_cajetin=Propiedades del cajet\u00edn
+propiedades_capa=Propiedades de la capa
+propiedades_de_la_capa=Propiedades de la capa
+Propiedades_escala_grafica=Propiedades de la escala
+propiedades_grafico=Propiedades del gr\u00e1fico
+propiedades_mapa=Propiedades del mapa
+propiedades_marco_imagenes=Propiedades del marco de im\u00e1genes
+propiedades_marco_leyenda=Propiedades del marco de la leyenda
+propiedades_marco_localizador=Propiedades del marco del localizador
+propiedades_marco_vista=Propiedades del marco de la vista
+propiedades_raster=Propiedades del r\u00e1ster
+propiedades_sesion=Propiedades de la sesi\u00f3n
+propiedades_tabla=Propiedades de la tabla
+Propiedades_texto=Propiedades del texto
+propiedades_vista=Propiedades de la vista
+Proyecciones=Proyecciones
+ps=Ps
+puerto=Puerto
+Pulgadas=Pulgadas
+punto=Punto
+quantile_intervals=Intervalos cuantiles
+quiere_continuar=\u00bfEst\u00e1 seguro de que quiere continuar?
+Quitar=Quitar
+Quitar_capa=Quitar capa
+quitar_enlaces=Quitar enlaces
+Quitar_todos=Quitar todos
+quitar_uniones=Quitar uniones
+rango_de_escalas=Rango de escalas
+Rango_de_escalas=Rango de escalas
+realce=Realce
+realmente_desea_guardar=\u00bfRealmente desea guardar?
+recargar=Recargar
+recorte_colas=Recorte de colas
+recorte_vista=Recorte a vista
+rectangulo=Rect\u00e1ngulo
+recuento=Recuento
+Recuperar_leyenda=Recuperar leyenda
+Recuperar_y_eliminar_otros_zoom=Recuperar y eliminar otros zooms
+reference_system=Sistema de Referencia
+refrescar=Refrescar
+rehacer=Rehacer
+rellenar_marco_vista=Rellenar marco de la vista
+relleno=Relleno\:
+remove_elements=Borrar elementos
+remove_fields=Borrar campos
+remove_row=Elimina fila
+remove_rows=Elimina filas
+rename_field=Renombrar Campo
+renombrar=Renombrar
+reproyectar_aviso=La proyecci\u00f3n de la capa no es igual que la de la vista.\nAVISO\: Puede ser inexacto con algunas transformaciones.\nPor favor, lea la documentaci\u00f3n.
+reproyectar_pregunta=\u00bfDesea reproyectar?
+resolucion_resultado=Resoluci\u00f3n del resultado\:
+resto_valores=Resto de valores
+restore_palette=Restaurar paleta
+rotation_field=Campo de rotaci\u00f3n
+salir=Salir
+salir_tooltip=Salir
+salvar_raster=Salvar a raster georreferenciado.
+Sample=Ejemplo
+schema=Esquema
+Se_superponen_a=Se superponen a
+Sean_disjuntos_a=sean disjuntos a
+Sean_iguales_a=sean iguales a
+seleccion=Selecci\u00f3n
+seleccion_fuente=Selecci\u00f3n de fuente
+Seleccion_por_capa=Selecci\u00f3n por capa
+selecciona_sistema_de_referencia=Selecciona sistema de referencia
+Seleccionar=Seleccionar
+seleccionar_capas=Seleccionar capas
+seleccionar_capas_raster=Seleccionar capas r\u00e1ster
+Seleccionar_de_las_capas_activas_los_elementos_que=Seleccionar de las capas activas los elementos que\:
+Seleccionar_del_conjunto=Seleccionar del conjunto
+Seleccionar_fichero=Seleccionar fichero
+seleccionar_por_poligono=Seleccionar por pol\u00edgono
+seleccionar_por_punto=Seleccionar por punto
+seleccionar_por_rectangulo=Seleccionar por rect\u00e1ngulo
+seleccionar_todos=Seleccionar todos
+seleccione_campo_enlace=Seleccione el campo por el que enlazar
+seleccione_el_campo_angulo_de_la_capa_de_anotaciones=<HTML>Seleccione el campo donde se almacenar\u00e1 el \u00e1ngulo con el que se mostrar\u00e1 el texto de la etiqueta</HTML>
+seleccione_el_campo_color_de_la_capa_de_anotaciones=<HTML>Selecione el campo donde se almacenar\u00e1 el color con el que se mostrar\u00e1 la etiqueta</HTML>
+seleccione_el_campo_de_texto_que_desea_que_se_utilize_para_mostrar_la_nueva_capa_virtual=<HTML>Seleccione el campo de texto que desea que se utilice para mostrar en la nueva capa virtual.</HTML>
+seleccione_el_campo_fuente_de_la_capa_de_anotaciones=<HTML>Selecione el campo donde se almacenar\u00e1 la fuente con el que se mostrar\u00e1 de la etiqueta</HTML>
+seleccione_el_campo_tamano_de_la_capa_de_anotaciones=<HTML>Selecione el campo donde se almacenar\u00e1 el alto con el que se mostrar\u00e1 la etiqueta</HTML>
+seleccione_fecha=Seleccione una fecha...
+seleccione_tabla_a_enlazar=Seleccione la tabla a enlazar
+seleccione_tabla_origen=Seleccione la tabla origen de la join
+selection_color=Color de la selecci\u00f3n
+selection_up=Mover arriba la selecci\u00f3n
+semantic_expresion_error=Error sem�ntico en la expresi�n.
+separator=Separador
+server_url=Url del servidor
+Servidor=Servidor
+Shapefile=Shapefile
+Show_grid=Mostrar cuadr�cula
+show_this_dialog_next_startup=Mostrar este di\u00e1logo la pr\u00f3xima vez
+si=s\u00ed
+siempre=Siempre
+simbolo=S\u00edmbolo
+Simbolo=S\u00edmbolo
+Simbolo_unico=S\u00edmbolo \u00fanico
+Simbologia=Simbolog\u00eda
+simplificar_leyenda=Simplificar leyenda
+simplify=Simplificar
+sin_titulo=Sin t\u00edtulo
+sincronizar_color_borde_relleno=Sincronizar el color del borde con el del relleno\:
+Size=Tama\u00f1o
+sobre_la_barra=Sobre la barra
+Solo_para_capas_vectoriales=S\u00f3lo para capas vectoriales
+sorter=Ordenado
+start_edition=Comenzar edici\u00f3n
+statistics=Estad\u00edsticas
+sorter=Ordenado
+specify_table_settings=Especificaci�n de la capa
+sql_restriction=Restricci�n SQL
+stop_edition=Terminar edici\u00f3n
+Style=Estilo
+Subir_capa=Subir capa
+suma=Suma
+Superior=Superior
+symbol_selector=Selector de simbolog\u00eda
+Tabla=Tabla
+Tabla_de_Atributos=Tabla de atributos
+tablas=Tablas
+Tablas=Tablas
+table_fields=Columnas de la tabla
+tag=tag
+tamano=Tama\u00f1o\:
+tamano_metros=Tama\u00f1o en metros
+tamano_pagina=Tama\u00f1o de p\u00e1gina\:
+tamano_posicion=tama\u00f1o/posici\u00f3n
+tamanyo_borde=Tama\u00f1o del borde
+tamanyo_fuente=Tama\u00f1o de fuente
+tamanyo_pagina=Tama\u00f1o de p\u00e1gina
+tamPixX=Tama\u00f1o pixel X
+tamPixY=Tama\u00f1o pixel Y
+terminar=Terminar
+terminar_edicion=Terminar edici\u00f3n
+texto=Texto
+this_table_is_not_self_editable=La tabla no tiene permiso de escritura.
+tipo_dato=Tipo dato
+tipo_de_intervalo=Tipo de intervalo
+tipo_de_leyenda=Tipo de leyenda
+tipo_fichero_proyecto=Fichero de proyecto gvSIG (*.gvsproj)
+tipo_linea=Tipo de L\u00ednea\:
+tipo_relleno=Tipo de Relleno\:
+tipo_simbolo=Tipo de s\u00edmbolo\:
+tipos_de_documentos=Tipos de documentos
+titulo=Gestor de proyectos
+titulo_fframetext=T\u00edtulo del campo de texto
+to_annotation=Transformar a capa de anotaciones
+to_palette=Cambiar a paleta
+tooltip_copiar_al_portapapeles=Copiar al portapapeles
+tooltip_cortar_al_portapapeles=Cortar al cortapapeles
+tooltip_pegar_desde_el_portapapeles=Pegar desde el cortapapeles
+Toquen=toquen
+transparencia=Transparencia
+Transparencia=Transparencia
+transparencia_pixel=Transparencia por pixel
+ungroup=Desagrupar
+unidades=Unidades\:
+Unidades=Unidades\:
+untitled=Sin t\u00edtulo
+url=url
+Usar_indice_espacial=Usar \u00edndice espacial
+usar_marco=Usar marco
+usar_titulo=Usar t\u00edtulo
+user=Usuario
+usuario=Usuario
+utilizar_margenes_impresora=Utilizar m\u00e1rgenes de la impresora.
+vacia=Vac\u00eda
+Valor=Valor
+Valores=Valores
+Valores_unicos=Valores \u00fanicos
+varianza=Varianza
+Ventana=Ventana
+ventana_proyecto=Ventana de proyecto
+Ver=Ver
+ver_error_capa=Ver errores
+ver_tabla_atributos=Ver Tabla de atributos
+ver_tags=Ver
+ver_tooltip=Muestra la ventana de proyecto
+vertical=Vertical
+vertical_space=Espacio vertical
+visible=Visible
+visibles=Visibles
+Vista=Vista
+vistas=Vistas
+visualizacion=Visualizaci\u00f3n
+Visualizacion=Visualizaci\u00f3n
+visualizar_cuadricula=Visualizar malla
+warning=Aviso
+working_area=Zona de inter�s
+xmax=xmax
+xmin=xmin
+Yardas=Yardas
+ymax=ymax
+ymin=ymin
+zone=Huso
+Zoom_a_la_capa=Zoom a la capa
+Zoom_Acercar=Zoom acercar
+Zoom_Alejar=Zoom alejar
+Zoom_Completo=Zoom completo
+Zoom_Completo_Vista=Zoom completo sobre la vista
+zoom_in_factor=Factor zoom m\u00e1s
+Zoom_Mas=Zoom m\u00e1s
+Zoom_Mas_Vista=Zoom m\u00e1s sobre la vista
+Zoom_Menos=Zoom menos
+Zoom_Menos_Vista=Zoom menos sobre la vista
+zoom_out_factor=Factor zoom menos
+Zoom_pixel=Zoom a la resoluci\u00f3n del r\u00e1ster
+Zoom_Previo=Zoom previo
+Zoom_Real=Zoom 1\:1
+Zoom_Select=Zoom a lo seleccionado
+
+categories=Categor�as
+cannot_apply_to_a_non_polygon_layer=No puede aplicarse a una capa no poligonal
+looks_like_too_low_value_for_this_field_may_cause_system_to_run_slow=Parece un valor para el punto demasiado bajo, puede causar que el sistema responda muy lentamente.
+in_layer=en capa
+could_not_setup_legend=No se pudo establecer la leyenda
+labeling_field=Campo de etiquetado
+dot_size=Tama�o de punto
+dot_value=Valor del punto
+outline_color=Color del borde
+densities=Densidades
+high=Alta
+medium=Media
+low=Baja
+Defines_a_dot_density_symbol_based_on_a_field_value=Define una leyenda de densidad de puntos basada en el valor de un determinado campo.
+dot_density=Densidad de puntos
+features=Objetos
+preview=Previsualizaci�n
+quantities=Cantidades
+choose_symbol=Seleccionar s�mbolo
+legend=Leyenda
+label_text_in_the_TOC=Etiqueta que aparecer� en el TOC
+exception_cloning_legend=Excepci�n clonando leyenda.
+character_marker=Marcador de car�cter
+character_marker_symbol=S�mbolo de Marcador de car�cter
+marker_fill=Relleno con marcadores
+choose_marker=Seleccionar marcador
+outline=Borde
+grid=Malla
+Grid_settings=Propiedades malla
+random=Aleatorio
+fill_properties=Propiedades de relleno
+offset=Desplazamiento
+separation=Separaci�n
+simple_fill=Relleno simple
+simple_fill_symbol=S�mbolo de Relleno simple
+fill_color=Color de relleno
+outline_width=Ancho del borde
+trying_to_add_a_non_TypeSymbolEditor_panel=Intentando a�adir un panel que no es de tipo TypeSymbolEditor.
+two_panels_with_the_same_name=Dos paneles con el mismo nombre.
+symbol_property_editor=Editor de propiedades de s�mbolo
+properties=Propiedades
+layers=Capas
+type=Tipo
+units=Unidades
+layer=Layer
+preview_not_available=Vista previa no disponible
+point_symbols=S�mbolos de marcador
+line_symbols=S�mbolos de l�neas
+polygon_symbols=S�mbolos de pol�gono
+shape_type_not_yet_supported=Tipo de shape no soportado todav�a.
+symbol_library=Biblioteca de s�mbolos
+could_not_find_symbol_directory=No se pudo encontral el directorio de la biblioteca s�mbolos
+options=Opciones
+new=Nuevo
+reset=Reiniciar
+save=Guardar
+size=Tama�o
+angle=�ngulo
+width=Ancho
+save_error=Error guardando
+marker_fill=Relleno de marcadores
+marker_fill_symbol=S�mbolo de Relleno de marcadores
+simple_line=S�mbolo de L�nea simple
+simple_marker=Marcador simple
+x_offset=Desplazamiento en X
+y_offset=Desplazamiento en Y
+simple_marker_symbol=S�mbolo de marcador simple
+enter_description=Introduzca una descripci�n
+syntax_error=Error de sintaxis
+error=Error
+label_expression_help=
+expression=Expresi�n
+label_expression_editor=Editor de expresiones de etiqueta
+method=M�todo
+class=Clase
+classes=Clases
+text_string=Texto
+text_symbol=S�mbolo de texto
+font_color=Color de fuente
+enable_labeling=Habilitar etiquetado
+visualization=Visualizaci�n
+label_styles=Estilos de etiqueta
+placement=Colocaci�n
+edit_expression=Editar expresi�n
+SQL_query=Sentencia SQL
+remane_class=Renombrar clase
+delete_class=Eliminar clase
+add_class=A�adir clase
+label_features_in_this_class=Etiquetar entidades dentro de esta clase
+labeling=Etiquetado
+shape_type_error=Tipo de shape err�neo.
+enter_new_name=Introduzca el nuevo nombre
+placement_properties=Propiedades de colocaci�n
+point_settings=Configuraci�n de punto
+line_settings=Configuraci�n de l�nea
+polygon_settings=Configuraci�n de pol�gono
+position=Posici�n
+orientation=Orientaci�n
+parallel=Paralela
+following_line=Siguiendo la l�nea
+perpedicular=Perpendicular
+duplicate_labels=Etiquetas repetidas
+place_one_label_per_feature_part=Situar una etiqueta por cada parte de la entidad
+place_one_label_per_feature=Situar �nicamente una etiqueta por entidad
+remove_duplicate_labels=Eliminar etiquetas repetidas
+label_features_in_the_same_way=Etiquetar todas las entidades de la misma manera
+define_classes_of_features_and_label_each_differently=Definir diferentes clases de entidades y etiquetarlas de manera diferente
+label_only_when_selected=Etiquetar solamente cuando sus entidades est�n seleccionadas
+could_not_apply_legend=No se pudo aplicar la leyenda
+quantity_by_category=Cantidades por categor�a
+graduated_symbols=S�mbolos graduados
+multiple_atributes=M�ltiples atributos
+too_large_border=Borde demasiado grande
+file=Archivo
+file_not_found=Archivo no encontrado
+file_corrupt=Archivo corrupto
+unsupported_legend=Tipo de leyenda no soportado
+symbol=S�mbolo
+from=Desde
+to=Hasta
+template=Plantilla
+generating_intervals=Generando intervalos
+draw_quantities_using_symbol_size_to_show_relative_values=Representa cantidades mediante el tama�o de un s�mbolo mostrando valores relativos.
+could_not_get_shape_type=No se pudo obtener el tipo de geometr�a.
+general=General
+text_field=Texto
+text_height_field=Altura del texto
+rotation_height=Rotaci�n
+accessing_file_structure=Accediendo a la estructura del fichero
+could_not_restore_text_height_field=No se pudo recuperar el campo para la altura del texto.
+could_not_restore_rotation_field=No se pudo recuperar el campo para la rotaci�n del texto.
+could_not_restore_text_field=No se pudo recuperar el campo del texto.
+font=Fuente
+usupported_layer_type=Tipo de capa no soportado
+driver_exception=Excepci�n de driver
+legend_exception=Excepci�n de leyenda
+variation_by=Variaci�n por
+color_ramp=Rampa de color
+value_fields=Campos de valores
+color_field=Campo de colores
+symbol_field=Campo de s�mbolo graduado
+draw_quantities_for_each_category=Representa cantidades para cada categor�a.
+recovering_recordset=Recuperando recordset.
+fields=campos
+user_defined_labels=Etiquetas definidas por el usuario
+label_attributes_defined_in_table=Atributos de la etiqueta definidos en tabla
+current=Actual
+text_symbols=S�mbolos textuales
+label_expression_help=
+fixed_height=Tama�o fijo
+location=Ubicaci�n
+location_along_the_lines=Ubicaci�n a lo largo de las l�neas
+at_best=En la mejor
+at_begin=Al principio
+at_end=Al final
+label-point-priority-help=Prioridad: 0 = Bloqueado, 1 = M�s alta, 3 = M�s baja
+change_location=Cambiar ubicaci�n
+offset_labels_on_top_of_the_points=Situar etiquetas sobre los puntos.
+offset_labels_horizontally=Desplazar etiquetas horizontalmente alrededor del punto.
+always_straight=Siempre recto
+always_horizontal=Siempre horizontal
+orientation_system=Orientaci�n
+line=L�nea
+page=P�gina
+below=Abajo
+on_the_line=Sobre la l�nea
+above=Arriba
+getting_shape_type=Determinando el tipo de shape
+confirmation_dialog=Di�logo de confirmaci�n
+mask=M�scara
+style=Estilo
+halo=Halo
+fill_opacity=Opacidad del relleno
+outline_opacity=Opacidad del borde
+new_style=Nuevo estilo
+editing=Editando
+edit_style=Editar estilo
+tools=Herramientas
+add_text_area=A�adir campo de texto
+offset_label=Desplazar etiqueta
+undefined_for_StylePreviewer_use=No definido para StylePreviewer, por favor use
+instead=en su lugar
+style_library=Biblioteca de estilos
+in_the_world=en el mundo
+in_the_paper=en el papel
+line_style=Estilo de l�nea
+proportional_symbols=S�mbolos proporcionales
+height=Altura
+description=Descripci�n
+merge=Combinar
+symbol_levels=Niveles de simbolog�a
+draw_symbols_in_specified_order=Dibujar s�mbolos usando el orden especificado
+advanced_view=Vista avanzada
+default_view=Vista normal
+picture_file=Fichero imagen
+bitmap_and_svg_image_files=Im�genes SVG y de mapa de bits
+failed_accessing_file=Fallo accediendo al fichero
+picture_marker_symbol=S�mbolo de marcador de imagen
+marker_style=Estilo de marcador
+use_outline=Usar borde
+square=cuadrado
+circle=c�rculo
+diamond=diamante
+triangle=tri�ngulo
+cross=cruz
+draw_quantities_using_symbol_size_to_show_exact_values=Representa cantidades a trav�s del tama�o del s�mbolo mostrando valores exactos
+unable_to_load_legend_from_XMLEntity=Imposible cargar leyenda desde persistencia XMLEntity
+Muestra_todos_s_elementos_de_una_capa_usando_el_mismo_simbolo=Muestra todos los elementos de una capa usando el mismo s�mbolo
+prefer_top_right_all_allowed=Preferiblemente arriba a la derecha, pero permitiendo cualquier posici�n
+in_the_middle=En mitad
+fit_inside_polygon=Acoplar dentro del pol�gono
+color_scheme=Esquema de color
+unrecognized_field_name=Nombre de campo no reconocido
+yes=S�
+error_file_exists=Error, el fichero ya existe
+field=campo
+picture_fill=Relleno de imagen
+picture_fill_symbol=S�mbolo de Relleno de imagen
+scale=Escala
+could_not_open_picture_file=No se pudo abrir el fichero de imagen
+text=Texto
+formatted=Formato
+advanced=Avanzada
+simple_text_symbol=S�mbolo de texto simple
+failed_installing_symbol_editor=No se pudo instalar el editor de s�mbolo
+apply_visual_correction_to_glyph_for_precise_size_and_position=Aplicar correcci�n visual al car�cter para precisi�n en tama�o y posici�n.
+arrow_decorator=Decoraci�n de flecha
+use_decorator=Usar decoraci�n
+arrow_sharpness=Agudeza de la flecha
+number_of_positions=N�mero de posiciones
+flip=Invertir
+flip_all=Invertir todos
+flip_first=Invertir primero
+rotation=Rotaci�n
+rotate_symbol_to_follow_line_angle=Rotar a la pendiente de la l�nea
+keep_symbol_at_fixed_angle_to_page=Inclinaci�n constante respecto de la p�gina
+line_fill=Relleno l�neas
+line_fill_symbol=S�mbolo de relleno de l�neas
+select_a_color_scheme=Seleccione un esquema de color
+scale=Escala
+picture_line_symbol=S�mbolo de L�nea de imagen
+selection_picture_file=Imagen de selecci�n
+marker_line=L�nea de marcadores
+marker_line_symbol=S�mbolo de L�nea de marcadores
+warning_you_must_input_the_exact_name_this_difference_between_capital_letters_and_small_letters=<html>Atenci\u00f3n: Introducir el nombre exacto (se distingue entre may\u00fasculas y min\u00fasculas).</html>
+formato_del_campo_incorrecto=Formato del campo incorrecto
+error_file_not_find_driver=El driver no encuentra un fichero
+error_opening_the_document=Error abriendo el documento
+se_han_producido_los_siguientes_errores_durante_la_carga_de_las_capas=Se han producido los siguientes errores durante la carga de capas.=======
+error_opening_the_document=Error abriendo el documento
+change_symbol=Cambiar s�mbolo
+skipped_symbol_changed_for_layer=Omitido el cambio de s�mbolo para la capa
+failed_computing_intervals=Fallo calculando intervalos
+invalid_interval_count_value=Valor inv�lido para la cuenta de intervalos
+Apply=Aplicar
+getting_layer_shape_type=Obteniendo el tipo de shape
+gradient_fill=Relleno gradiente
+intervals=Intervalos
+percentage=Porcentaje
+gradient_color=Color gradiente
+gradient_fill_symbol=S�mbolo de relleno gradiente
+buffered=Forma del pol�gono
+lineal=Lineal
+circular=Circular
+rectangular=Rectangular
+no_desc=Sin descripci�n
+marker=Marcador
+fill=Relleno
+behavior=Comportamiento
+options.view.behavior.screen_refreshrate=Refresco de pantalla
+line_properties=Propiedades de la l�nea
+join_style=Estilo de la uni�n
+join_bevel=En escuadra
+join_miter=A inglete
+join_round=Redondeada
+end_style=Estilo del extremo
+cap_butt=Sin extremo
+cap_round=Redondeado
+cap_square=Rectangular
+fill_pattern=Patr�n de relleno
+filter_of_Table=Filtro de Tabla
+openning_project=Abriendo un proyecto
+opened_project=Proyecto abierto
+error_openning_project=Error abriendo el proyecto
+writing_project=Guardando el proyecto
+wrote_project=Proyecto guardado
+error_writing_project=Error guardando el proyecto
+couldnt_load_panels_from_extension_point_exception=No se pudieron cargar algunos paneles a partir de un punto de extensi�n:
+panel_loading_exception=Error cargando capa:
+extension_point_load_extension=Error cargando punto de extensi�n:
+unidades_area=Unidades �rea
+Millas_Nauticas=Millas N�uticas
+Acres=Acres
+HanegadasC=HanegadasC
+HanegadasV=HanegadasV
+Hectareas=Hect�reas
+Areas=�reas
+Decimetros=Dec�metros
+_Metadata=Metadatos
+Central_point=Punto central
+Final_point=Punto final
+Insert_point=Punto de inserci�n
+Intersection_point=Punto de intersecci�n
+Medium_point=Punto medio
+Nearest_point=Punto m�s cercano
+Perpendicular_point=Punto perpendicular
+Pixel_point=Ajustado a p�xel
+Quadrant_point=Ajustado a cuadrante
+Tangent_point=Punto tangente
+All_supported=Todos los soportados
\ No newline at end of file

Property changes on: tags/v2_0_0_Build_2050/applications/appgvSIG/config/text.properties
___________________________________________________________________
Added: svn:keywords
   + Author Date Id Revision
Added: svn:eol-style
   + native

Index: tags/v2_0_0_Build_2050/applications/appgvSIG/config/text_zh.properties
===================================================================
--- tags/v2_0_0_Build_2050/applications/appgvSIG/config/text_zh.properties	(revision 0)
+++ tags/v2_0_0_Build_2050/applications/appgvSIG/config/text_zh.properties	(revision 38653)
@@ -0,0 +1,710 @@
+#Translations for language [en]
+#Thu Sep 28 13:19:48 CEST 2006
+(escala_maxima)=(\u6700\u5927\u6bd4\u4f8b)
+(escala_minima)=(\u6700\u5c0f\u6bd4\u4f8b)
+1\:=1
+_(Simbolo_unico)=(\u552f\u4e00\u7b26\u53f7)
+__proyeccion_actual=\u5f53\u524d\u6295\u5f71\:
+__redimensionar_texto_escala=\u5c06\u6587\u5b57\u8c03\u6574\u5230\u89c6\u56fe\u6bd4\u4f8b
+__seleccion_de_fuente=\u5b57\u7b26\u9009\u62e9
+A0=A0
+A1=A1
+A2=A2
+A3=A3
+A4=A4
+abajo=\u4e0b\u9762
+abrir=\u6253\u5f00
+abrir_plantilla=\u6253\u5f00\u6a21\u677f
+abrir_proyecto=\u6253\u5f00\u9879\u76ee
+abrir_tooltip=\u6253\u5f00\u9879\u76ee
+Abrir_una_capa=\u6253\u5f00\u56fe\u5c42
+Accion_Predefinida=\u9884\u5b9a\u4f5c\u7528
+aceptar=\u786e\u5b9a
+Aceptar=\u786e\u5b9a
+acerca_de=\u5173\u4e8e...
+activar=\u6fc0\u6d3b
+activar_regla=\u6fc0\u6d3b\u6807\u5c3a
+activos=\u6d3b\u52a8
+add_delete_edit_fields=\u53ef\u5c06\u5b57\u6bb5\u52a0\u5165\uff0c\u5220\u9664\u6216\u91cd\u547d\u540d
+add_layer=\u6dfb\u52a0\u56fe\u5c42
+add_rows=\u52a0\u884c
+adjust_transparency=\u900f\u660e\u8bbe\u7f6e
+agrupacion=\u5206\u7ec4
+agrupar=\u96c6\u5408
+agrupar_capas=\u96c6\u5408\u56fe\u5c42
+agrupar_graficos=\u96c6\u5408\u56fe\u7247
+agrupar_linea=\u5c06\u76f4\u7ebf\u548c\u56fe\u7247\u5408\u5e76
+Ajustar_transparencia=\u900f\u660e\u8bbe\u7f6e
+ajustes_linea_grafica=\u76f4\u7ebf\u8bbe\u7f6e
+Al_leer_la_leyenda=\u8bfb\u53d6\u56fe\u4f8b\u65f6
+alias=\u522b\u53f7
+align_center=\u5411\u4e2d\u5bf9\u9f50
+align_down=\u5411\u4e0b\u5bf9\u9f50
+align_left=\u5411\u5de6\u5bf9\u9f50
+align_right=\u5411\u53f3\u5bf9\u9f50
+align_to_layout_center=\u5411\u9875\u9762\u4e2d\u95f4\u5bf9\u9f50
+align_to_layout_down=\u5411\u9875\u9762\u4e0b\u9762\u5bf9\u9f50
+align_to_layout_left=\u5411\u9875\u9762\u5de6\u8fb9\u5bf9\u9f50
+align_to_layout_right=\u5411\u9875\u9762\u53f3\u8fb9\u5bf9\u9f50
+align_to_layout_up=\u5411\u9875\u9762\u4e0a\u9762\u5bf9\u9f50
+align_to_layout_vertical_center=\u5411\u9875\u9762\u5782\u7ebf\u4e2d\u95f4\u5bf9\u9f50
+align_up=\u5411\u4e0a\u5bf9\u9f50
+align_vertical_center=\u5411\u5782\u7ebf\u4e2d\u95f4\u5bf9\u9f50
+alineamiento=\u5bf9\u9f50\:
+alinear=\u5bf9\u9f50
+alinear_graficos=\u5bf9\u9f50\u56fe\u7247
+alta=\u9ad8
+alto=\u9ad8\u5ea6
+altura=\u9ad8\u5ea6\:
+Altura_fija_de_texto=\u6587\u5b57\u56fa\u5b9a\u9ad8\u5ea6
+ambito=\u8303\u56f4
+Anadir=\u6dfb\u52a0
+Anadir_al_conjunto=\u6dfb\u52a0\u5230\u7cfb\u5217\u4e2d
+Anadir_capa=\u6dfb\u52a0\u56fe\u5c42
+Anadir_Capa=\u6dfb\u52a0\u56fe\u5c42
+anadir_tag=\u6dfb\u52a0\u6807\u7b7e
+Anadir_todos=\u5168\u90e8\u6dfb\u52a0
+ancho=\u5bbd\u5ea6
+ancho_alto=\u5bbd X \u9ad8
+anchura=\u5bbd\u5ea6\:
+Aplicar=\u5e94\u7528
+Archivo=\u6587\u4ef6
+arriba=\u4e0a\u9762
+ascending_order=\u4e0a\u5347\u987a\u5e8f
+ascending_order_tooltip=\u6309\u5df2\u9009\u5b9a\u5b57\u6bb5\u4e0a\u5347\u987a\u5e8f\u6392\u5217
+Atributo=\u7279\u6027
+automatico=\u81ea\u52a8
+Ayuda=\u5e2e\u52a9
+back=\u540e\u9000
+background_color=\u80cc\u666f\u989c\u8272
+baja=\u4f4e
+Bajar_capa=\u5c06\u56fe\u5c42\u5411\u4e0b\u79fb\u52a8
+bandas=\u6ce2\u6bb5
+barra=\u6bd4\u4f8b\u5c3a\:
+base=\u57fa\u7840
+base_datos=\u6570\u636e\u5e93
+bmp=BMP \u6587\u4ef6
+Bold=\u7c97\u4f53
+borra_seleccion=\u5220\u9664\u9009\u4e2d
+borrador=\u8349\u7a3f
+borrar=\u5220\u9664
+box=\u6846\u5b50
+brillo=\u4eae\u5ea6
+brillo_y_contraste=\u4eae\u5ea6\u548c\u5bf9\u6bd4\u5ea6
+browse=\u6d4f\u89c8
+cajetin=\u6846\u5b50
+Calcular_intervalos=\u8ba1\u7b97\u8ddd\u79bb
+calidad=\u8d28\u91cf
+cambiar_el_alto_de_los_elementos_seleccionados_hasta_coincidir_con_el_mas_alto=\u628a\u5df2\u9009\u5b9a\u90e8\u5206\u7684\u9ad8\u5ea6\u66f4\u6539\u6210\u548c\u6700\u9ad8\u7684\u90a3\u90e8\u5206\u4e00\u81f4\u3002
+cambiar_el_ancho_de_los_elementos_seleccionados_hasta_coincidir_con_el_mas_ancho=\u628a\u5df2\u9009\u5b9a\u90e8\u5206\u7684\u5bbd\u5ea6\u66f4\u6539\u6210\u548c\u6700\u5bbd\u7684\u90a3\u90e8\u5206\u4e00\u81f4\u3002
+cambiar_el_tamano_de_los_elementos_seleccionados_hasta_coincidir_con_el_mas_grande=\u628a\u5df2\u9009\u5b9a\u90e8\u5206\u7684\u5927\u5c0f\u66f4\u6539\u6210\u548c\u6700\u5927\u7684\u90a3\u90e8\u5206\u4e00\u81f4\u3002
+Cambio_Color=\u66f4\u6539\u989c\u8272
+cambio_nombre=\u91cd\u547d\u540d
+campo=\u5b57\u6bb5
+Campo=\u5b57\u6bb5
+campo_altura_texto=\u6587\u672c\u5b57\u6bb5\u7684\u9ad8\u5ea6\:
+Campo_de_clasificacion=\u5b57\u6bb5\u5206\u7ea7
+Campo_de_etiquetado=\u6807\u7b7e\u5b57\u6bb5
+Campos=\u5b57\u6bb5
+cancel=\u53d6\u6d88
+Cancel=\u53d6\u6d88
+cancelar=\u53d6\u6d88
+Cancelar=\u53d6\u6d88
+Capa=\u56fe\u5c42
+Capas=\u56fe\u5c42
+Capas_del_localizador=\u5b9a\u4f4d\u5668\u7684\u56fe\u5c42
+Centimetros=\u5398\u7c73
+cerrar=\u5173\u95ed
+Cerrar=\u5173\u95ed
+change=\u66f4\u6539
+change_before=\u5728\u5bf9\u8c61\u4e4b\u524d
+change_behind=\u5728\u5bf9\u8c61\u4e4b\u540e
+change_height=\u66f4\u6539\u9ad8\u5ea6
+change_width=\u66f4\u6539\u5bbd\u5ea6
+circulo=\u5706\u5f62
+clave=\u5bc6\u7801
+close=\u5173\u95ed
+coincidir_tamanyo=\u4f7f\u5927\u5c0f\u76f8\u914d
+colocar_a_margenes=\u653e\u5728\u4e0e\u8fb9\u8ddd\u6709\u5173\u3002
+colocar_alrededor_seleccionados=\u653e\u5728\u5df2\u9009\u5b9a\u56fe\u7247\u7684\u5468\u56f4\u3002
+colocar_alrededor_todos=\u653e\u5728\u6240\u6709\u56fe\u7247\u7684\u5468\u56f4\u3002
+colocar_delante=\u79fb\u5230\u6700\u4e0a\u9762
+colocar_detras=\u79fb\u5230\u5e95\u5c42
+color=\u989c\u8272\:
+Color_final=\u989c\u8272(\u81f3)
+Color_inicio=\u989c\u8272(\u4ece)
+color_texto=\u5b57\u7b26\u989c\u8272\:
+comentarios=\u6ce8\u91ca
+comenzar_edicion=\u5f00\u59cb\u7f16\u8f91
+compleja=\u590d\u6742
+configurar=\u8bbe\u7f6e
+configurar_localizador=\u5b9a\u4f4d\u5668\u8bbe\u7f6e
+Configurar_localizador=\u5b9a\u4f4d\u5668\u8bbe\u7f6e...
+confirmar_borrar=\u8fd9\u4e2a\u5143\u4ef6\u5c06\u88ab\u5220\u9664\uff0c\u540c\u610f\u5417?
+conflicto_de_nombres_de_mapas_al_pegar=\u60a8\u6b63\u5728\u7c98\u8d34\u5728\u5f53\u524d\u9879\u76ee\u4e0a\u5df2\u6709\u7684\u5730\u56fe\u3002
+conflicto_de_nombres_de_tablas_al_pegar=\u60a8\u6b63\u5728\u7c98\u8d34\u5728\u5f53\u524d\u9879\u76ee\u4e0a\u5df2\u6709\u7684\u8868\u683c\u3002
+conflicto_de_nombres_de_vistas_al_pegar=\u60a8\u6b63\u5728\u7c98\u8d34\u5728\u5f53\u524d\u9879\u76ee\u4e0a\u5df2\u6709\u7684\u89c6\u56fe\u3002
+conflito_de_nombres_de_tablas_al_pegar=\u5728\u7c98\u8d34\u65f6\uff0c\u8868\u683c\u547d\u540d\u53d1\u751f\u51b2\u7a81
+conservar_escala_visualizacion=\u4fdd\u6301\u89c6\u56fe\u6bd4\u4f8b
+consulta=\u67e5\u8be2
+Contengan=\u5305\u62ec
+contraste=\u5bf9\u6bd4\u5ea6
+coor_geograficas=\u5730\u7406\u5750\u6807
+copiar=\u590d\u5236
+copy=\u590d\u5236
+cortar=\u526a\u5207
+creation_date=\u521b\u5efa\u65e5\u671f
+Crucen_con=\u4e8e .. \u4ea4\u53c9
+cuando_activo=\u6fc0\u6d3b\u65f6
+cut=\u526a\u5207
+Dado_un_campo_de_atributos=\u5df2\u77e5\u7684\u7279\u6027\u5b57\u6bb5
+datum=\u8d44\u6599
+debera_introducir_nombres_para_las_vistas_a_pegar=\u60a8\u5fc5\u987b\u7ed9\u89c6\u56fe\u8f93\u5165\u65b0\u547d\u540d
+debera_introducir_nombres_para_los_mapas_a_pegar=\u60a8\u5fc5\u987b\u7ed9\u5730\u56fe\u8f93\u5165\u65b0\u547d\u540d
+default_projection=\u9ed8\u8ba4\u6295\u5f71
+default_value=\u9ed8\u8ba4\u503c
+dehacer=\u64a4\u6d88\u547d\u4ee4
+delete_field=\u5220\u9664\u5b57\u6bb5
+Derecha=\u53f3
+Derecho=\u53f3\u8fb9
+desagrupar=\u53d6\u6d88\u5206\u7ec4
+desagrupar_capas=\u5c06\u56fe\u5c42\u53d6\u6d88\u5206\u7ec4
+desagrupar_graficos=\u53d6\u6d88\u5206\u7ec4
+descending_order=\u4e0b\u964d\u987a\u5e8f
+descending_order_tooltip=\u6309\u5df2\u9009\u5b9a\u5b57\u6bb5\u4e0b\u964d\u987a\u5e8f\u6392\u5217
+descripcion_de_configuracion_capa_de_anotaciones=<HTML>\u60a8\u8981\u662f\u8ba9\u56fe\u5c42\u7684\u6240\u6709\u7279\u6027\u4f7f\u7528\u5171\u540c\u503c\u7684\u8bdd\uff0c\u5c06\u8981\u4fdd\u6301\u9ed8\u8ba4\u503c\u3002\u5982\u679c\u60a8\u8981\u5b9a\u5236\u6807\u7b7e\u8bf7\u9009\u62e9\u6709\u5173\u5b57\u6bb5\u3002</HTML>
+descripcion_de_crear_capa_de_anotaciones=<HTML>\u6b64\u5de5\u5177\u5c06\u53ef\u4ee5\u521b\u5efa\u57fa\u4e8e\u5df2\u6709\u56fe\u5c42\u7684\u65b0\u865a\u62df\u5c42\uff0c\u8fd9\u6837\u5c31\u5141\u8bb8\u60a8\u5236\u4f5c\u9ad8\u7ea7\u6807\u7b7e\u3002 \u6539\u53d8\u5df2\u9009\u5b9a\u56fe\u5c42\u89c6\u56fe\uff0c\u663e\u793a\u4e00\u4e2a\u5b57\u6bb5\u6570\u636e\u3002</HTML>
+desde_arriba=\u4ece\u4e0a\:
+desde_izquierda=\u4ece\u5de6\:
+desea_borrar_el_documento=\u786e\u5b9e\u8981\u628a\u5df2\u9009\u5b9a\u6587\u6863\u5220\u9664\u5417?
+desea_borrar_la_capa=\u786e\u5b9e\u8981\u628a\u6d3b\u52a8\u56fe\u5c42\u5220\u9664\u4e86\u5417?
+desea_continuar=\u8981\u7ee7\u7eed\u5417?
+deshacer=\u64a4\u6d88\u547d\u4ee4
+desplaza_los_elementos_seleccionados_a_la_derecha=\u5c06\u5df2\u9009\u5b9a\u90e8\u5206\u79fb\u5230\u53f3\u8fb9\u3002
+desplaza_los_elementos_seleccionados_a_la_izquierda=\u5c06\u5df2\u9009\u5b9a\u90e8\u5206\u79fb\u5230\u5de6\u8fb9\u3002
+desplaza_los_elementos_seleccionados_al_centro_por_el_eje_x=\u5c06\u5df2\u9009\u5b9a\u90e8\u5206\u5728X\u8f74\u4e0a\u79fb\u5230\u4e2d\u95f4\u3002
+desplaza_los_elementos_seleccionados_al_centro_por_el_eje_y=\u5c06\u5df2\u9009\u5b9a\u90e8\u5206\u5728Y\u8f74\u4e0a\u79fb\u5230\u4e2d\u95f4\u3002
+desplaza_los_elementos_seleccionados_hacia_abajo=\u5c06\u5df2\u9009\u5b9a\u90e8\u5206\u79fb\u5230\u4e0b\u9762\u3002
+desplaza_los_elementos_seleccionados_hacia_arriba=\u5c06\u5df2\u9009\u5b9a\u90e8\u5206\u79fb\u5230\u4e0a\u9762\u3002
+Desplazamiento=\u624b\u5f62\u5de5\u5177
+desviacion_tipica=\u6807\u51c6\u5dee
+distance_units=\u6d4b\u91cf\u5355\u4f4d
+distribuir=\u5206\u914d\:
+distribuir_elementos_sobre_todo_el_layout=\u5c06\u6240\u6709\u90e8\u5206\u6392\u5217\u5728\u6574\u4e2a\u9875\u9762\u3002
+distributes_down=\u6392\u5217\u5230\u4e0b\u9762
+distributes_horizontal=\u6c34\u5e73\u5730\u6392\u5217
+distributes_left=\u6392\u5217\u5230\u5de6\u8fb9
+distributes_right=\u6392\u5217\u5230\u53f3\u8fb9
+distributes_to_layout_down=\u4ece\u9875\u9762\u4e0b\u9762\u6392\u5217
+distributes_to_layout_horizontal=\u4ece\u9875\u9762\u6c34\u5e73\u5730\u6392\u5217
+distributes_to_layout_left=\u4ece\u9875\u9762\u5de6\u8fb9\u6392\u5217
+distributes_to_layout_right=\u4ece\u9875\u9762\u53f3\u8fb9\u6392\u5217
+distributes_to_layout_up=\u4ece\u9875\u9762\u4e0a\u9762\u6392\u5217
+distributes_to_layout_vertical=\u4ece\u9875\u9762\u5782\u76f4\u5730\u6392\u5217
+distributes_up=\u6392\u5217\u5230\u4e0a\u9762
+distributes_vertical=\u5782\u76f4\u5730\u6392\u5217
+distribuye_el_espacio_entre_los_elementos_en_horizontal=\u5c06\u7a7a\u95f4\u5728\u5143\u7d20\u4e4b\u95f4\u6c34\u5e73\u5730\u6392\u5217\u3002
+distribuye_el_espacio_entre_los_elementos_en_vertical=\u5c06\u7a7a\u95f4\u5728\u5143\u7d20\u4e4b\u95f4\u5782\u76f4\u5730\u6392\u5217\u3002
+distribuye_los_elementos_seleccionados_de_forma_equidistante_de_abajo_hacia_arriba=\u5c06\u5df2\u9009\u5b9a\u90e8\u5206\u4ece\u4e0b\u5f80\u4e0a\u8ddd\u79bb\u76f8\u7b49\u5730\u6392\u5217\u3002
+distribuye_los_elementos_seleccionados_de_forma_equidistante_de_arriba_hacia_abajo=\u5c06\u5df2\u9009\u5b9a\u90e8\u5206\u4ece\u4e0a\u5f80\u4e0b\u8ddd\u79bb\u76f8\u7b49\u5730\u6392\u5217\u3002
+distribuye_los_elementos_seleccionados_de_forma_equidistante_de_derecha_a_izquierda=\u5c06\u5df2\u9009\u5b9a\u90e8\u5206\u4ece\u53f3\u5f80\u5de6\u8ddd\u79bb\u76f8\u7b49\u5730\u6392\u5217\u3002
+distribuye_los_elementos_seleccionados_de_forma_equidistante_de_izquierda_a_derecha=\u5c06\u5df2\u9009\u5b9a\u90e8\u5206\u4ece\u5de6\u5f80\u53f3\u8ddd\u79bb\u76f8\u7b49\u5730\u6392\u5217\u3002
+distribuye_los_elementos_seleccionados_de_forma_equidistante_y_horizontal=\u5c06\u5df2\u9009\u5b9a\u90e8\u5206\u4ece\u6c34\u5e73\u7ebf\u4e0a\u8ddd\u79bb\u76f8\u7b49\u5730\u6392\u5217\u3002
+distribuye_los_elementos_seleccionados_de_forma_equidistante_y_vertical=\u5c06\u5df2\u9009\u5b9a\u90e8\u5206\u4ece\u5782\u76f4\u7ebf\u4e0a\u8ddd\u79bb\u76f8\u7b49\u5730\u6392\u5217\u3002
+divisiones_izquierda=\u5de6\u8fb9\u7684\u95f4\u9694
+documento=\u6587\u6863
+documentos_existentes=\u6587\u6863
+draw_text_only=\u53ea\u53ef\u7f16\u5199\u6587\u5b57
+driver=\u9a71\u52a8\u7a0b\u5e8f
+Dxffiles=DXF \u6587\u4ef6
+edicion=\u7f16\u8f91
+editable=\u53ef\u7f16\u8f91\u7684
+Editar_leyenda=\u7f16\u8f91\u56fe\u4f8b
+editar_vertices=\u7f16\u8f91\u9876\u70b9
+el_numero_maximo_de_intervalos_para_este_campo_es=\u5728\u8fd9\u4e2a\u5b57\u6bb5\u91cc\u7684\u6700\u5927\u95f4\u9694\u6570\u662f
+Elegir_Color=\u9009\u62e9\u989c\u8272
+Elegir_Fuente=\u9009\u62e9\u5b57\u4f53
+elemento_ya_existe=\u5143\u4ef6\u5df2\u5b58\u5728
+Elementos_seleccionados_de_la_capa=\u56fe\u5c42\u7684\u5df2\u9009\u5b9a\u5143\u7d20
+Eliminar=\u5220\u9664
+eliminar_capa=\u5220\u9664\u56fe\u5c42
+eliminar_columna=\u5220\u9664\u5217
+eliminar_extremos=\u5220\u9664\u8fb9\u7f18
+eliminar_fila=\u5220\u9664\u884c
+en_el_mapa=\u5728\u5730\u56fe\u91cc\:
+En_metros=\u5398\u7c73
+En_pixels=\u50cf\u7d20
+en_unidades=\u5355\u4f4d
+Encuadre=\u624b\u5f62\u5de5\u5177
+Encuadre_Vista=\u624b\u5f62\u5de5\u5177
+enlace_vivo=\u6d3b\u52a8\u94fe\u63a5
+Enlazar_a_fichero_de_texto=\u8fde\u63a5\u5230\u6587\u672c\u6587\u6863
+Enlazar_a_ficheros_de_imagen=\u8fde\u63a5\u5230\u56fe\u50cf\u6587\u6863
+equal_intervals=\u8ddd\u79bb\u76f8\u7b49
+Error_exportando_SLD=\u8f93\u51fa SLD \u65f6\u51fa\u9519
+Error_guardando_la_leyenda=\u5b58\u76d8\u56fe\u4f8b\u65f6\u51fa\u9519
+Error_guardando_la_plantilla=\u5b58\u76d8\u6a21\u677f\u65f6\u51fa\u9519
+escala=\u6bd4\u4f8b
+Escala=\u6bd4\u4f8b
+escala_desconocida=\u672a\u77e5\u6bd4\u4f8b
+escala_maxima=\u6700\u5927\u6bd4\u4f8b
+Escala_Maxima=\u6700\u5927\u6bd4\u4f8b
+escala_minima=\u6700\u5c0f\u6bd4\u4f8b
+Escala_Minima=\u6700\u5c0f\u6bd4\u4f8b
+escala_usuario=\u7528\u6237\u81ea\u5b9a\u4e49\u6bd4\u4f8b
+espaciado_horizontal=\u7f51\u683c\u6c34\u5e73\u7a7a\u95f4
+espaciado_vertical=\u7f51\u683c\u5782\u76f4\u7a7a\u95f4
+espacio=\u7a7a\u95f4\:
+estadisticas=\u7edf\u8ba1
+este_por_debajo_de_=\u5728...\u4e4b\u4e0b
+este_por_encima_de=\u5728...\u4e4b\u4e0a
+Esten_contenidos_en=\u5305\u542b\u5728...\u4e4b\u4e2d
+Etiqueta=\u6807\u7b7e
+Etiquetados=\u6807\u7b7e
+etiquetas=\u6807\u7b7e\:
+Etiquetas_estandar=\u6807\u51c6\u6807\u7b7e
+Examinar=\u6d4f\u89c8
+export=\u8f93\u51fa
+exportar=\u8f93\u51fa
+exportar_pdf=\u8f93\u51fa\u6210 PDF
+exportar_ps=\u8f93\u51fa\u6210 PS
+extension=\u6269\u5c55\u540d
+Extent=\u56fe\u5c42\u6846\u67b6
+extents_no_coincidentes=\u6269\u5c55\u540d\u4e0d\u4e00\u81f4\u3002
+factor_zoom_incorrecto=\u7f29\u653e\u56e0\u5b50\u4e0d\u6b63\u786e
+fallo_capas=\u8fdb\u5165\u56fe\u5c42\u65f6\u51fa\u9519\u3002\u4e0b\u5217\u56fe\u5c42\u5c06\u88ab\u4ece\u9879\u76ee\u4e2d\u5220\u9664\u3002
+family=\u7cfb\u5217
+fichero=\u6587\u4ef6
+Fichero=\u6587\u4ef6
+fichero_existe=\u6587\u4ef6\u5df2\u5b58\u5728
+fichero_incorrecto=\u6587\u4ef6\u4e0d\u6b63\u786e
+fichero_ya_existe_seguro_desea_guardarlo=\u6587\u4ef6\u5df2\u5b58\u5728\uff0c\u60a8\u8981\u7ee7\u7eed\u5417?
+field_already_exists=\u5b57\u6bb5\u5df2\u5b58\u5728
+field_decimal_count=\u5c0f\u6570\u70b9\u4f4d\u6570
+field_default_value=\u9ed8\u8ba4\u503c
+field_length=\u957f\u5ea6
+field_manager=\u5b57\u6bb5\u7ba1\u7406\u5668
+field_name=\u5b57\u6bb5\u540d\u79f0
+field_type=\u7c7b\u578b
+filtro=\u7b5b\u9009
+finish=\u5b8c\u6210
+Font=\u5b57\u4f53
+formato=\u683c\u5f0f
+Formato_de_numero_erroneo=\u6570\u5b57\u683c\u5f0f\u65e0\u6548
+formato_incorrecto=\u683c\u5f0f\u4e0d\u6b63\u786e
+fuente=\u5b57\u4f53
+General=\u57fa\u672c\u8bbe\u7f6e
+georeferenciado=\u5730\u7406\u53c2\u8003
+gestion_encuadre=\u653e\u5927\u7ba1\u7406\u5668
+grados=\u89d2\u5ea6\:
+Grados=\u89d2\u5ea6
+Graficos=\u56fe\u7247
+grosor_linea=\u76f4\u7ebf\u5bbd\u5ea6\:
+group=\u96c6\u5408
+group_graphic_line=\u96c6\u5408\u76f4\u7ebf
+grupo=\u7ec4
+guardado=\u5b58\u76d8\u5728
+guardar=\u5b58\u76d8
+Guardar=\u5b58\u76d8
+guardar_cambios=\u8981\u4fdd\u5b58\u8fd9\u4e9b\u4fee\u6539\u5417?
+guardar_como=\u53e6\u5b58\u4e3a...
+guardar_como_plantilla=\u53e6\u5b58\u4e3a\u6a21\u677f
+Guardar_el_zoom_actual=\u7f29\u653e\u5b58\u76d8
+Guardar_leyenda=\u4fdd\u5b58\u56fe\u4f8b
+guardar_proyecto=\u9879\u76ee\u5b58\u76d8
+guardar_tooltip=\u9879\u76ee\u5b58\u76d8
+Habilitar_etiquetado=\u663e\u793a\u6807\u7b7e
+Hiperenlace=\u8d85\u7ea7\u94fe\u63a5
+horizontal=\u6c34\u5e73\u7684
+horizontal_space=\u6c34\u5e73\u7684\u7a7a\u95f4
+Identificar_Resultados=\u786e\u8ba4\u7ed3\u679c
+Igual_que_la_impresora=\u8ddf\u6253\u5370\u673a\u4e00\u81f4
+igual_todos_lados=\u5411\u6bcf\u8fb9\u4e00\u81f4\u5730\u79fb\u52a8\u3002
+imagen=\u56fe\u7247
+Implimir=\u6253\u5370
+importar=\u8f93\u5165
+Imprimir=\u6253\u5370
+Indexando=\u7d22\u5f15...
+Indexando_espacialmente=\u56fe\u5c42\u7a7a\u95f4\u7d22\u5f15
+indexar_campos=\u5b57\u6bb5\u7d22\u5f15
+Inferior=\u4e0b
+info=\u4fe1\u606f
+informacion=\u4fe1\u606f
+Informacion=\u4fe1\u606f
+Inicializando=\u542f\u52a8\u4e2d
+initial_warning=<html><b>\u6ce8\u610f\!</b><br>\u5f00\u53d1\u7248\u3002\u53ef\u80fd\u542b\u6709\u91cd\u8981\u9519\u8bef\uff0c\u5e76\u4e14\u6709\u53ef\u80fd\u628a\u5df2\u7f16\u8f91\u597d\u7684\u6587\u4ef6\u4f24\u5bb3\u3002<br><br>\u5411\u60a8\u4eec\u63a8\u8350\u6700\u65b0\u7a33\u5b9a\u7248\u672c\u3002</html>
+insert_row=\u63d2\u5165\u884c
+Insertar=\u63d2\u5165
+insertar_cajetin=\u63d2\u5165\u7f51\u683c
+insertar_circulo=\u63d2\u5165\u5706\u5f62
+insertar_columna=\u63d2\u5165\u5217
+insertar_escala=\u63d2\u5165\u6bd4\u4f8b
+insertar_fila=\u63d2\u5165\u884c
+insertar_imagen=\u63d2\u5165\u56fe\u7247
+insertar_leyenda=\u63d2\u5165\u56fe\u4f8b
+insertar_linea=\u63d2\u5165\u76f4\u7ebf
+insertar_norte=\u63d2\u5165\u5317\u65b9
+insertar_poligono=\u63d2\u5165\u591a\u8fb9\u5f62
+insertar_polilinea=\u63d2\u5165\u6298\u7ebf
+insertar_punto=\u63d2\u5165\u6807\u70b9
+insertar_rectangulo=\u63d2\u5165\u77e9\u5f62
+insertar_texto=\u63d2\u5165\u6587\u5b57
+insertar_vista=\u63d2\u5165\u89c6\u56fe
+Intersecten_con=\u4e8e...\u4ea4\u53c9
+Intervalo=\u95f4\u9694
+Intervalos=\u95f4\u9694
+introduce_nombre=\u8bf7\u8f93\u5165\u65b0\u547d\u540d
+introduzca_el_nombre_de_la_nueva_capa_de_anotaciones=\u8bf7\u7ed9\u65b0\u5efa\u6ce8\u89e3\u5c42\u8f93\u5165\u65b0\u540d\u79f0
+introduzca_nuevo_nombre_para_la_vista=\u8bf7\u7ed9\u65b0\u5efa\u89c6\u56fe\u8f93\u5165\u65b0\u540d\u79f0
+invalid_value_for_gap=\u95f4\u9694\u503c\u65e0\u6548
+invert_selection=\u53cd\u5411\u9009\u62e9
+Italic=\u659c\u4f53
+Izquierda=\u5de6
+Izquierdo=\u5de6\u8fb9
+join=\u8054\u63a5
+jpg=JPEG \u6587\u4ef6
+kilometros=\u516c\u91cc
+Kilometros=\u516c\u91cc
+leyenda=\u56fe\u4f8b
+Leyenda=\u56fe\u4f8b
+leyenda_campo_unido=\u60a8\u5728\u56fe\u4f8b\uff08\u548c/\u6216 \u6807\u7b7e\uff09\u4e0a\u4f7f\u7528\u4e00\u4e2a\u96c6\u5408\u7684\u5b57\u6bb5\u3002\u8bf7\u5728\u53d6\u6d88\u96c6\u5408\u4e4b\u524d\u66f4\u6539\u56fe\u4f8b\u3002
+Leyenda_Por_Defecto=\u9ed8\u8ba4\u56fe\u4f8b
+linea=\u76f4\u7ebf
+linea_grafica=\u76f4\u7ebf
+lineal_directo=\u76f4\u63a5\u7ebf\u65b9\u6cd5
+link=\u94fe\u63a5
+Link=\u94fe\u63a5
+localizador=\u5b9a\u4f4d\u5668
+locked_element=\u5143\u7d20\u88ab\u9501\u5b9a
+locked_element_it_cannot_be_deleted=\u5143\u7d20\u88ab\u9501\u5b9a\u3002\n\u65e0\u6cd5\u5220\u9664\u5b83\u3002
+locked_element_it_cannot_be_renamed=\u5143\u7d20\u88ab\u9501\u5b9a\u3002\n\u65e0\u6cd5\u91cd\u547d\u540d\u3002
+m/pixel=\u7c73/\u50cf\u7d20
+malla_activada=\u6d3b\u52a8\u7f51\u683c
+manage_fields=\u66f4\u6539\u8868\u683c\u7684\u7ed3\u6784
+mantener_intervalo=\u4fdd\u6301\u5dee\u8ddd
+map_units=\u5730\u56fe\u5355\u4f4d
+mapa=\u5730\u56fe
+Mapa=\u5730\u56fe
+mapas=\u5730\u56fe
+marco=\u6846\u67b6
+marco_vista=\u89c6\u56fe\u6846\u67b6
+margenes=\u8fb9\u8ddd\:
+mas_de_100_simbolos=\u6709100\u591a\u4e2a\u7b26\u53f7\uff0c\u4e00\u822c\u5728\u5e73\u9762\u4e0a\u4e0d\u4f1a\u63d0\u4f9b\u4fe1\u606f\u3002
+max_length_is=\u6700\u5927\u957f\u5ea6\u662f
+maximo=\u6700\u5927\u503c
+MDIFrame.quiere_salir=\u60a8\u786e\u5b9e\u8981\u9000\u51fa gvSIG \u5417?
+MDIFrame.salir=\u9000\u51fa
+media=\u5e73\u5747\u503c
+medir_area=\u9762\u79ef\u6d4b\u91cf
+medir_distancias=\u8ddd\u79bb\u6d4b\u91cf
+metadatos=\u5143\u6570\u636e
+metros=\u7c73
+Metros=\u7c73
+Milimetros=\u6beb\u7c73
+Millas=\u82f1\u91cc
+minimo=\u6700\u5c0f\u503c
+modificar=\u66f4\u6539
+modification_date=\u66f4\u6539\u65e5\u671f
+mostrar_escala_numerica=\u663e\u793a\u6570\u5b57\u6bd4\u4f8b
+Mostrar_siempre=\u7f6e\u9876
+mostrar_unidades=\u663e\u793a\u5355\u4f4d
+move_elements=\u90e8\u5206\u79fb\u52a8
+Muestra_atributos=\u663e\u793a\u5df2\u9009\u56fe\u5c42\u7684\u7279\u6027\u3002
+muestra_los_elementos_de_la_capa_usando_un_simbolo_por_cada_valor_unico=\u4f7f\u7528\u6bcf\u4e2a\u5355\u503c\u56fe\u7684\u7b26\u53f7\u663e\u793a\u56fe\u5c42\u5143\u7d20
+Muestra_los_elementos_de_la_capa_usando_una_gama_de_colores_en_funcion_del_valor_de_un_determinado_campo_de_atributos=\u4f7f\u7528\u591a\u79cd\u989c\u8272\u5e76\u6839\u636e\u67d0\u4e00\u4e2a\u5b57\u6bb5\u7279\u6027\u663e\u793a\u56fe\u5c42\u5143\u7d20
+Muestra_todos_los_elementos_de_una_capa_usando_el_mismo_simbolo=\u4f7f\u7528\u552f\u4e00\u7b26\u53f7\u663e\u793a\u56fe\u5c42\u6240\u6709\u5143\u7d20
+natural_intervals=\u81ea\u7136\u5212\u5206 (Natural Break)
+navegacion=\u6d4f\u89c8
+navegacion_vista=\u5728\u89c6\u56fe\u4e0a\u6d4f\u89c8
+necesita_una_capa_activa=\u9700\u8981\u4e00\u5c42\u6d3b\u52a8\u56fe\u5c42
+necesita_una_capa_vectorial_activa=\u9700\u8981\u4e00\u5c42\u6d3b\u52a8 Vectorial \u56fe\u5c42
+new_field=\u65b0\u5efa\u5b57\u6bb5
+new_field_properties=\u65b0\u5efa\u5b57\u6bb5\u5c5e\u6027
+next=\u7ee7\u7eed
+ninguna_impresora_configurada=\u6ca1\u6709\u627e\u5230\u6253\u5370\u673a
+Nivel_de_transparencia=\u900f\u660e\u5ea6
+no=\u5426
+no_activos=\u672a\u6fc0\u6d3b
+No_de_intervalos=\u95f4\u9694\u6570
+no_es_posible_aplicar_leyenda_vacia=\u65e0\u6cd5\u5e94\u7528\u7a7a\u56fe\u4f8b\u3002
+No_ha_sido_posible_realizar_la_operacion=\u64cd\u4f5c\u65e0\u6cd5\u8fd0\u884c\u3002
+No_mostrar=\u4e0d\u663e\u793a\u56fe\u5c42\u5f53\u56fe\u4f8b
+No_mostrar_la_capa_cuando_la_escala=\u4e0d\u663e\u793a\u56fe\u5c42\u5f53\u56fe\u4f8b
+no_se_pegaran_las_tablas=\u5c06\u4e0d\u4f1a\u7c98\u8d34\u4efb\u4f55\u8868\u683c
+no_se_pegaran_las_vistas_del_conflicto=\u4e0d\u4f1a\u7c98\u8d34\u6709\u51b2\u7a81\u89c6\u56fe
+No_se_pudo_obtener_la_tabla_de_la_capa=\u65e0\u6cd5\u4ece\u56fe\u5c42\u4e2d\u63d0\u53d6\u8868\u683c
+no_visibles=\u83ab\u663e\u793a
+nombre=\u6587\u4ef6\u540d
+Nombre=\u6587\u4ef6\u540d
+nombre_no_valido=\u6587\u4ef6\u540d\u65e0\u6548
+Nombre_que_se_le_dara_al_zoom=\u7f29\u653e\u540d
+nombre_sesion=\u540d\u79f0
+none=None
+none_selected=\u672a\u9009\u5b9a
+normal=Normal
+north=\u5317\u65b9
+Nueva_tabla=\u65b0\u5efa\u8868\u683c
+nuevo=\u65b0\u5efa
+Nuevo_conjunto=\u65b0\u5efa\u7cfb\u5217
+nuevo_nombre_para_el_mapa=\u7ed9\u56fe\u5c42\u8f93\u5165\u65b0\u540d\u79f0
+nuevo_proyecto=\u65b0\u5efa\u9879\u76ee
+nuevo_tooltip=\u521b\u5efa\u65b0\u9879\u76ee
+num_bandas=\u6ce2\u6bb5\u6570
+num_columnas=\u5217\u6570
+num_filas=\u884c\u6570
+Num_intervalos=\u95f4\u9694\u6570
+numero_decimales_mostrar=\u5c0f\u6570\u70b9\u4f4d\u6570
+numero_incorrecto=\u6570\u636e\u4e0d\u6b63\u786e
+ok=\u786e\u5b9a
+opacidad=\u4e0d\u900f\u660e\u5ea6
+operacion_cancelada=\u53d6\u6d88\u4efb\u52a1
+options.layout.paper_properties.landscaped=\u6a2a\u5411
+options.layout.paper_properties.paper_direction=\u5bf9\u9f50
+options.layout.paper_properties.portrait=\u7eb5\u5411
+options.layout.paper_properties.title=\u5c5e\u6027
+options.view.default_map_overview_back_color=\u9ed8\u8ba4\u5b9a\u4f4d\u5668\u80cc\u666f
+options.view.default_selection_color=\u9ed8\u8ba4\u9009\u62e9\u989c\u8272
+options.view.default_view_back_color=\u9ed8\u8ba4\u89c6\u56fe\u80cc\u666f
+options.view.invisible_new_layers=\u9690\u5f62\u6a21\u5f0f\u6dfb\u52a0\u56fe\u5c42
+options.view.keep_scale_on_resizing=\u4fdd\u6301\u6bd4\u4f8b
+orientacion=\u65b9\u5411\:
+origen_de_datos=\u6570\u636e\u6765\u6e90
+Origen_de_datos=\u6570\u636e\u6765\u6e90
+Origen_de_Datos=\u6570\u636e\u6765\u6e90\:
+owner=\u6240\u6709\u8005
+paste=\u7c98\u8d34
+paste_elements=\u7c98\u8d34\u5143\u7d20
+path=\u8def\u5f84
+pdf=PDF
+pegar=\u7c98\u8d34
+pegar_mapas=\u7c98\u8d34\u5730\u56fe
+pegar_vistas=\u7c98\u8d34\u89c6\u56fe
+Permite_etiquetar_los_elementos_del_mapa_con_el_valor_de_un_determinado_campo=\u5141\u8bb8\u5229\u7528\u67d0\u5b57\u6bb5\u7684\u6570\u503c\uff0c\u7ed9\u5730\u56fe\u5143\u7d20\u5b89\u7f6e\u6807\u7b7e\u3002
+Personalizado=\u81ea\u5b9a\u4e49
+personalizar_margenes=\u81ea\u5b9a\u4e49\u8fb9\u8ddd
+Pies=\u82f1\u5c3a
+pila_de_comandos=\u547d\u4ee4\u8868
+pixeles=\u50cf\u7d20
+pixels=\u50cf\u7d20
+Plain=\u6b63\u5e38
+plantilla=\u6a21\u677f
+please_insert_new_field_name=\u8bf7\u7ed9\u5b57\u6bb5\u8f93\u5165\u65b0\u540d\u79f0
+png=PNG \u6587\u4ef6
+poligono=\u591a\u8fb9\u5f62
+polilinea=\u6298\u7ebf
+poner_capas_a=\u7ed9...\u6dfb\u52a0\u56fe\u5c42
+por_debajo_de=\u5728...\u4e0b\u9762\:
+por_encima_de=\u5728...\u4e0a\u9762\:
+Por_favor_active_la_capa=\u8bf7\u6fc0\u6d3b\u56fe\u5c42
+posicion_linea=\u76f4\u7ebf\u65b9\u4f4d
+precision=\u7cbe\u786e\u5ea6
+preparar_pagina=\u9875\u9762\u8bbe\u7f6e
+Preparar_pagina=\u9875\u9762\u8bbe\u7f6e
+presentacion=\u6f14\u793a
+previsualizacion=\u9884\u89c8
+Previsualizacion=\u9884\u89c8
+Previsualizacion_de_simbolo=\u7b26\u53f7\u9884\u89c8
+projection=\u6295\u5f71
+propiedad=\u5c5e\u6027
+propiedades=\u5c5e\u6027
+propiedades_cajetin=\u65b9\u6846\u5c5e\u6027
+propiedades_capa=\u56fe\u5c42\u5c5e\u6027
+propiedades_de_la_capa=\u56fe\u5c42\u5c5e\u6027
+Propiedades_escala_grafica=\u6bd4\u4f8b\u5c3a\u5c5e\u6027
+propiedades_grafico=\u56fe\u7247\u5c5e\u6027
+propiedades_mapa=\u5730\u56fe\u5c5e\u6027
+propiedades_marco_imagenes=\u56fe\u7247\u6846\u67b6\u5c5e\u6027
+propiedades_marco_leyenda=\u56fe\u4f8b\u6846\u67b6\u5c5e\u6027
+propiedades_marco_vista=\u89c6\u56fe\u6846\u67b6\u5c5e\u6027
+propiedades_raster=Raster \u5c5e\u6027
+propiedades_sesion=\u5c5e\u6027
+propiedades_tabla=\u8868\u683c\u5c5e\u6027
+Propiedades_texto=\u6587\u5b57\u5c5e\u6027
+propiedades_vista=\u89c6\u56fe\u5c5e\u6027
+Proyecciones=\u6295\u5f71
+ps=PS
+puerto=\u94fe\u63a5\u53e3
+Pulgadas=\u82f1\u5bf8
+punto=\u6807\u70b9
+quantile_intervals=\u5206\u4f4d\u6570\uff08Quantile\uff09
+quiere_continuar=\u60a8\u8981\u7ee7\u7eed\u5417?
+Quitar=\u5220\u9664
+Quitar_capa=\u5220\u9664\u56fe\u5c42
+quitar_enlaces=\u5220\u9664\u94fe\u63a5
+Quitar_todos=\u5168\u90e8\u5220\u9664
+quitar_uniones=\u5220\u9664\u96c6\u5408
+rango_de_escalas=\u6bd4\u4f8b\u503c\u57df
+Rango_de_escalas=\u6bd4\u4f8b\u503c\u57df
+realce=\u589e\u5f3a
+realmente_desea_guardar=\u786e\u5b9a\u8981\u5b58\u76d8\u5417?
+recargar=\u91cd\u8f7d
+recorte_colas=\u526a\u5207\u5c3e\u90e8
+recorte_vista=\u526a\u5207\u6574\u4e2a\u89c6\u56fe
+rectangulo=\u77e9\u5f62
+recuento=\u91cd\u6570
+Recuperar_leyenda=\u8f7d\u5165\u56fe\u4f8b
+Recuperar_y_eliminar_otros_zoom=\u6062\u590d\u548c\u5220\u9664\u5176\u5b83\u7f29\u653e
+reference_system=\u53c2\u8003\u7cfb\u7edf
+refrescar=\u5237\u65b0
+rehacer=\u6062\u590d
+rellenar_marco_vista=\u5145\u586b\u89c6\u56fe\u6846\u67b6
+relleno=\u5145\u586b\:
+remove_elements=\u5220\u9664\u90e8\u5206
+remove_fields=\u5220\u9664\u5b57\u6bb5
+remove_row=\u5220\u9664\u884c
+remove_rows=\u5220\u9664\u884c
+rename_field=\u5b57\u6bb5\u91cd\u65b0\u547d\u540d
+renombrar=\u91cd\u547d\u540d
+reproyectar_aviso=\u56fe\u5c42\u6295\u5f71\u8ddf\u89c6\u56fe\u6295\u5f71\u4e0d\u4e00\u81f4\u3002\n\u6ce8\u610f\: \u5c06\u4f1a\u4e0d\u7cbe\u786e\u5730\u8fd0\u884c\u4e00\u4e9b\u8f6c\u6362\u3002\n\u8bf7\u9605\u8bfb\u8bf4\u660e\u3002
+reproyectar_pregunta=\u60a8\u8981\u91cd\u65b0\u6295\u5f71\u5417?
+resolucion_resultado=\u51b3\u8bae\u7ed3\u679c\:
+resto_valores=\u5176\u5b83\u6570\u636e
+restore_palette=\u56de\u590dpalette
+rotation_field=\u65cb\u8f6c\u5b57\u6bb5
+salir=\u9000\u51fa
+salir_tooltip=\u9000\u51fa gvSIG
+salvar_raster=\u53e6\u5b58\u4e3a Raster
+Sample=\u793a\u4f8b
+Se_superponen_a=\u5728...\u4e0a\u9762
+Sean_disjuntos_a=\u4e0e... \u6563\u5f00
+Sean_iguales_a=\u4e0e...\u4e00\u81f4
+seleccion=\u9009\u62e9
+seleccion_fuente=\u5b57\u4f53\u9009\u62e9
+Seleccion_por_capa=\u6839\u636e\u56fe\u5c42\u9009\u62e9
+selecciona_sistema_de_referencia=\u9009\u62e9\u53c2\u8003\u7cfb\u7edf
+Seleccionar=\u9009\u62e9
+seleccionar_capas=\u9009\u62e9\u56fe\u5c42
+seleccionar_capas_raster=\u9009\u62e9 Raster \u56fe\u5c42
+Seleccionar_de_las_capas_activas_los_elementos_que=\u4ece\u6d3b\u52a8\u56fe\u5c42\u4e2d\u5df2\u9009\u5b9a\u5143\u7d20\:
+Seleccionar_del_conjunto=\u4ece\u7cfb\u5217\u4e2d\u9009\u62e9
+Seleccionar_fichero=\u6587\u4ef6\u9009\u62e9
+seleccionar_por_poligono=\u591a\u8fb9\u5f62\u9009\u62e9
+seleccionar_por_punto=\u6807\u70b9\u9009\u62e9
+seleccionar_por_rectangulo=\u77e9\u5f62\u9009\u62e9
+seleccionar_todos=\u9009\u62e9\u5168\u90e8
+seleccione_campo_enlace=\u9009\u62e9\u94fe\u63a5\u5b57\u6bb5
+seleccione_el_campo_angulo_de_la_capa_de_anotaciones=<HTML>\u9009\u62e9\u4fdd\u5b58\u6807\u7b7e\u6b63\u6587\u89d2\u5ea6\u7684\u5b57\u6bb5\u3002</HTML>
+seleccione_el_campo_color_de_la_capa_de_anotaciones=<HTML>\u9009\u62e9\u4fdd\u5b58\u6807\u7b7e\u989c\u8272\u7684\u5b57\u6bb5\u3002</HTML>
+seleccione_el_campo_de_texto_que_desea_que_se_utilize_para_mostrar_la_nueva_capa_virtual=<HTML>\u9009\u62e9\u5728\u65b0\u5efa\u865a\u62df\u5c42\u4e0a\u663e\u793a\u7684\u6b63\u6587\u5b57\u6bb5\u3002</HTML>
+seleccione_el_campo_fuente_de_la_capa_de_anotaciones=<HTML>\u9009\u62e9\u4fdd\u5b58\u6807\u7b7e\u5b57\u7b26\u7684\u5b57\u6bb5\u3002</HTML>
+seleccione_el_campo_tamano_de_la_capa_de_anotaciones=<HTML>\u9009\u62e9\u4fdd\u5b58\u6807\u7b7e\u9ad8\u5ea6\u7684\u5b57\u6bb5\u3002</HTML>
+seleccione_fecha=\u9009\u62e9\u65e5\u671f...
+seleccione_tabla_a_enlazar=\u9009\u62e9\u94fe\u63a5\u8868\u683c
+seleccione_tabla_origen=\u9009\u62e9\u8054\u63a5\u7684\u6765\u6e90\u8868\u683c
+selection_color=\u9009\u62e9\u989c\u8272
+selection_up=\u5c06\u5df2\u9009\u5b9a\u90e8\u5206\u79fb\u5230\u6700\u4e0a\u9762
+separator=\u5206\u9694\u7b26
+Servidor=\u670d\u52a1\u5668
+Shapefile=Shapefile
+show_this_dialog_next_startup=\u5c06\u6b64\u63d0\u793a\u5728\u4e0b\u6b21\u542f\u52a8\u65f6\u663e\u793a
+si=\u662f
+siempre=\u59cb\u7ec8
+simbolo=\u7b26\u53f7
+Simbolo=\u7b26\u53f7
+Simbolo_unico=\u552f\u4e00\u7b26\u53f7
+Simbologia=\u6807\u7b7e
+simplificar_leyenda=\u7b80\u5316\u56fe\u4f8b
+simplify=\u7b80\u5316
+sin_titulo=\u672a\u547d\u540d
+sincronizar_color_borde_relleno=\u5c06\u8fb9\u6846\u989c\u8272\u4e0e\u5145\u586b\u989c\u8272\u6539\u53d8\u6210\u4e00\u81f4\:
+Size=\u5927\u5c0f
+sobre_la_barra=\u5728\u6bd4\u4f8b\u5c3a\u4e0a
+Solo_para_capas_vectoriales=\u53ea\u53ef\u7528\u4e8e Vectorial \u56fe\u5c42
+start_edition=\u5f00\u59cb\u7f16\u8f91
+statistics=\u7edf\u8ba1
+stop_edition=\u7ed3\u675f\u7f16\u8f91
+Style=\u98ce\u683c
+Subir_capa=\u5c06\u56fe\u5c42\u5f80\u4e0a\u79fb
+suma=\u603b\u8ba1
+Superior=\u4e0a
+symbol_selector=\u7b26\u53f7\u9009\u62e9\u5668
+Tabla=\u8868\u683c
+Tabla_de_Atributos=\u7279\u6027\u8868
+tablas=\u8868\u683c
+Tablas=\u8868\u683c
+tag=\u6807\u7b7e
+tamano=\u5927\u5c0f\:
+tamano_metros=\u5927\u5c0f\uff08\u7c73\uff09
+tamano_pagina=\u9875\u9762\u5927\u5c0f
+tamano_posicion=\u5927\u5c0f/\u4f4d\u7f6e
+tamanyo_borde=\u8fb9\u6846\u5927\u5c0f
+tamanyo_fuente=\u5b57\u4f53\u5927\u5c0f
+tamanyo_pagina=\u9875\u9762\u5927\u5c0f
+tamPixX=X\u8f74\u50cf\u7d20\u5927\u5c0f
+tamPixY=Y\u8f74\u50cf\u7d20\u5927\u5c0f
+terminar=\u5b8c\u6210
+terminar_edicion=\u5b8c\u6210\u7f16\u8f91
+texto=\u6b63\u6587
+this_table_is_not_self_editable=\u8868\u683c\u65e0\u6cd5\u7f16\u8f91
+tipo_dato=\u6570\u636e\u7c7b\u578b
+tipo_de_intervalo=\u95f4\u9694\u7c7b\u578b
+tipo_de_leyenda=\u56fe\u4f8b\u7c7b\u578b
+tipo_fichero_proyecto=gvSIG \u9879\u76ee\u6587\u4ef6(*.gvsproj)
+tipo_linea=\u76f4\u7ebf\u7c7b\u578b\:
+tipo_relleno=\u5145\u586b\u7c7b\u578b\:
+tipo_simbolo=\u7b26\u53f7\u7c7b\u578b\:
+tipos_de_documentos=\u6587\u6863\u7c7b\u578b
+titulo=\u9879\u76ee\u7ba1\u7406\u5668
+titulo_fframetext=\u6b63\u6587\u5b57\u6bb5\u6807\u9898
+to_annotation=\u6539\u53d8\u4e3a\u6ce8\u89e3\u5c42
+to_palette=\u6539\u53d8\u4e3a palette
+tooltip_copiar_al_portapapeles=\u590d\u5236\u5230\u526a\u8d34\u677f\u4e0a
+tooltip_cortar_al_portapapeles=\u526a\u5207\u5230\u526a\u8d34\u677f\u4e0a
+tooltip_pegar_desde_el_portapapeles=\u4ece\u526a\u8d34\u677f\u91cc\u7c98\u8d34
+Toquen=\u4e0e...\u63a5\u89e6
+transparencia=\u900f\u660e\u5ea6
+Transparencia=\u900f\u660e\u5ea6
+transparencia_pixel=\u6bcf\u4e00\u50cf\u7d20\u7684\u900f\u660e\u5ea6
+ungroup=\u53d6\u6d88\u5206\u7ec4
+unidades=\u5355\u4f4d\:
+Unidades=\u5355\u4f4d\: 
+untitled=\u672a\u547d\u540d
+url=\u94fe\u63a5
+Usar_indice_espacial=\u4f7f\u7528\u7a7a\u95f4\u7d22\u5f15
+usar_marco=\u4f7f\u7528\u6846\u67b6
+usar_titulo=\u4f7f\u7528\u6807\u9898
+usuario=\u7528\u6237
+utilizar_margenes_impresora=\u4f7f\u7528\u6253\u5370\u8fb9\u8ddd
+vacia=\u7a7a\u7684
+Valor=\u6570\u636e
+Valores=\u6570\u636e
+Valores_unicos=\u5355\u503c\u56fe
+varianza=\u65b9\u5dee
+Ventana=\u7a97\u53e3
+ventana_proyecto=\u9879\u76ee\u7a97\u53e3
+Ver=\u663e\u793a
+ver_error_capa=\u663e\u793a\u9519\u8bef
+ver_tabla_atributos=\u67e5\u770b\u7279\u6027\u8868
+ver_tags=\u663e\u793a
+ver_tooltip=\u663e\u793a\u9879\u76ee\u7a97\u53e3
+vertical=\u5782\u76f4\u7684
+vertical_space=\u5782\u76f4\u7a7a\u95f4
+visible=\u660e\u663e\u7684
+visibles=\u660e\u663e\u7684
+Vista=\u89c6\u56fe
+vistas=\u89c6\u56fe
+visualizacion=\u89c6\u56fe\u4e2d
+Visualizacion=\u89c6\u56fe\u4e2d
+visualizar_cuadricula=\u663e\u793a\u7f51\u683c
+warning=\u8b66\u544a
+xmax=X\u8f74\u6700\u5927\u503c
+xmin=X\u8f74\u6700\u5c0f\u503c
+Yardas=\u7801
+ymax=Y\u8f74\u6700\u5927\u503c
+ymin=Y\u8f74\u6700\u5c0f\u503c
+zone=\u533a\u57df
+Zoom_a_la_capa=\u56fe\u5c42\u653e\u5927
+Zoom_Acercar=\u653e\u5927
+Zoom_Alejar=\u7f29\u5c0f
+Zoom_Completo=\u5168\u90e8\u7f29\u653e
+Zoom_Completo_Vista=\u5168\u90e8\u7f29\u653e
+zoom_in_factor=\u653e\u5927\u56e0\u5b50
+Zoom_Mas=\u653e\u5927
+Zoom_Mas_Vista=\u89c6\u56fe\u6846\u67b6\u653e\u5927
+Zoom_Menos=\u7f29\u5c0f
+Zoom_Menos_Vista=\u89c6\u56fe\u6846\u67b6\u7f29\u5c0f
+zoom_out_factor=\u7f29\u5c0f\u56e0\u5b50
+Zoom_pixel=Raster \u56fe\u5f62\u6700\u4f73\u7f29\u653e
+Zoom_Previo=\u4e0a\u4e00\u4e2a\u7f29\u653e
+Zoom_Real=1\:1 \u7f29\u653e
+Zoom_Select=\u7f29\u653e\u5df2\u9009\u5b9a\u90e8\u5206

Property changes on: tags/v2_0_0_Build_2050/applications/appgvSIG/config/text_zh.properties
___________________________________________________________________
Added: svn:keywords
   + Author Date Id Revision
Added: svn:eol-style
   + native

Index: tags/v2_0_0_Build_2050/applications/appgvSIG/config/text_ca.properties
===================================================================
--- tags/v2_0_0_Build_2050/applications/appgvSIG/config/text_ca.properties	(revision 0)
+++ tags/v2_0_0_Build_2050/applications/appgvSIG/config/text_ca.properties	(revision 38653)
@@ -0,0 +1,717 @@
+#Translations for language [ca]
+#Mon Oct 30 09:38:21 CET 2006
+(escala_maxima)=(escala m\u00e0xima)
+(escala_minima)=(escala m\u00ednima)
+1\:=
+_(Simbolo_unico)=(S\u00edmbol \u00fanic)
+__proyeccion_actual=Projecci\u00f3 actual\:
+__redimensionar_texto_escala=Redimensione el text a escala amb la vista
+__seleccion_de_fuente=Selecci\u00f3 de font
+A0=A0
+A1=A1
+A2=A2
+A3=A3
+A4=A4
+abajo=Avall
+abrir=Obrir
+abrir_plantilla=Obrir plantilla
+abrir_proyecto=Obrir projecte
+abrir_tooltip=Obri un projecte existent
+Abrir_una_capa=Obrir una capa
+Accion_Predefinida=Acci\u00f3 predefinida
+aceptar=Acceptar
+Aceptar=Acceptar
+acerca_de=Sobre...
+activar=Activar
+activar_regla=Activar regla
+activos=Actius
+add_delete_edit_fields=
+add_layer=Afegir capa
+add_rows=
+adjust_transparency=Ajustar transpar\u00e8ncia
+agrupacion=
+agrupar=Agrupar
+agrupar_capas=Agrupar capes
+agrupar_graficos=Agrupar gr\u00e0fics
+agrupar_linea=Agrupar l\u00ednia gr\u00e0fica amb gr\u00e0fics
+Ajustar_transparencia=Ajustar transpar\u00e8ncia
+ajustes_linea_grafica=Ajustos de l\u00ednia gr\u00e0fica
+Al_leer_la_leyenda=En llegir la llegenda
+alias=\u00c0lies
+align_center=
+align_down=
+align_left=
+align_right=
+align_to_layout_center=
+align_to_layout_down=
+align_to_layout_left=
+align_to_layout_right=
+align_to_layout_up=
+align_to_layout_vertical_center=
+align_up=
+align_vertical_center=
+alineamiento=Alineament\:
+alinear=Alinear
+alinear_graficos=Alinear gr\u00e0fics
+alta=Alta
+alto=Alt
+altura=Altura\:
+Altura_fija_de_texto=Altura fixa de text
+ambito=\u00c0mbit
+Anadir=Afegir
+Anadir_al_conjunto=Afegir al conjunt
+Anadir_capa=Afegir capa
+Anadir_Capa=Afegir capa
+anadir_tag=
+Anadir_todos=Afegir tots
+ancho=Ample
+ancho_alto=Amplada al\u00e7ada
+anchura=Ampl\u00e0ria\:
+Aplicar=Aplicar
+Archivo=Fitxer
+arriba=Amunt
+ascending_order=Orde ascendent
+ascending_order_tooltip=S'ordena pel camp seleccionat en orde ascendent
+Atributo=Atribut
+automatico=Autom\u00e0tic
+Ayuda=Ajuda
+back=Anterior
+background_color=Color de fons
+baja=Baixa
+Bajar_capa=Baixar capa
+bandas=Bandes
+barra=Barra
+base=base
+base_datos=Base de dades
+bmp=Fitxers de tipus bmp
+Bold=
+borra_seleccion=Esborrar selecci\u00f3
+borrador=Esborrany
+borrar=Esborrar
+box=
+brillo=Brillantor
+brillo_y_contraste=Brillantor i contrast
+browse=Examinar
+cajetin=
+Calcular_intervalos=Calcular intervals
+calidad=Qualitat
+cambiar_el_alto_de_los_elementos_seleccionados_hasta_coincidir_con_el_mas_alto=
+cambiar_el_ancho_de_los_elementos_seleccionados_hasta_coincidir_con_el_mas_ancho=
+cambiar_el_tamano_de_los_elementos_seleccionados_hasta_coincidir_con_el_mas_grande=
+Cambio_Color=Canvi color
+cambio_nombre=Canvi de nom
+campo=Camp
+Campo=Camp
+campo_altura_texto=Camp d'altura de text\:
+Campo_de_clasificacion=Camp de classificaci\u00f3
+Campo_de_etiquetado=Camp d'etiquetat
+Campos=Camps
+cancel=Cancel\u00b7lar
+Cancel=Cancel\u00b7lar
+cancelar=Cancel\u00b7lar
+Cancelar=Cancel\u00b7lar
+Capa=Capa
+Capas=Capes
+Capas_del_localizador=Capes del localitzador
+Centimetros=Cent\u00edmetres
+cerrar=Tancar
+Cerrar=Tancar
+change=
+change_before=
+change_behind=
+change_height=
+change_width=Cambiar ampl\u00e0ria
+circulo=Cercle
+clave=Clau
+close=Tancar
+coincidir_tamanyo=
+colocar_a_margenes=Col\u00b7locar amb refer\u00e8ncia a m\u00e0rgens.
+colocar_alrededor_seleccionados=Col\u00b7locar al voltant dels gr\u00e0fics seleccionats.
+colocar_alrededor_todos=Col\u00b7locar al voltant de tots els gr\u00e0fics.
+colocar_delante=Col\u00b7locar davant
+colocar_detras=Col\u00b7locar darrere
+color=Color\:
+Color_final=Color final
+Color_inicio=Color d'inici
+color_texto=Color del text\:
+comentarios=Comentaris
+comenzar_edicion=
+compleja=
+configurar=Configurar
+configurar_localizador=Configurar localitzador
+Configurar_localizador=Configurar localitzador ...
+confirmar_borrar=Est\u00e0 segur que desitja esborrar l'element?
+conflicto_de_nombres_de_mapas_al_pegar=
+conflicto_de_nombres_de_tablas_al_pegar=
+conflicto_de_nombres_de_vistas_al_pegar=
+conflito_de_nombres_de_tablas_al_pegar=
+conservar_escala_visualizacion=Conservar escala de visualitzaci\u00f3
+consulta=Consulta
+Contengan=Ontinguen
+contraste=Contrast
+coor_geograficas=Coordenades geogr\u00e0fiques
+copiar=Copiar
+copy=Copiar
+cortar=Retallar
+creation_date=Data de creaci\u00f3
+Crucen_con=Encreuen amb
+cuando_activo=Si est\u00e0 Actiu
+cut=Retallar
+Dado_un_campo_de_atributos=Donat un camp d'atributs
+debera_introducir_nombres_para_las_vistas_a_pegar=
+debera_introducir_nombres_para_los_mapas_a_pegar=
+default_projection=
+default_value=
+dehacer=Desfer
+delete_field=Esborrar el camp
+Derecha=Dreta
+Derecho=Dret
+desagrupar=Desagrupar
+desagrupar_capas=
+desagrupar_graficos=Desagrupar gr\u00e0fics
+descending_order=Orde descendent
+descending_order_tooltip=S'ordena pel camp seleccionat en orde descendent
+descripcion_de_configuracion_capa_de_anotaciones=
+descripcion_de_crear_capa_de_anotaciones=
+desde_arriba=Des de Dalt\:
+desde_izquierda=Des de l'esquerra\:
+desea_borrar_el_documento=
+desea_borrar_la_capa=
+desea_continuar=
+deshacer=Desfer
+desplaza_los_elementos_seleccionados_a_la_derecha=
+desplaza_los_elementos_seleccionados_a_la_izquierda=
+desplaza_los_elementos_seleccionados_al_centro_por_el_eje_x=
+desplaza_los_elementos_seleccionados_al_centro_por_el_eje_y=
+desplaza_los_elementos_seleccionados_hacia_abajo=
+desplaza_los_elementos_seleccionados_hacia_arriba=
+Desplazamiento=Despla\u00e7ament
+desviacion_tipica=Desviaci\u00f3 t\u00edpica
+distance_units=Unitats de mesura
+distribuir=Distribuir\:
+distribuir_elementos_sobre_todo_el_layout=
+distributes_down=
+distributes_horizontal=
+distributes_left=
+distributes_right=
+distributes_to_layout_down=
+distributes_to_layout_horizontal=
+distributes_to_layout_left=
+distributes_to_layout_right=
+distributes_to_layout_up=
+distributes_to_layout_vertical=
+distributes_up=
+distributes_vertical=
+distribuye_el_espacio_entre_los_elementos_en_horizontal=
+distribuye_el_espacio_entre_los_elementos_en_vertical=
+distribuye_los_elementos_seleccionados_de_forma_equidistante_de_abajo_hacia_arriba=
+distribuye_los_elementos_seleccionados_de_forma_equidistante_de_arriba_hacia_abajo=
+distribuye_los_elementos_seleccionados_de_forma_equidistante_de_derecha_a_izquierda=
+distribuye_los_elementos_seleccionados_de_forma_equidistante_de_izquierda_a_derecha=
+distribuye_los_elementos_seleccionados_de_forma_equidistante_y_horizontal=
+distribuye_los_elementos_seleccionados_de_forma_equidistante_y_vertical=
+divisiones_izquierda=Divisions a l'esquerra
+documento=
+documentos_existentes=Documents existents
+draw_text_only=
+driver=Driver
+Dxffiles=Fitxers .DXF
+edicion=Edici\u00f3
+editable=
+Editar_leyenda=Editar legenda
+editar_vertices=Editar v\u00e8rtex
+el_numero_maximo_de_intervalos_para_este_campo_es=El nombre m\u00e0xim d'intervals per a este camps \u00e9s
+Elegir_Color=Elegir color
+Elegir_Fuente=Elegir font
+elemento_ya_existe=
+Elementos_seleccionados_de_la_capa=elements seleccionats de la capa
+Eliminar=Eliminar
+eliminar_capa=Eliminar capa
+eliminar_columna=
+eliminar_extremos=Eliminar extrems
+eliminar_fila=
+en_el_mapa=En el mapa\:
+En_metros=En metres
+En_pixels=En pixels
+en_unidades=
+Encuadre=Enquadre
+Encuadre_Vista=Enquadre sobre la vista
+enlace_vivo=Enlla\u00e7 viu
+Enlazar_a_fichero_de_texto=Enlla\u00e7ar a fitxer de text
+Enlazar_a_ficheros_de_imagen=Enlla\u00e7ar a fitxers d'imatge
+equal_intervals=Intervals iguals
+Error_exportando_SLD=
+Error_guardando_la_leyenda=Error guardant la llegenda
+Error_guardando_la_plantilla=
+escala=Escala
+Escala=Escala
+escala_desconocida=
+escala_maxima=Escala m\u00e0xima
+Escala_Maxima=Escala m\u00e0xima
+escala_minima=Escala m\u00ednima
+Escala_Minima=Escala m\u00ednima
+escala_usuario=Escala especificada per l'usuari
+espaciado_horizontal=Espaiat horitzontal de la malla
+espaciado_vertical=Espaiat vertical de la malla
+espacio=Espai\:
+estadisticas=Estad\u00edstiques
+este_por_debajo_de_=Que estiga por davall de
+este_por_encima_de=Que estiga per damunt de
+Esten_contenidos_en=Estiguen continguts en
+Etiqueta=Etiqueta
+Etiquetados=Etiquetats
+etiquetas=Etiquetes
+Etiquetas_estandar=Etiquetes est\u00e0ndard
+Examinar=Examinar
+export=Exportar
+exportar=Exportar
+exportar_pdf=Exportar a pdf
+exportar_ps=Exportar a ps
+extension=Extensi\u00f3
+Extent=Extensi\u00f3
+extents_no_coincidentes=Extensions no coincidents
+factor_zoom_incorrecto=
+fallo_capas=Fallada en l'acc\u00e9s a les capes. Les capes seg\u00fcents seran eliminades del projecte.
+family=
+fichero=
+Fichero=Fitxer
+fichero_existe=Hi ha fitxer
+fichero_incorrecto=Fitxer incorrecte
+fichero_ya_existe_seguro_desea_guardarlo=
+field_already_exists=
+field_decimal_count=
+field_default_value=
+field_length=
+field_manager=
+field_name=
+field_type=
+filtro=Filtre
+finish=Finalitzar
+Font=Font
+formato=Format
+Formato_de_numero_erroneo=
+formato_incorrecto=Format incorrecte
+fuente=Font
+General=General
+georeferenciado=
+gestion_encuadre=Gesti\u00f3 d'Enquadres
+grados=Graus\:
+Grados=Graus
+Graficos=Gr\u00e0fics
+grosor_linea=Gruix de l\u00ednia\:
+group=Agrupar
+group_graphic_line=
+grupo=
+guardado=Guardat en
+guardar=Guardar
+Guardar=Guardar
+guardar_cambios=Vol guardar els canvis?
+guardar_como=Guardar com a...
+guardar_como_plantilla=Guardar com a plantilla
+Guardar_el_zoom_actual=Guardar el zoom
+Guardar_leyenda=Guardar llegenda
+guardar_proyecto=Guardar projecte
+guardar_tooltip=Guarda els canvis del projecte
+Habilitar_etiquetado=Habilitar etiquetat
+Hiperenlace=Hiperenlla\u00e7
+horizontal=Horitzontal
+horizontal_space=
+Identificar_Resultados=Identificar resultats
+Igual_que_la_impresora=Igual que la impressora
+igual_todos_lados=Despla\u00e7ament igual per tots els costats.
+imagen=Imatge
+Implimir=
+importar=Importar
+Imprimir=Imprimir
+Indexando=S'est\u00e0 indexant...
+Indexando_espacialmente=S'est\u00e0 indexant espacialment la capa
+indexar_campos=
+Inferior=Inferior
+info=Informaci\u00f3
+informacion=Informaci\u00f3
+Informacion=Informaci\u00f3
+Inicializando=Inicialitzant
+initial_warning=
+insert_row=Inserix fila
+Insertar=Inserir
+insertar_cajetin=Inserir caixet\u00ed
+insertar_circulo=Insertar cercle
+insertar_columna=
+insertar_escala=Insertar escala
+insertar_fila=
+insertar_imagen=Insertar imatge
+insertar_leyenda=Insertar llegenda
+insertar_linea=Insertar l\u00ednia
+insertar_norte=Insertar nord
+insertar_poligono=Insertar pol\u00edgon
+insertar_polilinea=Inserir polil\u00ednia
+insertar_punto=Insertar punt
+insertar_rectangulo=Insertar rectangle
+insertar_texto=Insertar text
+insertar_vista=Insertar vista
+Intersecten_con=Intersecten amb
+Intervalo=Interval
+Intervalos=Intervals
+introduce_nombre=Introdu\u00efx el nou nom
+introduzca_el_nombre_de_la_nueva_capa_de_anotaciones=
+introduzca_nuevo_nombre_para_la_vista=
+invalid_value_for_gap=
+invert_selection=
+Italic=
+Izquierda=Esquerra
+Izquierdo=Esquerre
+join=Unir
+jpg=Fitxers JPEG
+kilometros=Kil\u00f2metres
+Kilometros=Kil\u00f2metres
+leyenda=Llegenda
+Leyenda=Llegenda
+leyenda_campo_unido=S'est\u00e0 utilitzant un camp de la uni\u00f3 en la llegenda (i/o etiquetatge). Canvie la llegenda abans de llevar la uni\u00f3, per favor.
+Leyenda_Por_Defecto=Llegenda per defecte
+linea=L\u00ednia
+linea_grafica=L\u00ednia gr\u00e0fica
+lineal_directo=Lineal directe
+link=Enlla\u00e7
+Link=Enlla\u00e7
+localizador=localitzador
+locked_element=
+locked_element_it_cannot_be_deleted=
+locked_element_it_cannot_be_renamed=
+m/pixel=metros/pixel
+malla_activada=Malla activada
+manage_fields=
+mantener_intervalo=Mantindre interval
+map_units=Unitats de mapa
+mapa=Mapa
+Mapa=Mapa
+mapas=Mapes
+marco=Marc
+marco_vista=Marc de la vista
+margenes=M\u00e0rgens\:
+mas_de_100_simbolos=M\u00e9s de 100 s\u00edmbols no solen aportar informaci\u00f3 en un pla
+max_length_is=
+maximo=M\u00e0xim
+MDIFrame.quiere_salir=Est\u00e0 segur que vol eixir?
+MDIFrame.salir=Eixir
+media=Media
+medir_area=Mesurar \u00e1rea
+medir_distancias=Mesurar dist\u00e0ncies
+metadatos=Metadatos
+metros=Metres
+Metros=Metres
+Milimetros=Mil\u00b7l\u00edmetres
+Millas=Milles
+minimo=M\u00ednim
+modificar=
+modification_date=\u00daltima data de modificaci\u00f3
+mostrar_escala_numerica=
+Mostrar_siempre=Mostrar sempre
+mostrar_unidades=Mostrar unitats
+move_elements=
+Muestra_atributos=Mostra els atributs de les capes seleccionades.
+muestra_los_elementos_de_la_capa_usando_un_simbolo_por_cada_valor_unico=Mostra els elements de la capa usant un s\u00edmbol per cada valor \u00fanic
+Muestra_los_elementos_de_la_capa_usando_una_gama_de_colores_en_funcion_del_valor_de_un_determinado_campo_de_atributos=Mostra els elements de la capa usant una gamma de colors en funci\u00f3 del valor d'un determinat camp d'atributs
+Muestra_todos_los_elementos_de_una_capa_usando_el_mismo_simbolo=Mostra tots els elements d'una capa usant el mateix s\u00edmbol
+natural_intervals=Intervals naturals
+navegacion=Navegaci\u00f3
+navegacion_vista=Navegaci\u00f3 vista
+necesita_una_capa_activa=Necessita una capa activa
+necesita_una_capa_vectorial_activa=Necessita una capa vectorial activa
+new_field=Nou camp
+new_field_properties=
+next=Seg\u00fcent
+ninguna_impresora_configurada=Cap impressora configurada
+Nivel_de_transparencia=Nivell de transpar\u00e8ncia
+no=No
+no_activos=No actius
+No_de_intervalos=Nr. d'intervals
+no_es_posible_aplicar_leyenda_vacia=
+No_ha_sido_posible_realizar_la_operacion=
+No_mostrar=No mostrar la capa quan l'escala
+No_mostrar_la_capa_cuando_la_escala=No mostrar la capa quan l'escala
+no_se_pegaran_las_tablas=
+no_se_pegaran_las_vistas_del_conflicto=
+No_se_pudo_obtener_la_tabla_de_la_capa=No s'ha pogut obtindre la taula de la capa
+no_visibles=No visibles
+nombre=Nom
+Nombre=Nom
+nombre_no_valido=
+Nombre_que_se_le_dara_al_zoom=Nom que se li donar\u00e0 al zoom
+nombre_sesion=Nom de la sessi\u00f3
+none=
+none_selected=Cap seleccionat
+normal=Normal
+north=Nord
+Nueva_tabla=Nova taula
+nuevo=Nou
+Nuevo_conjunto=Nou conjunt
+nuevo_nombre_para_el_mapa=
+nuevo_proyecto=Nou projecte
+nuevo_tooltip=Crea un nou projecte
+num_bandas=Nombre de bandes
+num_columnas=Nombre de columnes
+num_filas=Nombre de files
+Num_intervalos=
+numero_decimales_mostrar=
+numero_incorrecto=N\u00famero incorrecte
+ok=D'acord
+opacidad=Opacitat
+operacion_cancelada=
+options.layout.paper_properties.landscaped=
+options.layout.paper_properties.paper_direction=
+options.layout.paper_properties.portrait=
+options.layout.paper_properties.title=
+options.view.default_map_overview_back_color=
+options.view.default_selection_color=
+options.view.default_view_back_color=
+options.view.invisible_new_layers=
+options.view.keep_scale_on_resizing=
+orientacion=Orientaci\u00f3\:
+origen_de_datos=Origen de dades
+Origen_de_datos=Origen de dades
+Origen_de_Datos=Origen de les dades\:
+owner=Propietari
+paste=Apegar
+paste_elements=
+path=Ruta
+pdf=
+pegar=
+pegar_mapas=
+pegar_vistas=
+Permite_etiquetar_los_elementos_del_mapa_con_el_valor_de_un_determinado_campo=Permet etiquetar els elements del mapa amb el valor d'un determinat camp
+Personalizado=Personalitzat
+personalizar_margenes=
+Pies=Peus
+pila_de_comandos=Pila de comandaments
+pixeles=p\u00edxels
+pixels=pixels
+Plain=Normal
+plantilla=plantilla
+please_insert_new_field_name=
+png=Fitxers png
+poligono=Pol\u00edgon
+polilinea=polil\u00ednia
+poner_capas_a=Posar capes a
+por_debajo_de=per davall de\:
+por_encima_de=per damunt de\:
+Por_favor_active_la_capa=Per favor active la capa
+posicion_linea=Posici\u00f3 de la l\u00ednia
+precision=
+preparar_pagina=Preparar p\u00e0gina
+Preparar_pagina=Preparar p\u00e0gina
+presentacion=Presentaci\u00f3
+previsualizacion=Previsualitzaci\u00f3
+Previsualizacion=Previsualitzaci\u00f3
+Previsualizacion_de_simbolo=Previsualitzaci\u00f3 de s\u00edmbol
+propiedad=
+propiedades=Propietats
+propiedades_cajetin=Propietats del caixet\u00ed
+propiedades_capa=Propietats de la capa
+propiedades_de_la_capa=Propietats de la capa
+Propiedades_escala_grafica=Propietats de l'escala
+propiedades_grafico=Propietats gr\u00e0fic
+propiedades_mapa=Propietats del mapa
+propiedades_marco_imagenes=Propietats del marc d'im\u00e0tgens
+propiedades_marco_leyenda=Propietats del marc de la llegenda
+propiedades_marco_vista=Propietats del marc de la vista
+propiedades_raster=Propietats del raster
+propiedades_sesion=Propietats de la sessi\u00f3
+propiedades_tabla=Propietats de la taula
+Propiedades_texto=Propietats del text
+propiedades_vista=Propietats de la vista
+Proyecciones=
+ps=
+puerto=
+Pulgadas=Polsades
+punto=Punt
+quantile_intervals=Intervals quantils
+quiere_continuar=Est\u00e0 segur que vol continuar?
+Quitar=Llevar
+Quitar_capa=Llevar capa
+quitar_enlaces=LLevar enlla\u00e7os
+Quitar_todos=Llevar tots
+quitar_uniones=Llevar unions
+rango_de_escalas=Rang d'escales
+Rango_de_escalas=Rang d'escales
+realce=Relleu
+realmente_desea_guardar=Realment desitja guardar?
+recargar=
+recorte_colas=Retall de cues
+recorte_vista=Retall a vista
+rectangulo=Rectangle
+recuento=Recompte
+Recuperar_leyenda=Recuperar llegenda
+Recuperar_y_eliminar_otros_zoom=Recuperar i eliminar altres zooms
+refrescar=Refrescar
+rehacer=Refer
+rellenar_marco_vista=Reomplir marc de la vista
+relleno=Farciment\:
+remove_elements=
+remove_fields=
+remove_row=Eliminia fila
+remove_rows=
+rename_field=
+renombrar=Renomenar
+reproyectar_aviso=La projecci\u00f3 de la capa no \u00e9s igual que la de la vista.\nAVISO\: pot ser inexacte amb algunes transformaciones.\nPer favor, llija la documentaci\u00f3
+reproyectar_pregunta=Vol reprojectar-la?
+resolucion_resultado=Resoluci\u00f3 del resultat\:
+resto_valores=Resta de valors
+restore_palette=
+rotation_field=
+salir=Eixir
+salir_tooltip=Eixir
+salvar_raster=Salvar el raster georeferenciat
+Sample=Exemple
+Se_superponen_a=Se superposen a
+Sean_disjuntos_a=siguen disjunts a
+Sean_iguales_a=siguen iguals a
+seleccion=Selecci\u00f3
+seleccion_fuente=Selecci\u00f3 de font
+Seleccion_por_capa=Selecci\u00f3 per capa
+selecciona_sistema_de_referencia=Seleccioneu sistema de refer\u00e8ncia
+Seleccionar=Seleccionar
+seleccionar_capas=Seleccionar capes
+seleccionar_capas_raster=Seleccionar capes r\u00e0ster
+Seleccionar_de_las_capas_activas_los_elementos_que=Seleccione de les capes actives els elements que\:
+Seleccionar_del_conjunto=Seleccionar del conjunt
+Seleccionar_fichero=Seleccionar fitxer
+seleccionar_por_poligono=
+seleccionar_por_punto=Seleccionar per punt
+seleccionar_por_rectangulo=Seleccionar per rectangle
+seleccionar_todos=Seleccionar tots
+seleccione_campo_enlace=Seleccioneu el camp a trav\u00e9s del qual cal enlla\u00e7ar
+seleccione_el_campo_angulo_de_la_capa_de_anotaciones=
+seleccione_el_campo_color_de_la_capa_de_anotaciones=
+seleccione_el_campo_de_texto_que_desea_que_se_utilize_para_mostrar_la_nueva_capa_virtual=
+seleccione_el_campo_fuente_de_la_capa_de_anotaciones=
+seleccione_el_campo_tamano_de_la_capa_de_anotaciones=
+seleccione_fecha=Seleccione una data...
+seleccione_tabla_a_enlazar=Seleccioneu la taula que cal enlla\u00e7ar
+seleccione_tabla_origen=Seleccioneu la taula d'origen de la uni\u00f3
+selection_color=Color de la selecci\u00f3
+selection_up=
+separator=
+Servidor=Servidor
+Shapefile=Shapefile
+show_this_dialog_next_startup=
+si=
+siempre=Sempre
+simbolo=S\u00edmbol
+Simbolo=S\u00edmbol
+Simbolo_unico=S\u00edmbol \u00fanic
+Simbologia=Simbologia
+simplificar_leyenda=
+simplify=
+sin_titulo=Sense t\u00edtol
+sincronizar_color_borde_relleno=Sincronitzar el color de la vora amb el del farciment\:
+Size=Dimensi\u00f3
+sobre_la_barra=Sobre la barra
+Solo_para_capas_vectoriales=Sols per a capes vectorials
+start_edition=Comen\u00e7ar l'edici\u00f3
+statistics=Estad\u00edstiques
+stop_edition=Acabar l'edici\u00f3
+Style=Estil
+Subir_capa=Pujar capa
+suma=Suma
+Superior=Superior
+symbol_selector=
+Tabla=Taula
+Tabla_de_Atributos=Taula d'Atributs
+tablas=Taules
+Tablas=Taules
+tag=tag
+tamano=Dimensi\u00f3\:
+tamano_metros=Dimensi\u00f3 en metres
+tamano_pagina=Dimensi\u00f3 de p\u00e0gina\:
+tamano_posicion=dimensi\u00f3/posici\u00f3
+tamanyo_borde=Grand\u00e0ria de la vora
+tamanyo_fuente=Grand\u00e0ria de font
+tamanyo_pagina=
+tamPixX=
+tamPixY=
+terminar=
+terminar_edicion=
+texto=
+this_table_is_not_self_editable=
+tipo_dato=Tipus de dada
+tipo_de_intervalo=Tipus d'interval
+tipo_de_leyenda=Tipus de llegenda
+tipo_fichero_proyecto=Fitxer de projecte gvSIG (*.gvsproj)
+tipo_linea=Tipus de L\u00ednia\:
+tipo_relleno=Tipus de Farciment\:
+tipo_simbolo=Tipus de s\u00edmbol\:
+tipos_de_documentos=Tipus de documents
+titulo=Gestor de projectes
+titulo_fframetext=T\u00edtol del camp de text
+to_annotation=Transformar a capa d'anotacions
+to_palette=Canviar a paleta
+tooltip_copiar_al_portapapeles=
+tooltip_cortar_al_portapapeles=
+tooltip_pegar_desde_el_portapapeles=
+Toquen=toquen
+transparencia=Transpar\u00e8ncia
+Transparencia=Transpar\u00e8ncia
+transparencia_pixel=Transpar\u00e8ncia per p\u00edxel
+ungroup=Desagrupar
+unidades=Unitats\:
+Unidades=Unitats\:
+untitled=Sense t\u00edtol
+url=
+Usar_indice_espacial=Usar \u00edndex espacial
+usar_marco=Usar marc
+usar_titulo=Usar t\u00edtol
+usuario=Usuari
+utilizar_margenes_impresora=Utilitzar m\u00e0rgens de la impressora.
+vacia=Buida
+Valor=Valor
+Valores=Valors
+Valores_unicos=Valors \u00fanics
+varianza=Varian\u00e7a
+Ventana=Finestra
+ventana_proyecto=Finestra de projecte
+Ver=Veure
+ver_error_capa=
+ver_tabla_atributos=Veure Taula d'atributs
+ver_tags=
+ver_tooltip=Mostra la finestra de projecte
+vertical=Vertical
+vertical_space=
+visible=Visible
+visibles=Visibles
+Vista=Vista
+vistas=Vistes
+visualizacion=Visualitzaci\u00f3
+Visualizacion=Visualitzaci\u00f3
+visualizar_cuadricula=Visualitzeu malla
+warning=Av\u00eds
+xmax=X m\u00e0xima
+xmin=X m\u00ednima
+Yardas=Lardes
+ymax=Y m\u00e0xima
+ymin=Y m\u00ednima
+Zoom_a_la_capa=Zoom a la capa
+Zoom_Acercar=Zoom acostar
+Zoom_Alejar=Zoom allunyar
+Zoom_Completo=Zoom complet
+Zoom_Completo_Vista=Zoom complet sobre la vista
+zoom_in_factor=
+Zoom_Mas=Zoom m\u00e9s
+Zoom_Mas_Vista=Zoom m\u00e9s sobre la vista
+Zoom_Menos=Zoom menys
+Zoom_Menos_Vista=Zoom menys sobre la vista
+zoom_out_factor=
+Zoom_pixel=Zoom a la resoluci\u00f3 del raster
+Zoom_Previo=Zoom previ
+Zoom_Real=Zoom 1\:1
+Zoom_Select=Zoom a la part seleccionada
+line_properties=Propietats de la l�nea
+join_style=Estil de la uni�
+join_bevel=En esquadra
+join_miter=A bisell
+join_round=Arrodonida
+end_style=Estil del extrem
+cap_butt=Sense extrem
+cap_round=Arrodonit
+cap_square=Rectangular
+fill_pattern=Patr� de farciment
+_Metadata=Metadades
\ No newline at end of file

Property changes on: tags/v2_0_0_Build_2050/applications/appgvSIG/config/text_ca.properties
___________________________________________________________________
Added: svn:keywords
   + Author Date Id Revision
Added: svn:eol-style
   + native

Index: tags/v2_0_0_Build_2050/applications/appgvSIG/config/prodevelop.html
===================================================================
--- tags/v2_0_0_Build_2050/applications/appgvSIG/config/prodevelop.html	(revision 0)
+++ tags/v2_0_0_Build_2050/applications/appgvSIG/config/prodevelop.html	(revision 38653)
@@ -0,0 +1,12 @@
+<html>
+<body>
+
+<img src="prodevelop-logo.png"><br>
+
+<h2>PRODEVELOP</h2>
+<br>
+
+<p>EN CONSTRUCCION</p>
+
+</body>
+</html>
\ No newline at end of file

Property changes on: tags/v2_0_0_Build_2050/applications/appgvSIG/config/prodevelop.html
___________________________________________________________________
Added: svn:mime-type
   + text/plain

Index: tags/v2_0_0_Build_2050/applications/appgvSIG/config/gva-logo_horiz_bicolor.png
===================================================================
Cannot display: file marked as a binary type.
svn:mime-type = application/octet-stream

Property changes on: tags/v2_0_0_Build_2050/applications/appgvSIG/config/gva-logo_horiz_bicolor.png
___________________________________________________________________
Added: svn:mime-type
   + application/octet-stream

Index: tags/v2_0_0_Build_2050/applications/appgvSIG/config/text_pt.properties
===================================================================
--- tags/v2_0_0_Build_2050/applications/appgvSIG/config/text_pt.properties	(revision 0)
+++ tags/v2_0_0_Build_2050/applications/appgvSIG/config/text_pt.properties	(revision 38653)
@@ -0,0 +1,706 @@
+#Translations for language [pt]
+#Mon Oct 30 09:38:21 CET 2006
+(escala_maxima)=(escala m\u00e1xima)
+(escala_minima)=(escala m\u00ednima)
+1\:=
+_(Simbolo_unico)=(S\u00edmbolo \u00fanico)
+__proyeccion_actual=Projec\u00e7\u00e3o actual\:
+__redimensionar_texto_escala=Redimensionar o texto de acordo com a escala da vista
+__seleccion_de_fuente=Selec\u00e7\u00e3o da fonte
+A0=A0
+A1=A1
+A2=A2
+A3=A3
+A4=A4
+abajo=Abaixo
+abrir=Abrir
+abrir_plantilla=Abrir molde
+abrir_proyecto=Abrir projecto
+abrir_tooltip=Abrir um projecto existente
+Abrir_una_capa=Abrir uma capa
+Accion_Predefinida=Ac\u00e7\u00e3o predefinida
+aceptar=Aceitar
+Aceptar=Aceitar
+acerca_de=Sobre...
+activar=Activate
+activar_regla=Activar r\u00e9gua
+activos=Activos
+add_delete_edit_fields=
+add_layer=Adicionar capa
+add_rows=
+adjust_transparency=Configurar transpar\u00eancia
+agrupacion=
+agrupar=Agrupar
+agrupar_capas=Agrupar capas
+agrupar_graficos=Agrupar gr\u00e1ficos
+agrupar_linea=Agrupar linha gr\u00e1fica com gr\u00e1ficos
+Ajustar_transparencia=Ajustar transpar\u00eancia
+ajustes_linea_grafica=Ajustes de linha gr\u00e1fica
+Al_leer_la_leyenda=Ao ler a legenda
+alias=Ali\u00e1s
+align_center=
+align_down=
+align_left=
+align_right=
+align_to_layout_center=
+align_to_layout_down=
+align_to_layout_left=
+align_to_layout_right=
+align_to_layout_up=
+align_to_layout_vertical_center=
+align_up=
+align_vertical_center=
+alineamiento=Alinhamento\:
+alinear=Alinhar
+alinear_graficos=Alinhar gr\u00e1ficos
+alta=Alta
+alto=Alto
+altura=Altura\:
+Altura_fija_de_texto=Tamanho fixo de texto
+ambito=\u00c2mbito
+Anadir=Adicionar
+Anadir_al_conjunto=Adicionar ao conjunto
+Anadir_capa=Adicionar capa
+Anadir_Capa=Adicionar capa
+anadir_tag=
+Anadir_todos=Adicionar todos
+ancho=Largura
+ancho_alto=Largura X altura
+anchura=Grossura\:
+Aplicar=Aplicar
+Archivo=Ficheiro
+arriba=Acima
+ascending_order=Ordem ascendente
+ascending_order_tooltip=Ordenar segundo o campo seleccionado por ordem ascendente
+Atributo=Atributo
+automatico=Autom\u00e1tico
+Ayuda=Ajuda
+back=Anterior
+background_color=Cor de fundo
+baja=Baixa
+Bajar_capa=Mover capa para baixo
+bandas=Bandas
+barra=Barra\:
+base=base
+base_datos=Base de dados
+bmp=Ficheiros do tipo bmp
+Bold=Negrito
+borra_seleccion=Apagar selec\u00e7\u00e3o
+borrador=Rascunho
+borrar=Apagar
+box=
+brillo=Brightness
+brillo_y_contraste=
+browse=
+cajetin=
+Calcular_intervalos=Calcular intervalos
+calidad=Qualidade
+cambiar_el_alto_de_los_elementos_seleccionados_hasta_coincidir_con_el_mas_alto=
+cambiar_el_ancho_de_los_elementos_seleccionados_hasta_coincidir_con_el_mas_ancho=
+cambiar_el_tamano_de_los_elementos_seleccionados_hasta_coincidir_con_el_mas_grande=
+Cambio_Color=Mudar de cor
+cambio_nombre=Mudar de nome
+campo=Campo
+Campo=Campo
+campo_altura_texto=Altura do campo de texto\:
+Campo_de_clasificacion=Campo de classifica\u00e7\u00e3o
+Campo_de_etiquetado=Campo da etiqueta
+Campos=Campos
+cancel=Cancelar
+Cancel=Cancelar
+cancelar=Cancelar
+Cancelar=Cancelar
+Capa=Capa
+Capas=Capas
+Capas_del_localizador=Localizador de capas
+Centimetros=Cent\u00edmetros
+cerrar=Fechar
+Cerrar=Fechar
+change=
+change_before=
+change_behind=
+change_height=
+change_width=
+circulo=C\u00edrculo
+clave=Senha
+close=Fechar
+coincidir_tamanyo=
+colocar_a_margenes=Colocar com referencia \u00e0s margens
+colocar_alrededor_seleccionados=Colocar ao redor dos gr\u00e1ficos seleccionados.
+colocar_alrededor_todos=Colocar ao redor de todos os gr\u00e1ficos.
+colocar_delante=Colocar \u00e0 frente
+colocar_detras=Colocar atr\u00e1s
+color=Cor\:
+Color_final=Cor final
+Color_inicio=Cor inicial
+color_texto=Cor do texto\:
+comentarios=Coment\u00e1rios
+comenzar_edicion=
+compleja=
+configurar=Configurar
+configurar_localizador=Configurar localizador
+Configurar_localizador=Configurar localizador ...
+confirmar_borrar=Aceita apagar o elemento ?
+conflicto_de_nombres_de_mapas_al_pegar=
+conflicto_de_nombres_de_tablas_al_pegar=
+conflicto_de_nombres_de_vistas_al_pegar=
+conflito_de_nombres_de_tablas_al_pegar=
+conservar_escala_visualizacion=Manter escala de vis\u00e3o
+consulta=Consulta
+Contengan=Contenham
+contraste=Contrast
+coor_geograficas=Coordenadas geogr\u00e1ficas
+copiar=
+copy=
+cortar=
+creation_date=Data de cria\u00e7\u00e3o
+Crucen_con=Cruzem com
+cuando_activo=Quando activo
+cut=
+Dado_un_campo_de_atributos=Dado de um campo de atributos
+debera_introducir_nombres_para_las_vistas_a_pegar=
+debera_introducir_nombres_para_los_mapas_a_pegar=
+default_projection=
+default_value=
+dehacer=
+delete_field=
+Derecha=Direita
+Derecho=Direito
+desagrupar=Desagrupar
+desagrupar_capas=
+desagrupar_graficos=Desagrupar gr\u00e1ficos
+descending_order=Ordem descendente
+descending_order_tooltip=Ordenar segundo o campo seleccionado por ordem descendente
+descripcion_de_configuracion_capa_de_anotaciones=
+descripcion_de_crear_capa_de_anotaciones=
+desde_arriba=Desde cima\:
+desde_izquierda=Desde a esquerda\:
+desea_borrar_el_documento=
+desea_borrar_la_capa=
+desea_continuar=
+deshacer=
+desplaza_los_elementos_seleccionados_a_la_derecha=
+desplaza_los_elementos_seleccionados_a_la_izquierda=
+desplaza_los_elementos_seleccionados_al_centro_por_el_eje_x=
+desplaza_los_elementos_seleccionados_al_centro_por_el_eje_y=
+desplaza_los_elementos_seleccionados_hacia_abajo=
+desplaza_los_elementos_seleccionados_hacia_arriba=
+Desplazamiento=Movimenta\u00e7\u00e3o
+desviacion_tipica=Desvia\u00e7\u00e3o t\u00edpica
+distance_units=Unidades de medida
+distribuir=Distribuir\:
+distribuir_elementos_sobre_todo_el_layout=
+distributes_down=
+distributes_horizontal=
+distributes_left=
+distributes_right=
+distributes_to_layout_down=
+distributes_to_layout_horizontal=
+distributes_to_layout_left=Distribuye izquierda del layout
+distributes_to_layout_right=
+distributes_to_layout_up=
+distributes_to_layout_vertical=
+distributes_up=
+distributes_vertical=
+distribuye_el_espacio_entre_los_elementos_en_horizontal=
+distribuye_el_espacio_entre_los_elementos_en_vertical=
+distribuye_los_elementos_seleccionados_de_forma_equidistante_de_abajo_hacia_arriba=
+distribuye_los_elementos_seleccionados_de_forma_equidistante_de_arriba_hacia_abajo=
+distribuye_los_elementos_seleccionados_de_forma_equidistante_de_derecha_a_izquierda=
+distribuye_los_elementos_seleccionados_de_forma_equidistante_de_izquierda_a_derecha=
+distribuye_los_elementos_seleccionados_de_forma_equidistante_y_horizontal=
+distribuye_los_elementos_seleccionados_de_forma_equidistante_y_vertical=
+divisiones_izquierda=Divis\u00f5es para a esquerda
+documento=
+documentos_existentes=Documentos existentes
+draw_text_only=
+driver=Driver
+Dxffiles=Ficheiros dxf
+edicion=
+editable=Editav\u00e9l
+Editar_leyenda=Editar legenda
+editar_vertices=
+el_numero_maximo_de_intervalos_para_este_campo_es=O n\u00famero m\u00e1ximo de intervalos para este campo s\u00e3o
+Elegir_Color=Seleccionar cor
+Elegir_Fuente=Seleccionar fonte
+elemento_ya_existe=
+Elementos_seleccionados_de_la_capa=Elementos seleccionados da capa
+Eliminar=Remover
+eliminar_capa=Remover capa
+eliminar_columna=
+eliminar_extremos=Remover extremos
+eliminar_fila=
+en_el_mapa=No mapa\:
+En_metros=Em metros
+En_pixels=Em pixels
+en_unidades=
+Encuadre=Zooms
+Encuadre_Vista=Enquadrar vista
+enlace_vivo=Hiperliga\u00e7\u00e3o viva
+Enlazar_a_fichero_de_texto=Hiperliga\u00e7\u00e3o para ficheiros de texto
+Enlazar_a_ficheros_de_imagen=Hiperliga\u00e7\u00e3o para ficheiros de imagem
+equal_intervals=Intervalos iguais
+Error_exportando_SLD=
+Error_guardando_la_leyenda=Erro ao guardar a legenda
+Error_guardando_la_plantilla=
+escala=Escala
+Escala=Escala
+escala_desconocida=
+escala_maxima=Escala m\u00e1xima
+Escala_Maxima=Escala m\u00e1xima
+escala_minima=Escala m\u00ednima
+Escala_Minima=Escala m\u00ednima
+escala_usuario=Escala especificada pelo usu\u00e1rio
+espaciado_horizontal=Espa\u00e7o horizontal da malha
+espaciado_vertical=Espa\u00e7o vertical da malha
+espacio=Espa\u00e7o\:
+estadisticas=Estat\u00edsticas
+este_por_debajo_de_=Esteja por debaixo de
+este_por_encima_de=Esteja por em cima de
+Esten_contenidos_en=Estejam dentro de
+Etiqueta=Etiqueta
+Etiquetados=Etiquetas
+etiquetas=Etiquetas\:
+Etiquetas_estandar=Etiquetas padr\u00e3o
+Examinar=Procurar
+export=Exportar
+exportar=Exportar
+exportar_pdf=Exportar a pdf
+exportar_ps=Exportar a ps
+extension=Extens\u00e3o
+Extent=Extens\u00e3o
+extents_no_coincidentes=A extens\u00e3o da imagem seleccionada n\u00e3o coincide com a imagem de origem.
+factor_zoom_incorrecto=
+fallo_capas=Erro ao aceder \u00e0s capas. As siguientes capas v\u00e3o ser eliminadas do projecto
+family=
+fichero=
+Fichero=Ficheiro
+fichero_existe=O ficheiro seleccionado j\u00e1 existe como banda da capa
+fichero_incorrecto=Ficheiro incorrecto
+fichero_ya_existe_seguro_desea_guardarlo=
+field_already_exists=
+field_decimal_count=
+field_default_value=
+field_length=
+field_manager=
+field_name=
+field_type=
+filtro=Filtro
+finish=Terminar
+Font=Fonte
+formato=Formato
+Formato_de_numero_erroneo=
+formato_incorrecto=Formato incorrecto
+fuente=Fonte
+General=Geral
+georeferenciado=
+gestion_encuadre=Gest\u00e3o de enfoque
+grados=Graus\:
+Grados=Graus
+Graficos=Gr\u00e1ficos
+grosor_linea=Grossura da linha\:
+group=Agrupar
+group_graphic_line=
+grupo=
+guardado=Guardado em
+guardar=
+Guardar=Guardar
+guardar_cambios=Guardar as altera\u00e7\u00f5es?
+guardar_como=Guardar como...
+guardar_como_plantilla=Guardar como molde
+Guardar_el_zoom_actual=Guardar zoom actual
+Guardar_leyenda=Guardar legenda
+guardar_proyecto=Guardar projecto
+guardar_tooltip=Guardar as altera\u00e7\u00f5es do projeto
+Habilitar_etiquetado=Activar etiquetas
+Hiperenlace=Hiperliga\u00e7\u00e3o
+horizontal=Horizontal
+horizontal_space=
+Identificar_Resultados=Identificar resultados
+Igual_que_la_impresora=Igual \u00e0 impressora
+igual_todos_lados=Igual em todos os lados.
+imagen=Imagem
+Implimir=
+importar=Importar
+Imprimir=Imprimir
+Indexando=Indexing...
+Indexando_espacialmente=
+indexar_campos=
+Inferior=Abaixo
+info=Informa\u00e7\u00e3o
+informacion=Informa\u00e7\u00e3o
+Informacion=Informa\u00e7\u00e3o
+Inicializando=A iniciar
+initial_warning=
+insert_row=
+Insertar=Inserir
+insertar_cajetin=
+insertar_circulo=Inserir c\u00edrculo
+insertar_columna=
+insertar_escala=Inserir escala
+insertar_fila=
+insertar_imagen=Inserir imagem
+insertar_leyenda=Inserir legenda
+insertar_linea=Inserir linha
+insertar_norte=Inserir rosa-dos-ventos
+insertar_poligono=Inserir pol\u00edgono
+insertar_polilinea=
+insertar_punto=Inserir ponto
+insertar_rectangulo=Inserir rect\u00e2ngulo
+insertar_texto=Inserir texto
+insertar_vista=Inserir vista
+Intersecten_con=Intersectam com
+Intervalo=Intervalo
+Intervalos=Intervalos
+introduce_nombre=Introduzir novo nome
+introduzca_el_nombre_de_la_nueva_capa_de_anotaciones=
+introduzca_nuevo_nombre_para_la_vista=
+invalid_value_for_gap=
+invert_selection=
+Italic=It\u00e1lico
+Izquierda=Esquerda
+Izquierdo=Esquerdo
+join=Uni\u00e3o
+jpg=Ficheiros jpeg
+kilometros=Quil\u00f3metros
+Kilometros=Quil\u00f3metros
+leyenda=Legenda
+Leyenda=Legenda
+leyenda_campo_unido=Se est\u00e1 a utilizar um campo da uni\u00e3o na legenda (e/ou etiquetas). Mude a legenda antes de retirar a uni\u00e3o, por favor.
+Leyenda_Por_Defecto=Legenda por defeito
+linea=Linha
+linea_grafica=Linha gr\u00e1fica
+lineal_directo=Lineal direito
+link=Hiperliga\u00e7\u00e3o
+Link=Hiperliga\u00e7\u00e3o
+localizador=Locator
+locked_element=
+locked_element_it_cannot_be_deleted=
+locked_element_it_cannot_be_renamed=
+m/pixel=metros/pixel
+malla_activada=Malha activada
+manage_fields=
+mantener_intervalo=Manter intervalo
+map_units=Unidades do mapa
+mapa=Mapa
+Mapa=Mapa
+mapas=Mapas
+marco=Marco
+marco_vista=Marco da vista
+margenes=Margens\:
+mas_de_100_simbolos=Mais de 100 s\u00edmbolos n\u00e3o contribuem para uma clara informa\u00e7\u00e3o de um mapa.
+max_length_is=
+maximo=M\u00e1ximo
+MDIFrame.quiere_salir=Fechar gvSIG?
+MDIFrame.salir=Fechar
+media=M\u00e9dia
+medir_area=Medir \u00e1rea
+medir_distancias=Medir dist\u00e2ncias
+metadatos=Metadatos
+metros=Metros
+Metros=Metros
+Milimetros=Mil\u00edmetros
+Millas=Milhas
+minimo=M\u00ednimo
+modificar=
+modification_date=Data de modifica\u00e7\u00e3o
+mostrar_escala_numerica=
+Mostrar_siempre=Mostrar sempre
+mostrar_unidades=Mostrar unidades
+move_elements=
+Muestra_atributos=Mostrar atributos das capas seleccionadas.
+muestra_los_elementos_de_la_capa_usando_un_simbolo_por_cada_valor_unico=Mostra os elementos da capa usando um s\u00edmbolo por cada valor \u00fanico
+Muestra_los_elementos_de_la_capa_usando_una_gama_de_colores_en_funcion_del_valor_de_un_determinado_campo_de_atributos=Mostra os elementos da capa usando uma gama de cores em fun\u00e7\u00e3o do valor de um determinado campo de atributos
+Muestra_todos_los_elementos_de_una_capa_usando_el_mismo_simbolo=Mostra todos os elementos de uma capa usando o mesmo s\u00edmbolo
+natural_intervals=Intervalos naturais
+navegacion=Navega\u00e7\u00e3o
+navegacion_vista=Vista modo navega\u00e7\u00e3o
+necesita_una_capa_activa=
+necesita_una_capa_vectorial_activa=
+new_field=
+new_field_properties=
+next=Seguinte
+ninguna_impresora_configurada=Nenhuma impressora configurada
+Nivel_de_transparencia=N\u00edvel de transpar\u00eancia
+no=No
+no_activos=N\u00e3o activos
+No_de_intervalos=N\u00ba de intervalos
+no_es_posible_aplicar_leyenda_vacia=
+No_ha_sido_posible_realizar_la_operacion=
+No_mostrar=N\u00e3o mostrar a capa quando a escala
+No_mostrar_la_capa_cuando_la_escala=N\u00e3o mostrar a capa quando a escala
+no_se_pegaran_las_tablas=
+no_se_pegaran_las_vistas_del_conflicto=
+No_se_pudo_obtener_la_tabla_de_la_capa=
+no_visibles=N\u00e3o vis\u00edvel
+nombre=Nome
+Nombre=Nome
+nombre_no_valido=
+Nombre_que_se_le_dara_al_zoom=Nome para o zoom
+nombre_sesion=Nome da sess\u00e3o
+none=
+none_selected=Nenhum seleccionado
+normal=Normal
+north=Norte
+Nueva_tabla=Nova tabela
+nuevo=Novo
+Nuevo_conjunto=Novo conjunto
+nuevo_nombre_para_el_mapa=
+nuevo_proyecto=Novo projecto
+nuevo_tooltip=Criar novo projecto
+num_bandas=N\u00famero de bandas
+num_columnas=
+num_filas=
+Num_intervalos=
+numero_decimales_mostrar=
+numero_incorrecto=
+ok=Aceitar
+opacidad=Opacidade
+operacion_cancelada=
+options.layout.paper_properties.landscaped=
+options.layout.paper_properties.paper_direction=
+options.layout.paper_properties.portrait=
+options.layout.paper_properties.title=
+options.view.default_map_overview_back_color=
+options.view.default_selection_color=
+options.view.default_view_back_color=
+options.view.invisible_new_layers=
+options.view.keep_scale_on_resizing=
+orientacion=Orienta\u00e7\u00e3o\:
+origen_de_datos=Origem de dados
+Origen_de_datos=Origem dos dados
+Origen_de_Datos=Origem dos dados\:
+owner=Propriet\u00e1rio
+paste=Paste
+paste_elements=
+path=Rota
+pdf=
+pegar=
+pegar_mapas=
+pegar_vistas=
+Permite_etiquetar_los_elementos_del_mapa_con_el_valor_de_un_determinado_campo=Permite etiquetar os elementos do mapa com o valor de um determinado campo
+Personalizado=Personalizado
+personalizar_margenes=
+Pies=P\u00e9s
+pila_de_comandos=
+pixeles=pixels
+pixels=pixels
+Plain=
+plantilla=
+please_insert_new_field_name=
+png=Ficheiros png
+poligono=
+polilinea=
+poner_capas_a=
+por_debajo_de=Por debaixo de\:
+por_encima_de=Por em cima de\:
+Por_favor_active_la_capa=
+posicion_linea=Posi\u00e7\u00e3o da linha
+precision=
+preparar_pagina=Preparar p\u00e1gina
+Preparar_pagina=Preparar p\u00e1gina
+presentacion=Apresenta\u00e7\u00e3o
+previsualizacion=
+Previsualizacion=Pr\u00e9-visualizar
+Previsualizacion_de_simbolo=Pr\u00e9-visualiza\u00e7\u00e3o do s\u00edmbolo
+propiedad=
+propiedades=Propriedades
+propiedades_cajetin=
+propiedades_capa=
+propiedades_de_la_capa=
+Propiedades_escala_grafica=Propriedades da escala
+propiedades_grafico=Propriedades gr\u00e1ficas
+propiedades_mapa=Propriedades do mapa
+propiedades_marco_imagenes=Propriedades do marco das imagens
+propiedades_marco_leyenda=Propriedades do marco da legenda
+propiedades_marco_vista=Propriedades do marco da vista
+propiedades_raster=Propiedades da cobertura
+propiedades_sesion=Propriedades da sess\u00e3o
+propiedades_tabla=Propriedades de tabela
+Propiedades_texto=Propriedades do texto
+propiedades_vista=Propriedades da vista
+Proyecciones=
+ps=
+puerto=Porta
+Pulgadas=Polegadas
+punto=Ponto
+quantile_intervals=Intervalos quartis
+quiere_continuar=Tem a certeza de que quer continuar?
+Quitar=Remover
+Quitar_capa=Remover capa
+quitar_enlaces=Remover hiperliga\u00e7\u00f5es
+Quitar_todos=Remover todos
+quitar_uniones=Remover uni\u00f5es
+rango_de_escalas=Amplitude de escalas
+Rango_de_escalas=Amplitude de escalas
+realce=Realce
+realmente_desea_guardar=
+recargar=
+recorte_colas=Recorte de filas
+recorte_vista=Recortar a vista
+rectangulo=Rect\u00e2ngulo
+recuento=Recontar
+Recuperar_leyenda=Recuperar legenda
+Recuperar_y_eliminar_otros_zoom=Recuperar e eliminar outros zooms
+refrescar=Actualizar
+rehacer=
+rellenar_marco_vista=Preencher espa\u00e7o da vista
+relleno=Preencher\:
+remove_elements=
+remove_fields=
+remove_row=
+remove_rows=
+rename_field=
+renombrar=Mudar de nome
+reproyectar_aviso=A projec\u00e7\u00e3o da capa n\u00e3o \u00e9 a mesma da que a vista.\nAVISO\: Isto pode gerar imprecis\u00e3o com algumas transforma\u00e7\u00f5es.\nPor favor, leia a documenta\u00e7\u00e3o
+reproyectar_pregunta=Deseja voltar a projectar?
+resolucion_resultado=Resolu\u00e7\u00e3o do resultado\:
+resto_valores=Resto de valores
+restore_palette=
+rotation_field=
+salir=Fechar
+salir_tooltip=Fechar
+salvar_raster=Guardar como raster
+Sample=Exemplo
+Se_superponen_a=Se sobrep\u00f5em a
+Sean_disjuntos_a=sejam disjuntos a
+Sean_iguales_a=sejam iguais a
+seleccion=Selec\u00e7\u00e3o
+seleccion_fuente=Selec\u00e7\u00e3o de fonte
+Seleccion_por_capa=
+selecciona_sistema_de_referencia=
+Seleccionar=Seleccionar
+seleccionar_capas=Seleccionar capas
+seleccionar_capas_raster=
+Seleccionar_de_las_capas_activas_los_elementos_que=Seleccionar as capas activas dos elementos que\:
+Seleccionar_del_conjunto=Seleccionar o conjunto
+Seleccionar_fichero=Seleccionar ficheiro
+seleccionar_por_poligono=
+seleccionar_por_punto=Seleccionar por ponto
+seleccionar_por_rectangulo=Seleccioar por rect\u00e2ngulo
+seleccionar_todos=Seleccionar todos
+seleccione_campo_enlace=Seleccione o campo a juntar
+seleccione_el_campo_angulo_de_la_capa_de_anotaciones=
+seleccione_el_campo_color_de_la_capa_de_anotaciones=
+seleccione_el_campo_de_texto_que_desea_que_se_utilize_para_mostrar_la_nueva_capa_virtual=
+seleccione_el_campo_fuente_de_la_capa_de_anotaciones=
+seleccione_el_campo_tamano_de_la_capa_de_anotaciones=
+seleccione_fecha=Seleccionar uma data...
+seleccione_tabla_a_enlazar=Seleccione a tabela a juntar
+seleccione_tabla_origen=Seleccione a tabela de origem do join
+selection_color=Cor de selec\u00e7\u00e3o
+selection_up=
+separator=
+Servidor=Servidor
+Shapefile=Ficheiro shp
+show_this_dialog_next_startup=
+si=
+siempre=
+simbolo=
+Simbolo=S\u00edmbolo
+Simbolo_unico=S\u00edmbolo \u00fanico
+Simbologia=Simbologia
+simplificar_leyenda=
+simplify=
+sin_titulo=Sem t\u00edtulo
+sincronizar_color_borde_relleno=Sincronizar a cor do borde com a de preenchimento\:
+Size=Tamanho
+sobre_la_barra=Sobre a barra
+Solo_para_capas_vectoriales=S\u00f3 para capas (vectoriais)
+start_edition=
+statistics=Estat\u00edsticas
+stop_edition=
+Style=Estilo
+Subir_capa=Mover capa para cima
+suma=Soma
+Superior=Superior
+symbol_selector=
+Tabla=Tabela
+Tabla_de_Atributos=Tabela de atributos
+tablas=Tabelas
+Tablas=Tabelas
+tag=tag
+tamano=Tamanho\:
+tamano_metros=Tamanho em metros
+tamano_pagina=Tamanho da p\u00e1gina
+tamano_posicion=Tamanho e posi\u00e7\u00e3o
+tamanyo_borde=Tamanho do borde
+tamanyo_fuente=Tamanho da fonte
+tamanyo_pagina=
+tamPixX=
+tamPixY=
+terminar=
+terminar_edicion=
+texto=Texto
+this_table_is_not_self_editable=
+tipo_dato=Tipo de dado
+tipo_de_intervalo=Tipo de intervalo
+tipo_de_leyenda=Tipo de legenda
+tipo_fichero_proyecto=Ficheiros de projecto gvSIG (*.gvsproj)
+tipo_linea=Tipo de linha\:
+tipo_relleno=Tipo de preenchimento\:
+tipo_simbolo=Tipo de s\u00edmbolo\:
+tipos_de_documentos=Tipos de documentos
+titulo=Gestor de projectos
+titulo_fframetext=T\u00edtulo do campo de texto
+to_annotation=
+to_palette=
+tooltip_copiar_al_portapapeles=
+tooltip_cortar_al_portapapeles=
+tooltip_pegar_desde_el_portapapeles=
+Toquen=toquem
+transparencia=Transpar\u00eancia
+Transparencia=Transpar\u00eancia
+transparencia_pixel=
+ungroup=Desagrupar
+unidades=Unidades\:
+Unidades=Unidades\:
+untitled=Sem t\u00edtulo
+url=
+Usar_indice_espacial=Usar \u00edndice espacial
+usar_marco=Usar marco
+usar_titulo=Usar t\u00edtulo
+usuario=Usu\u00e1rio
+utilizar_margenes_impresora=Utilizar m\u00e1rgens da impressora.
+vacia=Vazia
+Valor=Valor
+Valores=Valores
+Valores_unicos=Valores \u00fanicos
+varianza=Varia\u00e7\u00e3o
+Ventana=Janela
+ventana_proyecto=Janela de projecto
+Ver=Ver
+ver_error_capa=
+ver_tabla_atributos=Ver tabela de atributos
+ver_tags=
+ver_tooltip=Ver janela de projecto
+vertical=Vertical
+vertical_space=
+visible=Vis\u00edvel
+visibles=Vis\u00edveis
+Vista=Vista
+vistas=Vis\u00f5es
+visualizacion=Visualiza\u00e7\u00e3o
+Visualizacion=Visualiza\u00e7\u00e3o
+visualizar_cuadricula=Visualizar malha
+warning=
+xmax=X m\u00e1xima
+xmin=X m\u00ednima
+Yardas=Jardas
+ymax=Y m\u00e1xima
+ymin=Y m\u00ednima
+Zoom_a_la_capa=
+Zoom_Acercar=Zoom aproximar
+Zoom_Alejar=Zoom afastar
+Zoom_Completo=Zoom completo
+Zoom_Completo_Vista=Zoom completo sobre a vista
+zoom_in_factor=
+Zoom_Mas=Zoom mais
+Zoom_Mas_Vista=Zoom mais sobre a vista
+Zoom_Menos=Zoom menos
+Zoom_Menos_Vista=Zoom menos sobre a vista
+zoom_out_factor=
+Zoom_pixel=Zoom \u00e0 resolu\u00e7\u00e3o do raster
+Zoom_Previo=Zoom anterior
+Zoom_Real=Zoom 1\:1
+Zoom_Select=Zoom \u00e0 selec\u00e7\u00e3o

Property changes on: tags/v2_0_0_Build_2050/applications/appgvSIG/config/text_pt.properties
___________________________________________________________________
Added: svn:keywords
   + Author Date Id Revision
Added: svn:eol-style
   + native

Index: tags/v2_0_0_Build_2050/applications/appgvSIG/config/scolab-logo.png
===================================================================
Cannot display: file marked as a binary type.
svn:mime-type = application/octet-stream

Property changes on: tags/v2_0_0_Build_2050/applications/appgvSIG/config/scolab-logo.png
___________________________________________________________________
Added: svn:mime-type
   + application/octet-stream

Index: tags/v2_0_0_Build_2050/applications/appgvSIG/config/iver-logo.png
===================================================================
Cannot display: file marked as a binary type.
svn:mime-type = application/octet-stream

Property changes on: tags/v2_0_0_Build_2050/applications/appgvSIG/config/iver-logo.png
___________________________________________________________________
Added: svn:mime-type
   + application/octet-stream

Index: tags/v2_0_0_Build_2050/applications/appgvSIG/config/gvsig-logo1-association.jpg
===================================================================
Cannot display: file marked as a binary type.
svn:mime-type = application/octet-stream

Property changes on: tags/v2_0_0_Build_2050/applications/appgvSIG/config/gvsig-logo1-association.jpg
___________________________________________________________________
Added: svn:mime-type
   + application/octet-stream

Index: tags/v2_0_0_Build_2050/applications/appgvSIG/config/text_de.properties
===================================================================
--- tags/v2_0_0_Build_2050/applications/appgvSIG/config/text_de.properties	(revision 0)
+++ tags/v2_0_0_Build_2050/applications/appgvSIG/config/text_de.properties	(revision 38653)
@@ -0,0 +1,706 @@
+#Translations for language [de]
+#Mon Oct 30 09:38:21 CET 2006
+(escala_maxima)=(Gr\u00f6\u00dfter Ma\u00dfstab)
+(escala_minima)=(Kleinster Ma\u00dfstab)
+1\:=
+_(Simbolo_unico)=(Einmaliges symbol)
+__proyeccion_actual=Aktuelle projektion\:
+__redimensionar_texto_escala=Textgr\u00f6\u00dfe an den ansichtsma\u00dfstab anpassen
+__seleccion_de_fuente=Auswahl der Schriftart
+A0=A0
+A1=A1
+A2=A2
+A3=A3
+A4=A4
+abajo=Nach unten
+abrir=\u00d6ffnen
+abrir_plantilla=Vorlage \u00f6ffnen
+abrir_proyecto=Projekt \u00f6ffnen
+abrir_tooltip=Vorhandenes Projekt \u00f6ffnen
+Abrir_una_capa=Layer \u00f6ffnen
+Accion_Predefinida=Vordefinierte aktion
+aceptar=OK
+Aceptar=OK
+acerca_de=\u00dcber...
+activar=Activate
+activar_regla=Lineal aktivieren
+activos=Aktiv
+add_delete_edit_fields=
+add_layer=Layer hinzuf\u00fcgen
+add_rows=
+adjust_transparency=Transparenz anpassen
+agrupacion=
+agrupar=Gruppieren
+agrupar_capas=Layer gruppieren
+agrupar_graficos=Grafiken gruppieren
+agrupar_linea=Grafiklinie mit grafiken gruppieren
+Ajustar_transparencia=Transparenz anpassen
+ajustes_linea_grafica=Anpassung grafiklinie
+Al_leer_la_leyenda=Beim lesen der legende
+alias=Alias
+align_center=
+align_down=
+align_left=
+align_right=
+align_to_layout_center=
+align_to_layout_down=
+align_to_layout_left=
+align_to_layout_right=
+align_to_layout_up=
+align_to_layout_vertical_center=
+align_up=
+align_vertical_center=
+alineamiento=Ausrichtung\:
+alinear=Ausrichtung
+alinear_graficos=Grafiken ausrichten
+alta=Hoch
+alto=Hoch
+altura=H\u00f6he\:
+Altura_fija_de_texto=Fixierte texth\u00f6he
+ambito=Bereich
+Anadir=Hinzuf\u00fcgen
+Anadir_al_conjunto=Zum Datensatz hinzuf\u00fcgen
+Anadir_capa=Layer hinzuf\u00fcgen
+Anadir_Capa=Layer hinzuf\u00fcgen
+anadir_tag=
+Anadir_todos=Alle hinzuf\u00fcgen
+ancho=Breite
+ancho_alto=Breite x h\u00f6he
+anchura=Breite\:
+Aplicar=Anwenden
+Archivo=Datei
+arriba=Nach oben
+ascending_order=Aufsteigende ordnung
+ascending_order_tooltip=Sortierung nach dem ausgew\u00e4hlten Feld in aufsteigender Ordnung.
+Atributo=Attribut
+automatico=Automatisch
+Ayuda=Hilfe
+back=Zur\u00fcck
+background_color=Hintergrundfarbe
+baja=Niedrig
+Bajar_capa=Layer nach unten
+bandas=Farbstreifen
+barra=Balken\:
+base=base
+base_datos=Datenbank
+bmp=BMP-Dateien
+Bold=Fett
+borra_seleccion=Auswahl l\u00f6schen
+borrador=Entwurf
+borrar=L\u00f6schen
+box=
+brillo=
+brillo_y_contraste=
+browse=
+cajetin=
+Calcular_intervalos=Intervalle berechnen
+calidad=Qualit\u00e4t
+cambiar_el_alto_de_los_elementos_seleccionados_hasta_coincidir_con_el_mas_alto=
+cambiar_el_ancho_de_los_elementos_seleccionados_hasta_coincidir_con_el_mas_ancho=
+cambiar_el_tamano_de_los_elementos_seleccionados_hasta_coincidir_con_el_mas_grande=
+Cambio_Color=Farbe \u00e4ndern
+cambio_nombre=Namen \u00e4ndern
+campo=Feld
+Campo=Feld
+campo_altura_texto=H\u00f6he textfeld\:
+Campo_de_clasificacion=Klassifikationsfeld
+Campo_de_etiquetado=Etikettierfeld
+Campos=Felder
+cancel=Abbrechen
+Cancel=Abbrechen
+cancelar=Abbrechen
+Cancelar=Abbrechen
+Capa=Layer
+Capas=
+Capas_del_localizador=Navigatorlayer
+Centimetros=Zentimeter
+cerrar=Schlie\u00dfen
+Cerrar=Schlie\u00dfen
+change=
+change_before=
+change_behind=
+change_height=
+change_width=
+circulo=Kreis
+clave=Passwort
+close=schlie\u00dfen
+coincidir_tamanyo=
+colocar_a_margenes=Zu den r\u00e4ndern anordnen
+colocar_alrededor_seleccionados=Um ausgew\u00e4hlte graphiken anordnen.
+colocar_alrededor_todos=Um alle grafiken anordnen.
+colocar_delante=Nach vorn
+colocar_detras=Nach hinten
+color=Farbe\:
+Color_final=Endfarbe
+Color_inicio=Anfangsfarbe
+color_texto=Textfarbe\:
+comentarios=Kommentare
+comenzar_edicion=
+compleja=
+configurar=Konfigurieren
+configurar_localizador=Navigator konfigurieren
+Configurar_localizador=Navigator konfigurieren ...
+confirmar_borrar=Sind Sie sicher, dass Sie dieses element l\u00f6schen wollen?
+conflicto_de_nombres_de_mapas_al_pegar=
+conflicto_de_nombres_de_tablas_al_pegar=
+conflicto_de_nombres_de_vistas_al_pegar=
+conflito_de_nombres_de_tablas_al_pegar=
+conservar_escala_visualizacion=Darstellungsma\u00dfstab beibehalten
+consulta=Abfrage
+Contengan=Beinhalten
+contraste=Contrast
+coor_geograficas=Geografische koordinaten
+copiar=
+copy=
+cortar=
+creation_date=Erstellungsdatum
+Crucen_con=Sich kreuzen mit
+cuando_activo=Wenn aktiv
+cut=
+Dado_un_campo_de_atributos=Bei vorgegebenen attributfeld\:
+debera_introducir_nombres_para_las_vistas_a_pegar=
+debera_introducir_nombres_para_los_mapas_a_pegar=
+default_projection=
+default_value=
+dehacer=
+delete_field=
+Derecha=Rechts
+Derecho=Rechts
+desagrupar=Gruppe aufl\u00f6sen
+desagrupar_capas=
+desagrupar_graficos=Grafikgruppe aufl\u00f6sen
+descending_order=Absteigende ordnung
+descending_order_tooltip=Sortierung nach dem ausgew\u00e4hlten Feld in absteigender Ordnung.
+descripcion_de_configuracion_capa_de_anotaciones=
+descripcion_de_crear_capa_de_anotaciones=
+desde_arriba=Von oben\:
+desde_izquierda=Von links\:
+desea_borrar_el_documento=
+desea_borrar_la_capa=
+desea_continuar=
+deshacer=
+desplaza_los_elementos_seleccionados_a_la_derecha=
+desplaza_los_elementos_seleccionados_a_la_izquierda=
+desplaza_los_elementos_seleccionados_al_centro_por_el_eje_x=
+desplaza_los_elementos_seleccionados_al_centro_por_el_eje_y=
+desplaza_los_elementos_seleccionados_hacia_abajo=
+desplaza_los_elementos_seleccionados_hacia_arriba=
+Desplazamiento=Verschieben
+desviacion_tipica=Typische Abweichung
+distance_units=Ma\u00dfeinheiten
+distribuir=Verteilen\:
+distribuir_elementos_sobre_todo_el_layout=
+distributes_down=
+distributes_horizontal=
+distributes_left=
+distributes_right=
+distributes_to_layout_down=
+distributes_to_layout_horizontal=
+distributes_to_layout_left=
+distributes_to_layout_right=
+distributes_to_layout_up=
+distributes_to_layout_vertical=
+distributes_up=
+distributes_vertical=
+distribuye_el_espacio_entre_los_elementos_en_horizontal=
+distribuye_el_espacio_entre_los_elementos_en_vertical=
+distribuye_los_elementos_seleccionados_de_forma_equidistante_de_abajo_hacia_arriba=
+distribuye_los_elementos_seleccionados_de_forma_equidistante_de_arriba_hacia_abajo=
+distribuye_los_elementos_seleccionados_de_forma_equidistante_de_derecha_a_izquierda=
+distribuye_los_elementos_seleccionados_de_forma_equidistante_de_izquierda_a_derecha=
+distribuye_los_elementos_seleccionados_de_forma_equidistante_y_horizontal=
+distribuye_los_elementos_seleccionados_de_forma_equidistante_y_vertical=
+divisiones_izquierda=Teilungen auf der linken Seite
+documento=
+documentos_existentes=Vorhandene dokumente
+draw_text_only=
+driver=Treiber
+Dxffiles=DXF-Dateien
+edicion=
+editable=Editierbar
+Editar_leyenda=Legende editieren
+editar_vertices=
+el_numero_maximo_de_intervalos_para_este_campo_es=Die maximal Intervallenummer f\u00fcr dieses Feld ist
+Elegir_Color=Farbe ausw\u00e4hlen
+Elegir_Fuente=Schriftart ausw\u00e4hlen
+elemento_ya_existe=
+Elementos_seleccionados_de_la_capa=Ausgew\u00e4hlte elemente des layers
+Eliminar=L\u00f6schen
+eliminar_capa=Layer l\u00f6schen
+eliminar_columna=
+eliminar_extremos=Extreme l\u00f6schen
+eliminar_fila=
+en_el_mapa=Auf der karte\:
+En_metros=In Metern
+En_pixels=In pixeln
+en_unidades=
+Encuadre=Bildausschnitt
+Encuadre_Vista=Ansicht im bildausschnitt verschieben
+enlace_vivo=Aktiver link zum original
+Enlazar_a_fichero_de_texto=Link zu textdateien
+Enlazar_a_ficheros_de_imagen=Link zu bilddateien
+equal_intervals=Gleiche intervalle
+Error_exportando_SLD=
+Error_guardando_la_leyenda=Fehler beim Speichern der Legende
+Error_guardando_la_plantilla=
+escala=Ma\u00dfstab
+Escala=Ma\u00dfstab
+escala_desconocida=
+escala_maxima=Maximalma\u00dfstab
+Escala_Maxima=Gr\u00f6\u00dfter ma\u00dfstab
+escala_minima=Minimalma\u00dfstab
+Escala_Minima=Kleinster ma\u00dfstab
+escala_usuario=Benutzerdefinierter Ma\u00dfstab
+espaciado_horizontal=Horizontaler rasterabstand
+espaciado_vertical=Vertikaler Rasterabstand
+espacio=Leerzeichen\:
+estadisticas=Statistiken
+este_por_debajo_de_=Kleiner ist als
+este_por_encima_de=Gr\u00f6\u00dfer ist als
+Esten_contenidos_en=Enthalten sind in
+Etiqueta=Etikett
+Etiquetados=Etikettierung
+etiquetas=Etiketten\:
+Etiquetas_estandar=Standard-Etiketten
+Examinar=Browse
+export=Exportieren
+exportar=Exportieren
+exportar_pdf=Als pdf exportieren
+exportar_ps=Als ps exportieren
+extension=Verl\u00e4ngerung
+Extent=Bildbereich
+extents_no_coincidentes=Die ausgew\u00e4hlte Bildgr\u00f6\u00dfe stimmt nicht mit dem Originalbild \u00fcberein.
+factor_zoom_incorrecto=
+fallo_capas=Fehler beim Zugriff auf die Layer. Die folgenden Layer werden aus dem Projekt entfernt
+family=
+fichero=
+Fichero=Datei
+fichero_existe=Ausgew\u00e4hlte datei existiert schon als layergruppe.
+fichero_incorrecto=Unrichtige datei
+fichero_ya_existe_seguro_desea_guardarlo=
+field_already_exists=
+field_decimal_count=
+field_default_value=
+field_length=
+field_manager=
+field_name=
+field_type=
+filtro=Filter
+finish=Beenden
+Font=Schriftart
+formato=Format
+Formato_de_numero_erroneo=
+formato_incorrecto=Unrichtig Format
+fuente=Schriftart
+General=Allgemein
+georeferenciado=
+gestion_encuadre=Verwaltung der Bildausschnitte
+grados=Grad\:
+Grados=Grad
+Graficos=Grafiken
+grosor_linea=Strichst\u00e4rke
+group=Gruppieren
+group_graphic_line=
+grupo=
+guardado=Gespeichert in
+guardar=
+Guardar=Speichern
+guardar_cambios=\u00c4nderungen speichern?
+guardar_como=Speichern unter ...
+guardar_como_plantilla=als Vorlage speichern
+Guardar_el_zoom_actual=Aktuellen zoom speichern
+Guardar_leyenda=Legende speichern
+guardar_proyecto=Projekt speichern
+guardar_tooltip=Speichert die \u00c4nderungen des Projekts
+Habilitar_etiquetado=Etikettierung aktivieren
+Hiperenlace=Hyperlink
+horizontal=Horizontal
+horizontal_space=
+Identificar_Resultados=Ergebnisse identifizieren
+Igual_que_la_impresora=Wie drucker
+igual_todos_lados=Gleiche Verschiebung in alle richtungen
+imagen=Bild
+Implimir=
+importar=Importieren
+Imprimir=Drucken
+Indexando=Indexing...
+Indexando_espacialmente=
+indexar_campos=
+Inferior=Unten
+info=Information
+informacion=Information
+Informacion=Information
+Inicializando=Initialisiert
+initial_warning=
+insert_row=
+Insertar=Einf\u00fcgen
+insertar_cajetin=
+insertar_circulo=Kreis einf\u00fcgen
+insertar_columna=
+insertar_escala=Ma\u00dfstab einf\u00fcgen
+insertar_fila=
+insertar_imagen=Bild einf\u00fcgen
+insertar_leyenda=Legende einf\u00fcgen
+insertar_linea=Linie einf\u00fcgen
+insertar_norte=Nordung einf\u00fcgen
+insertar_poligono=Polygon einf\u00fcgen
+insertar_polilinea=
+insertar_punto=Punkt einf\u00fcgen
+insertar_rectangulo=Rechteck einf\u00fcgen
+insertar_texto=Text einf\u00fcgen
+insertar_vista=Ansicht einf\u00fcgen
+Intersecten_con=Sich \u00fcberschneiden mit
+Intervalo=Intervall
+Intervalos=Intervalle
+introduce_nombre=Geben Sie den neuen Namen ein.
+introduzca_el_nombre_de_la_nueva_capa_de_anotaciones=
+introduzca_nuevo_nombre_para_la_vista=
+invalid_value_for_gap=
+invert_selection=
+Italic=Kursiv
+Izquierda=Links
+Izquierdo=Links
+join=Verbindung
+jpg=JPEG-Datei
+kilometros=Kilometer
+Kilometros=Kilometer
+leyenda=Legende
+Leyenda=Legende
+leyenda_campo_unido=Man verwendt ein Field der Verbindung in der Legende (und/oder Etikettierung). Tauschen Sie die Legende vorher aus, die Verbindung aufzul\u00f6sen.
+Leyenda_Por_Defecto=Legende nach vorgabe
+linea=Linie
+linea_grafica=Grafiklinie
+lineal_directo=Direktlineal
+link=Link
+Link=Link
+localizador=Locator
+locked_element=
+locked_element_it_cannot_be_deleted=
+locked_element_it_cannot_be_renamed=
+m/pixel=metros/pixel
+malla_activada=Raster aktiviert
+manage_fields=
+mantener_intervalo=Intervall beibehalten
+map_units=Karteneinheiten
+mapa=
+Mapa=Karte
+mapas=Karten
+marco=Rahmen
+marco_vista=Ansichtsrahmen
+margenes=R\u00e4nder\:
+mas_de_100_simbolos=Mehr als 100 Symbols liefern keine Information zu der Karte
+max_length_is=
+maximo=Maximal
+MDIFrame.quiere_salir=Sind Sie sicher, dass Sie das Programm beenden wollen?
+MDIFrame.salir=Beenden
+media=Mittel
+medir_area=Fl\u00e4che messen
+medir_distancias=Abst\u00e4nde messen
+metadatos=
+metros=Meter
+Metros=Meter
+Milimetros=Milimeter
+Millas=Meilen
+minimo=Minimal
+modificar=
+modification_date=Letzte \u00c4nderung
+mostrar_escala_numerica=
+Mostrar_siempre=Immer zeigen
+mostrar_unidades=Einheiten anzeigen
+move_elements=
+Muestra_atributos=Zeigt die attribute der ausgew\u00e4hlten Layer.
+muestra_los_elementos_de_la_capa_usando_un_simbolo_por_cada_valor_unico=Zeigt Elemente des Layers mit je einem symbol pro Wert.
+Muestra_los_elementos_de_la_capa_usando_una_gama_de_colores_en_funcion_del_valor_de_un_determinado_campo_de_atributos=Zeigt die Elemente des Layers mit der gleichen Farbpalette, abh\u00e4ngig vom Wert eines bestimmten Attributfelds.
+Muestra_todos_los_elementos_de_una_capa_usando_el_mismo_simbolo=Zeigt alle elemente des layers mit dem gleichen symbol.
+natural_intervals=Nat\u00fcrliche Intervalle
+navegacion=\u00dcbersicht
+navegacion_vista=\u00dcbersicht der Ansicht
+necesita_una_capa_activa=
+necesita_una_capa_vectorial_activa=
+new_field=
+new_field_properties=
+next=Weiter
+ninguna_impresora_configurada=Kein Drucker konfiguriert
+Nivel_de_transparencia=Transparenzgrad
+no=No
+no_activos=inaktiv
+No_de_intervalos=Anzahl intervalle
+no_es_posible_aplicar_leyenda_vacia=
+No_ha_sido_posible_realizar_la_operacion=
+No_mostrar=Den Layer nicht zeigen, wenn der Ma\u00dfstab ...
+No_mostrar_la_capa_cuando_la_escala=Den layer nicht zeigen, wenn der ma\u00dfstab ...
+no_se_pegaran_las_tablas=
+no_se_pegaran_las_vistas_del_conflicto=
+No_se_pudo_obtener_la_tabla_de_la_capa=
+no_visibles=Unsichtbar
+nombre=Name
+Nombre=Name
+nombre_no_valido=
+Nombre_que_se_le_dara_al_zoom=Name des zooms
+nombre_sesion=Name der session
+none=
+none_selected=keiner ausgew\u00e4hlt
+normal=Normal
+north=Nord
+Nueva_tabla=Neue tabelle
+nuevo=Neu
+Nuevo_conjunto=Neuer datensatz
+nuevo_nombre_para_el_mapa=
+nuevo_proyecto=Neues projekt
+nuevo_tooltip=Erstellt ein neues projekt
+num_bandas=Anzahl farbstreifen
+num_columnas=
+num_filas=
+Num_intervalos=
+numero_decimales_mostrar=
+numero_incorrecto=Unrichtig nummer
+ok=OK
+opacidad=Lichtundurchl\u00e4ssigkeit
+operacion_cancelada=
+options.layout.paper_properties.landscaped=
+options.layout.paper_properties.paper_direction=
+options.layout.paper_properties.portrait=
+options.layout.paper_properties.title=
+options.view.default_map_overview_back_color=
+options.view.default_selection_color=
+options.view.default_view_back_color=
+options.view.invisible_new_layers=
+options.view.keep_scale_on_resizing=
+orientacion=Ausrichtung
+origen_de_datos=Herkunft der daten
+Origen_de_datos=Herkunft der daten
+Origen_de_Datos=Herkunft der daten\:
+owner=Besitzer
+paste=Paste
+paste_elements=
+path=Pfad
+pdf=
+pegar=
+pegar_mapas=
+pegar_vistas=
+Permite_etiquetar_los_elementos_del_mapa_con_el_valor_de_un_determinado_campo=Erm\u00f6glicht das etiketieren von elementen der karte, mit dem wert eines bestimmten felds.
+Personalizado=Benutzerdefiniert
+personalizar_margenes=
+Pies=Feet
+pila_de_comandos=
+pixeles=pixel
+pixels=pixels
+Plain=Einfach
+plantilla=
+please_insert_new_field_name=
+png=PNG-Datei
+poligono=
+polilinea=
+poner_capas_a=
+por_debajo_de=unter\:
+por_encima_de=\u00fcber\:
+Por_favor_active_la_capa=
+posicion_linea=Position der Linie
+precision=
+preparar_pagina=Seite einrichten
+Preparar_pagina=Seite einrichten
+presentacion=Pr\u00e4sentation
+previsualizacion=
+Previsualizacion=Voransicht
+Previsualizacion_de_simbolo=Symbolvoransicht
+propiedad=
+propiedades=Eigenschaften
+propiedades_cajetin=
+propiedades_capa=
+propiedades_de_la_capa=Eigenschaften des Layers
+Propiedades_escala_grafica=Eigenschaften des Ma\u00dfstabsbalkens
+propiedades_grafico=Eigenschaften der grafik
+propiedades_mapa=Eigenschaften der Karte
+propiedades_marco_imagenes=Eigenschaften des bildrahmens
+propiedades_marco_leyenda=Eigenschaften des Legenderahmens
+propiedades_marco_vista=Eigenschaften des ansichtsrahmens
+propiedades_raster=Eigenschaften der rasterung
+propiedades_sesion=Eigenschaften der session
+propiedades_tabla=Eigenschaften der tabelle
+Propiedades_texto=Eigenschaften des textes
+propiedades_vista=Eigenschaften der ansicht
+Proyecciones=
+ps=
+puerto=
+Pulgadas=Inches
+punto=Punkt
+quantile_intervals=Quantile Intervalle
+quiere_continuar=W\u00f6llen Sie wietermachen?
+Quitar=Entfernen
+Quitar_capa=Layer entfernen
+quitar_enlaces=Links aufl\u00f6sen
+Quitar_todos=Alle entfernen
+quitar_uniones=Verbindungen aufl\u00f6sen
+rango_de_escalas=Ma\u00dfstabsbereich
+Rango_de_escalas=Ma\u00dfstabsbereich
+realce=Heraushebung
+realmente_desea_guardar=
+recargar=
+recorte_colas=Zuschnitt der Randbereiche
+recorte_vista=Ausschneiden nach Augenma\u00df
+rectangulo=Rechteck
+recuento=Nachz\u00e4hlung
+Recuperar_leyenda=Legende laden
+Recuperar_y_eliminar_otros_zoom=Andere zooms laden oder l\u00f6schen
+refrescar=Aktualisieren
+rehacer=
+rellenar_marco_vista=Ansichtsrahmen f\u00fcllen
+relleno=F\u00fcllung\:
+remove_elements=
+remove_fields=
+remove_row=
+remove_rows=
+rename_field=
+renombrar=Umbenennen
+reproyectar_aviso=Die Layerprojektion deckt sich nicht mit der Ansichtsprojektion. \nACHTUNG\: Bei einigen Transformationen k\u00f6nnte sie ungenau sein.\nLesen Sie bitte die Dokumentation.
+reproyectar_pregunta=W\u00fcnschen Sie eine neue Projektion?
+resolucion_resultado=Ausgabeauf\u00f6sung\:
+resto_valores=Andere werte
+restore_palette=
+rotation_field=
+salir=Schlie\u00dfen
+salir_tooltip=Schlie\u00dfen
+salvar_raster=Als Rasterung sichern
+Sample=Beispiel
+Se_superponen_a=Sich \u00fcberlagern \u00fcber
+Sean_disjuntos_a=getrennt sind von
+Sean_iguales_a=gleich sind wie
+seleccion=Auswahl
+seleccion_fuente=Schriftart w\u00e4hlen
+Seleccion_por_capa=
+selecciona_sistema_de_referencia=
+Seleccionar=ausw\u00e4hlen
+seleccionar_capas=Layer ausw\u00e4hlen
+seleccionar_capas_raster=
+Seleccionar_de_las_capas_activas_los_elementos_que=In den aktiven layern nach elementen suchen, die\:
+Seleccionar_del_conjunto=Aus dem datensatz ausw\u00e4hlen
+Seleccionar_fichero=Datei ausw\u00e4hlen
+seleccionar_por_poligono=
+seleccionar_por_punto=\u00dcber Punkt ausw\u00e4hlen
+seleccionar_por_rectangulo=Auswahlrahmen
+seleccionar_todos=Alle ausw\u00e4hlen
+seleccione_campo_enlace=W\u00e4hlen Sie das Feld aus, \u00fcber das sie verlinken wollen.
+seleccione_el_campo_angulo_de_la_capa_de_anotaciones=
+seleccione_el_campo_color_de_la_capa_de_anotaciones=
+seleccione_el_campo_de_texto_que_desea_que_se_utilize_para_mostrar_la_nueva_capa_virtual=
+seleccione_el_campo_fuente_de_la_capa_de_anotaciones=
+seleccione_el_campo_tamano_de_la_capa_de_anotaciones=
+seleccione_fecha=W\u00e4hlen sie ein Datum aus ...
+seleccione_tabla_a_enlazar=W\u00e4hlen Sie die Tabelle aus, die Sie verlinken wollen.
+seleccione_tabla_origen=W\u00e4hlen Sie die Originaltabelle f\u00fcr die Verbindung aus.
+selection_color=Farbe der Auswahl
+selection_up=
+separator=
+Servidor=Server
+Shapefile=Shapefile
+show_this_dialog_next_startup=
+si=
+siempre=Immer
+simbolo=
+Simbolo=Symbol
+Simbolo_unico=Einmaliges symbol
+Simbologia=Symbole
+simplificar_leyenda=
+simplify=
+sin_titulo=Ohne Titel
+sincronizar_color_borde_relleno=Die randfarbe mit der f\u00fcllung synchronisieren\:
+Size=Gr\u00f6\u00dfe
+sobre_la_barra=Auf dem Balken
+Solo_para_capas_vectoriales=Nur f\u00fcr Vektorlayer
+start_edition=
+statistics=Statistiken
+stop_edition=
+Style=Stil
+Subir_capa=Layer nach oben
+suma=Summe
+Superior=Oben
+symbol_selector=
+Tabla=Tabelle
+Tabla_de_Atributos=Attributtabelle
+tablas=Tabellen
+Tablas=Tabellen
+tag=tag
+tamano=Gr\u00f6\u00dfe\:
+tamano_metros=Gr\u00f6\u00dfe in Metern
+tamano_pagina=Seitenformat\:
+tamano_posicion=Gr\u00f6\u00dfe und Position
+tamanyo_borde=Randgr\u00f6\u00dfe
+tamanyo_fuente=Schriftgr\u00f6\u00dfe
+tamanyo_pagina=
+tamPixX=
+tamPixY=
+terminar=
+terminar_edicion=
+texto=
+this_table_is_not_self_editable=
+tipo_dato=Datentyp
+tipo_de_intervalo=Intervallesart
+tipo_de_leyenda=Legendentyp
+tipo_fichero_proyecto=Projektdatei gvSIG (*.gvsproj)
+tipo_linea=Strichtyp\:
+tipo_relleno=F\u00fcllstil\:
+tipo_simbolo=Symboltyp\:
+tipos_de_documentos=Dokumenttyp
+titulo=Projektverwalter
+titulo_fframetext=Titel des Textfelds
+to_annotation=
+to_palette=
+tooltip_copiar_al_portapapeles=
+tooltip_cortar_al_portapapeles=
+tooltip_pegar_desde_el_portapapeles=
+Toquen=fassen an
+transparencia=Transparenz
+Transparencia=Transparenz
+transparencia_pixel=
+ungroup=Gruppe aufl\u00f6sen
+unidades=Einheiten\:
+Unidades=Einheiten\:
+untitled=Ohne Titel
+url=
+Usar_indice_espacial=R\u00e4umlichen Index benutzen
+usar_marco=Rahmen verwenden
+usar_titulo=Titel verwenden
+usuario=Benutzer
+utilizar_margenes_impresora=Randbegrenzung des Druckers verwenden
+vacia=
+Valor=Wert
+Valores=Werte
+Valores_unicos=Einmalige werte
+varianza=Varianz
+Ventana=Fenster
+ventana_proyecto=Projektfenster
+Ver=Sehen
+ver_error_capa=
+ver_tabla_atributos=Attributtabelle sehen
+ver_tags=
+ver_tooltip=Zeigt das Projektfenster
+vertical=Vertikal
+vertical_space=
+visible=Sichtbar
+visibles=Sichtbar
+Vista=Ansicht
+vistas=Ansichten
+visualizacion=Darstellung
+Visualizacion=Visualisierung
+visualizar_cuadricula=Raster darstellen
+warning=
+xmax=Maximalwert x
+xmin=Minimalwert x
+Yardas=Yards
+ymax=Maximalwert y
+ymin=Minimalwert y
+Zoom_a_la_capa=
+Zoom_Acercar=Heranzoomen
+Zoom_Alejar=Wegzoomen
+Zoom_Completo=Zoom auf alles
+Zoom_Completo_Vista=Zoom auf alles im bildausschnitt
+zoom_in_factor=
+Zoom_Mas=Gr\u00f6\u00dfer zoomen
+Zoom_Mas_Vista=Im bildausschnitt gr\u00f6\u00dfer zoomen
+Zoom_Menos=Kleiner zoomen
+Zoom_Menos_Vista=Im bildausschnitt kleiner zoomen
+zoom_out_factor=
+Zoom_pixel=Zoom zur Rasteraufl\u00f6sung
+Zoom_Previo=Letzter zoom
+Zoom_Real=Zoom 1\:1
+Zoom_Select=Zur auswahl zoomen

Property changes on: tags/v2_0_0_Build_2050/applications/appgvSIG/config/text_de.properties
___________________________________________________________________
Added: svn:keywords
   + Author Date Id Revision
Added: svn:eol-style
   + native

Index: tags/v2_0_0_Build_2050/applications/appgvSIG/config/gva-cit.html
===================================================================
--- tags/v2_0_0_Build_2050/applications/appgvSIG/config/gva-cit.html	(revision 0)
+++ tags/v2_0_0_Build_2050/applications/appgvSIG/config/gva-cit.html	(revision 38653)
@@ -0,0 +1,12 @@
+<html>
+<body>
+
+<img src="gva-logo_horiz_bicolor.png"><br>
+
+<h2>GVA</h2>
+<br>
+
+<p>EN CONSTRUCCION</p>
+
+</body>
+</html>
\ No newline at end of file

Property changes on: tags/v2_0_0_Build_2050/applications/appgvSIG/config/gva-cit.html
___________________________________________________________________
Added: svn:mime-type
   + text/plain

Index: tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/app/ApplicationLibrary.java
===================================================================
--- tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/app/ApplicationLibrary.java	(revision 0)
+++ tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/app/ApplicationLibrary.java	(revision 38653)
@@ -0,0 +1,70 @@
+/* gvSIG. Geographic Information System of the Valencian Government
+ *
+ * Copyright (C) 2007-2008 Infrastructures and Transports Department
+ * of the Valencian Government (CIT)
+ *
+ * This program is free software; you can redistribute it and/or
+ * modify it under the terms of the GNU General Public License
+ * as published by the Free Software Foundation; either version 2
+ * of the License, or (at your option) any later version.
+ *
+ * This program is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
+ * GNU General Public License for more details.
+ *
+ * You should have received a copy of the GNU General Public License
+ * along with this program; if not, write to the Free Software
+ * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston,
+ * MA  02110-1301, USA.
+ *
+ */
+
+/*
+ * AUTHORS (In addition to CIT):
+ * 2009 IVER T.I   {{Task}}
+ */
+
+/**
+ *
+ */
+package org.gvsig.app;
+
+import org.gvsig.app.project.DefaultProject;
+import org.gvsig.fmap.mapcontrol.MapControl;
+import org.gvsig.installer.lib.api.InstallerLibrary;
+import org.gvsig.tools.library.AbstractLibrary;
+import org.gvsig.tools.library.LibraryException;
+import org.gvsig.tools.locator.ReferenceNotRegisteredException;
+
+/**
+ * @author 2008-2009 jmvivo
+ * @author 2009- jjdelcerro
+ * 
+ */
+public class ApplicationLibrary extends AbstractLibrary {
+
+    @Override
+    public void doRegistration() {
+        registerAsAPI(ApplicationLibrary.class);
+        require(MapControl.class);
+        require(InstallerLibrary.class);
+    }
+	
+	@Override
+	protected void doInitialize() throws LibraryException {
+		// Do nothing
+	}
+
+	@Override
+	protected void doPostInitialize() throws LibraryException {
+		ApplicationManager manager = ApplicationLocator.getManager();
+		if (manager == null) {
+			throw new ReferenceNotRegisteredException(
+					ApplicationLocator.APPGVSIG_MANAGER_NAME, ApplicationLocator
+							.getInstance());
+		}
+		DefaultProject.registerPersistent();
+		
+	}
+}
\ No newline at end of file

Property changes on: tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/app/ApplicationLibrary.java
___________________________________________________________________
Added: svn:mime-type
   + text/plain

Index: tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/app/extension/ClearSelectionExtension.java
===================================================================
--- tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/app/extension/ClearSelectionExtension.java	(revision 0)
+++ tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/app/extension/ClearSelectionExtension.java	(revision 38653)
@@ -0,0 +1,192 @@
+/*
+ * Created on 31-may-2004
+ *
+ * To change the template for this generated file go to
+ * Window&gt;Preferences&gt;Java&gt;Code Generation&gt;Code and Comments
+ */
+/* gvSIG. Sistema de Informaci�n Geogr�fica de la Generalitat Valenciana
+ *
+ * Copyright (C) 2004 IVER T.I. and Generalitat Valenciana.
+ *
+ * This program is free software; you can redistribute it and/or
+ * modify it under the terms of the GNU General Public License
+ * as published by the Free Software Foundation; either version 2
+ * of the License, or (at your option) any later version.
+ *
+ * This program is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
+ * GNU General Public License for more details.
+ *
+ * You should have received a copy of the GNU General Public License
+ * along with this program; if not, write to the Free Software
+ * Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA  02111-1307,USA.
+ *
+ * For more information, contact:
+ *
+ *  Generalitat Valenciana
+ *   Conselleria d'Infraestructures i Transport
+ *   Av. Blasco Ib��ez, 50
+ *   46010 VALENCIA
+ *   SPAIN
+ *
+ *      +34 963862235
+ *   gvsig@gva.es
+ *      www.gvsig.gva.es
+ *
+ *    or
+ *
+ *   IVER T.I. S.A
+ *   Salamanca 50
+ *   46005 Valencia
+ *   Spain
+ *
+ *   +34 963163400
+ *   dac@iver.es
+ */
+package org.gvsig.app.extension;
+
+import org.gvsig.andami.IconThemeHelper;
+import org.gvsig.andami.PluginServices;
+import org.gvsig.andami.messages.NotificationManager;
+import org.gvsig.andami.plugins.Extension;
+import org.gvsig.app.project.documents.AbstractDocument;
+import org.gvsig.app.project.documents.view.ViewDocument;
+import org.gvsig.app.project.documents.view.gui.AbstractViewPanel;
+import org.gvsig.fmap.dal.exception.DataException;
+import org.gvsig.fmap.dal.exception.ReadException;
+import org.gvsig.fmap.dal.feature.FeatureStore;
+import org.gvsig.fmap.mapcontext.MapContext;
+import org.gvsig.fmap.mapcontext.layers.FLayer;
+import org.gvsig.fmap.mapcontext.layers.FLayers;
+import org.gvsig.fmap.mapcontext.layers.vectorial.FLyrVect;
+import org.gvsig.fmap.mapcontrol.MapControl;
+
+
+
+/**
+ * Extensi�n encargada de limpiar la selecci�n.
+ *
+ * @author Vicente Caballero Navarro
+ */
+public class ClearSelectionExtension extends Extension {
+	/**
+	 * @see com.iver.mdiApp.plugins.IExtension#updateUI(java.lang.String)
+	 */
+	public void execute(String s) {
+		if (s.equalsIgnoreCase("selection-clear-view") ) {
+			boolean refresh = false;
+			org.gvsig.andami.ui.mdiManager.IWindow view =PluginServices.getMDIManager().getActiveWindow();
+
+			if (view instanceof AbstractViewPanel){
+				AbstractViewPanel vista = (AbstractViewPanel) view;
+				ViewDocument model = vista.getModel();
+				MapContext mapa = model.getMapContext();
+				MapControl mapCtrl = vista.getMapControl();
+				FLayers layers = mapa.getLayers();
+				refresh = clearSelectionOfView(layers);
+
+				if (refresh) {
+					mapCtrl.drawMap(false);
+				}
+				((AbstractDocument)vista.getModel()).setModified(true);
+			}
+        }
+    }
+
+
+	private boolean clearSelectionOfView(FLayers layers){
+		boolean refresh=false;
+
+		for (int i = 0; i < layers.getLayersCount(); i++) {
+			FLayer lyr =layers.getLayer(i);
+			if (lyr instanceof FLayers){
+				refresh = refresh || clearSelectionOfView((FLayers) lyr);
+			} else if (lyr instanceof FLyrVect) {
+				FLyrVect lyrVect = (FLyrVect) lyr;
+				if (lyrVect.isActive()) {
+					try {
+						FeatureStore featureStore;
+
+						featureStore = ((FLyrVect)lyr).getFeatureStore();
+						if (featureStore.getFeatureSelection().getSize() != 0) {
+							refresh = true;
+						}
+				        featureStore.getFeatureSelection().deselectAll();
+					} catch (ReadException e) {
+						e.printStackTrace();
+					} catch (DataException e) {
+						// TODO Auto-generated catch block
+						e.printStackTrace();
+					}
+				}
+			}
+		}
+		return refresh;
+	}
+	/**
+	 * @see com.iver.mdiApp.plugins.IExtension#isVisible()
+	 */
+	public boolean isVisible() {
+		org.gvsig.andami.ui.mdiManager.IWindow view = PluginServices.getMDIManager().getActiveWindow();
+
+		if (view == null) {
+			return false;
+		}
+		if (view instanceof AbstractViewPanel) {
+			MapContext mapa = ((AbstractViewPanel) view).getModel().getMapContext();
+			return mapa.getLayers().getLayersCount() > 0;
+		}
+
+		return false;
+	}
+
+	/**
+	 * @see org.gvsig.andami.plugins.IExtension#isEnabled()
+	 */
+	public boolean isEnabled() {
+		org.gvsig.andami.ui.mdiManager.IWindow view = PluginServices.getMDIManager().getActiveWindow();
+		if (view == null) {
+			return false;
+		}
+		if (view instanceof AbstractViewPanel){
+			MapContext mapa = ((AbstractViewPanel) view).getMapControl().getMapContext();
+			return hasVectorLayersWithSelection(mapa.getLayers());
+		}
+		return false;
+	}
+
+	private boolean hasVectorLayersWithSelection(FLayers layers) {
+		for (int i = 0; i < layers.getLayersCount(); i++) {
+			FLayer lyr =layers.getLayer(i);
+			if (lyr instanceof FLayers){
+				if (hasVectorLayersWithSelection((FLayers) lyr)){
+					return true;
+				}
+			} else if (lyr instanceof FLyrVect) {
+				FLyrVect lyrVect = (FLyrVect) lyr;
+				if (lyrVect.isActive()) {
+					if (lyrVect.isAvailable()){
+						try {
+							if (lyrVect.getFeatureStore().getFeatureSelection()
+									.getSize() > 0) {
+								return true;
+							}
+						} catch (DataException e) {
+							e.printStackTrace();
+							NotificationManager.addWarning("Capa " + lyrVect.getName() + " sin recordset correcto",e);
+						}
+					}
+				}
+			}
+		}
+		return false;
+	}
+
+	/**
+	 * @see org.gvsig.andami.plugins.IExtension#initialize()
+	 */
+	public void initialize() {
+		IconThemeHelper.registerIcon("action", "edit-clear", this);
+	}
+}

Property changes on: tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/app/extension/ClearSelectionExtension.java
___________________________________________________________________
Added: svn:keywords
   + Author Date Id Revision
Added: svn:eol-style
   + native

Index: tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/app/extension/ViewProjectWindow.java
===================================================================
--- tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/app/extension/ViewProjectWindow.java	(revision 0)
+++ tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/app/extension/ViewProjectWindow.java	(revision 38653)
@@ -0,0 +1,85 @@
+/* gvSIG. Sistema de Informaci�n Geogr�fica de la Generalitat Valenciana
+ *
+ * Copyright (C) 2004 IVER T.I. and Generalitat Valenciana.
+ *
+ * This program is free software; you can redistribute it and/or
+ * modify it under the terms of the GNU General Public License
+ * as published by the Free Software Foundation; either version 2
+ * of the License, or (at your option) any later version.
+ *
+ * This program is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
+ * GNU General Public License for more details.
+ *
+ * You should have received a copy of the GNU General Public License
+ * along with this program; if not, write to the Free Software
+ * Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA  02111-1307,USA.
+ *
+ * For more information, contact:
+ *
+ *  Generalitat Valenciana
+ *   Conselleria d'Infraestructures i Transport
+ *   Av. Blasco Ib��ez, 50
+ *   46010 VALENCIA
+ *   SPAIN
+ *
+ *      +34 963862235
+ *   gvsig@gva.es
+ *      www.gvsig.gva.es
+ *
+ *    or
+ *
+ *   IVER T.I. S.A
+ *   Salamanca 50
+ *   46005 Valencia
+ *   Spain
+ *
+ *   +34 963163400
+ *   dac@iver.es
+ */
+package org.gvsig.app.extension;
+
+import org.gvsig.andami.PluginServices;
+import org.gvsig.andami.plugins.Extension;
+
+
+/**
+ * Extensi�n que abre la ventana de gestor de proyecto.
+ *
+ * @author Vicente Caballero Navarro
+ */
+public class ViewProjectWindow extends Extension {
+	/**
+	 * @see com.iver.mdiApp.plugins.IExtension#updateUI(java.lang.String)
+	 */
+	public void execute(String arg0) {
+		if (arg0.equalsIgnoreCase("show-project-manager")) {
+			ProjectExtension pe = (ProjectExtension) PluginServices.getExtension(org.gvsig.app.extension.ProjectExtension.class);
+			pe.showProjectWindow();
+		}
+	}
+
+	/**
+	 * @see org.gvsig.andami.plugins.IExtension#initialize()
+	 */
+	public void initialize() {
+	}
+
+	public void postInitialize() {
+		
+	}
+	/**
+	 * @see org.gvsig.andami.plugins.IExtension#isEnabled()
+	 */
+	public boolean isEnabled() {
+		return true;
+	}
+
+	/**
+	 * @see org.gvsig.andami.plugins.IExtension#isVisible()
+	 */
+	public boolean isVisible() {
+		return true;
+	}
+}

Property changes on: tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/app/extension/ViewProjectWindow.java
___________________________________________________________________
Added: svn:keywords
   + Author Date Id Revision
Added: svn:eol-style
   + native

Index: tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/app/extension/MetadataPropertiesExtension.java
===================================================================
--- tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/app/extension/MetadataPropertiesExtension.java	(revision 0)
+++ tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/app/extension/MetadataPropertiesExtension.java	(revision 38653)
@@ -0,0 +1,29 @@
+package org.gvsig.app.extension;
+
+import org.gvsig.andami.plugins.Extension;
+import org.gvsig.app.project.documents.view.legend.gui.ThemeManagerWindow;
+import org.gvsig.app.project.documents.view.metadata.gui.MetadataInfoManager;
+import org.gvsig.fmap.mapcontext.layers.vectorial.FLyrVect;
+
+public class MetadataPropertiesExtension extends Extension {
+
+    public void initialize() {
+		ThemeManagerWindow.addPage(MetadataInfoManager.class);
+		ThemeManagerWindow.setTabEnabledForLayer(MetadataInfoManager.class, FLyrVect.class, true);	
+    }
+    
+    public void postInitialize(){
+    }
+
+    public void execute(String actionCommand) {
+    	// no commands, no code.
+    }
+
+    public boolean isEnabled() {
+        return true;
+    }
+
+    public boolean isVisible() {
+        return false;
+    }
+}
Index: tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/app/extension/FiltroExtension.java
===================================================================
--- tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/app/extension/FiltroExtension.java	(revision 0)
+++ tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/app/extension/FiltroExtension.java	(revision 38653)
@@ -0,0 +1,382 @@
+/* gvSIG. Sistema de Informaci�n Geogr�fica de la Generalitat Valenciana
+ *
+ * Copyright (C) 2004 IVER T.I. and Generalitat Valenciana.
+ *
+ * This program is free software; you can redistribute it and/or
+ * modify it under the terms of the GNU General Public License
+ * as published by the Free Software Foundation; either version 2
+ * of the License, or (at your option) any later version.
+ *
+ * This program is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
+ * GNU General Public License for more details.
+ *
+ * You should have received a copy of the GNU General Public License
+ * along with this program; if not, write to the Free Software
+ * Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA  02111-1307,USA.
+ *
+ * For more information, contact:
+ *
+ *  Generalitat Valenciana
+ *   Conselleria d'Infraestructures i Transport
+ *   Av. Blasco Ib��ez, 50
+ *   46010 VALENCIA
+ *   SPAIN
+ *
+ *      +34 963862235
+ *   gvsig@gva.es
+ *      www.gvsig.gva.es
+ *
+ *    or
+ *
+ *   IVER T.I. S.A
+ *   Salamanca 50
+ *   46005 Valencia
+ *   Spain
+ *
+ *   +34 963163400
+ *   dac@iver.es
+ */
+package org.gvsig.app.extension;
+
+import java.awt.Component;
+import java.util.Iterator;
+
+import javax.swing.JOptionPane;
+
+import org.gvsig.andami.IconThemeHelper;
+import org.gvsig.andami.PluginServices;
+import org.gvsig.andami.messages.NotificationManager;
+import org.gvsig.andami.plugins.Extension;
+import org.gvsig.andami.ui.mdiManager.IWindow;
+import org.gvsig.app.gui.filter.ExpressionListener;
+import org.gvsig.app.gui.filter.FilterDialog;
+import org.gvsig.app.project.documents.AbstractDocument;
+import org.gvsig.app.project.documents.view.ViewDocument;
+import org.gvsig.fmap.dal.DALLocator;
+import org.gvsig.fmap.dal.DataManager;
+import org.gvsig.fmap.dal.exception.DataException;
+import org.gvsig.fmap.dal.feature.Feature;
+import org.gvsig.fmap.dal.feature.FeatureQuery;
+import org.gvsig.fmap.dal.feature.FeatureSelection;
+import org.gvsig.fmap.dal.feature.FeatureSet;
+import org.gvsig.fmap.dal.feature.FeatureStore;
+import org.gvsig.fmap.mapcontext.layers.FLayer;
+import org.gvsig.fmap.mapcontext.layers.vectorial.FLyrVect;
+import org.gvsig.utils.exceptionHandling.ExceptionListener;
+
+/**
+ * Extensi�n que abre un di�logo para poder hacer un filtro de una capa o tabla.
+ * 
+ * @author Vicente Caballero Navarro
+ */
+public class FiltroExtension extends Extension implements ExpressionListener {
+
+    protected FeatureStore featureStore = null;
+    private String filterTitle;
+
+    /**
+     * DOCUMENT ME!
+     */
+    public void initialize() {
+    	IconThemeHelper.registerIcon("action", "layer-filter", this);
+    }
+
+    /**
+     * DOCUMENT ME!
+     * 
+     * @param actionCommand
+     *            DOCUMENT ME!
+     */
+    public void execute(String actionCommand) {
+        if ("layer-filter".equalsIgnoreCase(actionCommand)) {
+            // try {
+            IWindow v = PluginServices.getMDIManager().getActiveWindow();
+
+            if (v instanceof org.gvsig.app.project.documents.view.gui.DefaultViewPanel) {
+                ViewDocument pv =
+                    ((org.gvsig.app.project.documents.view.gui.DefaultViewPanel) v)
+                        .getModel();
+                filterTitle =
+                    ((org.gvsig.app.project.documents.view.gui.DefaultViewPanel) v)
+                        .getModel().getName();
+                FLayer layer = pv.getMapContext().getLayers().getActives()[0];
+                featureStore = ((FLyrVect) layer).getFeatureStore();// pv.getProject().getDataSourceByLayer(layer);
+                ((AbstractDocument) pv).setModified(true);
+            }
+            // } catch (ReadException e) {
+            // NotificationManager.addError("Error filtrando", e);
+            // }
+
+            doExecute();
+        }
+    }
+
+    /**
+     * "execute" method action.
+     * 
+     */
+    protected void doExecute() {
+        // DefaultExpressionDataSource ds = new DefaultExpressionDataSource();
+        // ds.setTable(featureStore);
+        FilterDialog dlg = new FilterDialog(filterTitle);
+        dlg.addExpressionListener(this);
+        dlg.addExceptionListener(new ExceptionListener() {
+
+            public void exceptionThrown(Throwable t) {
+                NotificationManager.addError(t.getMessage(), t);
+            }
+        });
+        dlg.setModel(featureStore);
+        PluginServices.getMDIManager().addWindow(dlg);
+    }
+
+    /**
+     * DOCUMENT ME!
+     * 
+     * @return DOCUMENT ME!
+     */
+    public boolean isEnabled() {
+        IWindow v = PluginServices.getMDIManager().getActiveWindow();
+
+        if (v == null) {
+            return false;
+        }
+
+        if (v instanceof org.gvsig.app.project.documents.view.gui.DefaultViewPanel) {
+            org.gvsig.app.project.documents.view.gui.DefaultViewPanel view =
+                (org.gvsig.app.project.documents.view.gui.DefaultViewPanel) v;
+            ViewDocument pv = view.getModel();
+            FLayer[] seleccionadas =
+                pv.getMapContext().getLayers().getActives();
+
+            if (seleccionadas.length == 1) {
+                if (seleccionadas[0].isAvailable()
+                    && (seleccionadas[0] instanceof FLyrVect)) {
+                    return true;
+                }
+            }
+        }
+        return false;
+    }
+
+    /**
+     * DOCUMENT ME!
+     * 
+     * @return DOCUMENT ME!
+     */
+    public boolean isVisible() {
+        IWindow v = PluginServices.getMDIManager().getActiveWindow();
+
+        if (v == null) {
+            return false;
+        }
+
+        if (v instanceof org.gvsig.app.project.documents.view.gui.DefaultViewPanel) {
+            org.gvsig.app.project.documents.view.gui.DefaultViewPanel view =
+                (org.gvsig.app.project.documents.view.gui.DefaultViewPanel) v;
+            ViewDocument pv = view.getModel();
+            FLayer[] seleccionadas =
+                pv.getMapContext().getLayers().getActives();
+
+            if (seleccionadas.length == 1) {
+                if (seleccionadas[0] instanceof FLyrVect) {
+                    return true;
+                }
+            }
+        }
+
+        return false;
+    }
+
+    /**
+     * DOCUMENT ME!
+     * 
+     * @param expression
+     *            DOCUMENT ME!
+     */
+    // By Pablo: if no filter expression -> no element selected
+    public void newSet(String expression) throws DataException {
+        if (!this.filterExpressionFromWhereIsEmpty(expression)) {
+            FeatureSet set = null;
+            try {
+                set = doSet(expression);
+
+                if (set == null) {
+                    // throw new RuntimeException("Not a 'where' clause?");
+                    return;
+                }
+                featureStore.setSelection(set);
+
+            } catch (Exception e) {
+                JOptionPane.showMessageDialog((Component) PluginServices
+                    .getMainFrame(),
+                    "Asegurate de que la consulta es correcta.");
+            } finally {
+                if (set != null) {
+                    set.dispose();
+                }
+            }
+        } else {
+            // By Pablo: if no expression -> no element selected
+            featureStore.getFeatureSelection().deselectAll();
+        }
+    }
+
+    /**
+     * @throws DataException
+     * @see org.gvsig.app.gui.filter.ExpressionListener#newSet(java.lang.String)
+     */
+    private FeatureSet doSet(String expression) throws DataException {
+        FeatureQuery query = featureStore.createFeatureQuery();
+        DataManager manager = DALLocator.getDataManager();
+        query.setFilter(manager.createExpresion(expression));
+        return featureStore.getFeatureSet(query);
+        // try {
+        // DataSource ds =
+        // LayerFactory.getDataSourceFactory().executeSQL(expression,
+        // DataSourceFactory.MANUAL_OPENING);
+        //
+        // return ds.getWhereFilter();
+        // } catch (DriverLoadException e) {
+        // JOptionPane.showMessageDialog((Component)PluginServices.getMainFrame(),PluginServices.getText(this,"driver_error")+"\n"+e.getMessage());
+        // } catch (ReadDriverException e) {
+        // JOptionPane.showMessageDialog((Component)PluginServices.getMainFrame(),PluginServices.getText(this,"driver_error")+"\n"+e.getMessage());
+        // } catch (ParseException e) {
+        // JOptionPane.showMessageDialog((Component)PluginServices.getMainFrame(),PluginServices.getText(this,"parse_expresion_error")+"\n"+e.getMessage());
+        // } catch (SemanticException e) {
+        // JOptionPane.showMessageDialog((Component)PluginServices.getMainFrame(),PluginServices.getText(this,"semantic_expresion_error")+"\n"+e.getMessage());
+        // } catch (IOException e) {
+        // JOptionPane.showMessageDialog((Component)PluginServices.getMainFrame(),PluginServices.getText(this,"input_output_error")+"\n"+e.getMessage());
+        // } catch (EvaluationException e) {
+        // JOptionPane.showMessageDialog((Component)PluginServices.getMainFrame(),PluginServices.getText(this,"parse_expresion_error")+"\n"+e.getMessage());
+        // } catch (com.hardcode.gdbms.parser.TokenMgrError e) {
+        // JOptionPane.showMessageDialog((Component)PluginServices.getMainFrame(),PluginServices.getText(this,"expresion_error")+"\n"+e.getMessage());
+        // }
+        // return null;
+    }
+
+    /**
+     * DOCUMENT ME!
+     * 
+     * @param expression
+     *            DOCUMENT ME!
+     * @throws DataException
+     */
+    public void addToSet(String expression) throws DataException {
+        // By Pablo: if no filter expression -> don't add more elements to set
+        if (!this.filterExpressionFromWhereIsEmpty(expression)) {
+            FeatureSet set = null;
+            try {
+                set = doSet(expression);
+
+                if (set == null) {
+                    // throw new RuntimeException("Not a 'where' clause?");
+                    return;
+                }
+                featureStore.getFeatureSelection().select(set);
+            } finally {
+                if (set != null) {
+                    set.dispose();
+                }
+            }
+
+            // FBitSet selection = new FBitSet();
+            //
+            // for (int i = 0; i < sel.length; i++) {
+            // selection.set((int) sel[i]);
+            // }
+            //
+            // FBitSet fbs = featureStore.getSelection();
+            // fbs.or(selection);
+            // featureStore.setSelection(fbs);
+        }
+    }
+
+    /**
+     * DOCUMENT ME!
+     * 
+     * @param expression
+     *            DOCUMENT ME!
+     */
+    public void fromSet(String expression) throws DataException {
+        // By Pablo: if no filter expression -> no element selected
+        try {
+            if (!this.filterExpressionFromWhereIsEmpty(expression)) {
+                // NotificationManager.showMessageInfo("Falta por implementar",
+                // null);
+
+                FeatureSet set = null;
+                set = doSet(expression);
+
+                if (set == null) {
+                    throw new RuntimeException("Not a 'where' clause?");
+                }
+
+                FeatureSelection oldSelection =
+                    featureStore.getFeatureSelection();
+
+                FeatureSelection newSelection =
+                    featureStore.createFeatureSelection();
+                Iterator iterator = set.iterator();
+                while (iterator.hasNext()) {
+                    Feature feature = (Feature) iterator.next();
+                    if (oldSelection.isSelected(feature)) {
+                        newSelection.select(feature);
+                    }
+                }
+                featureStore.setSelection(newSelection);
+                set.dispose();
+
+            } else {
+                // By Pablo: if no expression -> no element selected
+                featureStore.getFeatureSelection().deselectAll();
+                ;
+            }
+        } catch (DataException e) {
+            NotificationManager.addError(e);
+        }
+
+    }
+
+    /**
+     * Returns true if the WHERE subconsultation of the filterExpression is
+     * empty ("")
+     * 
+     * @author Pablo Piqueras Bartolom� (p_queras@hotmail.com)
+     * @param expression
+     *            An string
+     * @return A boolean value
+     */
+    private boolean filterExpressionFromWhereIsEmpty(String expression) {
+        String subExpression = expression.trim();
+        int pos;
+
+        // Remove last ';' if exists
+        if (subExpression.charAt(subExpression.length() - 1) == ';') {
+            subExpression =
+                subExpression.substring(0, subExpression.length() - 1).trim();
+        }
+
+        // If there is no 'where' clause
+        if ((pos = subExpression.indexOf("where")) == -1) {
+            return false;
+        }
+
+        // If there is no subexpression in the WHERE clause -> true
+        subExpression =
+            subExpression.substring(pos + 5, subExpression.length()).trim(); // +
+        // 5
+        // is
+        // the
+        // length
+        // of
+        // 'where'
+        if (subExpression.length() == 0) {
+            return true;
+        } else {
+            return false;
+        }
+    }
+}

Property changes on: tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/app/extension/FiltroExtension.java
___________________________________________________________________
Added: svn:eol-style
   + native
Added: svn:keywords
   + Author Date Id Revision

Index: tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/app/extension/MeasureExtension.java
===================================================================
--- tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/app/extension/MeasureExtension.java	(revision 0)
+++ tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/app/extension/MeasureExtension.java	(revision 38653)
@@ -0,0 +1,155 @@
+
+/* gvSIG. Sistema de Informaci�n Geogr�fica de la Generalitat Valenciana
+ *
+ * Copyright (C) 2005 IVER T.I. and Generalitat Valenciana.
+ *
+ * This program is free software; you can redistribute it and/or
+ * modify it under the terms of the GNU General Public License
+ * as published by the Free Software Foundation; either version 2
+ * of the License, or (at your option) any later version.
+ *
+ * This program is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
+ * GNU General Public License for more details.
+ *
+ * You should have received a copy of the GNU General Public License
+ * along with this program; if not, write to the Free Software
+ * Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA  02111-1307,USA.
+ *
+ * For more information, contact:
+ *
+ *  Generalitat Valenciana
+ *   Conselleria d'Infraestructures i Transport
+ *   Av. Blasco Ib��ez, 50
+ *   46010 VALENCIA
+ *   SPAIN
+ *
+ *      +34 963862235
+ *   gvsig@gva.es
+ *      www.gvsig.gva.es
+ *
+ *    or
+ *
+ *   IVER T.I. S.A
+ *   Salamanca 50
+ *   46005 Valencia
+ *   Spain
+ *
+ *   +34 963163400
+ *   dac@iver.es
+ */
+
+package org.gvsig.app.extension;
+
+import org.gvsig.andami.IconThemeHelper;
+import org.gvsig.andami.PluginServices;
+import org.gvsig.andami.plugins.Extension;
+import org.gvsig.app.project.documents.view.ViewDocument;
+import org.gvsig.app.project.documents.view.gui.DefaultViewPanel;
+import org.gvsig.fmap.mapcontext.MapContext;
+import org.gvsig.fmap.mapcontext.layers.FLayers;
+import org.gvsig.fmap.mapcontrol.MapControl;
+
+
+
+/**
+ * Extensi�n que controla las operaciones de medida realizadas sobre la vista.
+ *
+ * @author Vicente Caballero Navarro
+ */
+public class MeasureExtension extends Extension {
+    private void registerDistanceUnits() {
+    	MapContext.addDistanceUnit("Millas_Nauticas","nmi",1852);
+    	MapContext.addDistanceUnit("Decimetros","dm",0.1);
+    }
+private void registerAreaUnits(){
+	MapContext.addAreaUnit("Areas","a",false,10);
+	MapContext.addAreaUnit("Hectareas","ha",false,100);
+	MapContext.addAreaUnit("HanegadasV","hgV",false,28.8287);
+	MapContext.addAreaUnit("HanegadasC","hgC",false,80.2467);
+	MapContext.addAreaUnit("Decimetros","dm",true,0.1);
+	MapContext.addAreaUnit("Acres","acre",false,63.6149);
+	MapContext.addAreaUnit("Millas_Nauticas","nmi",true,1852);
+}
+	/* (non-Javadoc)
+     * @see com.iver.andami.plugins.IExtension#initialize()
+     */
+    public void initialize() {
+    	registerDistanceUnits();
+    	registerAreaUnits();
+    	IconThemeHelper.registerIcon("action", "view-query-distance", this);
+    	IconThemeHelper.registerIcon("action", "view-query-area", this);
+    }
+
+    /* (non-Javadoc)
+     * @see com.iver.andami.plugins.IExtension#execute(java.lang.String)
+     */
+    public void execute(String s) {
+        org.gvsig.andami.ui.mdiManager.IWindow view = PluginServices.getMDIManager()
+                                                                   .getActiveWindow();
+
+        if (!(view instanceof DefaultViewPanel)) {
+            return;
+        }
+
+        DefaultViewPanel vista = (DefaultViewPanel) view;
+        MapControl mapCtrl = vista.getMapControl();
+
+        if (s.equals("MEDICION")) {
+            mapCtrl.setTool("medicion");
+        } else if (s.equals("AREA")) {
+            mapCtrl.setTool("area");
+        }
+    }
+
+    /* (non-Javadoc)
+     * @see com.iver.andami.plugins.IExtension#isEnabled()
+     */
+    public boolean isEnabled() {
+        org.gvsig.andami.ui.mdiManager.IWindow f = PluginServices.getMDIManager()
+                                                                .getActiveWindow();
+
+        if (f == null) {
+            return false;
+        }
+
+        if (f instanceof DefaultViewPanel) {
+            DefaultViewPanel vista = (DefaultViewPanel) f;
+            ViewDocument model = vista.getModel();
+            MapContext mapa = model.getMapContext();
+
+            FLayers layers = mapa.getLayers();
+
+            for (int i = 0; i < layers.getLayersCount(); i++) {
+                if (layers.getLayer(i).isAvailable()) {
+                    return true;
+                }
+            }
+        }
+
+        return false;
+    }
+
+    /* (non-Javadoc)
+     * @see com.iver.andami.plugins.IExtension#isVisible()
+     */
+    public boolean isVisible() {
+        org.gvsig.andami.ui.mdiManager.IWindow f = PluginServices.getMDIManager()
+                                                                .getActiveWindow();
+
+        if (f == null) {
+            return false;
+        }
+
+        if (f instanceof DefaultViewPanel) {
+            DefaultViewPanel vista = (DefaultViewPanel) f;
+            ViewDocument model = vista.getModel();
+            MapContext mapa = model.getMapContext();
+
+            return mapa.getLayers().getLayersCount() > 0;
+        }
+
+        return false;
+    }
+}

Property changes on: tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/app/extension/MeasureExtension.java
___________________________________________________________________
Added: svn:keywords
   + Author Date Id Revision
Added: svn:eol-style
   + native

Index: tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/app/extension/ViewControls.java
===================================================================
--- tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/app/extension/ViewControls.java	(revision 0)
+++ tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/app/extension/ViewControls.java	(revision 38653)
@@ -0,0 +1,290 @@
+/*
+ * Created on 20-feb-2004
+ *
+ * To change the template for this generated file go to
+ * Window&gt;Preferences&gt;Java&gt;Code Generation&gt;Code and Comments
+ */
+/* gvSIG. Sistema de Informaci�n Geogr�fica de la Generalitat Valenciana
+ *
+ * Copyright (C) 2004 IVER T.I. and Generalitat Valenciana.
+ *
+ * This program is free software; you can redistribute it and/or
+ * modify it under the terms of the GNU General Public License
+ * as published by the Free Software Foundation; either version 2
+ * of the License, or (at your option) any later version.
+ *
+ * This program is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
+ * GNU General Public License for more details.
+ *
+ * You should have received a copy of the GNU General Public License
+ * along with this program; if not, write to the Free Software
+ * Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA  02111-1307,USA.
+ *
+ * For more information, contact:
+ *
+ *  Generalitat Valenciana
+ *   Conselleria d'Infraestructures i Transport
+ *   Av. Blasco Ib��ez, 50
+ *   46010 VALENCIA
+ *   SPAIN
+ *
+ *      +34 963862235
+ *   gvsig@gva.es
+ *      www.gvsig.gva.es
+ *
+ *    or
+ *
+ *   IVER T.I. S.A
+ *   Salamanca 50
+ *   46005 Valencia
+ *   Spain
+ *
+ *   +34 963163400
+ *   dac@iver.es
+ */
+package org.gvsig.app.extension;
+
+import javax.swing.JOptionPane;
+
+import org.gvsig.andami.IconThemeHelper;
+import org.gvsig.andami.PluginServices;
+import org.gvsig.andami.plugins.Extension;
+import org.gvsig.andami.preferences.IPreference;
+import org.gvsig.andami.preferences.IPreferenceExtension;
+import org.gvsig.app.gui.preferencespage.GridPage;
+import org.gvsig.app.gui.preferencespage.ViewPage;
+import org.gvsig.app.project.Project;
+import org.gvsig.app.project.documents.view.Encuadrator;
+import org.gvsig.app.project.documents.view.ViewDocument;
+import org.gvsig.app.project.documents.view.gui.DefaultViewPanel;
+import org.gvsig.app.project.documents.view.gui.ExtentListSelectorModel;
+import org.gvsig.app.project.documents.view.gui.FPanelExtentSelector;
+import org.gvsig.app.project.documents.view.gui.FPanelLocConfig;
+import org.gvsig.app.project.documents.view.toc.gui.FPopupMenu;
+import org.gvsig.app.project.documents.view.toolListeners.snapping.Snapping;
+import org.gvsig.fmap.mapcontext.MapContext;
+import org.gvsig.fmap.mapcontext.layers.FLayer;
+import org.gvsig.fmap.mapcontext.layers.FLayers;
+import org.gvsig.fmap.mapcontrol.MapControl;
+import org.gvsig.tools.ToolsLocator;
+import org.gvsig.tools.dataTypes.DataTypes;
+import org.gvsig.tools.extensionpoint.ExtensionPointManager;
+import org.slf4j.Logger;
+import org.slf4j.LoggerFactory;
+
+
+
+//import com.iver.utiles.FPanelExtentSelector;
+
+/**
+ * Extensi�n que controla las operaciones b�sicas realizadas sobre la vista.
+ *
+ * @author vcn
+ */
+public class ViewControls extends Extension implements IPreferenceExtension{
+    private static final Logger logger = LoggerFactory
+            .getLogger(ViewInvertSelection.class);
+    
+	private static ViewPage viewPropertiesPage = null;
+	private DefaultViewPanel vista;
+	/**
+	 * @see com.iver.mdiApp.plugins.IExtension#updateUI(java.lang.String)
+	 */
+	public void execute(String s) {
+		execute(s,null);
+	}
+	
+	public void execute(String command, Object[] args) {
+		ViewDocument document = vista.getViewDocument();
+		MapContext mapa = document.getMapContext();
+		MapControl mapCtrl = vista.getMapControl();
+
+		if (command.equalsIgnoreCase("view-navigation-zoom-all") ) {
+			// mapa.beginAtomicEvent();
+			mapa.getViewPort().setEnvelope(mapa.getLayers().getFullEnvelope());
+			document.setModified(true);
+			// mapa.endAtomicEvent();
+			
+		} else if (command.equalsIgnoreCase("view-navigation-frame-manager") ) {
+			FPanelExtentSelector l = new FPanelExtentSelector();
+
+			ProjectExtension p = (ProjectExtension) PluginServices.getExtension(org.gvsig.app.extension.ProjectExtension.class);
+			Project project = p.getProject();
+			ExtentListSelectorModel modelo = new ExtentListSelectorModel(project);
+			//ProjectExtent[] extents = project.getExtents();
+			project.addPropertyChangeListener(modelo);
+			l.setModel(modelo);
+			l.addSelectionListener(new Encuadrator(project, mapa, vista));
+			document.setModified(true);
+			PluginServices.getMDIManager().addWindow(l);
+			
+		} else if (command.equalsIgnoreCase("view-locator-setup") ) {
+			//Set up the map overview
+			FPanelLocConfig m_panelLoc = new FPanelLocConfig(vista.getMapOverview());
+			PluginServices.getMDIManager().addWindow(m_panelLoc);
+			m_panelLoc.setPreferredSize(m_panelLoc.getSize());
+			document.setModified(true);
+			
+		} else if (command.equalsIgnoreCase("view-navigation-pan") ) {
+			mapCtrl.setTool("pan");
+			document.setModified(true);
+			
+		} else if (command.equalsIgnoreCase("view-navigation-zoom-in-topoint") ) {
+			mapCtrl.setTool("zoomIn");
+			document.setModified(true);
+			
+		} else if (command.equalsIgnoreCase("view-navigation-zoom-out-topoint") ) {
+			mapCtrl.setTool("zoomOut");
+			document.setModified(true);
+			
+		} else if (command.equalsIgnoreCase("layer-set-visible") ) {
+			setVisibles(true, mapa.getLayers());
+			document.setModified(true);
+			
+		} else if (command.equalsIgnoreCase("layer-set-hide") ) {
+			setVisibles(false, mapa.getLayers());
+			document.setModified(true);
+			
+		} else if (command.equalsIgnoreCase("layer-set-active") ) {
+			setActives(true, mapa.getLayers());
+			document.setModified(true);
+			
+		} else if (command.equalsIgnoreCase("layer-set-inactive") ) {
+			setActives(false, mapa.getLayers());
+			document.setModified(true);
+			
+		} else if (command.equalsIgnoreCase("view-navigation-zoom-in-center") ) {
+			mapCtrl.zoomIn();
+			document.setModified(true);
+			
+		} else if (command.equalsIgnoreCase("view-navigation-zoom-out-center") ) {
+			mapCtrl.zoomOut();
+			document.setModified(true);
+			
+		} else if (command.equalsIgnoreCase("view-change-scale")) {
+			try {
+				Long scale = (Long) ToolsLocator.getDataTypesManager().coerce(DataTypes.LONG, args[0]);
+				mapa.setScaleView(scale.longValue());
+				document.setModified(true);
+			} catch(Throwable ex) {
+				logger.info("Can't change scale of view.", ex);
+				PluginServices.getMainFrame().getStatusBar().message("Can't change scale of view.", JOptionPane.ERROR_MESSAGE);
+			}
+		}
+	}
+
+	private ViewPage getViewPropertiesPage(){
+		if(viewPropertiesPage==null){
+			viewPropertiesPage = new ViewPage();
+		}
+		return viewPropertiesPage;
+	}
+	/**
+	 * Pone todas las capas visibles o no visibles.
+	 *
+	 * @param visible true si que quieren poner a visibles.
+	 * @param mapa FMap sobre el que actuar.
+	 */
+	private void setVisibles(boolean visible, FLayers layers) {
+		int layerCount=layers.getLayersCount();
+		for (int i = 0; i < layerCount; i++) {
+			FLayer layer = layers.getLayer(i);
+			layer.setVisible(visible);
+			if (layer instanceof FLayers){
+				setVisibles(visible,(FLayers)layer);
+			}
+		}
+	}
+	
+	/**
+	 * Pone todas las capas activas o no activas.
+	 *
+	 * @param active true si que quieren poner a activas.
+	 * @param mapa FMap sobre el que actuar.
+	 */
+	private void setActives(boolean active, FLayers layers) {
+		int layerCount=layers.getLayersCount();
+		for (int i = 0; i < layerCount; i++) {
+			FLayer layer = layers.getLayer(i);
+			layer.setActive(active);
+			if (layer instanceof FLayers){
+				setActives(active,(FLayers)layer);
+			}
+		}
+	}
+	/**
+	 * @see com.iver.mdiApp.plugins.IExtension#isVisible()
+	 */
+	public boolean isVisible() {
+		org.gvsig.andami.ui.mdiManager.IWindow f = PluginServices.getMDIManager()
+															 .getActiveWindow();
+
+		if (f!=null && f instanceof DefaultViewPanel) {
+			vista = (DefaultViewPanel) f;
+			ViewDocument model = vista.getViewDocument();
+			MapContext mapa = model.getMapContext();
+
+			return mapa.getLayers().getLayersCount() > 0;
+		}
+			return false;
+	}
+
+	/**
+	 * @see org.gvsig.andami.plugins.IExtension#initialize()
+	 */
+	public void initialize() {
+
+		ExtensionPointManager epManager = ToolsLocator.getExtensionPointManager();
+
+		if (!epManager.has("View_TocActions")) {
+			epManager.add(
+					"View_TocActions",
+					"Context menu options of the TOC " +
+						" in the view window "+
+						"(register instances of " +
+						"org.gvsig.app.gui.toc.AbstractTocContextMenuAction)"
+			);
+		}
+
+		FPopupMenu.registerExtensionPoint();
+
+		registerIcons();
+		Snapping.register();
+	}
+
+	private void registerIcons(){
+		IconThemeHelper.registerIcon("action", "view-navigation-zoom-in-topoint", this);
+		IconThemeHelper.registerIcon("action", "view-navigation-zoom-out-topoint", this);
+		IconThemeHelper.registerIcon("action", "view-navigation-zoom-all", this);
+		IconThemeHelper.registerIcon("action", "view-navigation-zoom-in-center", this);
+		IconThemeHelper.registerIcon("action", "view-navigation-zoom-out-center", this);
+		IconThemeHelper.registerIcon("action", "view-navigation-pan", this);
+		IconThemeHelper.registerIcon("action", "view-navigation-frame-manager", this);
+	}
+
+	/**
+	 * @see org.gvsig.andami.plugins.IExtension#isEnabled()
+	 */
+	public boolean isEnabled() {
+		ViewDocument model = vista.getViewDocument();
+		MapContext mapa = model.getMapContext();
+
+		FLayers layers = mapa.getLayers();
+		for (int i=0;i<layers.getLayersCount();i++) {
+			if (layers.getLayer(i).isAvailable()) {
+				return true;
+			}
+		}
+		return false;
+	}
+
+	public IPreference[] getPreferencesPages() {
+		IPreference[] preferences=new IPreference[2];
+		preferences[0]=getViewPropertiesPage();
+		GridPage gridPage=new GridPage();
+		preferences[1]=gridPage;
+		return preferences;
+	}
+}

Property changes on: tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/app/extension/ViewControls.java
___________________________________________________________________
Added: svn:keywords
   + Author Date Id Revision
Added: svn:eol-style
   + native

Index: tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/app/extension/ViewSelectionByTheme.java
===================================================================
--- tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/app/extension/ViewSelectionByTheme.java	(revision 0)
+++ tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/app/extension/ViewSelectionByTheme.java	(revision 38653)
@@ -0,0 +1,180 @@
+/* gvSIG. Sistema de Informaci�n Geogr�fica de la Generalitat Valenciana
+ *
+ * Copyright (C) 2005 IVER T.I. and Generalitat Valenciana.
+ *
+ * This program is free software; you can redistribute it and/or
+ * modify it under the terms of the GNU General Public License
+ * as published by the Free Software Foundation; either version 2
+ * of the License, or (at your option) any later version.
+ *
+ * This program is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
+ * GNU General Public License for more details.
+ *
+ * You should have received a copy of the GNU General Public License
+ * along with this program; if not, write to the Free Software
+ * Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA  02111-1307,USA.
+ *
+ * For more information, contact:
+ *
+ *  Generalitat Valenciana
+ *   Conselleria d'Infraestructures i Transport
+ *   Av. Blasco Ib��ez, 50
+ *   46010 VALENCIA
+ *   SPAIN
+ *
+ *      +34 963862235
+ *   gvsig@gva.es
+ *      www.gvsig.gva.es
+ *
+ *    or
+ *
+ *   IVER T.I. S.A
+ *   Salamanca 50
+ *   46005 Valencia
+ *   Spain
+ *
+ *   +34 963163400
+ *   dac@iver.es
+ */
+
+/* CVS MESSAGES:
+ *
+ * $Id: ViewSelectionControls.java 26282 2009-01-29 09:58:42Z vcaballero $
+ * $Log$
+ * Revision 1.16  2007-03-06 16:34:02  caballero
+ * Exceptions
+ *
+ * Revision 1.15  2007/01/04 07:24:32  caballero
+ * isModified
+ *
+ * Revision 1.14  2006/12/27 11:08:56  fdiaz
+ * Arreglado el metodo hasVectorLayers para que no se pare en los grupos de capas cuando estos no tienen capas vectoriales.
+ *
+ * Revision 1.13  2006/09/25 16:54:12  caballero
+ * invert selection
+ *
+ * Revision 1.12  2006/09/20 13:17:40  jaume
+ * *** empty log message ***
+ *
+ * Revision 1.11  2006/09/20 10:56:56  sbayarri
+ * Refactorizaci�n clases View y ProjectView
+ *
+ * Revision 1.10  2006/09/15 10:40:03  caballero
+ * extensibilidad de documentos
+ *
+ * Revision 1.9  2006/09/11 16:14:15  fjp
+ * Invertir seleccion. Falta subirlo al branch de la 1.0
+ *
+ * Revision 1.8  2006/09/11 06:53:13  fjp
+ * Antes del parto
+ *
+ * Revision 1.7  2006/09/04 16:26:54  fjp
+ * Seleccionar por pol�gono
+ *
+ * Revision 1.6  2006/08/29 07:56:27  cesar
+ * Rename the *View* family of classes to *Window* (ie: SingletonView to SingletonWindow, ViewInfo to WindowInfo, etc)
+ *
+ * Revision 1.5  2006/08/29 07:21:08  cesar
+ * Rename com.iver.cit.gvsig.fmap.Fmap class to com.iver.cit.gvsig.fmap.MapContext
+ *
+ * Revision 1.4  2006/08/29 07:13:53  cesar
+ * Rename class com.iver.andami.ui.mdiManager.View to com.iver.andami.ui.mdiManager.IWindow
+ *
+ * Revision 1.3  2006/08/18 08:40:04  jmvivo
+ * Actualizado para que el isEnabled tenga en cuenta que las capas esten 'avialable'
+ *
+ * Revision 1.2  2006/07/27 06:20:28  jaume
+ * *** empty log message ***
+ *
+ * Revision 1.1  2006/07/26 09:53:05  jaume
+ * separadas las herramientas de selecci�n del viewControls al ViewSelectionControls
+ *
+ *
+ */
+package org.gvsig.app.extension;
+
+import org.gvsig.andami.PluginServices;
+import org.gvsig.andami.plugins.Extension;
+import org.gvsig.andami.ui.mdiManager.IWindow;
+import org.gvsig.app.gui.selectionByTheme.DefaultSelectionByThemeModel;
+import org.gvsig.app.gui.selectionByTheme.MySelectionByThemeListener;
+import org.gvsig.app.gui.selectionByTheme.SelectionByTheme;
+import org.gvsig.app.project.documents.AbstractDocument;
+import org.gvsig.app.project.documents.view.ViewDocument;
+import org.gvsig.app.project.documents.view.gui.DefaultViewPanel;
+import org.gvsig.fmap.mapcontext.MapContext;
+import org.gvsig.fmap.mapcontext.layers.FLayer;
+import org.gvsig.fmap.mapcontext.layers.FLayers;
+import org.gvsig.fmap.mapcontext.layers.vectorial.FLyrVect;
+import org.slf4j.Logger;
+import org.slf4j.LoggerFactory;
+
+
+/**
+ * Extension that handles the selection tools, selection tools have sense on
+ * vectorial layers only.
+ *
+ * @author Vicente Caballero Navarro
+ *
+ */
+public class ViewSelectionByTheme extends Extension {
+    private static final Logger logger = LoggerFactory
+            .getLogger(ViewSelectionByTheme.class);
+    
+	private DefaultViewPanel vista;
+	public void initialize() {
+	}
+
+	public void execute(String actionCommand) {
+		if (actionCommand.equalsIgnoreCase("selection-select-by-layer")) {
+			SelectionByTheme dlg = new SelectionByTheme();
+			dlg.setModel(new DefaultSelectionByThemeModel());
+			dlg.addSelectionListener(new MySelectionByThemeListener());
+			PluginServices.getMDIManager().addWindow(dlg);
+			((AbstractDocument)vista.getModel()).setModified(true);
+		}
+	}
+
+	public boolean isEnabled() {
+		ViewDocument model = vista.getModel();
+		MapContext mapa = model.getMapContext();
+
+		for (int i = 0; i < mapa.getLayers().getActives().length; i++) {
+			FLayer lyr = mapa.getLayers().getActives()[i];
+			if (lyr.isAvailable() && lyr instanceof FLyrVect){// && !lyr.isEditing()) {
+				return true;
+			}
+		}
+		return false;
+	}
+
+	public boolean isVisible() {
+		IWindow f = PluginServices.getMDIManager().getActiveWindow();
+
+		if (f != null && f instanceof DefaultViewPanel) {
+			vista = (DefaultViewPanel) f;
+			ViewDocument model = vista.getModel();
+			MapContext mapa = model.getMapContext();
+
+			return hasVectorLayers(mapa.getLayers());
+
+		}
+		return false;
+	}
+
+	private boolean hasVectorLayers(FLayers layers) {
+		for (int i = 0; i < layers.getLayersCount(); i++) {
+			FLayer lyr =layers.getLayer(i);
+			if (lyr instanceof FLayers){
+				if (hasVectorLayers((FLayers) lyr)){
+					return true;
+				}
+			} else if (lyr instanceof FLyrVect) {
+				return true;
+			}
+		}
+		return false;
+	}
+}
Index: tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/app/extension/develtools/PersistenceDevelTool.java
===================================================================
--- tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/app/extension/develtools/PersistenceDevelTool.java	(revision 0)
+++ tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/app/extension/develtools/PersistenceDevelTool.java	(revision 38653)
@@ -0,0 +1,245 @@
+package org.gvsig.app.extension.develtools;
+
+import java.util.ArrayList;
+import java.util.Collections;
+import java.util.Comparator;
+import java.util.List;
+import java.util.Set;
+import java.util.TreeSet;
+
+import org.gvsig.tools.ToolsLocator;
+import org.gvsig.tools.dataTypes.DataTypesManager;
+import org.gvsig.tools.dynobject.DynField;
+import org.gvsig.tools.dynobject.DynStruct;
+import org.gvsig.tools.persistence.PersistenceFactory;
+import org.gvsig.tools.persistence.PersistenceManager;
+import org.gvsig.tools.persistence.Persistent;
+import org.gvsig.tools.swing.api.windowmanager.WindowManager;
+import org.slf4j.Logger;
+import org.slf4j.LoggerFactory;
+
+public class PersistenceDevelTool {
+	private static Logger logger = LoggerFactory.getLogger(PersistenceDevelTool.class);
+
+	public void showPersistenceFactories() {
+		String html = this.getPersistenceFactories();
+		InfoPanel.save2file("persistenceinfo", html);
+		InfoPanel.showPanel("Persistence factories", WindowManager.MODE.WINDOW, html);
+	}
+	
+
+	public class PersistenceInfo implements Comparable<PersistenceInfo> {
+		PersistenceFactory factory;
+		@SuppressWarnings("rawtypes")
+		Class theClass;
+		DynStruct definition;
+
+		PersistenceInfo(PersistenceFactory factory,
+				@SuppressWarnings("rawtypes") Class theClass,
+				DynStruct definition) {
+			this.factory = factory;
+			this.theClass = theClass;
+			this.definition = definition;
+		}
+
+		String getDefinitionName() {
+			if (definition == null) {
+				return "";
+			}
+			return definition.getFullName();
+		}
+
+		String getDefinitionDescription() {
+			if (definition == null) {
+				return "";
+			}
+			return definition.getDescription();
+		}
+
+		String getClassName() {
+			if (theClass == null) {
+				return "";
+			}
+			return theClass.getName();
+		}
+
+		String getFactoryName() {
+			if (factory == null) {
+				return "";
+			}
+			return factory.getClass().getName();
+		}
+
+		public int compareTo(PersistenceInfo other) {
+			int r = this.factory.getClass().getName()
+					.compareTo(other.factory.getClass().getName());
+			if (r == 0) {
+				return this.theClass.getName().compareTo(
+						other.theClass.getName());
+			}
+			return r;
+		}
+	}
+
+	@SuppressWarnings("rawtypes")
+	public class ClassComparator implements Comparator {
+
+		public int compare(Object o1, Object o2) {
+			if (o1 == null || o2 == null || ((Class) o1).getName() == null) {
+				logger.warn("Esto no deberia estar pasando.");
+				return 0; // FIXME
+			}
+			return ((Class) o1).getName().compareTo(((Class) o2).getName());
+		}
+
+	}
+
+	@SuppressWarnings({ "unchecked", "rawtypes" })
+	public String getPersistenceFactories() {
+		int warningsCounter = 0;
+		List<PersistenceInfo> classes = new ArrayList<PersistenceInfo>();
+		Set<Class> referencedClasses = new TreeSet<Class>(new ClassComparator());
+
+		PersistenceManager manager = ToolsLocator.getPersistenceManager();
+
+		List<PersistenceFactory> factories = manager.getFactories();
+		for (PersistenceFactory factory : factories) {
+			List<Class> theClasses = factory.getManagedClasses();
+			for (Class theClass : theClasses) {
+
+				DynStruct definition = manager.getDefinition(theClass);
+				List defs = factory.getDefinitions();
+				if (definition == null && defs != null && !defs.isEmpty()) {
+					for (int i = 0; i < defs.size(); i++) {
+						definition = (DynStruct) defs.get(i);
+						classes.add(new PersistenceInfo(factory, theClass,
+								definition));
+					}
+				} else {
+					classes.add(new PersistenceInfo(factory, theClass,
+							definition));
+				}
+			}
+		}
+		Collections.sort(classes);
+
+		StringBuffer buffer = new StringBuffer();
+		StringBuffer warnings = new StringBuffer();
+
+		buffer.append("<html>\n");
+		buffer.append("<body>\n");
+		buffer.append("<h2>Supported persistent classes</h2>\n");
+		buffer.append("<br>\n");
+
+		buffer.append("<ol>\n");
+		for (PersistenceInfo classInfo : classes) {
+			StringBuffer classBuffer = new StringBuffer();
+			boolean warning = false;
+			classBuffer.append("  <li>\n    ");
+			classBuffer.append("Class: <i>");
+			classBuffer.append(classInfo.getClassName());
+			classBuffer.append("</i><br>\n    Persistent: <i>");
+			if (Persistent.class.isAssignableFrom(classInfo.theClass)) {
+				classBuffer.append(" yes.");
+			} else {
+				classBuffer.append(" through a factory.");
+			}
+			classBuffer.append("<br>\n    Factory: <i>");
+			classBuffer.append(classInfo.getFactoryName()).append(
+					"</i><br>\n    Definition name: <i>");
+			classBuffer.append(classInfo.getDefinitionName()).append(
+					"</i><br>\n    Description: \n");
+			classBuffer.append(classInfo.getDefinitionDescription()).append(
+					"<br>\n    ");
+			DataTypesManager dataTypesManager = ToolsLocator
+					.getDataTypesManager();
+			DynStruct definition = classInfo.definition;
+			if (definition == null) {
+				classBuffer.append("Definition for ")
+						.append(classInfo.getClassName())
+						.append(" is null.<br>\n    ");
+				warningsCounter++;
+				warning = true;
+			} else {
+				DynField[] fields = definition.getDynFields();
+				for (int i = 0; i < fields.length; i++) {
+					DynField field = fields[i];
+					if (dataTypesManager.isContainer(field.getType())) {
+						if (field.getClassOfItems() == null) {
+							classBuffer
+									.append("Field <b>")
+									.append(field.getName())
+									.append("</b>, container,  can't has class for value of items.<br>\n    ");
+							warningsCounter++;
+							warning = true;
+						} else {
+							classBuffer.append("Field ")
+									.append(field.getName())
+									.append(", container of '")
+									.append(field.getClassOfItems().getName())
+									.append("'.<br>\n    ");
+							referencedClasses.add(field.getClassOfItems());
+						}
+					} else if (dataTypesManager.isObject(field.getType())) {
+						if (field.getClassOfValue() == null) {
+							classBuffer
+									.append("Field <b>")
+									.append(field.getName())
+									.append("</b> can't has class of value.<br>\n    ");
+							warningsCounter++;
+							warning = true;
+						} else {
+							classBuffer.append("Field ")
+									.append(field.getName()).append(" of '")
+									.append(field.getClassOfValue())
+									.append("'.<br>\n    ");
+							referencedClasses.add(field.getClassOfValue());
+						}
+					}
+				}
+			}
+			classBuffer.append("<br>\n  </li>\n");
+			buffer.append(classBuffer);
+			if (warning) {
+				warnings.append(classBuffer);
+			}
+		}
+		buffer.append("</ol>\n");
+		buffer.append("<br>\n");
+		buffer.append("<br>\n");
+
+		buffer.append("<h2>Persistent classes with problems</h2>\n");
+		buffer.append("<ol>\n");
+		buffer.append(warnings);
+		buffer.append("</ol>\n");
+		buffer.append("<br>\n<p>Total warnigs: ").append(warningsCounter)
+				.append("</p>");
+
+		buffer.append("<h2>Not persistents used classes</h2>\n");
+		buffer.append("<ol>\n");
+		for (Class theClass : referencedClasses) {
+			// if( manager.canPersist(theClass) ) {
+			// continue;
+			// }
+			if (Persistent.class.isAssignableFrom(theClass)) {
+				continue;
+			}
+			if (manager.getFactories().get(theClass) != null) {
+				continue;
+			}
+			buffer.append("  <li>\n");
+			buffer.append("    <i>").append(theClass.getName())
+					.append("</i><br>\n");
+			buffer.append("  </li>\n");
+			warningsCounter++;
+		}
+		buffer.append("</ol>\n");
+
+		buffer.append("</body>\n");
+		buffer.append("</html>\n");
+
+		return buffer.toString();
+	}
+
+
+}

Property changes on: tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/app/extension/develtools/PersistenceDevelTool.java
___________________________________________________________________
Added: svn:mime-type
   + text/plain

Index: tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/app/extension/develtools/MenusDevelTool.java
===================================================================
--- tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/app/extension/develtools/MenusDevelTool.java	(revision 0)
+++ tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/app/extension/develtools/MenusDevelTool.java	(revision 38653)
@@ -0,0 +1,131 @@
+package org.gvsig.app.extension.develtools;
+
+import java.util.Collections;
+import java.util.Comparator;
+import java.util.List;
+
+import org.gvsig.andami.Launcher;
+import org.gvsig.andami.Launcher.PluginMenuItem;
+import org.gvsig.andami.actioninfo.ActionInfo;
+import org.gvsig.tools.swing.api.windowmanager.WindowManager;
+
+public class MenusDevelTool {
+	public void showAllMenus() {
+		String html = this.getAllMenus();
+		InfoPanel.save2file("menusinfo", html);
+		InfoPanel.showPanel("Menu information", WindowManager.MODE.WINDOW, html);
+	}
+	public void showAllMenusByPlugin() {
+		String html = this.getAllMenusByPlugin();
+		InfoPanel.save2file("menusbyplugininfo", html);
+		InfoPanel.showPanel("Menu by plugin information", WindowManager.MODE.WINDOW, html);
+	}
+	
+	public String getAllMenus() {
+		Launcher launcher = Launcher.getInstance();
+		List<PluginMenuItem> menuItems = launcher.getPluginMenuItems();
+		
+		return this.getAllMenus(menuItems);
+	}
+	
+	public String getAllMenusByPlugin() {
+		Launcher launcher = Launcher.getInstance();
+		List<PluginMenuItem> menuItems = launcher.getPluginMenuItems();
+		
+		Collections.sort(menuItems, new Comparator<PluginMenuItem>() {
+			public int compare(PluginMenuItem o1, PluginMenuItem o2) {
+				String s1 = String.format("%s:%012d:%s", o1.getPluginName(), o1.getPosition(), o1.getText());
+				String s2 = String.format("%s:%012d:%s", o2.getPluginName(), o2.getPosition(), o2.getText());
+				return s1.compareTo(s2);
+			}
+		});
+		return this.getAllMenus(menuItems);
+	}
+	
+	private String getAllMenus(List<PluginMenuItem> menuItems) {
+		StringBuffer buffer = new StringBuffer();
+
+//		String warning_open = "<b>";
+//		String warning_close = "</b>";
+		
+		String error_open = "<b><font color=\"red\">";
+		String error_close = "</font></b>";
+		
+		buffer.append("<html>\n");
+		buffer.append("<body>\n");
+		buffer.append("<h2>Menu information </h2>\n");
+		buffer.append("<br>\n");
+		
+		buffer.append("<table border=\"0\">\n");
+		buffer.append("  <tr>\n");
+		buffer.append("    <td>Position</td>\n");
+		buffer.append("    <td>Text</td>\n");
+		buffer.append("    <td>Action</td>\n");
+		buffer.append("    <td>Plugin</td>\n");
+		buffer.append("  </tr>\n");
+
+		
+		for (PluginMenuItem menu : menuItems) {
+			buffer.append("  <tr valign=\"top\">\n");
+			buffer
+				.append("    <td>")
+				.append(formatPosition( menu.getPosition()))
+				.append("</td>\n");			
+			buffer
+				.append("    <td>")
+				.append(menu.getText())
+				.append("</td>\n");		
+			if( menu.isParent() ) {
+				buffer
+					.append("    <td>")
+					.append("----")
+					.append("</td>\n");
+				buffer
+					.append("    <td>")
+					.append(menu.getPluginName())
+					.append("</td>\n");			
+			} else {
+				ActionInfo action = menu.getAction();
+				if( action == null ) {
+					buffer
+						.append("    <td>")
+						.append(error_open)
+						.append(menu.getName())
+						.append(error_close)
+						.append("</td>\n");
+					buffer
+						.append("    <td>")
+						.append(menu.getPluginName())
+						.append("</td>\n");			
+				} else {
+					buffer
+						.append("    <td>")
+						.append(action.getName())
+						.append("</td>\n");
+					buffer
+						.append("    <td>")
+						.append(action.getPluginName())
+						.append("</td>\n");			
+				}
+			}
+			buffer.append("  </tr>\n");
+		}
+		buffer.append("</table>\n");
+		buffer.append("</body>\n");
+		buffer.append("</html>\n");
+
+		return buffer.toString();
+	}
+	
+	static String formatPosition(long position) {
+		String pos = String.format("%012d",position);
+		if( pos.length() != 12) {
+			return pos;
+		}
+		String posf = pos.substring(0, 5) + "-" +
+			pos.substring(5,8) + "-" +
+			pos.substring(8,11) + "-" +
+			pos.substring(11);
+		return posf;
+	}
+}

Property changes on: tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/app/extension/develtools/MenusDevelTool.java
___________________________________________________________________
Added: svn:mime-type
   + text/plain

Index: tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/app/extension/develtools/IconThemeDevelTool.java
===================================================================
--- tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/app/extension/develtools/IconThemeDevelTool.java	(revision 0)
+++ tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/app/extension/develtools/IconThemeDevelTool.java	(revision 38653)
@@ -0,0 +1,535 @@
+package org.gvsig.app.extension.develtools;
+
+import java.util.ArrayList;
+import java.util.Collections;
+import java.util.Comparator;
+import java.util.HashSet;
+import java.util.Iterator;
+import java.util.List;
+import java.util.Set;
+
+import javax.swing.ImageIcon;
+
+import org.gvsig.andami.PluginsLocator;
+import org.gvsig.andami.actioninfo.ActionInfo;
+import org.gvsig.tools.swing.api.ToolsSwingLocator;
+import org.gvsig.tools.swing.api.windowmanager.WindowManager;
+import org.gvsig.tools.swing.icontheme.IconTheme;
+import org.gvsig.tools.swing.icontheme.IconThemeManager;
+
+public class IconThemeDevelTool {
+
+	public void showDefaultIconTheme() {
+		String html = this.getIconThemeInformationByGroup();
+		InfoPanel.save2file("iconthemeinfo", html);
+		InfoPanel.showPanel("Icon theme information", WindowManager.MODE.WINDOW, html);
+	}
+
+	public void showDefaultIconThemeByPlugin() {
+		String html = this.getIconThemeInformationByPlugin();
+		InfoPanel.save2file("iconthemeinfo", html);
+		InfoPanel.showPanel("Icon theme information", WindowManager.MODE.WINDOW, html);
+	}
+
+	private String getIconThemeInformationByPlugin() {
+		IconThemeManager manager = ToolsSwingLocator.getIconThemeManager();
+		IconTheme theme = manager.getDefault();
+		
+		List<IconTheme.Icon>themeIcons = new ArrayList<IconTheme.Icon>();
+		Iterator<IconTheme.Icon> themeIconsIt = theme.getThemeIcons();
+		while (themeIconsIt.hasNext()) {
+			themeIcons.add(themeIconsIt.next());
+		}
+		Collections.sort(themeIcons, new Comparator<IconTheme.Icon>() {
+			public int compare(IconTheme.Icon o1, IconTheme.Icon o2) {
+				String s1 = String.format("%s:%s:%s", o1.getProviderName(), o1.getGroup(), o1.getName());
+				String s2 = String.format("%s:%s:%s", o2.getProviderName(), o2.getGroup(), o2.getName());
+				return s1.compareTo(s2);
+			}
+		});
+		themeIconsIt = themeIcons.iterator();
+		return getIconThemeInformation(theme, themeIconsIt);
+	}
+	
+	private String getIconThemeInformationByGroup() {
+		IconThemeManager manager = ToolsSwingLocator.getIconThemeManager();
+		IconTheme theme = manager.getDefault();
+		
+		List<IconTheme.Icon>themeIcons = new ArrayList<IconTheme.Icon>();
+		Iterator<IconTheme.Icon> themeIconsIt = theme.getThemeIcons();
+		while (themeIconsIt.hasNext()) {
+			themeIcons.add(themeIconsIt.next());
+		}
+		Collections.sort(themeIcons, new Comparator<IconTheme.Icon>() {
+			public int compare(IconTheme.Icon o1, IconTheme.Icon o2) {
+				String s1 = String.format("%s:%s:%s", o1.getGroup(), o1.getName(), o1.getProviderName());
+				String s2 = String.format("%s:%s:%s", o2.getGroup(), o2.getName(), o2.getProviderName());
+				return s1.compareTo(s2);
+			}
+		});
+		themeIconsIt = themeIcons.iterator();
+		return getIconThemeInformation(theme,themeIconsIt);
+	}
+
+	private String getIconThemeInformation(IconTheme theme, Iterator<IconTheme.Icon> themeIconsIt) {
+		Set<String> actionIcons = new HashSet<String>();
+		Iterator<ActionInfo> actions = PluginsLocator.getActionInfoManager().getActions(); 
+		while (actions.hasNext()) {
+			ActionInfo action = actions.next();
+			if( action.getIconName()!=null ) {
+				actionIcons.add(action.getIconName());
+			}
+		}
+		Set<String> tangoIconNames = getTangoIconNames();
+		
+		StringBuffer buffer = new StringBuffer();
+
+		String warning_open = "<b>";
+		String warning_close = "</b>";
+		
+		String error_open = "<b><font color=\"red\">";
+		String error_close = "</font></b>";
+
+		String tangoicon_open = "<b><font color=\"green\">";
+		String tangoicon_close = "</font></b>";
+		
+		String previousPluginName = null;
+
+		buffer.append("<html>\n");
+		buffer.append("<body>\n");
+		buffer.append("<h2>Icon theme information</h2>\n");
+		buffer.append("<br>\n");
+		buffer.append("Theme: ");
+		buffer.append(theme.getName());
+		buffer.append("<br>\n");
+		buffer.append("Description: ");
+		buffer.append(theme.getDescription());
+		buffer.append("<br>\n");
+
+		buffer.append("<table border=\"0\">\n");
+		buffer.append("  <tr>\n");
+		buffer.append("    <td>Preview</td>\n");
+		buffer.append("    <td>Group</td>\n");
+		buffer.append("    <td>Name</td>\n");
+		buffer.append("    <td>Plugin</td>\n");
+		buffer.append("    <td>Resource</td>\n");
+		buffer.append("  </tr>\n");
+		
+		
+		while (themeIconsIt.hasNext()) {
+			IconTheme.Icon themeIcon = themeIconsIt.next();
+			if( previousPluginName!=null && !themeIcon.getProviderName().equals(previousPluginName) ) {
+				buffer
+					.append("  <tr>\n")
+					.append("    <td colspan=\"4\"><hr></td>\n")
+					.append("  </tr>\n");
+				previousPluginName = themeIcon.getProviderName();
+			}
+			
+			buffer.append("  <tr valign=\"top\">\n");
+			
+			// Preview			
+			if( themeIcon.getLabel().length()>0 && themeIcon.getImageIcon()!=null ) {
+				try {
+					ImageIcon img = themeIcon.getImageIcon();
+					if( img.getIconHeight() > 48 || img.getIconWidth() > 48 ) {
+						buffer
+							.append("    <td nowrap>")
+							.append("<img width=\"48\" height=\"48\" src=\"")
+							.append(themeIcon.getLabel())
+							.append("\">(*)</td>");
+					} else {
+						buffer
+							.append("    <td>")
+							.append("<img src=\"")
+							.append(themeIcon.getLabel())
+							.append("\"></td>");
+					}
+				} catch(Exception ex) {
+					buffer
+						.append("    <td>")
+						.append("<img src=\"")
+						.append(themeIcon.getLabel())
+						.append("\"></td>");
+				}
+			} else {
+				buffer.append("    <td></td>");
+			}
+		
+			// Group
+			if( themeIcon.getGroup()==null ) {
+				buffer.append("    <td title=\"missing recomended group\">")
+					.append(warning_open)
+					.append(themeIcon.getGroup())
+					.append(warning_close)
+					.append("</td>\n");
+			} else {
+				buffer.append("    <td>")
+					.append(themeIcon.getGroup())
+					.append("</td>\n");
+			}
+
+			// Name
+			if( "action".equals(themeIcon.getGroup()) && !actionIcons.contains(themeIcon.getName())) {
+				buffer.append("    <td title=\"Don't exists an action associated to this icon\">")
+					.append(error_open)
+					.append(themeIcon.getName())
+					.append(error_close)
+					.append("</td>\n");
+			} else if( !themeIcon.getName().contains("-") ) {
+				buffer.append("    <td title=\"Name don't have recomended format\">")
+					.append(warning_open)
+					.append(themeIcon.getName())
+					.append(warning_close)
+					.append("</td>\n");
+			} else if( tangoIconNames.contains(themeIcon.getName()) ){
+				buffer.append("    <td>")
+					.append(tangoicon_open)
+					.append(themeIcon.getName())
+					.append(tangoicon_close)
+					.append("</td>\n");
+			} else {
+				buffer.append("    <td>")
+					.append(themeIcon.getName())
+					.append("</td>\n");
+			}
+
+			// Plugin
+			if( themeIcon.getProviderName()== null ) {
+				buffer.append("    <td title=\"missing recomended associated plugin\">")
+					.append(warning_open)
+					.append(themeIcon.getProviderName())
+					.append(warning_close)
+					.append("</td>\n");
+				
+			}  else {
+				buffer.append("    <td>")
+					.append(themeIcon.getProviderName())
+					.append("</td>\n");
+			}			
+			
+			// Resource
+			if( themeIcon.getLabel().length()<1 ) {
+				buffer.append("    <td title=\"Resource icon not specified\">")
+					.append(error_open)
+					.append("(missing)")
+					.append(error_close)
+					.append("</td>\n");
+			} else if( themeIcon.getImageIcon()==null ) {
+				buffer.append("    <td title=\"Can't locate icon\">")
+					.append(error_open)
+					.append(themeIcon.getLabel())
+					.append(error_close)
+					.append("</td>\n");
+			} else {
+				buffer.append("    <td>")
+					.append(themeIcon.getLabel())
+					.append("</td>\n");
+
+			}
+			buffer.append("  </tr>\n");
+		}
+		buffer.append("</table>\n");
+		buffer.append("</body>\n");
+		buffer.append("</html>\n");
+
+		return buffer.toString();
+	}
+
+	private Set<String> getTangoIconNames() {
+		String[] iconNames = new String[] {
+				"address-book-new",
+				"application-exit",
+				"appointment-new",
+				"call-start",
+				"call-stop",
+				"contact-new",
+				"document-new",
+				"document-open",
+				"document-open-recent",
+				"document-page-setup",
+				"document-print",
+				"document-print-preview",
+				"document-properties",
+				"document-revert",
+				"document-save",
+				"document-save-as",
+				"document-send",
+				"edit-clear",
+				"edit-copy",
+				"edit-cut",
+				"edit-delete",
+				"edit-find",
+				"edit-find-replace",
+				"edit-paste",
+				"edit-redo",
+				"edit-select-all",
+				"edit-undo",
+				"folder-new",
+				"format-indent-less",
+				"format-indent-more",
+				"format-justify-center",
+				"format-justify-fill",
+				"format-justify-left",
+				"format-justify-right",
+				"format-text-direction-ltr",
+				"format-text-direction-rtl",
+				"format-text-bold",
+				"format-text-italic",
+				"format-text-underline",
+				"format-text-strikethrough",
+				"go-bottom",
+				"go-down",
+				"go-first",
+				"go-home",
+				"go-jump",
+				"go-last",
+				"go-next",
+				"go-previous",
+				"go-top",
+				"go-up",
+				"help-about",
+				"help-contents",
+				"help-faq",
+				"insert-image",
+				"insert-link",
+				"insert-object",
+				"insert-text",
+				"list-add",
+				"list-remove",
+				"mail-forward",
+				"mail-mark-important",
+				"mail-mark-junk",
+				"mail-mark-notjunk",
+				"mail-mark-read",
+				"mail-mark-unread",
+				"mail-message-new",
+				"mail-reply-all",
+				"mail-reply-sender",
+				"mail-send",
+				"mail-send-receive",
+				"media-eject",
+				"media-playback-pause",
+				"media-playback-start",
+				"media-playback-stop",
+				"media-record",
+				"media-seek-backward",
+				"media-seek-forward",
+				"media-skip-backward",
+				"media-skip-forward",
+				"object-flip-horizontal",
+				"object-flip-vertical",
+				"object-rotate-left",
+				"object-rotate-right",
+				"process-stop",
+				"system-lock-screen",
+				"system-log-out",
+				"system-run",
+				"system-search",
+				"system-reboot",
+				"system-shutdown",
+				"tools-check-spelling",
+				"view-fullscreen",
+				"view-refresh",
+				"view-restore",
+				"view-sort-ascending",
+				"view-sort-descending",
+				"window-close",
+				"window-new",
+				"zoom-fit-best",
+				"zoom-in",
+				"zoom-original",
+				"zoom-out",
+				"process-working",
+				"accessories-calculator",
+				"accessories-character-map",
+				"accessories-dictionary",
+				"accessories-text-editor",
+				"help-browser",
+				"multimedia-volume-control",
+				"preferences-desktop-accessibility",
+				"preferences-desktop-font",
+				"preferences-desktop-keyboard",
+				"preferences-desktop-locale",
+				"preferences-desktop-multimedia",
+				"preferences-desktop-screensaver",
+				"preferences-desktop-theme",
+				"preferences-desktop-wallpaper",
+				"system-file-manager",
+				"system-software-install",
+				"system-software-update",
+				"utilities-system-monitor",
+				"utilities-terminal",
+				"applications-accessories",
+				"applications-development",
+				"applications-engineering",
+				"applications-games",
+				"applications-graphics",
+				"applications-internet",
+				"applications-multimedia",
+				"applications-office",
+				"applications-other",
+				"applications-science",
+				"applications-system",
+				"applications-utilities",
+				"preferences-desktop",
+				"preferences-desktop-peripherals",
+				"preferences-desktop-personal",
+				"preferences-other",
+				"preferences-system",
+				"preferences-system-network",
+				"system-help",
+				"audio-card",
+				"audio-input-microphone",
+				"battery",
+				"camera-photo",
+				"camera-video",
+				"camera-web",
+				"computer",
+				"drive-harddisk",
+				"drive-optical",
+				"drive-removable-media",
+				"input-gaming",
+				"input-keyboard",
+				"input-mouse",
+				"input-tablet",
+				"media-flash",
+				"media-floppy",
+				"media-optical",
+				"media-tape",
+				"modem",
+				"multimedia-player",
+				"network-wired",
+				"network-wireless",
+				"pda",
+				"phone",
+				"printer",
+				"scanner",
+				"video-display",
+				"emblem-default",
+				"emblem-documents",
+				"emblem-downloads",
+				"emblem-favorite",
+				"emblem-important",
+				"emblem-mail",
+				"emblem-photos",
+				"emblem-readonly",
+				"emblem-shared",
+				"emblem-symbolic-link",
+				"emblem-synchronized",
+				"emblem-system",
+				"emblem-unreadable",
+				"face-angel",
+				"face-angry",
+				"face-cool",
+				"face-crying",
+				"face-devilish",
+				"face-embarrassed",
+				"face-kiss",
+				"face-laugh",
+				"face-monkey",
+				"face-plain",
+				"face-raspberry",
+				"face-sad",
+				"face-sick",
+				"face-smile",
+				"face-smile-big",
+				"face-smirk",
+				"face-surprise",
+				"face-tired",
+				"face-uncertain",
+				"face-wink",
+				"face-worried",
+				"flag-aa",
+				"application-x-executable",
+				"audio-x-generic",
+				"font-x-generic",
+				"image-x-generic",
+				"package-x-generic",
+				"text-html",
+				"text-x-generic",
+				"text-x-generic-template",
+				"text-x-script",
+				"video-x-generic",
+				"x-office-address-book",
+				"x-office-calendar",
+				"x-office-document",
+				"x-office-presentation",
+				"x-office-spreadsheet",
+				"folder",
+				"folder-remote",
+				"network-server",
+				"network-workgroup",
+				"start-here",
+				"user-bookmarks",
+				"user-desktop",
+				"user-home",
+				"user-trash",
+				"appointment-missed",
+				"appointment-soon",
+				"audio-volume-high",
+				"audio-volume-low",
+				"audio-volume-medium",
+				"audio-volume-muted",
+				"battery-caution",
+				"battery-low",
+				"dialog-error",
+				"dialog-information",
+				"dialog-password",
+				"dialog-question",
+				"dialog-warning",
+				"folder-drag-accept",
+				"folder-open",
+				"folder-visiting",
+				"image-loading",
+				"image-missing",
+				"mail-attachment",
+				"mail-unread",
+				"mail-read",
+				"mail-replied",
+				"mail-signed",
+				"mail-signed-verified",
+				"media-playlist-repeat",
+				"media-playlist-shuffle",
+				"network-error",
+				"network-idle",
+				"network-offline",
+				"network-receive",
+				"network-transmit",
+				"network-transmit-receive",
+				"printer-error",
+				"printer-printing",
+				"security-high",
+				"security-medium",
+				"security-low",
+				"software-update-available",
+				"software-update-urgent",
+				"sync-error",
+				"sync-synchronizing",
+				"task-due",
+				"task-past-due",
+				"user-available",
+				"user-away",
+				"user-idle",
+				"user-offline",
+				"user-trash-full",
+				"weather-clear",
+				"weather-clear-night",
+				"weather-few-clouds",
+				"weather-few-clouds-night",
+				"weather-fog",
+				"weather-overcast",
+				"weather-severe-alert",
+				"weather-showers",
+				"weather-showers-scattered",
+				"weather-snow",
+				"weather-storm"
+		};
+		Set<String> icons = new HashSet<String>();
+		for (int i = 0; i < iconNames.length; i++) {
+			icons.add(iconNames[i]);
+		}
+		return icons;
+	}
+
+}

Property changes on: tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/app/extension/develtools/IconThemeDevelTool.java
___________________________________________________________________
Added: svn:mime-type
   + text/plain

Index: tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/app/extension/develtools/ActionsInfoDevelTool.java
===================================================================
--- tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/app/extension/develtools/ActionsInfoDevelTool.java	(revision 0)
+++ tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/app/extension/develtools/ActionsInfoDevelTool.java	(revision 38653)
@@ -0,0 +1,187 @@
+package org.gvsig.app.extension.develtools;
+
+import java.util.Iterator;
+
+import org.gvsig.andami.PluginsLocator;
+import org.gvsig.andami.actioninfo.ActionInfo;
+import org.gvsig.tools.swing.api.windowmanager.WindowManager;
+
+public class ActionsInfoDevelTool {
+
+	public void showActions() {
+		String html = this.getActionsInformation();
+		InfoPanel.save2file("actionsinfo", html);
+		InfoPanel.showPanel("Actions information", WindowManager.MODE.WINDOW, html);
+	}
+	
+	public String getActionsInformation() {
+		
+		String previousPluginName = null;
+		
+		String warning_open = "<b>";
+		String warning_close = "</b>";
+		
+		String error_open = "<b><font color=\"red\">";
+		String error_close = "</font></b>";
+
+		StringBuffer buffer = new StringBuffer();
+
+		buffer.append("<html>\n");
+		buffer.append("<body>\n");
+		buffer.append("<h2>Actions information </h2>\n");
+		buffer.append("<br>\n");
+
+		buffer.append("<table border=\"0\">\n");
+		buffer.append("  <tr>\n");
+		buffer.append("    <td>Plugin</td>\n");
+		buffer.append("    <td>Extension</td>\n");
+		buffer.append("    <td>Name</td>\n");
+		buffer.append("    <td>Position</td>\n");
+		buffer.append("    <td>Text</td>\n");
+		buffer.append("    <td>Command</td>\n");
+		buffer.append("    <td>Icon</td>\n");
+		buffer.append("    <td>Tip</td>\n");
+		buffer.append("    <td>Accelerator</td>\n");
+		buffer.append("  </tr>\n");
+		Iterator<ActionInfo> actions = PluginsLocator.getActionInfoManager().getActions(); 
+		while (actions.hasNext()) {
+			ActionInfo action = actions.next();
+			if( previousPluginName!=null && !action.getPluginName().equals(previousPluginName) ) {
+				buffer
+					.append("  <tr>\n")
+					.append("    <td colspan=\"9\"><hr></td>\n")
+					.append("  </tr>\n");
+				previousPluginName = action.getPluginName();
+			}
+			buffer.append("  <tr valign=\"top\">\n");
+			buffer.append("    <td>")
+				.append(action.getPluginName())
+				.append("</td>\n");
+			buffer.append("    <td>")
+				.append(action.getExtensionName())
+				.append("</td>\n");
+			if( action.getName().startsWith("anonymous__") ) {
+				buffer.append("    <td title=\"Missing action name, asigned one by default\">")
+					.append(error_open)
+					.append(action.getName())
+					.append(error_close)
+					.append("</td>\n");
+			} else if( !action.getName().contains("-") ) {
+				buffer.append("    <td title=\"Name don't have recomended syntax\">")
+					.append(warning_open)
+					.append(action.getName())
+					.append(warning_close)
+					.append("</td>\n");
+			} else {
+				buffer.append("    <td>")
+					.append(action.getName())
+					.append("</td>\n");
+			}  
+			if( action.getPosition()<100000000 ) {
+				buffer.append("    <td title=\"Incorrect position\">")
+					.append(error_open)
+					.append(MenusDevelTool.formatPosition(action.getPosition()))
+					.append(error_close)
+					.append("</td>\n");
+			} else {
+				buffer.append("    <td>")
+					.append(MenusDevelTool.formatPosition(action.getPosition()))
+					.append("</td>\n");
+			}
+			if( action.getLabel()==null ) {
+				buffer.append("    <td title=\"Missing label of action\">")
+					.append(error_open)
+					.append("(missing)")
+					.append(error_close)
+					.append("</td>\n");
+			} else {
+				buffer.append("    <td>")
+					.append(action.getLabel())
+					.append("</td>\n");
+			}
+			if( action.getCommand()==null ) {
+				buffer.append("    <td title=\"Missing command of action\">")
+					.append(error_open)
+					.append(action.getCommand())
+					.append(error_close)
+					.append("</td>\n");
+				
+			} else if(!action.getCommand().contains("-") && !action.getCommand().equals(action.getName())) {
+				buffer.append("    <td title=\"Command don't have recomended syntax and differ fron action name\">")
+					.append(warning_open)
+					.append(action.getCommand())
+					.append(warning_close)
+					.append("</td>\n");
+				
+			} else if(!action.getCommand().contains("-") ) {
+				buffer.append("    <td title=\"Command don't have recomended syntax\">")
+					.append(warning_open)
+					.append(action.getCommand())
+					.append(warning_close)
+					.append("</td>\n");
+				
+			} else if(!action.getCommand().equals(action.getName())) {
+				buffer.append("    <td title=\"Command differ fron action name\">")
+					.append(warning_open)
+					.append(action.getCommand())
+					.append(warning_close)
+					.append("</td>\n");
+				
+			} else {
+				buffer.append("    <td>")
+					.append(action.getCommand())
+					.append("</td>\n");
+			}
+			if( action.getIconName()==null ) {
+				buffer.append("    <td title=\"Missing icon name\">")
+					.append(error_open)
+					.append("(missing)")
+					.append(error_close)
+					.append("</td>\n");
+			} else if( action.getIcon()==null ) {
+				buffer.append("    <td title=\"Missing icon\">")
+					.append(error_open)
+					.append(action.getIconName())
+					.append(error_close)
+					.append("</td>\n");
+			} else {
+				buffer.append("    <td>")
+					.append(action.getIconName())
+					.append("</td>\n");
+			}
+			if( action.getTooltip()==null ) {
+				buffer.append("    <td title=\"Missing tooltip\">")
+					.append(error_open)
+					.append(action.getTooltip())
+					.append(error_close)
+					.append("</td>\n");
+				
+			} else {
+				buffer.append("    <td>")
+					.append(action.getTooltip())
+					.append("</td>\n");
+			}
+			if( action.getAccelerator()!=null && action.getKeyStroke()==null ) {
+				buffer.append("    <td title=\"Incorrect syntax of the accelerator key\">")
+					.append(error_open)
+					.append(action.getAccelerator())
+					.append(error_close)
+					.append("</td>\n");
+				
+			} else {
+				buffer.append("    <td>")
+					.append(action.getAccelerator())
+					.append("</td>\n");
+			}
+			buffer.append("  </tr>\n");
+			
+		}
+		buffer.append("</table>\n");
+		buffer.append("</body>\n");
+		buffer.append("</html>\n");
+
+		return buffer.toString();
+	}
+
+
+}

Property changes on: tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/app/extension/develtools/ActionsInfoDevelTool.java
___________________________________________________________________
Added: svn:mime-type
   + text/plain

Index: tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/app/extension/develtools/InfoPanel.java
===================================================================
--- tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/app/extension/develtools/InfoPanel.java	(revision 0)
+++ tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/app/extension/develtools/InfoPanel.java	(revision 38653)
@@ -0,0 +1,95 @@
+package org.gvsig.app.extension.develtools;
+
+import java.awt.BorderLayout;
+import java.awt.Dimension;
+import java.awt.event.ActionEvent;
+import java.awt.event.ActionListener;
+import java.io.File;
+import java.io.FileWriter;
+import java.io.IOException;
+
+import javax.swing.BorderFactory;
+import javax.swing.Box;
+import javax.swing.BoxLayout;
+import javax.swing.JButton;
+import javax.swing.JPanel;
+import javax.swing.JScrollPane;
+import javax.swing.JTextPane;
+
+import org.gvsig.app.ApplicationLocator;
+import org.gvsig.tools.swing.api.ToolsSwingLocator;
+import org.gvsig.tools.swing.api.windowmanager.WindowManager;
+import org.slf4j.Logger;
+import org.slf4j.LoggerFactory;
+
+public class InfoPanel extends JPanel {
+	private static Logger logger = LoggerFactory.getLogger(InfoPanel.class);
+
+
+	private static final long serialVersionUID = 7164653790859770568L;
+
+	private JButton accept = null;
+	private JButton copy = null;
+	private JTextPane text = null;
+
+	public static void showPanel(String title, WindowManager.MODE mode,
+			String html) {
+		JPanel panel = new InfoPanel(html);
+		WindowManager wm = ToolsSwingLocator.getWindowManager();
+		wm.showWindow(panel, title, mode);
+	}
+
+	public static void save2file(String name, String contents) {
+		File file;
+		try {
+			file = File.createTempFile("gvsig-" + name, ".html");
+			FileWriter fwriter = new FileWriter(file);
+			fwriter.append(contents);
+			fwriter.close();
+		} catch (IOException e) {
+			logger.warn("Can't save contents to temp file gvsig-" + name, e);
+		}
+	}
+	public InfoPanel(final String html) {
+		this.setLayout(new BorderLayout());
+		this.setPreferredSize(new Dimension(500, 300));
+		this.setBorder(BorderFactory.createEmptyBorder(4, 4, 4, 4));
+
+		text = new JTextPane();
+		text.setContentType("text/html");
+		text.setEditable(false);
+		text.setText(html);
+		text.setCaretPosition(0);
+
+		JScrollPane scrollPane = new JScrollPane(text);
+		scrollPane.setPreferredSize(new Dimension(500, 220));
+
+		accept = new JButton("Accept");
+		accept.addActionListener(new ActionListener() {
+			public void actionPerformed(ActionEvent arg0) {
+				setVisible(false);
+			}
+		});
+		copy = new JButton("Copy to clipboard");
+		copy.addActionListener(new ActionListener() {
+			public void actionPerformed(ActionEvent arg0) {
+				ApplicationLocator.getManager().putInClipboard(
+						text.getText());
+			}
+		});
+
+		JPanel buttonsPanel = new JPanel();
+		buttonsPanel.setLayout(new BoxLayout(buttonsPanel,
+				BoxLayout.LINE_AXIS));
+		buttonsPanel.setBorder(BorderFactory.createEmptyBorder(2, 2, 2, 2));
+
+		buttonsPanel.add(Box.createHorizontalGlue());
+		buttonsPanel.add(copy);
+		buttonsPanel.add(accept);
+
+		this.add(scrollPane, BorderLayout.CENTER);
+		this.add(buttonsPanel, BorderLayout.SOUTH);
+		this.setVisible(true);
+	}
+
+}

Property changes on: tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/app/extension/develtools/InfoPanel.java
___________________________________________________________________
Added: svn:mime-type
   + text/plain

Index: tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/app/extension/Preferences.java
===================================================================
--- tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/app/extension/Preferences.java	(revision 0)
+++ tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/app/extension/Preferences.java	(revision 38653)
@@ -0,0 +1,90 @@
+/* gvSIG. Sistema de Informaci�n Geogr�fica de la Generalitat Valenciana
+ *
+ * Copyright (C) 2004 IVER T.I. and Generalitat Valenciana.
+ *
+ * This program is free software; you can redistribute it and/or
+ * modify it under the terms of the GNU General Public License
+ * as published by the Free Software Foundation; either version 2
+ * of the License, or (at your option) any later version.
+ *
+ * This program is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
+ * GNU General Public License for more details.
+ *
+ * You should have received a copy of the GNU General Public License
+ * along with this program; if not, write to the Free Software
+ * Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA  02111-1307,USA.
+ *
+ * For more information, contact:
+ *
+ *  Generalitat Valenciana
+ *   Conselleria d'Infraestructures i Transport
+ *   Av. Blasco Ib��ez, 50
+ *   46010 VALENCIA
+ *   SPAIN
+ *
+ *      +34 963862235
+ *   gvsig@gva.es
+ *      www.gvsig.gva.es
+ *
+ *    or
+ *
+ *   IVER T.I. S.A
+ *   Salamanca 50
+ *   46005 Valencia
+ *   Spain
+ *
+ *   +34 963163400
+ *   dac@iver.es
+ */
+package org.gvsig.app.extension;
+
+import org.gvsig.andami.PluginServices;
+import org.gvsig.andami.plugins.Extension;
+import org.gvsig.app.project.documents.AbstractDocument;
+import org.gvsig.app.project.documents.view.gui.DefaultViewPanel;
+import org.gvsig.fmap.mapcontext.ViewPort;
+
+
+
+/**
+ * Extensi�n para que el usuario fije sus preferencias.
+ * La idea es usar algo como lo que tiene Eclipse, que
+ * permita a las extensiones registrar sus cuadros de
+ * di�logo de preferencias.
+ *
+ * @author Fjp
+ */
+public class Preferences extends Extension {
+	/**
+	 * @see com.iver.mdiApp.plugins.IExtension#isEnabled()
+	 */
+	public boolean isEnabled() {
+
+		return true;
+	}
+
+	/**
+	 * @see com.iver.mdiApp.plugins.IExtension#isVisible()
+	 */
+	public boolean isVisible() {
+			return true;
+	}
+
+	/**
+	 * @see com.iver.mdiApp.plugins.IExtension#updateUI(java.lang.String)
+	 */
+	public void execute(String arg0) {
+		DefaultViewPanel vista = (DefaultViewPanel) PluginServices.getMDIManager().getActiveWindow();
+		ViewPort vp = vista.getModel().getMapContext().getViewPort();
+		vp.setPreviousExtent();
+		((AbstractDocument)vista.getModel()).setModified(true);
+	}
+
+	/**
+	 * @see org.gvsig.andami.plugins.IExtension#initialize()
+	 */
+	public void initialize() {
+	}
+}

Property changes on: tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/app/extension/Preferences.java
___________________________________________________________________
Added: svn:keywords
   + Author Date Id Revision
Added: svn:eol-style
   + native

Index: tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/app/extension/PaletteViewInfoExtension.java
===================================================================
--- tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/app/extension/PaletteViewInfoExtension.java	(revision 0)
+++ tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/app/extension/PaletteViewInfoExtension.java	(revision 38653)
@@ -0,0 +1,98 @@
+/* gvSIG. Sistema de Informaci�n Geogr�fica de la Generalitat Valenciana
+*
+* Copyright (C) 2004 IVER T.I. and Generalitat Valenciana.
+*
+* This program is free software; you can redistribute it and/or
+* modify it under the terms of the GNU General Public License
+* as published by the Free Software Foundation; either version 2
+* of the License, or (at your option) any later version.
+*
+* This program is distributed in the hope that it will be useful,
+* but WITHOUT ANY WARRANTY; without even the implied warranty of
+* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
+* GNU General Public License for more details.
+*
+* You should have received a copy of the GNU General Public License
+* along with this program; if not, write to the Free Software
+* Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA  02111-1307,USA.
+*
+* For more information, contact:
+*
+*  Generalitat Valenciana
+*   Conselleria d'Infraestructures i Transport
+*   Av. Blasco Ib��ez, 50
+*   46010 VALENCIA
+*   SPAIN
+*
+*      +34 963862235
+*   gvsig@gva.es
+*      www.gvsig.gva.es
+*
+*    or
+*
+*   IVER T.I. S.A
+*   Salamanca 50
+*   46005 Valencia
+*   Spain
+*
+*   +34 963163400
+*   dac@iver.es
+*/
+package org.gvsig.app.extension;
+
+
+import org.gvsig.andami.PluginServices;
+import org.gvsig.andami.plugins.Extension;
+import org.gvsig.andami.ui.mdiManager.IWindow;
+import org.gvsig.andami.ui.mdiManager.IWindowTransform;
+import org.slf4j.Logger;
+import org.slf4j.LoggerFactory;
+
+
+
+public class PaletteViewInfoExtension extends Extension{
+    private static final Logger logger = LoggerFactory
+            .getLogger(PaletteViewInfoExtension.class);
+    
+	/**
+	 * @see org.gvsig.andami.plugins.IExtension#initialize()
+	 */
+	public void initialize() {
+	}
+
+	/**
+	 * @see org.gvsig.andami.plugins.IExtension#execute(java.lang.String)
+	 */
+	public void execute(String s) {
+        if (s.equals("window-convert-to-tool")){
+    		IWindow view = PluginServices.getMDIManager().getActiveWindow();
+        	IWindowTransform vt=(IWindowTransform)view;
+        	vt.toPalette();
+            PluginServices.getMainFrame().enableControls();
+        }
+	}
+
+	/**
+	 * @see org.gvsig.andami.plugins.IExtension#isEnabled()
+	 */
+	public boolean isEnabled() {
+       return true;
+	}
+
+	/**
+	 * @see org.gvsig.andami.plugins.IExtension#isVisible()
+	 */
+	public boolean isVisible() {
+		IWindow f = PluginServices.getMDIManager().getFocusWindow();
+		if (f == null) {
+			return false;
+		}
+		if (f instanceof IWindowTransform) {
+			IWindowTransform vt=(IWindowTransform)f;
+			if (!vt.isPalette())
+				return true;
+		}
+		return false;
+	}
+
+}

Property changes on: tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/app/extension/PaletteViewInfoExtension.java
___________________________________________________________________
Added: svn:eol-style
   + native

Index: tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/app/extension/ProjectExtension.java
===================================================================
--- tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/app/extension/ProjectExtension.java	(revision 0)
+++ tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/app/extension/ProjectExtension.java	(revision 38653)
@@ -0,0 +1,744 @@
+/* gvSIG. Geographic Information System of the Valencian Government
+ *
+ * Copyright (C) 2007-2008 Infrastructures and Transports Department
+ * of the Valencian Government (CIT)
+ *
+ * This program is free software; you can redistribute it and/or
+ * modify it under the terms of the GNU General Public License
+ * as published by the Free Software Foundation; either version 2
+ * of the License, or (at your option) any later version.
+ *
+ * This program is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
+ * GNU General Public License for more details.
+ *
+ * You should have received a copy of the GNU General Public License
+ * along with this program; if not, write to the Free Software
+ * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston,
+ * MA  02110-1301, USA.
+ *
+ */
+package org.gvsig.app.extension;
+
+import java.awt.Component;
+import java.io.File;
+import java.text.MessageFormat;
+import java.util.ArrayList;
+import java.util.Iterator;
+import java.util.List;
+import java.util.prefs.Preferences;
+
+import javax.swing.JOptionPane;
+
+import org.gvsig.andami.IconThemeHelper;
+import org.gvsig.andami.Launcher;
+import org.gvsig.andami.Launcher.TerminationProcess;
+import org.gvsig.andami.PluginServices;
+import org.gvsig.andami.messages.NotificationManager;
+import org.gvsig.andami.plugins.Extension;
+import org.gvsig.andami.plugins.IExtension;
+import org.gvsig.andami.plugins.status.IExtensionStatus;
+import org.gvsig.andami.plugins.status.IUnsavedData;
+import org.gvsig.andami.plugins.status.UnsavedData;
+import org.gvsig.andami.ui.mdiManager.IWindow;
+import org.gvsig.andami.ui.mdiManager.WindowInfo;
+import org.gvsig.andami.ui.wizard.UnsavedDataPanel;
+import org.gvsig.app.project.Project;
+import org.gvsig.app.project.ProjectManager;
+import org.gvsig.app.project.documents.gui.ProjectWindow;
+import org.gvsig.app.project.documents.view.ViewManager;
+import org.gvsig.gui.beans.swing.JFileChooser;
+import org.gvsig.tools.ToolsLocator;
+import org.gvsig.tools.extensionpoint.ExtensionPointManager;
+import org.gvsig.tools.persistence.exception.PersistenceException;
+import org.gvsig.utils.GenericFileFilter;
+import org.gvsig.utils.save.AfterSavingListener;
+import org.gvsig.utils.save.BeforeSavingListener;
+import org.gvsig.utils.save.SaveEvent;
+import org.gvsig.utils.swing.threads.IMonitorableTask;
+import org.slf4j.Logger;
+import org.slf4j.LoggerFactory;
+
+/**
+ * Extension que proporciona controles para crear proyectos nuevos, abrirlos y
+ * guardarlos. Adem�s los tipos de tabla que soporta el proyecto son a�adidos
+ * en esta clase.
+ * 
+ * @author Fernando Gonz�lez Cort�s
+ */
+public class ProjectExtension extends Extension implements IExtensionStatus {
+    private static final Logger LOG =
+        LoggerFactory.getLogger(ProjectExtension.class);
+    
+    private static String projectPath = null;
+    private ProjectWindow projectFrame;
+    private Project p;
+    private String lastSavePath;
+    private WindowInfo seedProjectWindow;
+    public static final String PROJECT_FILE_CHOOSER_ID =
+        "PROJECT_FILECHOOSER_ID";
+    /**
+     * Use UTF-8 for encoding, as it can represent characters from
+     * any language.
+     * 
+     * Another sensible option would be
+     * encoding = System.getProperty("file.encoding");
+     * but this would need some extra testing.
+     * 
+     * @deprecated see PersistentManager
+     */
+    public static String PROJECTENCODING = "UTF-8";
+
+    private List<BeforeSavingListener> beforeSavingListeners =
+        new ArrayList<BeforeSavingListener>();
+
+    private List<AfterSavingListener> afterSavingListeners =
+        new ArrayList<AfterSavingListener>();
+
+    /**
+     * @see com.iver.mdiApp.plugins.IExtension#initialize()
+     */
+    public void initialize() {
+        try {
+            Class.forName("javax.media.jai.EnumeratedParameter");
+        } catch (ClassNotFoundException e) {
+            NotificationManager
+                .addError(
+                    "La m�quina virtual con la que se ejecuta gvSIG no tiene JAI instalado",
+                    e);
+        }
+
+        initializeDocumentActionsExtensionPoint();
+        registerIcons();
+    }
+
+    private void registerIcons() {
+    	IconThemeHelper.registerIcon("action", "application-project-new", this);
+    	IconThemeHelper.registerIcon("action", "application-project-open", this);
+    	IconThemeHelper.registerIcon("action", "application-project-save", this);
+    	IconThemeHelper.registerIcon("action", "application-project-save-as", this);
+    	IconThemeHelper.registerIcon("action", "application-exit", this);
+    }
+
+    private void loadInitialProject() {
+        String[] theArgs = PluginServices.getArguments();
+        String lastArg = theArgs[theArgs.length - 1];
+        if ((lastArg.toLowerCase().endsWith(Project.FILE_EXTENSION
+            .toLowerCase()))) {
+            PluginServices.getLogger().debug(
+                "Intentando cargar el proyecto " + lastArg);
+            // File projectFile = new File(lastArg);
+            setProject(readProject(lastArg));
+            PluginServices.getMainFrame().setTitle(p.getName());
+            projectPath = lastArg;
+        } else {
+            setProject(ProjectManager.getInstance().createProject());
+            p.setName(PluginServices.getText(this, "untitled"));
+            p.setModified(false);
+            PluginServices.getMainFrame().setTitle(
+                PluginServices.getText(this, "sin_titulo"));
+        }
+
+    }
+
+    /**
+     * @see com.iver.mdiApp.plugins.IExtension#postInitialize()
+     */
+    public void postInitialize() {
+        registerDocuments();
+        loadInitialProject();
+        getProjectFrame().setProject(p);
+        showProjectWindow();
+    }
+
+    public ProjectWindow getProjectFrame() {
+        if (projectFrame == null) {
+            projectFrame = new ProjectWindow();
+        }
+        return projectFrame;
+    }
+
+    /**
+     * Muestra la ventana con el gestor de proyectos.
+     */
+    public void showProjectWindow() {
+        if (seedProjectWindow != null) {
+            if (seedProjectWindow.isClosed()) {
+                // if it was closed, we just don't open the window now
+                seedProjectWindow.setClosed(false);
+                return;
+            }
+            WindowInfo winProps = seedProjectWindow;
+            seedProjectWindow = null;
+            PluginServices.getMDIManager().addWindow(getProjectFrame());
+            PluginServices.getMDIManager().changeWindowInfo(getProjectFrame(),
+                winProps);
+        } else {
+            PluginServices.getMDIManager().addWindow(getProjectFrame());
+        }
+    }
+
+    /**
+     * Muestra la ventana con el gestor de proyectos, con las propiedades
+     * de ventana especificadas.
+     */
+    public void showProjectWindow(WindowInfo wi) {
+        seedProjectWindow = wi;
+        showProjectWindow();
+    }
+
+    /**
+     * Guarda el proyecto actual en disco.
+     */
+    private boolean guardar() {
+        boolean saved = false;
+        // if (p.getPath() == null) {
+        if (projectPath == null) {
+            saved = guardarDialogo();
+        } else {
+            long t1, t2;
+            t1 = System.currentTimeMillis();
+            saved = writeProject(new File(projectPath), p, false);
+            t2 = System.currentTimeMillis();
+            PluginServices.getLogger().info(
+                "Project saved. " + (t2 - t1) + " miliseconds");
+            getProjectFrame().refreshControls();
+        }
+        return saved;
+    }
+
+    private boolean guardarDialogo() {
+        boolean saved = false;
+
+        if (lastSavePath == null) {
+            lastSavePath = projectPath;
+        }
+
+        Preferences prefs = Preferences.userRoot().node("gvsig.foldering");
+        JFileChooser jfc =
+            new JFileChooser(PROJECT_FILE_CHOOSER_ID, prefs.get(
+                "ProjectsFolder", null));
+
+        jfc.setDialogTitle(PluginServices.getText(this, "guardar_proyecto"));
+        jfc.addChoosableFileFilter(new GenericFileFilter(
+            Project.FILE_EXTENSION, MessageFormat.format(
+                PluginServices.getText(this, "_gvSIG_file_project_({0})"),
+                Project.FILE_EXTENSION)));
+
+        if (jfc.showSaveDialog((Component) PluginServices.getMainFrame()) == JFileChooser.APPROVE_OPTION) {
+            File file = jfc.getSelectedFile();
+            if (!(file.getPath().toLowerCase().endsWith(Project.FILE_EXTENSION
+                .toLowerCase()))) {
+                file = new File(file.getPath() + Project.FILE_EXTENSION);
+            }
+            saved = writeProject(file, p);
+            String filePath = file.getAbsolutePath();
+            lastSavePath =
+                filePath.substring(0, filePath.lastIndexOf(File.separatorChar));
+
+            getProjectFrame().refreshControls();
+        }
+        return saved;
+    }
+
+    /**
+     * Checks whether the project and related unsaved data is modified,
+     * and allows the user to save it.
+     * 
+     * @return true if the data has been correctly saved, false otherwise
+     */
+    private boolean askSave() {
+        if (p != null && p.hasChanged()) {
+            TerminationProcess process = Launcher.getTerminationProcess();
+            UnsavedDataPanel panel = process.getUnsavedDataPanel();
+            panel.setHeaderText(PluginServices.getText(this,
+                "Select_resources_to_save_before_closing_current_project"));
+            panel.setAcceptText(PluginServices.getText(this, "save_resources"),
+                PluginServices.getText(this,
+                    "Save_the_selected_resources_and_close_current_project"));
+            panel.setCancelText(PluginServices.getText(this, "Dont_close"),
+                PluginServices.getText(this, "Return_to_current_project"));
+            int closeCurrProj;
+            try {
+                closeCurrProj = process.manageUnsavedData();
+                if (closeCurrProj == JOptionPane.NO_OPTION) {
+                    // the user chose to return to current project
+                    return false;
+                }
+            } catch (Exception e) {
+                LOG.error("Some data can not be saved", e);
+            }           
+        }
+        return true;
+    }
+
+    /**
+     * @see com.iver.mdiApp.plugins.IExtension#updateUI(java.lang.String)
+     */
+    public void execute(String actionCommand) {
+        if (actionCommand.equals("NUEVO")) {
+            if (!askSave()) {
+                return;
+            }
+
+            projectPath = null;
+            // ProjectDocument.initializeNUMS();
+            PluginServices.getMDIManager().closeAllWindows();
+            setProject(ProjectManager.getInstance().createProject());
+            getProjectFrame().setProject(p);
+            showProjectWindow();
+            PluginServices.getMainFrame().setTitle(
+                PluginServices.getText(this, "sin_titulo"));
+        } else
+            if (actionCommand.equals("ABRIR")) {
+                if (!askSave()) {
+                    return;
+                }
+
+                Preferences prefs =
+                    Preferences.userRoot().node("gvsig.foldering");
+                JFileChooser jfc =
+                    new JFileChooser(PROJECT_FILE_CHOOSER_ID, prefs.get(
+                        "ProjectsFolder", null));
+                jfc.addChoosableFileFilter(new GenericFileFilter(
+                    Project.FILE_EXTENSION, PluginServices.getText(this,
+                        "tipo_fichero_proyecto")));
+
+                if (jfc.showOpenDialog((Component) PluginServices
+                    .getMainFrame()) == JFileChooser.APPROVE_OPTION) {
+                    // ProjectDocument.initializeNUMS();
+                    PluginServices.getMDIManager().closeAllWindows();
+
+                    File projectFile = jfc.getSelectedFile();
+                    Project o = readProject(projectFile);
+                    setPath(projectFile.getAbsolutePath());
+                    // lastPath = getPath();
+                    if (o != null) {
+                        setProject(o);
+                    }
+
+                    getProjectFrame().setProject(p);
+                    PluginServices.getMainFrame().setTitle(p.getName());
+                    getProjectFrame().refreshControls();
+
+                    // p.restoreWindowProperties();
+                }
+            } else
+                if (actionCommand.equals("GUARDAR")) {
+                    guardar();
+                } else
+                    if (actionCommand.equals("GUARDAR_COMO")) {
+                        guardarDialogo();
+                    } else
+                        if (actionCommand.equals("SALIR")) {
+                            Launcher.closeApplication();
+                        }
+    }
+
+    /**
+     * Escribe el proyecto en XML.
+     * 
+     * @param file
+     *            Fichero.
+     * @param p
+     *            Proyecto.
+     */
+    public boolean writeProject(File file, Project p) {
+        return writeProject(file, p, true);
+    }
+
+    /**
+     * Escribe el proyecto en XML. Pero permite decidir si se
+     * pide confirmaci�n para sobreescribir
+     * 
+     * @param file
+     *            Fichero.
+     * @param p
+     *            Proyecto.
+     * @param askConfirmation
+     *            boolean
+     */
+    public boolean writeProject(File file, Project p, boolean askConfirmation) {
+        if (askConfirmation && file.exists()) {
+            int resp =
+                JOptionPane.showConfirmDialog((Component) PluginServices
+                    .getMainFrame(), PluginServices.getText(this,
+                    "fichero_ya_existe_seguro_desea_guardarlo"), PluginServices
+                    .getText(this, "guardar"), JOptionPane.YES_NO_OPTION);
+            if (resp != JOptionPane.YES_OPTION) {
+                return false;
+            }
+        }
+        NotificationManager.addInfo(PluginServices.getText(this,
+            "writinng_project") + ": " + file.getName());
+
+        // write it out as XML
+        try {
+            fireBeforeSavingFileEvent(new SaveEvent(this,
+                SaveEvent.BEFORE_SAVING, file));
+            p.saveState(file);
+            fireAfterSavingFileEvent(new SaveEvent(this,
+                SaveEvent.AFTER_SAVING, file));
+            PluginServices.getMainFrame().setTitle(file.getName());
+            setPath(file.toString());
+
+        } catch (PersistenceException e) {
+            String messagestack = e.getLocalizedMessageStack();
+            NotificationManager.addError(
+                PluginServices.getText(this, "error_writing_project") + ": "
+                    + file.getName() + "\n" + messagestack, e);
+            return false;
+        } catch (Exception e) {
+            NotificationManager.addError(
+                PluginServices.getText(this, "error_writing_project") + ": "
+                    + file.getName(), e);
+            return false;
+        }
+        NotificationManager.addInfo(PluginServices.getText(this,
+            "wrote_project") + ": " + file.getName());
+        return true;
+    }
+
+    public Project readProject(String path) {
+        Project project = ProjectManager.getInstance().createProject();
+
+        project.loadState(new File(path));
+        return (Project) project;
+    }
+
+    /**
+     * Lee del XML el proyecto.<br>
+     * <br>
+     * 
+     * Reads the XML of the project.<br>
+     * It returns a project object holding all needed info that is not linked to
+     * the Project Dialog. <br>
+     * In case you want the project to be
+     * linked to the window you must set this object to the extension:<br>
+     * 
+     * <b>Example:</b><br>
+     * 
+     * ...<br>
+     * ...<br>
+     * Project p = ProjectExtension.readProject(projectFile);<br>
+     * ProjectExtension.setProject(p);
+     * ...<br>
+     * ...<br>
+     * 
+     * @param file
+     *            Fichero.
+     * 
+     * @return Project
+     * 
+     */
+    public Project readProject(File file) {
+        Project project = ProjectManager.getInstance().createProject();
+
+        project.loadState(file);
+        return (Project) project;
+    }
+
+    /**
+     * Devuelve el proyecto.
+     * 
+     * @return Proyecto.
+     */
+    public Project getProject() {
+        return p;
+    }
+
+    /**
+     * @see org.gvsig.andami.plugins.IExtension#isEnabled()
+     */
+    public boolean isEnabled() {
+        return true;
+    }
+
+    /**
+     * @see org.gvsig.andami.plugins.IExtension#isVisible()
+     */
+    public boolean isVisible() {
+        return true;
+    }
+
+    /**
+     * Sets the project
+     * 
+     * @param p
+     */
+    public void setProject(Project p) {
+        getProjectFrame().setProject(p);
+        this.p = p;
+    }
+
+    private void registerDocuments() {
+        ViewManager.register();
+    }
+
+    private void initializeDocumentActionsExtensionPoint() {
+        ExtensionPointManager epMan = ToolsLocator.getExtensionPointManager();
+        epMan.add("DocumentActions_View",
+            "Context menu options of the view document list"
+                + " in the project window " + "(register instances of "
+                + "org.gvsig.app.project.AbstractDocumentContextMenuAction)");
+    }
+
+    public static String getPath() {
+        return projectPath;
+    }
+
+    public static void setPath(String path) {
+        projectPath = path;
+    }
+
+    public IWindow getProjectWindow() {
+        return getProjectFrame();
+    }
+
+    public IExtensionStatus getStatus() {
+        return this;
+    }
+
+    public boolean hasUnsavedData() {
+        return p.hasChanged();
+    }
+
+    public IUnsavedData[] getUnsavedData() {
+        if (hasUnsavedData()) {
+            UnsavedProject data = new UnsavedProject(this);
+            IUnsavedData[] dataArray = { data };
+            return dataArray;
+        } else {
+            return null;
+        }
+    }
+
+    /**
+     * Implements the IUnsavedData interface to show unsaved projects
+     * in the Unsavad Data dialog.
+     * 
+     * @author Cesar Martinez Izquierdo <cesar.martinez@iver.es>
+     */
+    public class UnsavedProject extends UnsavedData {
+
+        public UnsavedProject(IExtension extension) {
+            super(extension);
+        }
+
+        public String getDescription() {
+            if (getPath() == null) {
+                return PluginServices.getText(ProjectExtension.this,
+                    "Unnamed_new_gvsig_project_");
+            } else {
+                return PluginServices.getText(ProjectExtension.this,
+                    "Modified_project_");
+            }
+        }
+
+        public String getResourceName() {
+            if (getPath() == null) {
+                return PluginServices.getText(ProjectExtension.this, "Unnamed");
+            } else {
+                return getPath();
+            }
+
+        }
+
+        public boolean saveData() {
+            return guardar();
+        }
+
+        public String getIcon() {
+            return "images/logoGVA.gif";
+        }
+    }
+
+    public IMonitorableTask[] getRunningProcesses() {
+        // TODO Auto-generated method stub
+        return null;
+    }
+
+    public boolean hasRunningProcesses() {
+        // TODO Auto-generated method stub
+        return false;
+    }
+
+    /**
+     * Adds the specified before saving listener to receive
+     * "before saving file events" from
+     * this component.
+     * If l is null, no exception is thrown and no action is performed.
+     * 
+     * @author Pablo Piqueras Bartolom� <pablo.piqueras@iver.es>
+     * 
+     * @param l
+     *            the before saving listener.
+     * @see SaveEvent
+     * @see BeforeSavingListener
+     * @see #removeListener(BeforeSavingListener)
+     * @see #getBeforeSavingListeners
+     */
+    public synchronized void addListener(BeforeSavingListener l) {
+        if (l == null) {
+            return;
+        }
+        if (!this.beforeSavingListeners.contains(l)) {
+            this.beforeSavingListeners.add(l);
+        }
+    }
+
+    /**
+     * Adds the specified after saving listener to receive
+     * "after saving file events" from
+     * this component.
+     * If l is null, no exception is thrown and no action is performed.
+     * 
+     * @author Pablo Piqueras Bartolom� <pablo.piqueras@iver.es>
+     * 
+     * @param l
+     *            the after saving listener.
+     * @see SaveEvent
+     * @see AfterSavingListener
+     * @see #removeListener(AfterSavingListener)
+     * @see #getAfterSavingListeners()
+     */
+    public synchronized void addListener(AfterSavingListener l) {
+        if (l == null) {
+            return;
+        }
+
+        if (!this.afterSavingListeners.contains(l)) {
+            this.afterSavingListeners.add(l);
+        }
+
+    }
+
+    /**
+     * Returns an array of all the before saving listeners
+     * registered on this component.
+     * 
+     * @author Pablo Piqueras Bartolom� <pablo.piqueras@iver.es>
+     * 
+     * @return all of this component's <code>BeforeSavingListener</code>s
+     *         or an empty array if no key
+     *         listeners are currently registered
+     * 
+     * @see #addBeforeSavingListener(BeforeSavingListener)
+     * @see #removeBeforeSavingListener(BeforeSavingListener)
+     */
+    public synchronized BeforeSavingListener[] getBeforeSavingListeners() {
+        return this.beforeSavingListeners
+            .toArray(new BeforeSavingListener[] {});
+    }
+
+    /**
+     * Returns an array of all the after saving listeners
+     * registered on this component.
+     * 
+     * @author Pablo Piqueras Bartolom� <pablo.piqueras@iver.es>
+     * 
+     * @return all of this component's <code>AfterSavingListener</code>s
+     *         or an empty array if no key
+     *         listeners are currently registered
+     * 
+     * @see #addAfterSavingListener(AfterSavingListener)
+     * @see #removeAfterSavingListener
+     */
+    public synchronized AfterSavingListener[] getAfterSavingListeners() {
+        return this.afterSavingListeners.toArray(new AfterSavingListener[] {});
+
+    }
+
+    /**
+     * Removes the specified before saving listener so that it no longer
+     * receives save file events from this component. This method performs
+     * no function, nor does it throw an exception, if the listener
+     * specified by the argument was not previously added to this component.
+     * If listener <code>l</code> is <code>null</code>,
+     * no exception is thrown and no action is performed.
+     * 
+     * @author Pablo Piqueras Bartolom� <pablo.piqueras@iver.es>
+     * 
+     * @param l
+     *            the before saving listener
+     * @see SaveEvent
+     * @see BeforeSavingListener
+     * @see #addListener(BeforeSavingListener)
+     * @see #getBeforeSavingListeners()
+     */
+    public synchronized void removeListener(BeforeSavingListener l) {
+        if (l == null) {
+            return;
+        }
+
+        this.beforeSavingListeners.remove(l);
+    }
+
+    /**
+     * Removes the specified after saving listener so that it no longer
+     * receives save file events from this component. This method performs
+     * no function, nor does it throw an exception, if the listener
+     * specified by the argument was not previously added to this component.
+     * If listener <code>l</code> is <code>null</code>,
+     * no exception is thrown and no action is performed.
+     * 
+     * @author Pablo Piqueras Bartolom� <pablo.piqueras@iver.es>
+     * 
+     * @param l
+     *            the after saving listener
+     * @see SaveEvent
+     * @see AfterSavingListener
+     * @see #addListener(AfterSavingListener)
+     * @see #getAfterSavingListeners()
+     */
+    public synchronized void removeListener(AfterSavingListener l) {
+        if (l == null) {
+            return;
+        }
+
+        this.afterSavingListeners.remove(l);
+    }
+
+    /**
+     * Reports a before saving file event.
+     * 
+     * @author Pablo Piqueras Bartolom� <pablo.piqueras@iver.es>
+     * 
+     * @param evt
+     *            the before saving file event
+     */
+    protected void fireBeforeSavingFileEvent(SaveEvent evt) {
+        if ((evt.getID() != SaveEvent.BEFORE_SAVING) || (evt.getFile() == null)) {
+            return;
+        }
+
+        Iterator<BeforeSavingListener> iter =
+            this.beforeSavingListeners.iterator();
+
+        while (iter.hasNext()) {
+            iter.next().beforeSaving(evt);
+        }
+    }
+
+    /**
+     * Reports a after saving file event.
+     * 
+     * @author Pablo Piqueras Bartolom� <pablo.piqueras@iver.es>
+     * 
+     * @param evt
+     *            the after saving file event
+     */
+    protected void fireAfterSavingFileEvent(SaveEvent evt) {
+        if ((evt.getID() != SaveEvent.AFTER_SAVING) || (evt.getFile() == null)) {
+            return;
+        }
+        Iterator<AfterSavingListener> iter =
+            this.afterSavingListeners.iterator();
+
+        while (iter.hasNext()) {
+            iter.next().afterSaving(evt);
+        }
+
+    }
+}

Property changes on: tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/app/extension/ProjectExtension.java
___________________________________________________________________
Added: svn:eol-style
   + native
Added: svn:keywords
   + Author Date Id Revision

Index: tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/app/extension/ViewSelectionControls.java
===================================================================
--- tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/app/extension/ViewSelectionControls.java	(revision 0)
+++ tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/app/extension/ViewSelectionControls.java	(revision 38653)
@@ -0,0 +1,195 @@
+/* gvSIG. Sistema de Informaci�n Geogr�fica de la Generalitat Valenciana
+ *
+ * Copyright (C) 2005 IVER T.I. and Generalitat Valenciana.
+ *
+ * This program is free software; you can redistribute it and/or
+ * modify it under the terms of the GNU General Public License
+ * as published by the Free Software Foundation; either version 2
+ * of the License, or (at your option) any later version.
+ *
+ * This program is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
+ * GNU General Public License for more details.
+ *
+ * You should have received a copy of the GNU General Public License
+ * along with this program; if not, write to the Free Software
+ * Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA  02111-1307,USA.
+ *
+ * For more information, contact:
+ *
+ *  Generalitat Valenciana
+ *   Conselleria d'Infraestructures i Transport
+ *   Av. Blasco Ib��ez, 50
+ *   46010 VALENCIA
+ *   SPAIN
+ *
+ *      +34 963862235
+ *   gvsig@gva.es
+ *      www.gvsig.gva.es
+ *
+ *    or
+ *
+ *   IVER T.I. S.A
+ *   Salamanca 50
+ *   46005 Valencia
+ *   Spain
+ *
+ *   +34 963163400
+ *   dac@iver.es
+ */
+
+/* CVS MESSAGES:
+ *
+ * $Id$
+ * $Log$
+ * Revision 1.16  2007-03-06 16:34:02  caballero
+ * Exceptions
+ *
+ * Revision 1.15  2007/01/04 07:24:32  caballero
+ * isModified
+ *
+ * Revision 1.14  2006/12/27 11:08:56  fdiaz
+ * Arreglado el metodo hasVectorLayers para que no se pare en los grupos de capas cuando estos no tienen capas vectoriales.
+ *
+ * Revision 1.13  2006/09/25 16:54:12  caballero
+ * invert selection
+ *
+ * Revision 1.12  2006/09/20 13:17:40  jaume
+ * *** empty log message ***
+ *
+ * Revision 1.11  2006/09/20 10:56:56  sbayarri
+ * Refactorizaci�n clases View y ProjectView
+ *
+ * Revision 1.10  2006/09/15 10:40:03  caballero
+ * extensibilidad de documentos
+ *
+ * Revision 1.9  2006/09/11 16:14:15  fjp
+ * Invertir seleccion. Falta subirlo al branch de la 1.0
+ *
+ * Revision 1.8  2006/09/11 06:53:13  fjp
+ * Antes del parto
+ *
+ * Revision 1.7  2006/09/04 16:26:54  fjp
+ * Seleccionar por pol�gono
+ *
+ * Revision 1.6  2006/08/29 07:56:27  cesar
+ * Rename the *View* family of classes to *Window* (ie: SingletonView to SingletonWindow, ViewInfo to WindowInfo, etc)
+ *
+ * Revision 1.5  2006/08/29 07:21:08  cesar
+ * Rename com.iver.cit.gvsig.fmap.Fmap class to com.iver.cit.gvsig.fmap.MapContext
+ *
+ * Revision 1.4  2006/08/29 07:13:53  cesar
+ * Rename class com.iver.andami.ui.mdiManager.View to com.iver.andami.ui.mdiManager.IWindow
+ *
+ * Revision 1.3  2006/08/18 08:40:04  jmvivo
+ * Actualizado para que el isEnabled tenga en cuenta que las capas esten 'avialable'
+ *
+ * Revision 1.2  2006/07/27 06:20:28  jaume
+ * *** empty log message ***
+ *
+ * Revision 1.1  2006/07/26 09:53:05  jaume
+ * separadas las herramientas de selecci�n del viewControls al ViewSelectionControls
+ *
+ *
+ */
+package org.gvsig.app.extension;
+
+import org.gvsig.andami.IconThemeHelper;
+import org.gvsig.andami.PluginServices;
+import org.gvsig.andami.plugins.Extension;
+import org.gvsig.andami.ui.mdiManager.IWindow;
+import org.gvsig.app.project.documents.AbstractDocument;
+import org.gvsig.app.project.documents.view.ViewDocument;
+import org.gvsig.app.project.documents.view.gui.DefaultViewPanel;
+import org.gvsig.fmap.mapcontext.MapContext;
+import org.gvsig.fmap.mapcontext.layers.FLayer;
+import org.gvsig.fmap.mapcontext.layers.FLayers;
+import org.gvsig.fmap.mapcontext.layers.vectorial.FLyrVect;
+import org.gvsig.fmap.mapcontrol.MapControl;
+import org.slf4j.Logger;
+import org.slf4j.LoggerFactory;
+
+
+/**
+ * Extension that handles the selection tools, selection tools have sense on
+ * vectorial layers only.
+ *
+ * @author jaume dominguez faus - jaume.dominguez@iver.es
+ *
+ */
+public class ViewSelectionControls extends Extension {
+    private static final Logger logger = LoggerFactory
+            .getLogger(ViewSelectionControls.class);
+	private DefaultViewPanel vista;
+	public void initialize() {
+		// TODO Auto-generated method stub
+		registerIcons();
+	}
+
+	private void registerIcons(){
+		IconThemeHelper.registerIcon("action", "selection-simple-select", this);
+		IconThemeHelper.registerIcon("action", "selection-select-by-rectangle", this);
+		IconThemeHelper.registerIcon("action", "selection-select-by-polygon", this);
+		IconThemeHelper.registerIcon("action", "selection-clear", this);
+	}
+
+	public void execute(String actionCommand) {
+		MapControl mapCtrl = vista.getMapControl();
+		logger.debug("Comand : " + actionCommand);
+		if (actionCommand.equalsIgnoreCase("selection-select-by-rectangle-view")) {
+			mapCtrl.setTool("rectSelection");
+			((AbstractDocument)vista.getModel()).setModified(true);
+
+		} else if (actionCommand.equalsIgnoreCase("selection-simple-select")) {
+			mapCtrl.setTool("pointSelection");
+			((AbstractDocument)vista.getModel()).setModified(true);
+			
+		} else if (actionCommand.equalsIgnoreCase("selection-select-by-polygon")) {
+			mapCtrl.setTool("polSelection");
+			((AbstractDocument)vista.getModel()).setModified(true);
+			
+		}
+	}
+	
+	public boolean isEnabled() {
+		ViewDocument model = vista.getModel();
+		MapContext mapa = model.getMapContext();
+
+		for (int i = 0; i < mapa.getLayers().getActives().length; i++) {
+			FLayer lyr = mapa.getLayers().getActives()[i];
+			if (lyr.isAvailable() && lyr instanceof FLyrVect) { // && !lyr.isEditing()) {
+				return true;
+			}
+		}
+		return false;
+	}
+
+	public boolean isVisible() {
+		IWindow f = PluginServices.getMDIManager().getActiveWindow();
+
+		if (f != null && f instanceof DefaultViewPanel) {
+			vista = (DefaultViewPanel) f;
+			ViewDocument model = vista.getModel();
+			MapContext mapa = model.getMapContext();
+
+			return hasVectorLayers(mapa.getLayers());
+
+		}
+		return false;
+	}
+
+	private boolean hasVectorLayers(FLayers layers) {
+		for (int i = 0; i < layers.getLayersCount(); i++) {
+			FLayer lyr =layers.getLayer(i);
+			if (lyr instanceof FLayers){
+				if (hasVectorLayers((FLayers) lyr)){
+					return true;
+				}
+			} else if (lyr instanceof FLyrVect) {
+				return true;
+			}
+		}
+		return false;
+	}
+}

Property changes on: tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/app/extension/ViewSelectionControls.java
___________________________________________________________________
Added: svn:keywords
   + Author Date Id Revision
Added: svn:eol-style
   + native

Index: tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/app/extension/ViewInvertSelection.java
===================================================================
--- tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/app/extension/ViewInvertSelection.java	(revision 0)
+++ tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/app/extension/ViewInvertSelection.java	(revision 38653)
@@ -0,0 +1,208 @@
+/* gvSIG. Sistema de Informaci�n Geogr�fica de la Generalitat Valenciana
+ *
+ * Copyright (C) 2005 IVER T.I. and Generalitat Valenciana.
+ *
+ * This program is free software; you can redistribute it and/or
+ * modify it under the terms of the GNU General Public License
+ * as published by the Free Software Foundation; either version 2
+ * of the License, or (at your option) any later version.
+ *
+ * This program is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
+ * GNU General Public License for more details.
+ *
+ * You should have received a copy of the GNU General Public License
+ * along with this program; if not, write to the Free Software
+ * Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA  02111-1307,USA.
+ *
+ * For more information, contact:
+ *
+ *  Generalitat Valenciana
+ *   Conselleria d'Infraestructures i Transport
+ *   Av. Blasco Ib��ez, 50
+ *   46010 VALENCIA
+ *   SPAIN
+ *
+ *      +34 963862235
+ *   gvsig@gva.es
+ *      www.gvsig.gva.es
+ *
+ *    or
+ *
+ *   IVER T.I. S.A
+ *   Salamanca 50
+ *   46005 Valencia
+ *   Spain
+ *
+ *   +34 963163400
+ *   dac@iver.es
+ */
+
+/* CVS MESSAGES:
+ *
+ * $Id: ViewSelectionControls.java 26282 2009-01-29 09:58:42Z vcaballero $
+ * $Log$
+ * Revision 1.16  2007-03-06 16:34:02  caballero
+ * Exceptions
+ *
+ * Revision 1.15  2007/01/04 07:24:32  caballero
+ * isModified
+ *
+ * Revision 1.14  2006/12/27 11:08:56  fdiaz
+ * Arreglado el metodo hasVectorLayers para que no se pare en los grupos de capas cuando estos no tienen capas vectoriales.
+ *
+ * Revision 1.13  2006/09/25 16:54:12  caballero
+ * invert selection
+ *
+ * Revision 1.12  2006/09/20 13:17:40  jaume
+ * *** empty log message ***
+ *
+ * Revision 1.11  2006/09/20 10:56:56  sbayarri
+ * Refactorizaci�n clases View y ProjectView
+ *
+ * Revision 1.10  2006/09/15 10:40:03  caballero
+ * extensibilidad de documentos
+ *
+ * Revision 1.9  2006/09/11 16:14:15  fjp
+ * Invertir seleccion. Falta subirlo al branch de la 1.0
+ *
+ * Revision 1.8  2006/09/11 06:53:13  fjp
+ * Antes del parto
+ *
+ * Revision 1.7  2006/09/04 16:26:54  fjp
+ * Seleccionar por pol�gono
+ *
+ * Revision 1.6  2006/08/29 07:56:27  cesar
+ * Rename the *View* family of classes to *Window* (ie: SingletonView to SingletonWindow, ViewInfo to WindowInfo, etc)
+ *
+ * Revision 1.5  2006/08/29 07:21:08  cesar
+ * Rename com.iver.cit.gvsig.fmap.Fmap class to com.iver.cit.gvsig.fmap.MapContext
+ *
+ * Revision 1.4  2006/08/29 07:13:53  cesar
+ * Rename class com.iver.andami.ui.mdiManager.View to com.iver.andami.ui.mdiManager.IWindow
+ *
+ * Revision 1.3  2006/08/18 08:40:04  jmvivo
+ * Actualizado para que el isEnabled tenga en cuenta que las capas esten 'avialable'
+ *
+ * Revision 1.2  2006/07/27 06:20:28  jaume
+ * *** empty log message ***
+ *
+ * Revision 1.1  2006/07/26 09:53:05  jaume
+ * separadas las herramientas de selecci�n del viewControls al ViewSelectionControls
+ *
+ *
+ */
+package org.gvsig.app.extension;
+
+import org.gvsig.andami.IconThemeHelper;
+import org.gvsig.andami.PluginServices;
+import org.gvsig.andami.messages.NotificationManager;
+import org.gvsig.andami.plugins.Extension;
+import org.gvsig.andami.ui.mdiManager.IWindow;
+import org.gvsig.app.project.documents.AbstractDocument;
+import org.gvsig.app.project.documents.view.ViewDocument;
+import org.gvsig.app.project.documents.view.gui.DefaultViewPanel;
+import org.gvsig.fmap.dal.DataStore;
+import org.gvsig.fmap.dal.exception.DataException;
+import org.gvsig.fmap.dal.feature.FeatureStore;
+import org.gvsig.fmap.mapcontext.MapContext;
+import org.gvsig.fmap.mapcontext.layers.FLayer;
+import org.gvsig.fmap.mapcontext.layers.FLayers;
+import org.gvsig.fmap.mapcontext.layers.operations.SingleLayer;
+import org.gvsig.fmap.mapcontext.layers.vectorial.FLyrVect;
+import org.slf4j.Logger;
+import org.slf4j.LoggerFactory;
+
+
+/**
+ * Extension that handles the selection tools, selection tools have sense on
+ * vectorial layers only.
+ *
+ * @author Vicente Caballero Navarro
+ *
+ */
+public class ViewInvertSelection extends Extension {
+    private static final Logger logger = LoggerFactory
+            .getLogger(ViewInvertSelection.class);
+	private DefaultViewPanel vista;
+	
+	public void initialize() {
+		IconThemeHelper.registerIcon("action", "selection-reverse", this);
+	}
+
+	public void postInitialize() {
+	}
+	
+	public void execute(String actionCommand) {
+		ViewDocument model = vista.getModel();
+		MapContext mapa = model.getMapContext();
+		logger.debug("Comand : " + actionCommand);
+		if (actionCommand.equalsIgnoreCase("selection-reverse-view")) {
+			FLayer[] actives = mapa.getLayers().getActives();
+			for (int i = 0; i < actives.length; i++) {
+				FLayer lyr = actives[i];
+				if (lyr.isAvailable() && lyr instanceof SingleLayer) {
+					SingleLayer lyrSingle = (SingleLayer) lyr;
+					DataStore ds = lyrSingle.getDataStore();
+					if (ds instanceof FeatureStore) {
+						try {
+							((FeatureStore) ds).getFeatureSelection().reverse();
+							((AbstractDocument) vista.getModel())
+									.setModified(true);
+						} catch (DataException e) {
+							e.printStackTrace();
+							NotificationManager.addError(e);
+						}
+					} else {
+						// TODO Not supported yet
+					}
+
+
+				}
+			}
+			((AbstractDocument)vista.getModel()).setModified(true);
+		}
+	}
+
+	public boolean isEnabled() {
+		ViewDocument model = vista.getModel();
+		MapContext mapa = model.getMapContext();
+
+		for (int i = 0; i < mapa.getLayers().getActives().length; i++) {
+			FLayer lyr = mapa.getLayers().getActives()[i];
+			if (lyr.isAvailable() && lyr instanceof FLyrVect){// && !lyr.isEditing()) {
+				return true;
+			}
+		}
+		return false;
+	}
+
+	public boolean isVisible() {
+		IWindow f = PluginServices.getMDIManager().getActiveWindow();
+
+		if (f != null && f instanceof DefaultViewPanel) {
+			vista = (DefaultViewPanel) f;
+			ViewDocument model = vista.getModel();
+			MapContext mapa = model.getMapContext();
+
+			return hasVectorLayers(mapa.getLayers());
+
+		}
+		return false;
+	}
+
+	private boolean hasVectorLayers(FLayers layers) {
+		for (int i = 0; i < layers.getLayersCount(); i++) {
+			FLayer lyr =layers.getLayer(i);
+			if (lyr instanceof FLayers){
+				if (hasVectorLayers((FLayers) lyr)){
+					return true;
+				}
+			} else if (lyr instanceof FLyrVect) {
+				return true;
+			}
+		}
+		return false;
+	}
+}
Index: tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/app/extension/ShowDevelInfoExtension.java
===================================================================
--- tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/app/extension/ShowDevelInfoExtension.java	(revision 0)
+++ tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/app/extension/ShowDevelInfoExtension.java	(revision 38653)
@@ -0,0 +1,65 @@
+package org.gvsig.app.extension;
+
+import org.gvsig.andami.PluginsLocator;
+import org.gvsig.andami.actioninfo.ActionInfo;
+import org.gvsig.andami.actioninfo.ActionInfoManager;
+import org.gvsig.andami.plugins.Extension;
+import org.gvsig.app.extension.develtools.ActionsInfoDevelTool;
+import org.gvsig.app.extension.develtools.IconThemeDevelTool;
+import org.gvsig.app.extension.develtools.MenusDevelTool;
+import org.gvsig.app.extension.develtools.PersistenceDevelTool;
+import org.gvsig.tools.ToolsLocator;
+import org.gvsig.tools.persistence.PersistenceManager;
+import org.gvsig.tools.persistence.exception.PersistenceException;
+import org.slf4j.Logger;
+import org.slf4j.LoggerFactory;
+
+public class ShowDevelInfoExtension extends Extension {
+
+	private static Logger logger = LoggerFactory
+			.getLogger(ShowDevelInfoExtension.class);
+
+	public void initialize() {
+		// Do nothing
+	}
+
+	public void postInitialize() {
+		super.postInitialize();
+//		ActionInfoManager actionMgr = PluginsLocator.getActionInfoManager();
+//		actionMgr.redirect("tools-devel-disposables-show-pendings", "layer-info-by-point");
+		
+		PersistenceManager manager = ToolsLocator.getPersistenceManager();
+		
+		try {
+			manager.setAutoValidation(PersistenceManager.MANDATORY_IF_DECLARED);
+		} catch (PersistenceException e) {
+			logger.warn(
+					"Error modificando el modo de autovalidacion de persistencia.",
+					e);
+		}
+
+	}
+
+	public void execute(String actionCommand) {
+		if ("tools-devel-show-persistencefactories".equalsIgnoreCase(actionCommand)) {
+			new PersistenceDevelTool().showPersistenceFactories();
+		} else if ("tools-devel-show-icontheme".equalsIgnoreCase(actionCommand)) {
+			new IconThemeDevelTool().showDefaultIconTheme();
+		} else if ("tools-devel-show-actions".equalsIgnoreCase(actionCommand)) {
+			new ActionsInfoDevelTool().showActions();
+		} else if ("tools-devel-show-menus".equalsIgnoreCase(actionCommand)) {
+			new MenusDevelTool().showAllMenus();
+		} else if ("tools-devel-show-menus-by-plugin".equalsIgnoreCase(actionCommand)) {
+			new MenusDevelTool().showAllMenusByPlugin();
+		}
+	}
+
+
+	public boolean isEnabled() {
+		return true;
+	}
+
+	public boolean isVisible() {
+		return true;
+	}
+}

Property changes on: tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/app/extension/ShowDevelInfoExtension.java
___________________________________________________________________
Added: svn:mime-type
   + text/plain

Index: tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/app/extension/About.java
===================================================================
--- tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/app/extension/About.java	(revision 0)
+++ tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/app/extension/About.java	(revision 38653)
@@ -0,0 +1,224 @@
+/*
+ * Created on 17-feb-2004
+ *
+ * To change the template for this generated file go to
+ * Window&gt;Preferences&gt;Java&gt;Code Generation&gt;Code and Comments
+ */
+/* gvSIG. Sistema de Informaci�n Geogr�fica de la Generalitat Valenciana
+ *
+ * Copyright (C) 2004 IVER T.I. and Generalitat Valenciana.
+ *
+ * This program is free software; you can redistribute it and/or
+ * modify it under the terms of the GNU General Public License
+ * as published by the Free Software Foundation; either version 2
+ * of the License, or (at your option) any later version.
+ *
+ * This program is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
+ * GNU General Public License for more details.
+ *
+ * You should have received a copy of the GNU General Public License
+ * along with this program; if not, write to the Free Software
+ * Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA  02111-1307,USA.
+ *
+ * For more information, contact:
+ *
+ *  Generalitat Valenciana
+ *   Conselleria d'Infraestructures i Transport
+ *   Av. Blasco Ib��ez, 50
+ *   46010 VALENCIA
+ *   SPAIN
+ *
+ *      +34 963862235
+ *   gvsig@gva.es
+ *      www.gvsig.gva.es
+ *
+ *    or
+ *
+ *   IVER T.I. S.A
+ *   Salamanca 50
+ *   46005 Valencia
+ *   Spain
+ *
+ *   +34 963163400
+ *   dac@iver.es
+ */
+package org.gvsig.app.extension;
+
+import java.awt.BorderLayout;
+import java.awt.FlowLayout;
+import java.awt.event.ActionEvent;
+import java.awt.event.ActionListener;
+import java.net.URL;
+
+import javax.swing.JButton;
+import javax.swing.JPanel;
+
+import org.gvsig.about.AboutLocator;
+import org.gvsig.about.AboutManager;
+import org.gvsig.andami.PluginServices;
+import org.gvsig.andami.plugins.Extension;
+import org.gvsig.andami.ui.mdiManager.IWindow;
+import org.gvsig.andami.ui.mdiManager.WindowInfo;
+import org.gvsig.app.ApplicationLocator;
+import org.gvsig.app.ApplicationManager;
+
+
+
+/**
+ * Extensi�n que abre una nueva ventana mostrando la informaci�n sobre el
+ * gvSIG.
+ *
+ */
+public class About extends Extension {
+	/**
+	 * @see org.gvsig.andami.plugins.IExtension#isEnabled()
+	 */
+	public boolean isEnabled() {
+		return true;
+	}
+
+	/**
+	 * @see com.iver.mdiApp.plugins.IExtension#isVisible()
+	 */
+	public boolean isVisible() {
+		return true;
+	}
+
+	/**
+	 * @see org.gvsig.andami.plugins.IExtension#initialize()
+	 */
+	public void initialize() {
+	}
+
+	private URL getResource(String name) {
+        URL resource = this.getClass().getClassLoader().getResource(name);
+		return resource;
+	}
+	
+	public void postInitialize() {
+		super.postInitialize();
+		ApplicationManager application = ApplicationLocator.getManager();
+		
+		Version version = application.getVersion();
+		AboutManager about = application.getAbout();
+		
+        about.setProject("gvSIG desktop", getResource("about.htm"),
+            getResource("images/gvsig-icon16x16.png"));
+		about.getProject().set("build",version.getBuildId());
+		about.getProject().set("version",version.getFormat());
+        about.getProject().set("java.version",
+            System.getProperty("java.version"));
+		
+		about.addSponsor(
+			"CIT GVA", //"Conselleria d'infraestructures i transport de la Generalitat Valenciana",
+			getResource("gva-cit.html"),
+			1
+		);
+
+		about.addDeveloper(
+			"IVER",
+			getResource("iver.html"),
+			1
+		);
+		
+		about.addDeveloper(
+			"PRODEVELOP",
+			getResource("prodevelop.html"),
+			2
+		);
+		
+		about.addDeveloper(
+			"Software Colaborativo",
+			getResource("scolab.html"),
+			3
+		);
+		
+		about.addDeveloper(
+			"DISID",
+			getResource("disid.html"),
+			4
+		);
+	}
+
+	public void execute(String actionCommand) {
+		ApplicationManager application = ApplicationLocator.getManager();
+		
+		application.getUIManager().addCentredWindow(new AboutWindow());
+	}
+    
+	class AboutWindow extends JPanel implements IWindow {
+
+		/**
+		 * 
+		 */
+		private static final long serialVersionUID = -3577229971045886621L;
+
+		AboutWindow() {
+			AboutManager aboutManager = AboutLocator.getManager();
+
+			this.setLayout(new BorderLayout());
+			this.add(aboutManager.getAboutPanel(), BorderLayout.CENTER);
+			this.add(new JPanelButtons(), BorderLayout.SOUTH);
+		}
+		
+		public WindowInfo getWindowInfo() {
+			WindowInfo winfo = new WindowInfo(
+					WindowInfo.MODALDIALOG|WindowInfo.RESIZABLE
+			);
+			winfo.setTitle(PluginServices.getText(this,"acerca_de"));
+            winfo.setHeight(500);
+            winfo.setWidth(750);
+			return winfo;
+		}
+
+		public Object getWindowProfile() {
+			return WindowInfo.DIALOG_PROFILE;
+		}
+		
+		public void closeWindow() {
+			PluginServices.getMDIManager().closeWindow(this);
+		}
+
+		class JPanelButtons extends JPanel {
+			/**
+			 * 
+			 */
+			private static final long serialVersionUID = 1529755877776747074L;
+			JButton close = null;
+			JButton installedPlugins = null;
+
+			JPanelButtons() {
+                this.setLayout(new FlowLayout(FlowLayout.RIGHT));
+				this.close = getCloseButton();
+				this.installedPlugins = getInstalledPluginsButton();
+                this.add(this.close);
+				this.add(this.installedPlugins);
+			}
+
+			private JButton getCloseButton() {
+				JButton button = new JButton(
+						PluginServices.getText(this, "Close"));
+				button.addActionListener(new ActionListener() {
+					public void actionPerformed(ActionEvent e) {
+						closeWindow();
+					}
+				});
+				return button;
+			}
+
+			private JButton getInstalledPluginsButton() {
+				JButton button = new JButton(PluginServices.getText(this,
+						"Installed plugins"));
+				button.addActionListener(new ActionListener() {
+					public void actionPerformed(ActionEvent e) {
+						// TODO: Need implementation
+					}
+				});
+				return button;
+			}
+
+		}
+	}
+}

Property changes on: tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/app/extension/About.java
___________________________________________________________________
Added: svn:eol-style
   + native
Added: svn:keywords
   + Author Date Id Revision

Index: tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/app/extension/InitialWarningExtension.java
===================================================================
--- tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/app/extension/InitialWarningExtension.java	(revision 0)
+++ tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/app/extension/InitialWarningExtension.java	(revision 38653)
@@ -0,0 +1,210 @@
+/* gvSIG. Sistema de Informaci�n Geogr�fica de la Generalitat Valenciana
+ *
+ * Copyright (C) 2005 IVER T.I. and Generalitat Valenciana.
+ *
+ * This program is free software; you can redistribute it and/or
+ * modify it under the terms of the GNU General Public License
+ * as published by the Free Software Foundation; either version 2
+ * of the License, or (at your option) any later version.
+ *
+ * This program is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
+ * GNU General Public License for more details.
+ *
+ * You should have received a copy of the GNU General Public License
+ * along with this program; if not, write to the Free Software
+ * Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA  02111-1307,USA.
+ *
+ * For more information, contact:
+ *
+ *  Generalitat Valenciana
+ *   Conselleria d'Infraestructures i Transport
+ *   Av. Blasco Ib��ez, 50
+ *   46010 VALENCIA
+ *   SPAIN
+ *
+ *      +34 963862235
+ *   gvsig@gva.es
+ *      www.gvsig.gva.es
+ *
+ *    or
+ *
+ *   IVER T.I. S.A
+ *   Salamanca 50
+ *   46005 Valencia
+ *   Spain
+ *
+ *   +34 963163400
+ *   dac@iver.es
+ */
+
+/* CVS MESSAGES:
+*
+* $Id$
+* $Log$
+* Revision 1.4  2006-10-02 13:52:34  jaume
+* organize impots
+*
+* Revision 1.3  2006/08/29 07:56:27  cesar
+* Rename the *View* family of classes to *Window* (ie: SingletonView to SingletonWindow, ViewInfo to WindowInfo, etc)
+*
+* Revision 1.2  2006/08/29 07:13:53  cesar
+* Rename class com.iver.andami.ui.mdiManager.View to com.iver.andami.ui.mdiManager.IWindow
+*
+* Revision 1.1  2006/05/25 16:27:21  jaume
+* *** empty log message ***
+*
+*
+*/
+package org.gvsig.app.extension;
+
+import java.awt.Color;
+import java.awt.Window;
+
+import javax.swing.JButton;
+import javax.swing.JCheckBox;
+import javax.swing.JLabel;
+import javax.swing.JPanel;
+import javax.swing.JWindow;
+import javax.swing.border.TitledBorder;
+
+import org.gvsig.andami.PluginServices;
+import org.gvsig.andami.plugins.Extension;
+import org.gvsig.andami.ui.mdiManager.WindowInfo;
+
+
+public class InitialWarningExtension extends Extension {
+//	public static Preferences fPrefs = Preferences.userRoot().node( "gvsig.initial_warkning" );
+//	private boolean show = fPrefs.getBoolean( "show_panel", true);
+	private DlgWaring dlgWarning;
+    /**
+	 * @see org.gvsig.andami.plugins.IExtension#isEnabled()
+	 */
+	public boolean isEnabled() {
+		return true;
+	}
+
+	/**
+	 * @see com.iver.mdiApp.plugins.IExtension#isVisible()
+	 */
+	public boolean isVisible() {
+		return true;
+	}
+
+	/**
+	 * @see org.gvsig.andami.plugins.IExtension#initialize()
+	 */
+	public void initialize() {
+//		if (show) {
+			dlgWarning = new DlgWaring();
+			dlgWarning.setText(PluginServices.getText(this, "initial_warning"));
+			dlgWarning.setVisible(true);
+			//			PluginServices.getMDIManager().addWindow(dlgWarning);
+//		}
+
+	}
+
+	/**
+	 * @see org.gvsig.andami.plugins.IExtension#execute(java.lang.String)
+	 */
+	public void execute(String actionCommand) {
+
+	}
+
+	private class DlgWaring extends JWindow{
+
+		private JButton btnOk = null;
+		private JCheckBox chkBoxShowAgain = null;
+		private JLabel lblText = null;
+		private JPanel panel=null;
+		private JPanel panel2;
+		/**
+		 * This is the default constructor
+		 */
+		public DlgWaring() {
+			super((Window)PluginServices.getMainFrame());
+			Window window=(Window)PluginServices.getMainFrame();
+			setLocation(window.getWidth()/2+window.getX()-150,window.getHeight()/2+window.getY()-150);
+			initialize();
+			this.setAlwaysOnTop(true);
+		}
+
+		public void setText(String string) {
+			lblText.setText(string);
+		}
+
+		/**
+		 * This method initializes this
+		 *
+		 * @return void
+		 */
+		private void initialize() {
+			panel=new JPanel();
+			panel.setBackground(Color.black);
+			panel.setLayout(null);
+			panel.setBounds(0,0,300,300);
+			panel2=new JPanel();
+			panel2.setLayout(null);
+			panel2.setBounds(2,2,298,298);
+			lblText = new JLabel();
+			lblText.setBounds(15, 15, 271, 200);
+			lblText.setText("JLabel");
+			lblText.setBorder(new TitledBorder(PluginServices.getText(this, "warning")));
+			panel2.add(lblText);
+			panel2.setSize((int)(panel.getSize().getWidth()-4),(int)(panel.getSize().getHeight()-4));
+			panel.add(panel2);
+			this.setLayout(null);
+			this.setSize(300, 300);
+			this.add(getBtnOk(), null);
+//			this.add(getChkBoxShowAgain(), null);
+			this.add(panel, null);
+		}
+
+		/**
+		 * This method initializes btnOk
+		 *
+		 * @return javax.swing.JButton
+		 */
+		private JButton getBtnOk() {
+			if (btnOk == null) {
+				btnOk = new JButton();
+				btnOk.setBounds(100, 250, 100, 20);
+				btnOk.setText(PluginServices.getText(this, "aceptar"));
+				btnOk.addActionListener(new java.awt.event.ActionListener() {
+					public void actionPerformed(java.awt.event.ActionEvent e) {
+						dlgWarning.setVisible(false);
+						dlgWarning.dispose();
+						//						PluginServices.getMDIManager().closeWindow(dlgWarning);
+					}
+				});
+			}
+			return btnOk;
+		}
+
+		/**
+		 * This method initializes chkBoxShowAgain
+		 *
+		 * @return javax.swing.JCheckBox
+		 */
+//		private JCheckBox getChkBoxShowAgain() {
+//			if (chkBoxShowAgain == null) {
+//				chkBoxShowAgain = new JCheckBox();
+//				chkBoxShowAgain.setBounds(44, 116, 241, 21);
+//				chkBoxShowAgain.setSelected(true);
+//				chkBoxShowAgain.setText(PluginServices.getText(this, "show_this_dialog_next_startup"));
+//			}
+//			return chkBoxShowAgain;
+//		}
+
+		public WindowInfo getWindowInfo() {
+			WindowInfo vi = new WindowInfo(WindowInfo.MODALDIALOG);
+			vi.setWidth(300+8);
+			vi.setHeight(250);
+			vi.setTitle(PluginServices.getText(this, "warning"));
+			return vi;
+		}
+
+	}  //  @jve:decl-index=0:visual-constraint="10,10"
+
+}

Property changes on: tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/app/extension/InitialWarningExtension.java
___________________________________________________________________
Added: svn:keywords
   + Author Date Id Revision
Added: svn:eol-style
   + native

Index: tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/app/extension/ZoomPrev.java
===================================================================
--- tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/app/extension/ZoomPrev.java	(revision 0)
+++ tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/app/extension/ZoomPrev.java	(revision 38653)
@@ -0,0 +1,104 @@
+/* gvSIG. Sistema de Informaci�n Geogr�fica de la Generalitat Valenciana
+ *
+ * Copyright (C) 2004 IVER T.I. and Generalitat Valenciana.
+ *
+ * This program is free software; you can redistribute it and/or
+ * modify it under the terms of the GNU General Public License
+ * as published by the Free Software Foundation; either version 2
+ * of the License, or (at your option) any later version.
+ *
+ * This program is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
+ * GNU General Public License for more details.
+ *
+ * You should have received a copy of the GNU General Public License
+ * along with this program; if not, write to the Free Software
+ * Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA  02111-1307,USA.
+ *
+ * For more information, contact:
+ *
+ *  Generalitat Valenciana
+ *   Conselleria d'Infraestructures i Transport
+ *   Av. Blasco Ib��ez, 50
+ *   46010 VALENCIA
+ *   SPAIN
+ *
+ *      +34 963862235
+ *   gvsig@gva.es
+ *      www.gvsig.gva.es
+ *
+ *    or
+ *
+ *   IVER T.I. S.A
+ *   Salamanca 50
+ *   46005 Valencia
+ *   Spain
+ *
+ *   +34 963163400
+ *   dac@iver.es
+ */
+package org.gvsig.app.extension;
+
+import org.gvsig.andami.IconThemeHelper;
+import org.gvsig.andami.PluginServices;
+import org.gvsig.andami.plugins.Extension;
+import org.gvsig.app.project.documents.AbstractDocument;
+import org.gvsig.app.project.documents.view.gui.DefaultViewPanel;
+import org.gvsig.fmap.mapcontext.MapContext;
+import org.gvsig.fmap.mapcontext.ViewPort;
+
+
+
+/**
+ * Extensi�n que cambia el extent de la vista al extent anterior.
+ *
+ * @author Vicente Caballero Navarro
+ */
+public class ZoomPrev extends Extension {
+	private DefaultViewPanel vista;
+	/**
+	 * @see com.iver.mdiApp.plugins.IExtension#isEnabled()
+	 */
+	public boolean isEnabled() {
+		ViewPort vp = vista.getModel().getMapContext().getViewPort();
+
+		return vp.getExtents().hasPrevious();
+	}
+
+	/**
+	 * @see com.iver.mdiApp.plugins.IExtension#isVisible()
+	 */
+	public boolean isVisible() {
+		org.gvsig.andami.ui.mdiManager.IWindow f = PluginServices.getMDIManager()
+															 .getActiveWindow();
+
+		if (f!=null && f instanceof DefaultViewPanel) {
+			vista = (DefaultViewPanel) f;
+
+			MapContext mapa = vista.getModel().getMapContext();
+
+			return mapa.getLayers().getLayersCount() > 0;
+		}
+		return false;
+	}
+
+	/**
+	 * @see com.iver.mdiApp.plugins.IExtension#updateUI(java.lang.String)
+	 */
+	public void execute(String arg0) {
+		ViewPort vp = vista.getModel().getMapContext().getViewPort();
+		vp.setPreviousExtent();
+		((AbstractDocument)vista.getModel()).setModified(true);
+	}
+
+	/**
+	 * @see org.gvsig.andami.plugins.IExtension#initialize()
+	 */
+	public void postInitialize() {
+	}
+	
+	public void initialize() {
+		IconThemeHelper.registerIcon("action", "view-navigation-zoom-back", this);
+	}
+}

Property changes on: tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/app/extension/ZoomPrev.java
___________________________________________________________________
Added: svn:keywords
   + Author Date Id Revision
Added: svn:eol-style
   + native

Index: tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/app/extension/InitializeApplicationExtension.java
===================================================================
--- tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/app/extension/InitializeApplicationExtension.java	(revision 0)
+++ tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/app/extension/InitializeApplicationExtension.java	(revision 38653)
@@ -0,0 +1,197 @@
+package org.gvsig.app.extension;
+
+import java.io.BufferedReader;
+import java.io.InputStream;
+import java.io.InputStreamReader;
+import java.io.StringWriter;
+import java.util.Properties;
+
+import org.gvsig.andami.IconThemeHelper;
+import org.gvsig.andami.PluginsLocator;
+import org.gvsig.andami.PluginsManager;
+import org.gvsig.andami.plugins.Extension;
+import org.gvsig.app.ApplicationLocator;
+import org.gvsig.app.ApplicationManager;
+import org.gvsig.app.gui.preferencespage.AppSymbolPreferences;
+import org.gvsig.app.project.documents.view.toolListeners.InfoListener;
+import org.gvsig.app.tools.swing.serv.field.crs.JCRSDynFieldComponentFactory;
+import org.gvsig.app.util.BaseOpenErrorHandler;
+import org.gvsig.fmap.dal.DALLocator;
+import org.gvsig.fmap.dal.OpenErrorHandler;
+import org.gvsig.fmap.dal.resource.ResourceManager;
+import org.gvsig.fmap.dal.resource.exception.DisposeResorceManagerException;
+import org.gvsig.fmap.mapcontext.MapContextLocator;
+import org.gvsig.installer.lib.api.InstallerLocator;
+import org.gvsig.installer.lib.api.InstallerManager;
+import org.gvsig.installer.lib.api.PackageInfo;
+import org.gvsig.tools.evaluator.sqljep.SQLJEPEvaluator;
+import org.gvsig.tools.service.spi.ServiceManager;
+import org.gvsig.tools.swing.spi.ToolsSwingServiceLocator;
+import org.slf4j.Logger;
+import org.slf4j.LoggerFactory;
+
+public class InitializeApplicationExtension extends Extension {
+    private static final Logger logger = LoggerFactory
+            .getLogger(InitializeApplicationExtension.class);
+//	private Observer dbPasswordResorceObserver;
+
+    private OpenErrorHandler openErrorHandler = null;
+
+	public void initialize() {
+
+		// Register default expression parser
+		DALLocator.getDataManager().registerDefaultEvaluator(
+				SQLJEPEvaluator.class);
+
+		InfoListener.initializeExtensionPoint();
+		// addToLogInfo();
+		registerIcons();
+	}
+	
+	public void postInitialize(){
+	    // Validate there is any implementation registered.
+        ServiceManager dsManager = ToolsSwingServiceLocator.getServiceManager();
+
+        openErrorHandler = new BaseOpenErrorHandler();
+        ApplicationLocator.getManager().getDataManager().setOpenErrorHandler(openErrorHandler);
+        
+        //CRS Definition
+        dsManager.addServiceFactory(new JCRSDynFieldComponentFactory());
+  
+//		registerObservers();
+		
+		DALLocator.getResourceManager().startResourceCollector(
+				3 * (60 * 1000), // minutes --> miliseconds
+				null);
+		
+		MapContextLocator.getSymbolManager().setSymbolPreferences(new AppSymbolPreferences());
+
+	}
+	
+//	private void registerObservers() {
+////		FIXME
+////		ResourceManager resMan = DALLocator.getResourceManager();//.getResource(PostgresqlStore.DATASTORE_NAME);
+////		dbPasswordResorceObserver = new DBResourceManager();
+////		resMan.addObserver(dbPasswordResorceObserver);
+//	}
+
+	private void registerIcons(){
+		IconThemeHelper.registerIcon("action", "edit-clear", this);
+		IconThemeHelper.registerIcon("action", "edit-copy", this);
+		IconThemeHelper.registerIcon("action", "edit-cut", this);
+		IconThemeHelper.registerIcon("action", "edit-delete", this);
+		IconThemeHelper.registerIcon("action", "edit-find", this);
+		IconThemeHelper.registerIcon("action", "edit-find-replace", this);
+		IconThemeHelper.registerIcon("action", "edit-paste", this);
+		IconThemeHelper.registerIcon("action", "edit-redo", this);
+		IconThemeHelper.registerIcon("action", "edit-select-all", this);
+		IconThemeHelper.registerIcon("action", "edit-undo", this);
+		IconThemeHelper.registerIcon("action", "edit-undo-redo-actions", this);
+    	IconThemeHelper.registerIcon("action", "document-print", this);
+		
+    	IconThemeHelper.registerIcon("toolbar-go", "go-next", this);
+    	IconThemeHelper.registerIcon("toolbar-go", "go-previous", this);
+    	IconThemeHelper.registerIcon("toolbar-go", "go-next-fast", this);
+    	IconThemeHelper.registerIcon("toolbar-go", "go-previous-fast", this);
+    	IconThemeHelper.registerIcon("toolbar-go", "go-first", this);
+    	IconThemeHelper.registerIcon("toolbar-go", "go-last", this);
+
+	}
+
+	public void execute(String actionCommand) {
+
+	}
+
+	public boolean isEnabled() {
+		return false;
+	}
+
+	public boolean isVisible() {
+		return false;
+	}
+
+	private void addToLogInfo() {
+		String info[] = this.getStringInfo().split("\n");
+		for (int i=0;i< info.length;i++) {
+			logger.info(info[i]);
+		}
+	}
+
+	public String getStringInfo() {
+		ApplicationManager application = ApplicationLocator.getManager();
+		PluginsManager pluginmgr = PluginsLocator.getManager();
+		InstallerManager installmgr = InstallerLocator.getInstallerManager();
+
+		StringWriter writer = new StringWriter();
+
+		Properties props = System.getProperties();
+
+		// OS information
+		String osName = props.getProperty("os.name");
+		writer.write("OS\n");
+		writer.write("    name   : " + osName + "\n");
+		writer.write("    arch   : " + props.get("os.arch") + "\n");
+		writer.write("    version: " + props.get("os.version") + "\n");
+		if (osName.startsWith("Linux")) {
+			try {
+				String[] command = {"lsb_release", "-a"};
+				Process p = Runtime.getRuntime().exec(command);
+				InputStream is = p.getInputStream();
+				BufferedReader reader = new BufferedReader(new InputStreamReader(is));
+				String line;
+				while ( (line = reader.readLine()) != null) {
+					writer.write("    "+line+"\n");
+				}
+			} catch (Exception ex) {
+				writer.write("Can't get detailled os information (lsb_release -a).");
+			}
+		}
+
+		// JRE information
+		writer.write("JRE\n");
+		writer.write("    vendor : " + props.get("java.vendor") + "\n");
+		writer.write("    version: " +props.get("java.version")+ "\n");
+		writer.write("    home   : " + props.get("java.home") + "\n");
+		
+
+		writer.write("gvSIG\n");
+		writer.write("    version                 : " + application.getVersion().getLongFormat() + "\n");
+		writer.write("    locale language         : " + application.getLocaleLanguage()+ "\n");
+		writer.write("    application forlder     : " + pluginmgr.getApplicationFolder()+ "\n");
+		writer.write("    install forlder         : " + pluginmgr.getInstallFolder()+ "\n");
+		writer.write("    application home forlder: " + pluginmgr.getApplicationHomeFolder()+ "\n");
+		writer.write("    plugins forlder         : " + pluginmgr.getPluginsFolder()+ "\n");
+		
+		try {
+			PackageInfo[] pkgs = installmgr.getInstalledPackages(pluginmgr.getPluginsFolder());
+			writer.write("Installed packages\n");
+			for( int i=0; i<pkgs.length; i++) {
+				writer.write("    ");
+				writer.write(pkgs[i].toStringCompact());
+				writer.write("\n");
+			}
+		} catch(Throwable e) {
+			writer.write("Can't get installed package information.");
+		}
+		return writer.toString();
+	}
+
+	public void terminate() {
+		// XXX: Need a TerminateApplicationExtension ???
+		ResourceManager resMan = DALLocator.getResourceManager();
+		resMan.stopResourceCollector();
+		try {
+			resMan.dispose();
+		} catch (DisposeResorceManagerException e) {
+			logger.error("Exceptions at dispose Resource Manager", e);
+		}
+
+		super.terminate();
+//		try {
+//			LayerFactory.getDataSourceFactory().finalizeThis();
+//		} catch (Exception e) {
+//			//e.printStackTrace();
+//		}
+
+	}
+}

Property changes on: tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/app/extension/InitializeApplicationExtension.java
___________________________________________________________________
Added: svn:keywords
   + Author Date Id Revision
Added: svn:eol-style
   + native

Index: tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/app/extension/BasicSymbologyExtension.java
===================================================================
--- tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/app/extension/BasicSymbologyExtension.java	(revision 0)
+++ tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/app/extension/BasicSymbologyExtension.java	(revision 38653)
@@ -0,0 +1,232 @@
+/* gvSIG. Sistema de Informaci�n Geogr�fica de la Generalitat Valenciana
+ *
+ * Copyright (C) 2005 IVER T.I. and Generalitat Valenciana.
+ *
+ * This program is free software; you can redistribute it and/or
+ * modify it under the terms of the GNU General Public License
+ * as published by the Free Software Foundation; either version 2
+ * of the License, or (at your option) any later version.
+ *
+ * This program is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
+ * GNU General Public License for more details.
+ *
+ * You should have received a copy of the GNU General Public License
+ * along with this program; if not, write to the Free Software
+ * Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA  02111-1307,USA.
+ *
+ * For more information, contact:
+ *
+ *  Generalitat Valenciana
+ *   Conselleria d'Infraestructures i Transport
+ *   Av. Blasco Ib��ez, 50
+ *   46010 VALENCIA
+ *   SPAIN
+ *
+ *      +34 963862235
+ *   gvsig@gva.es
+ *      www.gvsig.gva.es
+ *
+ *    or
+ *
+ *   IVER T.I. S.A
+ *   Salamanca 50
+ *   46005 Valencia
+ *   Spain
+ *
+ *   +34 963163400
+ *   dac@iver.es
+ */
+
+/* CVS MESSAGES:
+*
+* $Id: AdvancedSymbologyExtension.java 16205 2007-11-08 16:33:35Z jdominguez $
+* $Log: AdvancedSymbologyExtension.java,v $
+* Revision 1.12  2007/09/19 15:34:59  jaume
+* removed unnecessary imports
+*
+* Revision 1.11  2007/09/17 09:11:28  jaume
+* order of the elements inverted
+*
+* Revision 1.10  2007/09/13 11:37:09  jvidal
+* *** empty log message ***
+*
+* Revision 1.9  2007/09/04 10:53:10  caballero
+* show page
+*
+* Revision 1.8  2007/08/09 10:39:04  jaume
+* first round of found bugs fixed
+*
+* Revision 1.7  2007/08/01 13:03:31  jaume
+* plugable symbol editor
+*
+* Revision 1.6  2007/05/22 12:17:12  jaume
+* *** empty log message ***
+*
+* Revision 1.5  2007/05/17 09:32:37  jaume
+* *** empty log message ***
+*
+* Revision 1.4  2007/03/21 08:03:03  jaume
+* refactored to use ISymbol instead of FSymbol
+*
+* Revision 1.3  2007/03/13 16:57:35  jaume
+* Added MultiVariable legend
+*
+* Revision 1.2  2007/03/09 11:25:00  jaume
+* Advanced symbology (start committing)
+*
+* Revision 1.1.2.4  2007/02/21 07:35:14  jaume
+* *** empty log message ***
+*
+* Revision 1.1.2.3  2007/02/12 15:14:41  jaume
+* refactored interval legend and added graduated symbol legend
+*
+* Revision 1.1.2.2  2007/02/01 17:47:12  jaume
+* *** empty log message ***
+*
+* Revision 1.1.2.1  2007/02/01 12:12:41  jaume
+* theme manager window and all its components are now dynamic
+*
+*/
+package org.gvsig.app.extension;
+
+import org.gvsig.andami.PluginServices;
+import org.gvsig.andami.plugins.Extension;
+import org.gvsig.andami.preferences.IPreference;
+import org.gvsig.andami.preferences.IPreferenceExtension;
+import org.gvsig.app.ApplicationLocator;
+import org.gvsig.app.gui.preferencespage.CartographicSupportPage;
+import org.gvsig.app.gui.preferencespage.SymbologyPage;
+import org.gvsig.app.gui.styling.MarkerFill;
+import org.gvsig.app.gui.styling.PictureFill;
+import org.gvsig.app.gui.styling.PictureLine;
+import org.gvsig.app.gui.styling.PictureMarker;
+import org.gvsig.app.gui.styling.SimpleFill;
+import org.gvsig.app.gui.styling.SimpleLine;
+import org.gvsig.app.gui.styling.SimpleMarker;
+import org.gvsig.app.gui.styling.SimpleText;
+import org.gvsig.app.gui.styling.SymbolEditor;
+import org.gvsig.app.project.documents.view.legend.gui.AttrInTableLabeling;
+import org.gvsig.app.project.documents.view.legend.gui.Categories;
+import org.gvsig.app.project.documents.view.legend.gui.Features;
+import org.gvsig.app.project.documents.view.legend.gui.General;
+import org.gvsig.app.project.documents.view.legend.gui.LabelingManager;
+import org.gvsig.app.project.documents.view.legend.gui.LegendManager;
+import org.gvsig.app.project.documents.view.legend.gui.MultipleAttributes;
+import org.gvsig.app.project.documents.view.legend.gui.Quantities;
+import org.gvsig.app.project.documents.view.legend.gui.SingleSymbol;
+import org.gvsig.app.project.documents.view.legend.gui.ThemeManagerWindow;
+import org.gvsig.app.project.documents.view.legend.gui.VectorialInterval;
+import org.gvsig.app.project.documents.view.legend.gui.VectorialUniqueValue;
+import org.gvsig.fmap.geom.Geometry;
+import org.gvsig.fmap.mapcontext.layers.vectorial.FLyrVect;
+import org.gvsig.symbology.swing.SymbologySwingLocator;
+
+/**
+ * Extension for enable the symbology. It only installs the core symbology.
+ * @author jaume dominguez faus - jaume.dominguez@iver.es
+ *
+ */
+public class BasicSymbologyExtension extends Extension implements IPreferenceExtension{
+//	private SymbologyLibrary simbologyLibrary;	
+//	private SymbologyDefaultImplLibrary simbologyDefaultImplLibrary;
+
+	public void initialize() {
+		// modules for symbol editor
+		SymbolEditor.addSymbolEditorPanel(SimpleFill.class, Geometry.TYPES.SURFACE);
+		SymbolEditor.addSymbolEditorPanel(SimpleMarker.class, Geometry.TYPES.POINT);
+		SymbolEditor.addSymbolEditorPanel(SimpleLine.class, Geometry.TYPES.CURVE);
+		SymbolEditor.addSymbolEditorPanel(SimpleFill.class, Geometry.TYPES.MULTISURFACE);
+		SymbolEditor.addSymbolEditorPanel(SimpleMarker.class, Geometry.TYPES.MULTIPOINT);
+		SymbolEditor.addSymbolEditorPanel(SimpleLine.class, Geometry.TYPES.MULTICURVE);
+		
+		//FIXME 
+		SymbolEditor.addSymbolEditorPanel(PictureMarker.class, Geometry.TYPES.POINT);
+		SymbolEditor.addSymbolEditorPanel(PictureLine.class, Geometry.TYPES.CURVE);
+		SymbolEditor.addSymbolEditorPanel(PictureFill.class, Geometry.TYPES.SURFACE);
+		SymbolEditor.addSymbolEditorPanel(MarkerFill.class, Geometry.TYPES.SURFACE);
+
+		SymbolEditor.addSymbolEditorPanel(PictureMarker.class, Geometry.TYPES.MULTIPOINT);
+		SymbolEditor.addSymbolEditorPanel(PictureLine.class, Geometry.TYPES.MULTICURVE);
+		SymbolEditor.addSymbolEditorPanel(PictureFill.class, Geometry.TYPES.MULTISURFACE);
+		SymbolEditor.addSymbolEditorPanel(MarkerFill.class, Geometry.TYPES.MULTISURFACE);
+
+		// pages
+		ThemeManagerWindow.addPage(General.class);
+		ThemeManagerWindow.addPage(LegendManager.class);
+		ThemeManagerWindow.addPage(LabelingManager.class);
+
+		ThemeManagerWindow.setTabEnabledForLayer(General.class, FLyrVect.class, true);
+		ThemeManagerWindow.setTabEnabledForLayer(LegendManager.class, FLyrVect.class, true);
+		ThemeManagerWindow.setTabEnabledForLayer(LabelingManager.class, FLyrVect.class, true);
+		// labeling strategies (inverse order to the wanted to be shown)
+		LabelingManager.addLabelingStrategy(AttrInTableLabeling.class);
+
+		// legends available in the legend page
+		LegendManager.addLegendPage(Quantities.class);
+		LegendManager.addLegendPage(Features.class);
+		LegendManager.addLegendPage(Categories.class);
+		LegendManager.addLegendPage(MultipleAttributes.class);
+
+		LegendManager.addLegendPage(SingleSymbol.class);
+		LegendManager.addLegendPage(VectorialInterval.class);
+		LegendManager.addLegendPage(VectorialUniqueValue.class);
+
+//		LegendManager.addLegendDriver(FMapGVLDriver.class);
+		registerIcons();
+	}
+	
+	@Override
+	public void postInitialize() {
+		super.postInitialize();
+		
+		SymbologySwingLocator.getSwingManager().setColorTablesFactory(
+				ApplicationLocator.getManager().getColorTablesFactory());
+	}
+
+	private void registerIcons(){
+//		PluginServices.getIconTheme().registerDefault(
+//				"chain",
+//				this.getClass().getClassLoader().getResource("images/chain.png")
+//			);
+//		PluginServices.getIconTheme().registerDefault(
+//				"broken-chain",
+//				this.getClass().getClassLoader().getResource("images/broken-chain.png")
+//			);
+//		PluginServices.getIconTheme().registerDefault(
+//				"underline-icon",
+//				this.getClass().getClassLoader().getResource("images/underlined.png")
+//			);
+//		PluginServices.getIconTheme().registerDefault(
+//				"italic-icon",
+//				this.getClass().getClassLoader().getResource("images/italic.png")
+//			);
+//		PluginServices.getIconTheme().registerDefault(
+//				"bold-icon",
+//				this.getClass().getClassLoader().getResource("images/bold.png")
+//			);
+//		PluginServices.getIconTheme().registerDefault(
+//				"symbol-pref",
+//				this.getClass().getClassLoader().getResource("images/QuantitiesByCategory.png"));
+
+	}
+
+	public void execute(String actionCommand) {
+
+	}
+
+	public boolean isEnabled() {
+		return true; // or whatever
+	}
+
+	public boolean isVisible() {
+		return true; // or whatever
+	}
+
+	public IPreference[] getPreferencesPages() {
+		return new IPreference[] {
+			new CartographicSupportPage(), new SymbologyPage()
+		};
+	}
+}
\ No newline at end of file
Index: tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/app/extension/ZoomToSelectExtension.java
===================================================================
--- tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/app/extension/ZoomToSelectExtension.java	(revision 0)
+++ tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/app/extension/ZoomToSelectExtension.java	(revision 38653)
@@ -0,0 +1,143 @@
+/*
+ * Created on 31-may-2004
+ *
+ * To change the template for this generated file go to
+ * Window&gt;Preferences&gt;Java&gt;Code Generation&gt;Code and Comments
+ */
+/* gvSIG. Sistema de Informaci�n Geogr�fica de la Generalitat Valenciana
+ *
+ * Copyright (C) 2004 IVER T.I. and Generalitat Valenciana.
+ *
+ * This program is free software; you can redistribute it and/or
+ * modify it under the terms of the GNU General Public License
+ * as published by the Free Software Foundation; either version 2
+ * of the License, or (at your option) any later version.
+ *
+ * This program is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
+ * GNU General Public License for more details.
+ *
+ * You should have received a copy of the GNU General Public License
+ * along with this program; if not, write to the Free Software
+ * Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA  02111-1307,USA.
+ *
+ * For more information, contact:
+ *
+ *  Generalitat Valenciana
+ *   Conselleria d'Infraestructures i Transport
+ *   Av. Blasco Ib��ez, 50
+ *   46010 VALENCIA
+ *   SPAIN
+ *
+ *      +34 963862235
+ *   gvsig@gva.es
+ *      www.gvsig.gva.es
+ *
+ *    or
+ *
+ *   IVER T.I. S.A
+ *   Salamanca 50
+ *   46005 Valencia
+ *   Spain
+ *
+ *   +34 963163400
+ *   dac@iver.es
+ */
+package org.gvsig.app.extension;
+
+import org.gvsig.andami.IconThemeHelper;
+import org.gvsig.andami.PluginServices;
+import org.gvsig.andami.messages.NotificationManager;
+import org.gvsig.andami.plugins.Extension;
+import org.gvsig.app.project.documents.view.gui.DefaultViewPanel;
+import org.gvsig.fmap.dal.exception.DataException;
+import org.gvsig.fmap.geom.primitive.Envelope;
+import org.gvsig.fmap.mapcontext.MapContext;
+import org.gvsig.fmap.mapcontext.layers.FLayer;
+import org.gvsig.fmap.mapcontext.layers.vectorial.FLyrVect;
+import org.gvsig.tools.exception.BaseException;
+
+
+
+/**
+ * Extensi�n de zoom a lo seleccionado teniendo como ventana activa una vista.
+ * 
+ * @author Vicente Caballero Navarro
+ */
+public class ZoomToSelectExtension extends Extension {
+	/**
+	 * @see com.iver.mdiApp.plugins.IExtension#updateUI(java.lang.String)
+	 */
+	public void execute(String s) {
+		org.gvsig.andami.ui.mdiManager.IWindow f = PluginServices.getMDIManager()
+		 	.getActiveWindow();
+		MapContext mapa = null;
+		Envelope selectedExtent = null;
+		if (f instanceof DefaultViewPanel) {
+			DefaultViewPanel vista = (DefaultViewPanel)f;
+			mapa = vista.getModel().getMapContext();
+		}
+		try {
+			selectedExtent = mapa.getSelectionBounds();
+			mapa.getViewPort().setEnvelope(selectedExtent);
+		} catch (BaseException e) {
+			NotificationManager.addError(e);
+		}
+
+		//if (selectedExtent != null) {
+			//Envelope env=new DefaultEnvelope(2,new double[]{selectedExtent.getX(),selectedExtent.getY()},new double[]{selectedExtent.getMaxX(),selectedExtent.getMaxY()});
+			//((ProjectDocument) vista.getModel()).setModified(true);
+
+		//}
+
+	}
+
+	/**
+	 * @see com.iver.mdiApp.plugins.IExtension#isVisible()
+	 */
+	public boolean isVisible() {
+		org.gvsig.andami.ui.mdiManager.IWindow window = PluginServices.getMDIManager().getActiveWindow();
+		if (window != null && window instanceof DefaultViewPanel) {
+			MapContext mapa = ((DefaultViewPanel) window).getModel().getMapContext();
+			return mapa.getLayers().getLayersCount() > 0;
+		}
+		return false;
+	}
+
+	/**
+	 * @see org.gvsig.andami.plugins.IExtension#isEnabled()
+	 */
+	public boolean isEnabled() {
+		org.gvsig.andami.ui.mdiManager.IWindow f = PluginServices.getMDIManager()
+		 	.getActiveWindow();
+		if (f == null) {
+			return false;
+		}
+		if (f instanceof DefaultViewPanel) {
+			DefaultViewPanel view = (DefaultViewPanel) f;
+			FLayer[] selected = view.getModel().getMapContext().getLayers().getActives();
+			if (selected.length == 1 && selected[0] instanceof FLyrVect && selected[0].isAvailable()){
+				try {
+					if (!((FLyrVect) selected[0]).getFeatureStore()
+							.getFeatureSelection().isEmpty()) {
+						return true;
+					}
+				} catch (DataException e) {
+					NotificationManager.addError(e);
+					return false;
+				}
+			}
+        }
+
+
+		return false;
+	}
+
+	/**
+	 * @see org.gvsig.andami.plugins.IExtension#initialize()
+	 */
+	public void initialize() {
+	   	IconThemeHelper.registerIcon("action", "view-navigation-zoom-to-selection", this);
+	}
+}

Property changes on: tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/app/extension/ZoomToSelectExtension.java
___________________________________________________________________
Added: svn:keywords
   + Author Date Id Revision
Added: svn:eol-style
   + native

Index: tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/app/extension/ViewPropertiesExtension.java
===================================================================
--- tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/app/extension/ViewPropertiesExtension.java	(revision 0)
+++ tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/app/extension/ViewPropertiesExtension.java	(revision 38653)
@@ -0,0 +1,139 @@
+/* gvSIG. Sistema de Informaci�n Geogr�fica de la Generalitat Valenciana
+ *
+ * Copyright (C) 2004 IVER T.I. and Generalitat Valenciana.
+ *
+ * This program is free software; you can redistribute it and/or
+ * modify it under the terms of the GNU General Public License
+ * as published by the Free Software Foundation; either version 2
+ * of the License, or (at your option) any later version.
+ *
+ * This program is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
+ * GNU General Public License for more details.
+ *
+ * You should have received a copy of the GNU General Public License
+ * along with this program; if not, write to the Free Software
+ * Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA  02111-1307,USA.
+ *
+ * For more information, contact:
+ *
+ *  Generalitat Valenciana
+ *   Conselleria d'Infraestructures i Transport
+ *   Av. Blasco Ib��ez, 50
+ *   46010 VALENCIA
+ *   SPAIN
+ *
+ *      +34 963862235
+ *   gvsig@gva.es
+ *      www.gvsig.gva.es
+ *
+ *    or
+ *
+ *   IVER T.I. S.A
+ *   Salamanca 50
+ *   46005 Valencia
+ *   Spain
+ *
+ *   +34 963163400
+ *   dac@iver.es
+ */
+/* gvSIG. Sistema de Informaci�n Geogr�fica de la Generalitat Valenciana
+ *
+ * Copyright (C) 2004 IVER T.I. and Generalitat Valenciana.
+ *
+ * This program is free software; you can redistribute it and/or
+ * modify it under the terms of the GNU General Public License
+ * as published by the Free Software Foundation; either version 2
+ * of the License, or (at your option) any later version.
+ *
+ * This program is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
+ * GNU General Public License for more details.
+ *
+ * You should have received a copy of the GNU General Public License
+ * along with this program; if not, write to the Free Software
+ * Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA  02111-1307,USA.
+ *
+ * For more information, contact:
+ *
+ *  Generalitat Valenciana
+ *   Conselleria d'Infraestructures i Transport
+ *   Av. Blasco Ib��ez, 50
+ *   46010 VALENCIA
+ *   SPAIN
+ *
+ *      +34 963862235
+ *   gvsig@gva.es
+ *      www.gvsig.gva.es
+ *
+ *    or
+ *
+ *   IVER T.I. S.A
+ *   Salamanca 50
+ *   46005 Valencia
+ *   Spain
+ *
+ *   +34 963163400
+ *   dac@iver.es
+ */
+package org.gvsig.app.extension;
+
+import org.gvsig.andami.PluginServices;
+import org.gvsig.andami.plugins.Extension;
+import org.gvsig.andami.preferences.IPreference;
+import org.gvsig.andami.preferences.IPreferenceExtension;
+import org.gvsig.app.gui.preferencespage.ViewBehaviorPage;
+import org.gvsig.app.project.documents.view.ViewDocument;
+import org.gvsig.app.project.documents.view.DefaultViewDocument;
+import org.gvsig.app.project.documents.view.gui.DefaultViewPanel;
+import org.gvsig.app.project.documents.view.gui.ViewProperties;
+
+
+
+/**
+ * DOCUMENT ME!
+ *
+ * @author Vicente Caballero Navarro
+ */
+public class ViewPropertiesExtension extends Extension implements IPreferenceExtension {
+	private ViewBehaviorPage vb = new ViewBehaviorPage();
+    public void initialize() {
+    }
+
+    public void execute(String s) {
+        DefaultViewPanel vista = (DefaultViewPanel) PluginServices.getMDIManager().getActiveWindow();
+        ViewDocument model = vista.getModel();
+
+        if (s.equalsIgnoreCase("view-properties") ) {
+        	DefaultViewDocument viewModel = (DefaultViewDocument)model;
+        	if (viewModel != null) {
+              ViewProperties viewProperties = new ViewProperties(viewModel);
+              PluginServices.getMDIManager().addWindow(viewProperties);
+              if (viewProperties.isAcceppted()) {
+            	  viewModel.setModified(true);
+              }
+        	}
+        }
+    }
+
+     public boolean isEnabled() {
+        return true;
+    }
+
+    /**
+     * DOCUMENT ME!
+     *
+     * @return DOCUMENT ME!
+     */
+    public boolean isVisible() {
+        org.gvsig.andami.ui.mdiManager.IWindow f = PluginServices.getMDIManager()
+                                                             .getActiveWindow();
+        return (f!=null && f instanceof DefaultViewPanel);
+    }
+
+    public IPreference[] getPreferencesPages() {
+    	return new IPreference[] {vb};
+    }
+}

Property changes on: tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/app/extension/ViewPropertiesExtension.java
___________________________________________________________________
Added: svn:keywords
   + Author Date Id Revision
Added: svn:eol-style
   + native

Index: tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/app/extension/AddLayer.java
===================================================================
--- tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/app/extension/AddLayer.java	(revision 0)
+++ tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/app/extension/AddLayer.java	(revision 38653)
@@ -0,0 +1,258 @@
+/* gvSIG. Sistema de Informaci�n Geogr�fica de la Generalitat Valenciana
+ *
+ * Copyright (C) 2004 IVER T.I. and Generalitat Valenciana.
+ *
+ * This program is free software; you can redistribute it and/or
+ * modify it under the terms of the GNU General Public License
+ * as published by the Free Software Foundation; either version 2
+ * of the License, or (at your option) any later version.
+ *
+ * This program is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
+ * GNU General Public License for more details.
+ *
+ * You should have received a copy of the GNU General Public License
+ * along with this program; if not, write to the Free Software
+ * Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA  02111-1307,USA.
+ */
+package org.gvsig.app.extension;
+
+import java.awt.Component;
+import java.lang.reflect.InvocationTargetException;
+import java.util.ArrayList;
+
+import javax.swing.JOptionPane;
+
+import org.cresques.cts.ICoordTrans;
+import org.cresques.cts.IProjection;
+import org.gvsig.andami.IconThemeHelper;
+import org.gvsig.andami.PluginServices;
+import org.gvsig.andami.plugins.Extension;
+import org.gvsig.app.addlayer.AddLayerDialog;
+import org.gvsig.app.gui.WizardPanel;
+import org.gvsig.app.project.documents.AbstractDocument;
+import org.gvsig.app.project.documents.view.gui.AbstractViewPanel;
+import org.gvsig.app.project.documents.view.gui.IView;
+import org.gvsig.fmap.dal.serverexplorer.filesystem.swing.FilesystemExplorerAddLayerWizardPanel;
+import org.gvsig.fmap.mapcontext.ViewPort;
+import org.gvsig.fmap.mapcontext.layers.FLayer;
+import org.gvsig.fmap.mapcontext.layers.FLayers;
+import org.gvsig.fmap.mapcontext.layers.vectorial.FLyrVect;
+import org.gvsig.fmap.mapcontrol.MapControl;
+
+
+
+/**
+ * Extensi�n que abre un di�logo para seleccionar la capa o capas que se quieren
+ * a�adir a la vista.
+ *
+ * @author Fernando Gonz�lez Cort�s
+ */
+public class AddLayer extends Extension {
+	public AddLayerDialog fopen = null;
+
+	private static ArrayList<Class<? extends WizardPanel>> wizardStack = null;
+
+	static {
+		AddLayer.wizardStack = new ArrayList<Class<? extends WizardPanel>>();
+		// A�adimos el panel al wizard de cargar capa. (Esto es temporal hasta que
+    // el actual sea totalmente extensible)
+		//		AddLayer.addWizard(FileOpenWizard.class);
+		AddLayer.addWizard(FilesystemExplorerAddLayerWizardPanel.class);
+	}
+
+	public static void addWizard(Class<? extends WizardPanel> wpClass) {
+		AddLayer.wizardStack.add(wpClass);
+	}
+
+	private static WizardPanel getInstance(int i, MapControl mapControl)
+			throws IllegalArgumentException, SecurityException,
+			InstantiationException, IllegalAccessException,
+			InvocationTargetException, NoSuchMethodException {
+		Class<? extends WizardPanel> wpClass = AddLayer.wizardStack.get(i);
+		Object[] params = {};
+		WizardPanel wp = wpClass.getConstructor()
+				.newInstance(params);
+		wp.setMapCtrl(mapControl);
+		wp.initWizard();
+
+		return wp;
+	}
+
+	/**
+	 * @see com.iver.mdiApp.plugins.IExtension#isVisible()
+	 */
+	public boolean isVisible() {
+		org.gvsig.andami.ui.mdiManager.IWindow window = PluginServices.getMDIManager()
+															 .getActiveWindow();
+
+		if (window == null) {
+			return false;
+		}
+
+		// Any view derived from BaseView should have AddLayer available
+
+		IView view;
+		try {
+			view = (IView)window;
+		}
+		catch (ClassCastException e) {
+		    return false;
+		}
+
+		if (view == null) {
+			return false;
+		}
+
+		AbstractViewPanel baseView = (AbstractViewPanel)view;
+		return (baseView != null);
+	}
+
+	/**
+	 * @see org.gvsig.andami.plugins.IExtension#postInitialize()
+	 */
+	public void postInitialize() {
+//		LayerFactory.initialize();
+//		DriverManager dm=LayerFactory.getDM();
+//		PluginServices.addLoaders(dm.getDriverClassLoaders());
+//		WriterManager wm=LayerFactory.getWM();
+//		PluginServices.addLoaders(wm.getWriterClassLoaders());
+
+		//		ToolsLocator.getExtensionPointManager().add("FileExtendingOpenDialog",
+		//				"").append("FileOpenVectorial", "", VectorialFileOpen.class);
+	}
+
+	public static void checkProjection(FLayer lyr, ViewPort viewPort) {
+		if (lyr instanceof FLayers){
+			FLayers layers=(FLayers)lyr;
+			for (int i=0;i<layers.getLayersCount();i++){
+				checkProjection(layers.getLayer(i),viewPort);
+			}
+		}
+		if (lyr instanceof FLyrVect) {
+			FLyrVect lyrVect = (FLyrVect) lyr;
+			IProjection proj = lyr.getProjection();
+			// Comprobar que la projecci�n es la misma que la vista
+			if (proj == null) {
+				// SUPONEMOS que la capa est� en la proyecci�n que
+				// estamos pidiendo (que ya es mucho suponer, ya).
+				lyrVect.setProjection(viewPort.getProjection());
+				return;
+			}
+			int option = JOptionPane.YES_OPTION;
+			if (proj != viewPort.getProjection()) {
+				option = JOptionPane.showConfirmDialog((Component)PluginServices.getMainFrame(), PluginServices
+						.getText(AddLayer.class, "reproyectar_aviso")+"\n"+ PluginServices.getText(AddLayer.class,"Capa")+": "+lyrVect.getName(), PluginServices
+						.getText(AddLayer.class, "reproyectar_pregunta"),
+						JOptionPane.YES_NO_OPTION);
+
+				if (option != JOptionPane.OK_OPTION) {
+					return;
+				}
+
+				ICoordTrans ct = proj.getCT(viewPort.getProjection());
+				lyrVect.setCoordTrans(ct);
+				System.err.println("coordTrans = " + proj.getAbrev() + " "
+						+ viewPort.getProjection().getAbrev());
+			}
+		}
+
+	}
+
+	/**
+	 * @see org.gvsig.andami.plugins.IExtension#execute(java.lang.String)
+	 */
+	public void execute(String actionCommand) {
+		// Project project = ((ProjectExtension)
+		// PluginServices.getExtension(ProjectExtension.class)).getProject();
+		AbstractViewPanel theView = (AbstractViewPanel) PluginServices.getMDIManager().getActiveWindow();
+		MapControl mapControl=theView.getMapControl();
+		this.addLayers(mapControl);
+		mapControl.getMapContext().callLegendChanged();
+		((AbstractDocument)theView.getModel()).setModified(true);
+	}
+
+	/**
+	 * @see org.gvsig.andami.plugins.IExtension#isEnabled()
+	 */
+	public boolean isEnabled() {
+		return true;
+	}
+
+	/**
+	 * Creates FOpenDialog, and adds file tab, and additional registered tabs
+	 *
+	 * @return FOpenDialog
+	 */
+    private AddLayerDialog createFOpenDialog(MapControl mapControl) {
+		fopen = new AddLayerDialog();
+
+		// after that, all registerez tabs (wizardpanels implementations)
+		for (int i = 0; i < wizardStack.size(); i++) {
+			WizardPanel wp;
+			try {
+				wp = AddLayer.getInstance(i, mapControl);
+                
+				fopen.addWizardTab(wp.getTabName(), wp);
+			} catch (IllegalArgumentException e) {
+				e.printStackTrace();
+			} catch (SecurityException e) {
+				e.printStackTrace();
+			} catch (InstantiationException e) {
+				e.printStackTrace();
+			} catch (IllegalAccessException e) {
+				e.printStackTrace();
+			} catch (InvocationTargetException e) {
+				e.printStackTrace();
+			} catch (NoSuchMethodException e) {
+				e.printStackTrace();
+			}
+		}// for
+		return fopen;
+	}
+
+	/**
+	 * Adds to mapcontrol all layers selected by user in the specified WizardPanel.
+	 *
+	 * @param mapControl
+	 * 	MapControl on which we want to load user selected layers.
+	 * @param wizardPanel
+	 * 	WizardPanel where user selected the layers to load
+	 * @return
+	 */
+	private boolean loadGenericWizardPanelLayers(MapControl mapControl, WizardPanel wp) {
+		wp.setMapCtrl(mapControl);
+		wp.execute();
+		return true;
+	}
+
+	/**
+	 * Abre dialogo para a�adir capas y las a�ade en mapControl
+	 *
+	 * Devuelve true si se han a�adido capas.
+	 */
+	public boolean addLayers(MapControl mapControl) {
+		// create and show the modal fopen dialog
+        fopen = createFOpenDialog(mapControl);
+		PluginServices.getMDIManager().addWindow(fopen);
+
+		if (fopen.isAccepted()) {
+				if (fopen.getSelectedTab() instanceof WizardPanel) {
+				WizardPanel wp = (WizardPanel) fopen.getSelectedTab();
+				return loadGenericWizardPanelLayers(mapControl, wp);
+			} else {
+				JOptionPane.showMessageDialog((Component) PluginServices
+						.getMainFrame(), PluginServices.getText(this,"ninguna_capa_seleccionada"));
+			}
+		}
+		return false;
+	}
+
+	/* (non-Javadoc)
+	 * @see com.iver.andami.plugins.IExtension#initialize()
+	 */
+	public void initialize() {
+	   	IconThemeHelper.registerIcon("action", "view-layer-add", this);
+	}
+}

Property changes on: tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/app/extension/AddLayer.java
___________________________________________________________________
Added: svn:keywords
   + Author Date Id Revision
Added: svn:eol-style
   + native

Index: tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/app/extension/Version.java
===================================================================
--- tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/app/extension/Version.java	(revision 0)
+++ tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/app/extension/Version.java	(revision 38653)
@@ -0,0 +1,128 @@
+/* gvSIG. Geographic Information System of the Valencian Government
+ *
+ * Copyright (C) 2007-2008 Infrastructures and Transports Department
+ * of the Valencian Government (CIT)
+ *
+ * This program is free software; you can redistribute it and/or
+ * modify it under the terms of the GNU General Public License
+ * as published by the Free Software Foundation; either version 2
+ * of the License, or (at your option) any later version.
+ *
+ * This program is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
+ * GNU General Public License for more details.
+ *
+ * You should have received a copy of the GNU General Public License
+ * along with this program; if not, write to the Free Software
+ * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston,
+ * MA  02110-1301, USA.
+ *
+ */
+package org.gvsig.app.extension;
+
+import java.util.StringTokenizer;
+
+import org.gvsig.app.ApplicationLocator;
+import org.gvsig.installer.lib.api.InstallerLocator;
+import org.gvsig.installer.lib.api.PackageInfo;
+import org.gvsig.installer.lib.api.creation.MakePluginPackageService;
+import org.slf4j.Logger;
+import org.slf4j.LoggerFactory;
+
+/**
+ * gvSIG application version information.
+ * 
+ * @author gvSIG Team
+ * @version $Id$
+ */
+public class Version {
+
+    private static final Logger LOG = LoggerFactory.getLogger(Version.class);
+    private static final String APP_PACKAGE_CODE = "org.gvsig.app";
+
+    private int majorVersionNumber;
+    private int minorVersionNumber;
+    private int releaseNumber;
+
+    private String buildNumber = "unknown";
+
+    @Deprecated
+    public static String format() {
+        return ApplicationLocator.getManager().getVersion().getFormat();
+    }
+
+    @Deprecated
+    public static String longFormat() {
+        return ApplicationLocator.getManager().getVersion().getLongFormat();
+    }
+
+    @Deprecated
+    public static String getBuild() {
+        return ApplicationLocator.getManager().getVersion().getBuildId();
+    }
+
+    /**
+     * Constructor.
+     * Loads version information from the application installation information.
+     */
+    public Version() {
+        String[] versions = new String[] { "2", "0", "0" };
+        try {
+            MakePluginPackageService packageService =
+                InstallerLocator.getInstallerManager()
+                    .getMakePluginPackageService();
+
+            PackageInfo info =
+                packageService.getPluginPackageInfo(APP_PACKAGE_CODE);
+
+            String version = info.getGvSIGVersion();
+
+            StringTokenizer tokens = new StringTokenizer(version, ".");
+            int i = 0;
+            while (tokens.hasMoreTokens() && i < 3) {
+                versions[i] = tokens.nextToken();
+                i++;
+            }
+            this.buildNumber = Integer.toString(info.getBuild());
+
+        } catch (Exception e) {
+            LOG.error("Error getting version information through "
+                + "the InstallManager", e);
+        }
+
+        this.majorVersionNumber = Integer.parseInt(versions[0]);
+        this.minorVersionNumber = Integer.parseInt(versions[1]);
+        this.releaseNumber = Integer.parseInt(versions[2]);
+        
+        LOG.debug("Loaded version information: {}", getLongFormat());
+    }
+
+    public int getMinor() {
+        return minorVersionNumber;
+    }
+
+    public int getMajor() {
+        return majorVersionNumber;
+    }
+
+    public int getRelease() {
+        return releaseNumber;
+    }
+
+    public String getBuildId() {
+        return buildNumber;
+    }
+
+    public String toString() {
+        return getLongFormat();
+    }
+
+    public String getFormat() {
+        return getMajor() + "." + getMinor() + "." + getRelease();
+    }
+
+    public String getLongFormat() {
+        return getFormat() + " (Build " + getBuildId() + ")";
+    }
+}

Property changes on: tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/app/extension/Version.java
___________________________________________________________________
Added: svn:eol-style
   + native
Added: svn:keywords
   + Author Date Id Revision

Index: tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/app/extension/InfoToolExtension.java
===================================================================
--- tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/app/extension/InfoToolExtension.java	(revision 0)
+++ tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/app/extension/InfoToolExtension.java	(revision 38653)
@@ -0,0 +1,124 @@
+/*
+ * Created on 20-feb-2004
+ *
+ * To change the template for this generated file go to
+ * Window&gt;Preferences&gt;Java&gt;Code Generation&gt;Code and Comments
+ */
+/* gvSIG. Sistema de Informaci�n Geogr�fica de la Generalitat Valenciana
+ *
+ * Copyright (C) 2004 IVER T.I. and Generalitat Valenciana.
+ *
+ * This program is free software; you can redistribute it and/or
+ * modify it under the terms of the GNU General Public License
+ * as published by the Free Software Foundation; either version 2
+ * of the License, or (at your option) any later version.
+ *
+ * This program is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
+ * GNU General Public License for more details.
+ *
+ * You should have received a copy of the GNU General Public License
+ * along with this program; if not, write to the Free Software
+ * Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA  02111-1307,USA.
+ *
+ * For more information, contact:
+ *
+ *  Generalitat Valenciana
+ *   Conselleria d'Infraestructures i Transport
+ *   Av. Blasco Ib��ez, 50
+ *   46010 VALENCIA
+ *   SPAIN
+ *
+ *      +34 963862235
+ *   gvsig@gva.es
+ *      www.gvsig.gva.es
+ *
+ *    or
+ *
+ *   IVER T.I. S.A
+ *   Salamanca 50
+ *   46005 Valencia
+ *   Spain
+ *
+ *   +34 963163400
+ *   dac@iver.es
+ */
+package org.gvsig.app.extension;
+
+import org.gvsig.andami.IconThemeHelper;
+import org.gvsig.andami.plugins.Extension;
+import org.gvsig.andami.ui.mdiManager.IWindow;
+import org.gvsig.app.ApplicationLocator;
+import org.gvsig.app.project.documents.view.gui.IView;
+import org.gvsig.fmap.mapcontext.MapContext;
+import org.gvsig.fmap.mapcontext.layers.FLayer;
+import org.gvsig.fmap.mapcontrol.MapControl;
+import org.slf4j.Logger;
+import org.slf4j.LoggerFactory;
+
+
+
+/**
+ * Extension that handles the info by point tool for a selected layer set
+ * @author laura
+ */
+public class InfoToolExtension extends Extension {
+    private static final Logger logger = LoggerFactory
+            .getLogger(InfoToolExtension.class);
+
+    public void initialize() {
+    	IconThemeHelper.registerIcon("action", "layer-info-by-point", this);
+    }
+
+	public void execute(String s) {
+        IWindow window = ApplicationLocator.getManager().getActiveWindow();
+        if( window instanceof IView ) {
+            IView view = (IView) window;
+    		MapControl mapCtrl = view.getMapControl();
+    
+    		if (s.compareTo("layer-info-by-point") == 0) {
+    			mapCtrl.setTool("info");
+    			view.getDocument().setModified(true);
+    		}
+        }
+	}
+
+	public boolean isEnabled() {
+        IWindow window = ApplicationLocator.getManager().getActiveWindow();
+
+        if (window == null) {
+			return false;
+		}
+
+		if (window instanceof IView) {
+			IView view = (IView) window;
+			MapContext mapa = view.getViewDocument().getMapContext();
+
+			FLayer[] layers =mapa.getLayers().getActives();
+			for (int i=0;i<layers.length;i++) {
+				if (layers[i].isAvailable()) {
+				    return true;
+				}
+			}
+		}
+		return false;
+	}
+
+	public boolean isVisible() {
+        IWindow window = ApplicationLocator.getManager().getActiveWindow();
+
+        if (window == null) {
+            return false;
+        }
+
+        if (window instanceof IView) {
+            IView view = (IView) window;
+            MapContext mapa = view.getViewDocument().getMapContext();
+			return mapa.getLayers().getLayersCount() > 0;
+		} else {
+			return false;
+		}
+	}
+}
+

Property changes on: tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/app/extension/InfoToolExtension.java
___________________________________________________________________
Added: svn:keywords
   + Author Date Id Revision
Added: svn:eol-style
   + native

Index: tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/app/extension/dispose/DisposableManagementExtension.java
===================================================================
--- tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/app/extension/dispose/DisposableManagementExtension.java	(revision 0)
+++ tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/app/extension/dispose/DisposableManagementExtension.java	(revision 38653)
@@ -0,0 +1,118 @@
+/* gvSIG. Geographic Information System of the Valencian Government
+ *
+ * Copyright (C) 2007-2008 Infrastructures and Transports Department
+ * of the Valencian Government (CIT)
+ * 
+ * This program is free software; you can redistribute it and/or
+ * modify it under the terms of the GNU General Public License
+ * as published by the Free Software Foundation; either version 2
+ * of the License, or (at your option) any later version.
+ * 
+ * This program is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
+ * GNU General Public License for more details.
+ * 
+ * You should have received a copy of the GNU General Public License
+ * along with this program; if not, write to the Free Software
+ * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, 
+ * MA  02110-1301, USA.
+ * 
+ */
+
+/*
+ * AUTHORS (In addition to CIT):
+ * 2009 {}  {{Task}}
+ */
+package org.gvsig.app.extension.dispose;
+
+import java.util.Iterator;
+import java.util.Set;
+
+import javax.swing.JOptionPane;
+
+import org.gvsig.andami.plugins.Extension;
+import org.gvsig.tools.ToolsLocator;
+import org.gvsig.tools.dispose.Disposable;
+import org.gvsig.tools.dispose.DisposableInfo;
+import org.gvsig.tools.dispose.DisposableManager;
+import org.gvsig.tools.exception.BaseException;
+import org.slf4j.Logger;
+import org.slf4j.LoggerFactory;
+
+/**
+ * An extension to view and manage {@link Disposable} objects which are still
+ * bound.
+ * 
+ * TODO: remove this extension and replace with a better one, maybe based on
+ * scripting.
+ * 
+ * @author 2009- <a href="cordinyana@gvsig.org">C�sar Ordi�ana</a> - gvSIG team
+ */
+public class DisposableManagementExtension extends Extension {
+
+	public static String SHOW_COMMAND = "show";
+	public static String DISPOSE_ALL_COMMAND = "releaseAll";
+
+	private static final Logger LOG =
+			LoggerFactory.getLogger(DisposableManagementExtension.class);
+
+	private DisposableManager manager;
+
+	public void initialize() {
+		// Nothing to do
+	}
+
+	@Override
+	public void postInitialize() {
+		super.postInitialize();
+		manager = ToolsLocator.getDisposableManager();
+	}
+
+	public void execute(String actionCommand) {
+		if (DISPOSE_ALL_COMMAND.equals(actionCommand)) {
+			disposeAll();
+		} else {
+			showDisposables();
+		}
+	}
+
+	@SuppressWarnings("unchecked")
+	private void showDisposables() {
+		Set<DisposableInfo> disposables =
+				(Set<DisposableInfo>) manager.getBoundDisposables();
+
+		String message;
+		if (disposables.size() < 1) {
+			message = "There aren't any bound Disposables actually";
+		} else {
+			LOG.info("Disposable infos with stack trace:");
+			StringBuffer buffer = new StringBuffer();
+			int i = 1;
+			for (Iterator<DisposableInfo> iterator = disposables.iterator(); iterator.hasNext();) {
+				DisposableInfo disposableInfo = iterator.next();
+				buffer.append(i++).append(": ").append(
+						disposableInfo.getDisposable()).append('\n');
+				LOG.info("\n" + disposableInfo.toString());
+			}
+			message = buffer.toString();
+		}
+		JOptionPane.showMessageDialog(null, message);
+	}
+
+	private void disposeAll() {
+		try {
+			manager.releaseAll();
+		} catch (BaseException ex) {
+			LOG.error("Error disposing all bound disposable objects", ex);
+		}
+	}
+
+	public boolean isEnabled() {
+		return true;
+	}
+
+	public boolean isVisible() {
+		return true;
+	}
+}
\ No newline at end of file
Index: tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/app/extension/RestoreViewInfoExtension.java
===================================================================
--- tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/app/extension/RestoreViewInfoExtension.java	(revision 0)
+++ tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/app/extension/RestoreViewInfoExtension.java	(revision 38653)
@@ -0,0 +1,98 @@
+/* gvSIG. Sistema de Informaci�n Geogr�fica de la Generalitat Valenciana
+*
+* Copyright (C) 2004 IVER T.I. and Generalitat Valenciana.
+*
+* This program is free software; you can redistribute it and/or
+* modify it under the terms of the GNU General Public License
+* as published by the Free Software Foundation; either version 2
+* of the License, or (at your option) any later version.
+*
+* This program is distributed in the hope that it will be useful,
+* but WITHOUT ANY WARRANTY; without even the implied warranty of
+* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
+* GNU General Public License for more details.
+*
+* You should have received a copy of the GNU General Public License
+* along with this program; if not, write to the Free Software
+* Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA  02111-1307,USA.
+*
+* For more information, contact:
+*
+*  Generalitat Valenciana
+*   Conselleria d'Infraestructures i Transport
+*   Av. Blasco Ib��ez, 50
+*   46010 VALENCIA
+*   SPAIN
+*
+*      +34 963862235
+*   gvsig@gva.es
+*      www.gvsig.gva.es
+*
+*    or
+*
+*   IVER T.I. S.A
+*   Salamanca 50
+*   46005 Valencia
+*   Spain
+*
+*   +34 963163400
+*   dac@iver.es
+*/
+package org.gvsig.app.extension;
+
+
+import org.gvsig.andami.PluginServices;
+import org.gvsig.andami.plugins.Extension;
+import org.gvsig.andami.ui.mdiManager.IWindow;
+import org.gvsig.andami.ui.mdiManager.IWindowTransform;
+import org.slf4j.Logger;
+import org.slf4j.LoggerFactory;
+
+
+
+public class RestoreViewInfoExtension extends Extension{
+    private static final Logger logger = LoggerFactory
+            .getLogger(RestoreViewInfoExtension.class);
+    
+	/**
+	 * @see org.gvsig.andami.plugins.IExtension#initialize()
+	 */
+	public void initialize() {
+	}
+
+	/**
+	 * @see org.gvsig.andami.plugins.IExtension#execute(java.lang.String)
+	 */
+	public void execute(String s) {
+		IWindow view = PluginServices.getMDIManager().getFocusWindow();
+        if (s.equalsIgnoreCase("window-restore-from-tool")){
+        	IWindowTransform vt=(IWindowTransform)view;
+        	vt.restore();
+        }
+        PluginServices.getMainFrame().enableControls();
+	}
+
+	/**
+	 * @see org.gvsig.andami.plugins.IExtension#isEnabled()
+	 */
+	public boolean isEnabled() {
+       return true;
+	}
+
+	/**
+	 * @see org.gvsig.andami.plugins.IExtension#isVisible()
+	 */
+	public boolean isVisible() {
+		IWindow f = PluginServices.getMDIManager().getFocusWindow();
+		if (f == null) {
+			return false;
+		}
+		if (f instanceof IWindowTransform) {
+			IWindowTransform vt=(IWindowTransform)f;
+			if (vt.isPalette())
+				return true;
+		}
+		return false;
+	}
+
+}

Property changes on: tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/app/extension/RestoreViewInfoExtension.java
___________________________________________________________________
Added: svn:eol-style
   + native

Index: tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/app/panelGroup/loaders/PanelGroupLoaderFromExtensionPoint.java
===================================================================
--- tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/app/panelGroup/loaders/PanelGroupLoaderFromExtensionPoint.java	(revision 0)
+++ tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/app/panelGroup/loaders/PanelGroupLoaderFromExtensionPoint.java	(revision 38653)
@@ -0,0 +1,172 @@
+/* gvSIG. Sistema de Informaci�n Geogr�fica de la Generalitat Valenciana
+ *
+ * Copyright (C) 2007 IVER T.I. and Generalitat Valenciana.
+ *
+ * This program is free software; you can redistribute it and/or
+ * modify it under the terms of the GNU General Public License
+ * as published by the Free Software Foundation; either version 2
+ * of the License, or (at your option) any later version.
+ *
+ * This program is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
+ * GNU General Public License for more details.
+ *
+ * You should have received a copy of the GNU General Public License
+ * along with this program; if not, write to the Free Software
+ * Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA  02111-1307,USA.
+ */
+
+package org.gvsig.app.panelGroup.loaders;
+
+import java.io.Serializable;
+import java.util.ArrayList;
+import java.util.Iterator;
+import java.util.Map;
+
+import org.gvsig.andami.PluginServices;
+import org.gvsig.gui.beans.panelGroup.exceptions.ListCouldntLoadPanelException;
+import org.gvsig.gui.beans.panelGroup.exceptions.PanelBaseException;
+import org.gvsig.gui.beans.panelGroup.loaders.IPanelGroupLoader;
+import org.gvsig.gui.beans.panelGroup.panels.AbstractPanel;
+import org.gvsig.gui.beans.panelGroup.panels.IPanel;
+import org.gvsig.tools.ToolsLocator;
+import org.gvsig.tools.extensionpoint.ExtensionPointManager;
+import org.gvsig.tools.extensionpoint.ExtensionPoint.Extension;
+import org.slf4j.Logger;
+import org.slf4j.LoggerFactory;
+
+
+/**
+ * <p>
+ * Panel loader version that loads {@link AbstractPanel AbstractPanel} classes
+ * registered as a extension point.
+ * </p>
+ *
+ * @see IPanelGroupLoader
+ *
+ * @version 15/10/2007
+ * @author Pablo Piqueras Bartolom� (pablo.piqueras@iver.es)
+ */
+public class PanelGroupLoaderFromExtensionPoint implements IPanelGroupLoader, Serializable {
+    private static final Logger logger = LoggerFactory
+            .getLogger(PanelGroupLoaderFromExtensionPoint.class);
+    
+	private static final long serialVersionUID = 6810333457209196344L;
+
+	/**
+	 * Extension point id
+	 */
+	private String id;
+
+	/**
+	 * <p>
+	 * Initializes this loader.
+	 * </p>
+	 *
+	 * @param id
+	 *            extension point identifier
+	 */
+	public PanelGroupLoaderFromExtensionPoint(String id) {
+		this.id = id;
+	}
+
+	/*
+	 * (non-Javadoc)
+	 * @see org.gvsig.gui.beans.panelGroup.loaders.IPanelGroupLoader#loadPanels(java.util.ArrayList)
+	 */
+	public void loadPanels(ArrayList<IPanel> panels) throws ListCouldntLoadPanelException {
+		if (id == null) {
+			return;
+		}
+
+		ExtensionPointManager ePManager = ToolsLocator
+				.getExtensionPointManager();
+		ListCouldntLoadPanelException lCLPException = null;
+		Iterator<Extension> iterator = null;
+
+		try {
+			if (!ePManager.has(id)) {
+				return;
+			}
+
+			iterator = ePManager.get(id).iterator();
+		} catch (Exception e) {
+			logger.debug(PluginServices
+                    .getText(this, "panel_loading_exception"), e);
+
+			if ( lCLPException == null ) {
+				lCLPException = new ListCouldntLoadPanelFromExtensionPointException();
+			}
+
+			lCLPException.add(e);
+		}
+
+		AbstractPanel panel = null;
+
+		while (iterator.hasNext()) {
+			try {
+
+				panel = (AbstractPanel) ((iterator.next()).create());
+				panels.add(panel);
+			} catch (Exception e) {
+				logger.debug(PluginServices.getText(this,
+                        "panel_loading_exception"), e);
+
+				if ( lCLPException == null ) {
+					lCLPException = new ListCouldntLoadPanelFromExtensionPointException();
+				}
+
+				PanelBaseException bew = null;
+
+				if (panel == null) {
+					bew = new PanelBaseException(e, "");
+				} else {
+					bew = new PanelBaseException(e, panel.getLabel());
+				}
+
+				lCLPException.add(bew);
+			}
+		}
+
+		if ( lCLPException != null ) {
+			throw lCLPException;
+		}
+
+	}
+
+	/**
+	 * <p>
+	 * Exception produced when fails the load of a panel by a loader of type
+	 * <code>PanelGroupLoaderFromExtensionPoint</code>.
+	 * </p>
+	 *
+	 * @version 27/11/2007
+	 * @author Pablo Piqueras Bartolom� (pablo.piqueras@iver.es)
+	 */
+	public class ListCouldntLoadPanelFromExtensionPointException extends ListCouldntLoadPanelException {
+		private static final long serialVersionUID = -1513294728326593385L;
+
+		private static final String formatString = "Couldn't load some panels from an extension point of classes:";
+		private static final String messageKey = "couldnt_load_panels_from_extension_point_exception";
+
+		/**
+		 * <p>
+		 * Creates an initializes a new instance of
+		 * <code>ListCouldntLoadPanelFromExtensionPointException</code>.
+		 * </p>
+		 */
+		public ListCouldntLoadPanelFromExtensionPointException() {
+			super(formatString, messageKey, serialVersionUID);
+		}
+
+		/*
+		 * (non-Javadoc)
+		 *
+		 * @see org.gvsig.tools.exceptions.BaseException#values()
+		 */
+		protected Map<String, String> values() {
+			return null;
+		}
+	}
+}
Index: tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/app/panelGroup/PanelGroupDialog.java
===================================================================
--- tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/app/panelGroup/PanelGroupDialog.java	(revision 0)
+++ tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/app/panelGroup/PanelGroupDialog.java	(revision 38653)
@@ -0,0 +1,590 @@
+/* gvSIG. Sistema de Informaci�n Geogr�fica de la Generalitat Valenciana
+ *
+ * Copyright (C) 2007 IVER T.I. and Generalitat Valenciana.
+ *
+ * This program is free software; you can redistribute it and/or
+ * modify it under the terms of the GNU General Public License
+ * as published by the Free Software Foundation; either version 2
+ * of the License, or (at your option) any later version.
+ *
+ * This program is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
+ * GNU General Public License for more details.
+ *
+ * You should have received a copy of the GNU General Public License
+ * along with this program; if not, write to the Free Software
+ * Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA  02111-1307,USA.
+ */
+
+package org.gvsig.app.panelGroup;
+
+import java.awt.BorderLayout;
+import java.awt.Dimension;
+import java.io.Serializable;
+import java.util.Hashtable;
+
+import javax.swing.JOptionPane;
+
+import org.gvsig.andami.PluginServices;
+import org.gvsig.andami.messages.NotificationManager;
+import org.gvsig.andami.ui.mdiManager.IWindow;
+import org.gvsig.andami.ui.mdiManager.IWindowListener;
+import org.gvsig.andami.ui.mdiManager.WindowInfo;
+import org.gvsig.gui.beans.Messages;
+import org.gvsig.gui.beans.buttonspanel.ButtonsPanel;
+import org.gvsig.gui.beans.buttonspanel.ButtonsPanelEvent;
+import org.gvsig.gui.beans.buttonspanel.ButtonsPanelListener;
+import org.gvsig.gui.beans.buttonspanel.IButtonsPanel;
+import org.gvsig.gui.beans.defaultbuttonspanel.DefaultButtonsPanel;
+import org.gvsig.gui.beans.panelGroup.AbstractPanelGroup;
+import org.gvsig.gui.beans.panelGroup.IPanelGroup;
+import org.gvsig.gui.beans.panelGroup.exceptions.EmptyPanelGroupException;
+import org.gvsig.gui.beans.panelGroup.exceptions.EmptyPanelGroupGUIException;
+import org.gvsig.gui.beans.panelGroup.exceptions.ListCouldntAddPanelException;
+import org.gvsig.gui.beans.panelGroup.loaders.IPanelGroupLoader;
+import org.gvsig.gui.beans.panelGroup.panels.IPanel;
+import org.gvsig.tools.exception.BaseException;
+
+
+/**
+ * <p>Graphical component that is represented as an {@link IWindow IWindow}, and that has two immediate internal
+ *  panels, the top is a {@link PanelGroup PanelGroup}, and the bottom is a {@link PanelGroupDialog PanelGroupDialog}
+ *  of <code>PanelGroupDialog.BUTTONS_ACCEPTCANCELAPPLY</code> type.</p>
+ *
+ * @see DefaultButtonsPanel
+ *
+ * @version 15/10/2007
+ * @author Pablo Piqueras Bartolom� (pablo.piqueras@iver.es)
+ */
+public class PanelGroupDialog extends DefaultButtonsPanel implements ButtonsPanelListener, IWindow, IWindowListener, IPanelGroup, IButtonsPanel, Serializable {
+	private static final long serialVersionUID = 6267404338808012765L;
+
+	/**
+	 * <p>Default width.</p>
+	 */
+	protected static int defaultWidth = 530;
+
+	/**
+	 * <p>Default height.</p>
+	 */
+	protected static int defaultHeight = 432;
+
+	/**
+	 * <p>This graphical component has a panel that allows work {@link IPanel IPanel}.</p>
+	 *
+	 * @see #getPanelGroup()
+	 */
+	protected IPanelGroup panelGroup;
+
+	/**
+	 * <p>Properties about the managing of this dialog by <i>Andami</i>.</p>
+	 */
+	private WindowInfo windowInfo;
+
+	/**
+	 * <p>Default constructor with two parameters, that creates a panel with an {@link AbstractPanelGroup AbstractPanelGroup}
+	 *  on top and another with <i>accept</i>, <i>apply</i>, and <i>cancel</i> buttons on bottom.</p>
+	 *
+	 * @param windowTitle title for this <code>IWindow</code>
+	 * @param PanelGroup kind of panel for work with this <code>IWindow</code>
+	 */
+	public PanelGroupDialog(String windowTitle, IPanelGroup panelGroup) {
+		super(ButtonsPanel.BUTTONS_ACCEPTCANCELAPPLY);
+
+		windowInfo = new WindowInfo();
+		windowInfo.setTitle(PluginServices.getText(this, windowTitle));
+		windowInfo.setWidth(defaultWidth);
+		windowInfo.setHeight(defaultHeight);
+
+		this.panelGroup = panelGroup;
+
+		initialize();
+	}
+
+	/**
+	 * <p>Default constructor with six parameters, that creates a panel with an {@link AbstractPanelGroup AbstractPanelGroup}
+	 *  on top and another with <i>accept</i>, <i>apply</i>, and <i>cancel</i> buttons on bottom.</p>
+	 * <p>Last parameter is the {@link PanelGroup PanelGroup} graphical component that
+	 *  this panel will have, and the previous are information to initialize this {@link IWindow IWindow}.</p>
+	 *
+	 * @param additionalInfo additional information about this <code>IWindow</code>
+	 * @param windowTitle title for this <code>IWindow</code>
+	 * @param width width for this component
+	 * @param height height for this component
+	 * @param windowInfoProperties properties about the managing of this dialog by <i>Andami</i>
+	 * @param PanelGroup kind of panel for work with this <code>IWindow</code>
+	 */
+	public PanelGroupDialog(String additionalInfo, String windowTitle, int  width, int height, byte windowInfoProperties, IPanelGroup panelGroup) {
+		super(ButtonsPanel.BUTTONS_ACCEPTCANCELAPPLY);
+
+		windowInfo = new WindowInfo(windowInfoProperties);
+		windowInfo.setAdditionalInfo(additionalInfo);
+		windowInfo.setTitle(PluginServices.getText(this, windowTitle));
+		windowInfo.setWidth(width);
+		windowInfo.setHeight(height);
+
+		this.panelGroup = panelGroup;
+
+		initialize();
+	}
+
+	/**
+	 * <p>This method is used to execute initialization tasks of this graphical component.</p>
+	 */
+	private void initialize() {
+		setLayout(new BorderLayout());
+		addButtonPressedListener(this);
+
+		this.panelGroup.setParentPanelGroup(this);
+
+		// Mask possible extra exceptions
+		if (panelGroup != null) {
+			add((AbstractPanelGroup)panelGroup, BorderLayout.CENTER);
+
+			// Holds the preferred size
+			if ((windowInfo.getWidth() > getPreferredSize().width) || (windowInfo.getHeight() > getPreferredSize().height)) {
+				setPreferredSize(new Dimension(Math.max(windowInfo.getWidth(), getWidth()), Math.max(windowInfo.getHeight(), getHeight())));
+			}
+		}
+	}
+
+	/**
+	 * <p>Determinates if this panel is resizable or not.</p>
+	 *
+	 * @return <code>true</code> if it's resizable; <code>false</code> otherwise.
+	 */
+	public boolean isResizable() {
+		return windowInfo.isResizable();
+	}
+
+	/**
+	 * <p>Closes this {@link IWindow IWindow}.</p>
+	 */
+	public void close() {
+		PluginServices.getMDIManager().closeWindow(this);
+	}
+
+	/*
+	 * (non-Javadoc)
+	 * @see com.iver.andami.ui.mdiManager.IWindow#getWindowInfo()
+	 */
+	public WindowInfo getWindowInfo() {
+		return windowInfo;
+	}
+
+	/*
+	 * (non-Javadoc)
+	 * @see org.gvsig.gui.beans.buttonspanel.ButtonsPanelListener#actionButtonPressed(org.gvsig.gui.beans.buttonspanel.ButtonsPanelEvent)
+	 */
+	public void actionButtonPressed(ButtonsPanelEvent e) {
+		// Masks possible extra exceptions
+		if (panelGroup != null) {
+			switch (e.getButton()) {
+			case ButtonsPanel.BUTTON_ACCEPT:
+				accept();
+				close();
+				break;
+			case ButtonsPanel.BUTTON_APPLY:
+				apply();
+				break;
+			case ButtonsPanel.BUTTON_CANCEL:
+				cancel();
+				close();
+				break;
+			}
+		}
+	}
+
+	/*
+	 * (non-Javadoc)
+	 * @see com.iver.andami.ui.mdiManager.IWindowListener#windowActivated()
+	 */
+	public void windowActivated() {}
+
+	/*
+	 * (non-Javadoc)
+	 * @see com.iver.andami.ui.mdiManager.IWindowListener#windowClosed()
+	 */
+	public void windowClosed() {
+		// Masks possible extra exceptions
+		if (panelGroup != null) {
+			if (!panelGroup.isAccepted()) {
+				panelGroup.cancel();
+			}
+		}
+	}
+
+	/*
+	 * (non-Javadoc)
+	 * @see org.gvsig.gui.beans.panelGroup.IPanelGroup#accept()
+	 */
+	public void accept() {
+		panelGroup.accept();
+	}
+
+	/*
+	 * (non-Javadoc)
+	 * @see org.gvsig.gui.beans.panelGroup.IPanelGroup#addPanel(org.gvsig.gui.beans.panelGroup.panels.IPanel)
+	 */
+	public void addPanel(IPanel panel) throws BaseException {
+		panelGroup.addPanel(panel);
+	}
+
+	/*
+	 * (non-Javadoc)
+	 * @see org.gvsig.gui.beans.panelGroup.IPanelGroup#apply()
+	 */
+	public void apply() {
+		panelGroup.apply();
+	}
+
+	/*
+	 * (non-Javadoc)
+	 * @see org.gvsig.gui.beans.panelGroup.IPanelGroup#cancel()
+	 */
+	public void cancel() {
+		panelGroup.cancel();
+	}
+
+	/*
+	 * (non-Javadoc)
+	 * @see org.gvsig.gui.beans.panelGroup.IPanelGroup#getActivePanel()
+	 */
+	public IPanel getActivePanel() {
+		return panelGroup.getActivePanel();
+	}
+
+	/*
+	 * (non-Javadoc)
+	 * @see org.gvsig.gui.beans.panelGroup.IPanelGroup#getProperties()
+	 */
+	public Hashtable getProperties() {
+		return panelGroup.getProperties();
+	}
+
+	/*
+	 * (non-Javadoc)
+	 * @see org.gvsig.gui.beans.panelGroup.IPanelGroup#getReference()
+	 */
+	public Object getReference() {
+		return panelGroup.getReference();
+	}
+
+	/*
+	 * (non-Javadoc)
+	 * @see org.gvsig.gui.beans.panelGroup.IPanelGroup#updateReference(java.lang.Object)
+	 */
+	public void updateReference(Object reference) {
+		panelGroup.updateReference(reference);
+	}
+
+	/*
+	 * (non-Javadoc)
+	 * @see org.gvsig.gui.beans.panelGroup.IPanelGroup#isAccepted()
+	 */
+	public boolean isAccepted() {
+		return panelGroup.isAccepted();
+	}
+
+	/*
+	 * (non-Javadoc)
+	 * @see org.gvsig.gui.beans.panelGroup.IPanelGroup#loadPanels(org.gvsig.gui.beans.panelGroup.loaders.IPanelGroupLoader)
+	 */
+	public void loadPanels(IPanelGroupLoader loader) throws ListCouldntAddPanelException, EmptyPanelGroupException, EmptyPanelGroupGUIException {
+		try {
+			panelGroup.loadPanels(loader);
+
+			if (panelGroup.getPanelInGUICount() == 0) {
+				close();
+			}
+		}
+		catch (BaseException be) {
+			be.setTranslator(new Messages());
+
+			JOptionPane.showMessageDialog(this, be.getLocalizedMessageStack());
+
+			// Don't show the dialog if there is no panels in the GUI
+			if (panelGroup.getPanelInGUICount() == 0) {
+				close();
+			}
+		}
+		catch (Exception e) {
+			NotificationManager.showMessageError(e.getMessage(), e);
+
+			// Don't show the dialog if there is no panels in the GUI
+			if (panelGroup.getPanelInGUICount() == 0) {
+				close();
+			}
+		}
+	}
+
+	/*
+	 * (non-Javadoc)
+	 * @see org.gvsig.gui.beans.panelGroup.IPanelGroup#removePanel(org.gvsig.gui.beans.panelGroup.panels.IPanel)
+	 */
+	public void removePanel(IPanel panel) {
+		panelGroup.removePanel(panel);
+	}
+
+	/*
+	 * (non-Javadoc)
+	 * @see org.gvsig.gui.beans.panelGroup.IPanelGroup#isPanelInGUI(org.gvsig.gui.beans.panelGroup.panels.IPanel)
+	 */
+	public boolean isPanelInGUI(IPanel panel) {
+		return panelGroup.isPanelInGUI(panel);
+	}
+
+	/*
+	 * (non-Javadoc)
+	 * @see org.gvsig.gui.beans.panelGroup.IPanelGroup#setPanelInGUI(org.gvsig.gui.beans.panelGroup.panels.IPanel, boolean)
+	 */
+	public void setPanelInGUI(IPanel panel, boolean b) {
+		panelGroup.setPanelInGUI(panel, b);
+	}
+
+	/*
+	 * (non-Javadoc)
+	 * @see org.gvsig.gui.beans.panelGroup.IPanelGroup#getPanelCount()
+	 */
+	public int getPanelCount() {
+		return panelGroup.getPanelCount();
+	}
+
+	/*
+	 * (non-Javadoc)
+	 * @see org.gvsig.gui.beans.panelGroup.IPanelGroup#getPanelInGUICount()
+	 */
+	public int getPanelInGUICount() {
+		return panelGroup.getPanelInGUICount();
+	}
+
+	/*
+	 * (non-Javadoc)
+	 * @see javax.swing.JComponent#setPreferredSize(java.awt.Dimension)
+	 */
+	public void setPreferredSize(Dimension preferredSize) {
+		super.setPreferredSize(preferredSize);
+
+		windowInfo.setWidth(preferredSize.width);
+		windowInfo.setHeight(preferredSize.height);
+	}
+
+	/*
+	 * (non-Javadoc)
+	 * @see org.gvsig.gui.beans.panelGroup.IPanelGroup#setParentPanelGroup(org.gvsig.gui.beans.panelGroup.IPanelGroup)
+	 */
+	public void setParentPanelGroup(IPanelGroup parent) {
+		panelGroup.setParentPanelGroup(parent);
+
+//		this.addComponentListener(new ComponentAdapter())
+	}
+
+	///// BEGIN: Buttons Enable/Disable functionality /////
+
+	/*
+	 * (non-Javadoc)
+	 * @see org.gvsig.gui.beans.buttonspanel.IButtonsPanel#isEnabledAcceptButton()
+	 */
+	public boolean isEnabledAcceptButton() {
+		return getButtonsPanel().getButton(ButtonsPanel.BUTTON_ACCEPT).isEnabled();
+	}
+
+	/*
+	 * (non-Javadoc)
+	 * @see org.gvsig.gui.beans.buttonspanel.IButtonsPanel#isEnabledApplyButton()
+	 */
+	public boolean isEnabledApplyButton() {
+		return getButtonsPanel().getButton(ButtonsPanel.BUTTON_APPLY).isEnabled();
+	}
+
+	/*
+	 * (non-Javadoc)
+	 * @see org.gvsig.gui.beans.buttonspanel.IButtonsPanel#isEnabledCancelButton()
+	 */
+	public boolean isEnabledCancelButton() {
+		return getButtonsPanel().getButton(ButtonsPanel.BUTTON_CANCEL).isEnabled();
+	}
+
+	/*
+	 * (non-Javadoc)
+	 * @see org.gvsig.gui.beans.buttonspanel.IButtonsPanel#isEnabledCloseButton()
+	 */
+	public boolean isEnabledCloseButton() {
+		/* Unimplemented */
+		return false;
+	}
+
+	/*
+	 * (non-Javadoc)
+	 * @see org.gvsig.gui.beans.buttonspanel.IButtonsPanel#isEnabledExitButton()
+	 */
+	public boolean isEnabledExitButton() {
+		/* Unimplemented */
+		return false;
+	}
+
+	/*
+	 * (non-Javadoc)
+	 * @see org.gvsig.gui.beans.buttonspanel.IButtonsPanel#isEnabledHideDetailsButton()
+	 */
+	public boolean isEnabledHideDetailsButton() {
+		/* Unimplemented */
+		return false;
+	}
+
+	/*
+	 * (non-Javadoc)
+	 * @see org.gvsig.gui.beans.buttonspanel.IButtonsPanel#isEnabledNoButton()
+	 */
+	public boolean isEnabledNoButton() {
+		/* Unimplemented */
+		return false;
+	}
+
+	/*
+	 * (non-Javadoc)
+	 * @see org.gvsig.gui.beans.buttonspanel.IButtonsPanel#isEnabledPauseButton()
+	 */
+	public boolean isEnabledPauseButton() {
+		/* Unimplemented */
+		return false;
+	}
+
+	/*
+	 * (non-Javadoc)
+	 * @see org.gvsig.gui.beans.buttonspanel.IButtonsPanel#isEnabledRestartButton()
+	 */
+	public boolean isEnabledRestartButton() {
+		/* Unimplemented */
+		return false;
+	}
+
+	/*
+	 * (non-Javadoc)
+	 * @see org.gvsig.gui.beans.buttonspanel.IButtonsPanel#isEnabledSaveButton()
+	 */
+	public boolean isEnabledSaveButton() {
+		/* Unimplemented */
+		return false;
+	}
+
+	/*
+	 * (non-Javadoc)
+	 * @see org.gvsig.gui.beans.buttonspanel.IButtonsPanel#isEnabledSeeDetailsButton()
+	 */
+	public boolean isEnabledSeeDetailsButton() {
+		/* Unimplemented */
+		return false;
+	}
+
+	/*
+	 * (non-Javadoc)
+	 * @see org.gvsig.gui.beans.buttonspanel.IButtonsPanel#isEnabledYesButton()
+	 */
+	public boolean isEnabledYesButton() {
+		/* Unimplemented */
+		return false;
+	}
+
+	/*
+	 * (non-Javadoc)
+	 * @see org.gvsig.gui.beans.buttonspanel.IButtonsPanel#setEnabledAcceptButton(boolean)
+	 */
+	public void setEnabledAcceptButton(boolean b) {
+		getButtonsPanel().getButton(ButtonsPanel.BUTTON_ACCEPT).setEnabled(b);
+	}
+
+	/*
+	 * (non-Javadoc)
+	 * @see org.gvsig.gui.beans.buttonspanel.IButtonsPanel#setEnabledApplyButton(boolean)
+	 */
+	public void setEnabledApplyButton(boolean b) {
+		getButtonsPanel().getButton(ButtonsPanel.BUTTON_APPLY).setEnabled(b);
+	}
+
+	/*
+	 * (non-Javadoc)
+	 * @see org.gvsig.gui.beans.buttonspanel.IButtonsPanel#setEnabledCancelButton(boolean)
+	 */
+	public void setEnabledCancelButton(boolean b) {
+		getButtonsPanel().getButton(ButtonsPanel.BUTTON_CANCEL).setEnabled(b);
+	}
+
+	/*
+	 * (non-Javadoc)
+	 * @see org.gvsig.gui.beans.buttonspanel.IButtonsPanel#setEnabledCloseButton(boolean)
+	 */
+	public void setEnabledCloseButton(boolean b) {
+		/* Unimplemented */
+	}
+
+	/*
+	 * (non-Javadoc)
+	 * @see org.gvsig.gui.beans.buttonspanel.IButtonsPanel#setEnabledExitButton(boolean)
+	 */
+	public void setEnabledExitButton(boolean b) {
+		/* Unimplemented */
+	}
+
+	/*
+	 * (non-Javadoc)
+	 * @see org.gvsig.gui.beans.buttonspanel.IButtonsPanel#setEnabledHideDetailsButton(boolean)
+	 */
+	public void setEnabledHideDetailsButton(boolean b) {
+		/* Unimplemented */
+	}
+
+	/*
+	 * (non-Javadoc)
+	 * @see org.gvsig.gui.beans.buttonspanel.IButtonsPanel#setEnabledNoButton(boolean)
+	 */
+	public void setEnabledNoButton(boolean b) {
+		/* Unimplemented */
+	}
+
+	/*
+	 * (non-Javadoc)
+	 * @see org.gvsig.gui.beans.buttonspanel.IButtonsPanel#setEnabledPauseButton(boolean)
+	 */
+	public void setEnabledPauseButton(boolean b) {
+		/* Unimplemented */
+	}
+
+	/*
+	 * (non-Javadoc)
+	 * @see org.gvsig.gui.beans.buttonspanel.IButtonsPanel#setEnabledRestartButton(boolean)
+	 */
+	public void setEnabledRestartButton(boolean b) {
+		/* Unimplemented */
+	}
+
+	/*
+	 * (non-Javadoc)
+	 * @see org.gvsig.gui.beans.buttonspanel.IButtonsPanel#setEnabledSaveButton(boolean)
+	 */
+	public void setEnabledSaveButton(boolean b) {
+		/* Unimplemented */
+	}
+
+	/*
+	 * (non-Javadoc)
+	 * @see org.gvsig.gui.beans.buttonspanel.IButtonsPanel#setEnabledSeeDetailsButton(boolean)
+	 */
+	public void setEnabledSeeDetailsButton(boolean b) {
+		/* Unimplemented */
+	}
+
+	/*
+	 * (non-Javadoc)
+	 * @see org.gvsig.gui.beans.buttonspanel.IButtonsPanel#setEnabledYesButton(boolean)
+	 */
+	public void setEnabledYesButton(boolean b) {
+		/* Unimplemented */
+	}
+
+	public Object getWindowProfile() {
+		return WindowInfo.PROPERTIES_PROFILE;
+	}
+	///// END: Buttons Enable/Disable functionality /////
+}
Index: tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/app/prepareAction/prepareAction.java
===================================================================
--- tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/app/prepareAction/prepareAction.java	(revision 0)
+++ tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/app/prepareAction/prepareAction.java	(revision 38653)
@@ -0,0 +1,11 @@
+package org.gvsig.app.prepareAction;
+
+
+public interface prepareAction {
+	Object execute(PrepareContext context, Object data);
+	
+	String getName();
+
+	String getDescription();
+
+}

Property changes on: tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/app/prepareAction/prepareAction.java
___________________________________________________________________
Added: svn:mime-type
   + text/plain

Index: tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/app/prepareAction/PrepareContextView.java
===================================================================
--- tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/app/prepareAction/PrepareContextView.java	(revision 0)
+++ tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/app/prepareAction/PrepareContextView.java	(revision 38653)
@@ -0,0 +1,49 @@
+/* gvSIG. Geographic Information System of the Valencian Government
+*
+* Copyright (C) 2007-2008 Infrastructures and Transports Department
+* of the Valencian Government (CIT)
+*
+* This program is free software; you can redistribute it and/or
+* modify it under the terms of the GNU General Public License
+* as published by the Free Software Foundation; either version 2
+* of the License, or (at your option) any later version.
+*
+* This program is distributed in the hope that it will be useful,
+* but WITHOUT ANY WARRANTY; without even the implied warranty of
+* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
+* GNU General Public License for more details.
+*
+* You should have received a copy of the GNU General Public License
+* along with this program; if not, write to the Free Software
+* Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston,
+* MA  02110-1301, USA.
+*
+*/
+
+/*
+* AUTHORS (In addition to CIT):
+* 2009 IVER T.I   {{Task}}
+*/
+
+/**
+ *
+ */
+package org.gvsig.app.prepareAction;
+
+import org.gvsig.fmap.mapcontrol.MapControl;
+
+/**
+ * @author jmvivo
+ *
+ */
+public interface PrepareContextView extends PrepareContext {
+
+	/**
+	 *
+	 *
+	 * @return
+	 */
+
+	MapControl getMapControl();
+
+}

Property changes on: tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/app/prepareAction/PrepareContextView.java
___________________________________________________________________
Added: svn:mime-type
   + text/plain

Index: tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/app/prepareAction/PrepareContext.java
===================================================================
--- tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/app/prepareAction/PrepareContext.java	(revision 0)
+++ tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/app/prepareAction/PrepareContext.java	(revision 38653)
@@ -0,0 +1,52 @@
+/* gvSIG. Geographic Information System of the Valencian Government
+*
+* Copyright (C) 2007-2008 Infrastructures and Transports Department
+* of the Valencian Government (CIT)
+*
+* This program is free software; you can redistribute it and/or
+* modify it under the terms of the GNU General Public License
+* as published by the Free Software Foundation; either version 2
+* of the License, or (at your option) any later version.
+*
+* This program is distributed in the hope that it will be useful,
+* but WITHOUT ANY WARRANTY; without even the implied warranty of
+* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
+* GNU General Public License for more details.
+*
+* You should have received a copy of the GNU General Public License
+* along with this program; if not, write to the Free Software
+* Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston,
+* MA  02110-1301, USA.
+*
+*/
+
+/*
+* AUTHORS (In addition to CIT):
+* 2009 IVER T.I   {{Task}}
+*/
+
+package org.gvsig.app.prepareAction;
+
+import java.awt.Window;
+
+import org.cresques.cts.IProjection;
+
+public interface PrepareContext {
+	/**
+	 * Return a {@link java.awt.Dialog} or a {@link java.awt.Frame} to use like
+	 * owner for any created dialogs.
+	 * 
+	 * @return <ul>
+	 *         <li>null</li>
+	 *         <li>{@link java.awt.Dialog} instance</li>
+	 *         <li>{@link java.awt.Frame} instance</li>
+	 *         </ul>
+	 */
+	Window getOwnerWindow();
+	
+	/**
+	 * Gets the view projection
+	 * @return IProjection
+	 */
+	public IProjection getViewProjection();
+}

Property changes on: tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/app/prepareAction/PrepareContext.java
___________________________________________________________________
Added: svn:mime-type
   + text/plain

Index: tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/app/prepareAction/PrepareDataStore.java
===================================================================
--- tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/app/prepareAction/PrepareDataStore.java	(revision 0)
+++ tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/app/prepareAction/PrepareDataStore.java	(revision 38653)
@@ -0,0 +1,41 @@
+/* gvSIG. Geographic Information System of the Valencian Government
+*
+* Copyright (C) 2007-2008 Infrastructures and Transports Department
+* of the Valencian Government (CIT)
+*
+* This program is free software; you can redistribute it and/or
+* modify it under the terms of the GNU General Public License
+* as published by the Free Software Foundation; either version 2
+* of the License, or (at your option) any later version.
+*
+* This program is distributed in the hope that it will be useful,
+* but WITHOUT ANY WARRANTY; without even the implied warranty of
+* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
+* GNU General Public License for more details.
+*
+* You should have received a copy of the GNU General Public License
+* along with this program; if not, write to the Free Software
+* Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston,
+* MA  02110-1301, USA.
+*
+*/
+
+/*
+* AUTHORS (In addition to CIT):
+* 2009 IVER T.I   {{Task}}
+*/
+
+package org.gvsig.app.prepareAction;
+
+import org.gvsig.fmap.dal.DataStore;
+import org.gvsig.tools.exception.BaseException;
+import org.gvsig.tools.extensionpoint.ExtensionBuilder;
+
+public interface PrepareDataStore extends ExtensionBuilder {
+	DataStore prepare(DataStore store, PrepareContext context)
+			throws BaseException;
+
+	String getName();
+
+	String getDescription();
+}

Property changes on: tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/app/prepareAction/PrepareDataStore.java
___________________________________________________________________
Added: svn:mime-type
   + text/plain

Index: tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/app/prepareAction/PrepareDataStoreParameters.java
===================================================================
--- tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/app/prepareAction/PrepareDataStoreParameters.java	(revision 0)
+++ tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/app/prepareAction/PrepareDataStoreParameters.java	(revision 38653)
@@ -0,0 +1,45 @@
+/* gvSIG. Geographic Information System of the Valencian Government
+*
+* Copyright (C) 2007-2008 Infrastructures and Transports Department
+* of the Valencian Government (CIT)
+*
+* This program is free software; you can redistribute it and/or
+* modify it under the terms of the GNU General Public License
+* as published by the Free Software Foundation; either version 2
+* of the License, or (at your option) any later version.
+*
+* This program is distributed in the hope that it will be useful,
+* but WITHOUT ANY WARRANTY; without even the implied warranty of
+* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
+* GNU General Public License for more details.
+*
+* You should have received a copy of the GNU General Public License
+* along with this program; if not, write to the Free Software
+* Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston,
+* MA  02110-1301, USA.
+*
+*/
+
+/*
+* AUTHORS (In addition to CIT):
+* 2009 IVER T.I   {{Task}}
+*/
+
+package org.gvsig.app.prepareAction;
+
+import org.gvsig.fmap.dal.DataStoreParameters;
+import org.gvsig.tools.exception.BaseException;
+import org.gvsig.tools.extensionpoint.ExtensionBuilder;
+
+public interface PrepareDataStoreParameters extends ExtensionBuilder {
+	void pre(DataStoreParameters storeParamters, PrepareContext context);
+	
+	void post(DataStoreParameters storeParamters, PrepareContext context);
+	
+	DataStoreParameters prepare(DataStoreParameters storeParamters,
+			PrepareContext context) throws BaseException;
+
+	String getName();
+
+	String getDescription();
+}

Property changes on: tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/app/prepareAction/PrepareDataStoreParameters.java
___________________________________________________________________
Added: svn:mime-type
   + text/plain

Index: tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/app/prepareAction/PrepareLayer.java
===================================================================
--- tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/app/prepareAction/PrepareLayer.java	(revision 0)
+++ tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/app/prepareAction/PrepareLayer.java	(revision 38653)
@@ -0,0 +1,48 @@
+/* gvSIG. Geographic Information System of the Valencian Government
+*
+* Copyright (C) 2007-2008 Infrastructures and Transports Department
+* of the Valencian Government (CIT)
+*
+* This program is free software; you can redistribute it and/or
+* modify it under the terms of the GNU General Public License
+* as published by the Free Software Foundation; either version 2
+* of the License, or (at your option) any later version.
+*
+* This program is distributed in the hope that it will be useful,
+* but WITHOUT ANY WARRANTY; without even the implied warranty of
+* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
+* GNU General Public License for more details.
+*
+* You should have received a copy of the GNU General Public License
+* along with this program; if not, write to the Free Software
+* Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston,
+* MA  02110-1301, USA.
+*
+*/
+
+/*
+* AUTHORS (In addition to CIT):
+* 2009 IVER T.I   {{Task}}
+*/
+
+package org.gvsig.app.prepareAction;
+
+import org.gvsig.fmap.mapcontext.layers.FLayer;
+import org.gvsig.tools.exception.BaseException;
+import org.gvsig.tools.extensionpoint.ExtensionBuilder;
+
+public interface PrepareLayer extends ExtensionBuilder {
+	/**
+	 * Returns the layer input or a new processed layer
+	 * @param layer
+	 * @param context
+	 * @return
+	 * @throws BaseException
+	 */
+	FLayer prepare(FLayer layer, PrepareContextView context)
+			throws BaseException;
+
+	String getName();
+
+	String getDescription();
+}

Property changes on: tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/app/prepareAction/PrepareLayer.java
___________________________________________________________________
Added: svn:mime-type
   + text/plain

Index: tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/app/util/BaseOpenErrorHandler.java
===================================================================
--- tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/app/util/BaseOpenErrorHandler.java	(revision 0)
+++ tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/app/util/BaseOpenErrorHandler.java	(revision 38653)
@@ -0,0 +1,137 @@
+package org.gvsig.app.util;
+
+import java.io.File;
+import java.lang.reflect.InvocationTargetException;
+
+import javax.swing.JOptionPane;
+
+import org.gvsig.fmap.dal.DataParameters;
+import org.gvsig.fmap.dal.OpenErrorHandler;
+import org.gvsig.fmap.dal.exception.InitializeException;
+import org.gvsig.fmap.dal.exception.OpenException;
+import org.gvsig.fmap.dal.serverexplorer.filesystem.FilesystemStoreParameters;
+import org.gvsig.fmap.dal.serverexplorer.filesystem.swing.FilesystemExplorerWizardPanel;
+import org.gvsig.fmap.dal.store.shp.SHPStoreParameters;
+import org.gvsig.fmap.dal.store.shp.utils.SHP;
+import org.gvsig.gui.beans.swing.JFileChooser;
+import org.gvsig.i18n.Messages;
+import org.gvsig.utils.SimpleFileFilter;
+
+public class BaseOpenErrorHandler implements OpenErrorHandler{
+	
+	
+	private DataParameters parameters;
+	private Exception exception;
+
+	public BaseOpenErrorHandler() {
+		exception=null;
+		parameters=null;
+		
+	}
+
+	public boolean canRetryOpen(Exception e, DataParameters parameters) {
+		this.exception=e;
+		this.parameters=parameters;
+		Throwable cause = null;
+
+		if (this.exception instanceof InvocationTargetException){
+			cause = this.exception.getCause();
+		} else {
+			cause = this.exception;
+		}
+		if (cause instanceof InitializeException){
+			if (cause.getCause() instanceof OpenException){
+				if ( this.parameters instanceof FilesystemStoreParameters){
+					FilesystemStoreParameters filesystemStoreParameters = (FilesystemStoreParameters)this.parameters;
+					File searchedFile = filesystemStoreParameters.getFile();
+					File file = null;
+					if( searchedFile != null && !searchedFile.exists() ){
+						file = chooseAlternateFile(searchedFile);
+						if( file!=null){
+							filesystemStoreParameters.setFile(file);
+						} else {
+							return false;
+						}
+					}
+
+					if (this.parameters instanceof SHPStoreParameters){
+						SHPStoreParameters shpStoreParameters = (SHPStoreParameters)this.parameters;
+						File searchedDBFFile = shpStoreParameters.getDBFFile();
+						if (searchedDBFFile!=null && !searchedDBFFile.exists()){
+							File possibleDbfFile = null;
+							if (file != null){
+								possibleDbfFile = SHP.getDbfFile(file);
+							}
+							if (possibleDbfFile != null && possibleDbfFile.exists()){
+								shpStoreParameters.setDBFFile(possibleDbfFile);
+							} else {
+								File dbfFile = chooseAlternateFile(searchedDBFFile);
+								if (dbfFile != null){
+									shpStoreParameters.setDBFFile(dbfFile);
+								} else {
+									return false;
+								}
+							}
+						}
+						File searchedSHXFile = shpStoreParameters.getSHXFile();
+						if (searchedDBFFile!=null && !searchedSHXFile.exists()){
+							File possibleShxFile = null;
+							if (file != null){
+								possibleShxFile = SHP.getShxFile(file);
+							}
+							if (possibleShxFile != null && possibleShxFile.exists()){
+								shpStoreParameters.setSHXFile(possibleShxFile);
+							} else {
+								File shxFile = chooseAlternateFile(searchedSHXFile);
+								if (shxFile != null){
+									shpStoreParameters.setSHXFile(shxFile);
+								} else {
+									return false;
+								}
+							}
+						}
+					}
+					return true;
+				}
+			}
+		}
+		return false;
+	}
+	
+	private File chooseAlternateFile(File searchedFile){
+			int resp = JOptionPane.showConfirmDialog(
+					null,
+					Messages.getText("dont_find_the_file")+"\n"+
+					searchedFile.getName()+"\n"+
+					Messages.getText("do_you_want_to_locate_the_file"),
+					Messages.getText("dont_find_the_file"),
+					JOptionPane.YES_NO_OPTION,
+					JOptionPane.QUESTION_MESSAGE);
+			if (resp == JOptionPane.OK_OPTION){
+				JFileChooser fileChooser = new JFileChooser(FilesystemExplorerWizardPanel.OPEN_LAYER_FILE_CHOOSER_ID,
+						searchedFile.getParentFile());
+				File parentFile = searchedFile.getParentFile();
+				if (parentFile.exists()){
+					fileChooser.setLastPath(parentFile);
+				}
+				fileChooser.setMultiSelectionEnabled(false);
+				fileChooser.setAcceptAllFileFilterUsed(false);
+				fileChooser.setDialogTitle("dont_find_the_file: "+searchedFile.getAbsolutePath());
+
+				String searchedFileName = searchedFile.getName();
+				String ext = searchedFileName.substring(searchedFileName.lastIndexOf(".")+1);
+				SimpleFileFilter fileFilter = new SimpleFileFilter(ext, ext);
+				fileChooser.addChoosableFileFilter(fileFilter);
+				fileChooser.setFileFilter(fileFilter);
+				
+				int result = fileChooser.showOpenDialog(null);
+				if (result == JFileChooser.APPROVE_OPTION) {
+		            File file = fileChooser.getSelectedFile();
+		            return file;
+		        }
+			}
+		return null;
+	}
+}
+
+
Index: tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/app/ApplicationManager.java
===================================================================
--- tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/app/ApplicationManager.java	(revision 0)
+++ tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/app/ApplicationManager.java	(revision 38653)
@@ -0,0 +1,308 @@
+/* gvSIG. Geographic Information System of the Valencian Government
+*
+* Copyright (C) 2007-2008 Infrastructures and Transports Department
+* of the Valencian Government (CIT)
+*
+* This program is free software; you can redistribute it and/or
+* modify it under the terms of the GNU General Public License
+* as published by the Free Software Foundation; either version 2
+* of the License, or (at your option) any later version.
+*
+* This program is distributed in the hope that it will be useful,
+* but WITHOUT ANY WARRANTY; without even the implied warranty of
+* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
+* GNU General Public License for more details.
+*
+* You should have received a copy of the GNU General Public License
+* along with this program; if not, write to the Free Software
+* Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston,
+* MA  02110-1301, USA.
+*
+*/
+
+/*
+* AUTHORS (In addition to CIT):
+* 2009 IVER T.I   {{Task}}
+*/
+
+package org.gvsig.app;
+
+import java.util.List;
+
+import org.cresques.cts.IProjection;
+
+import org.gvsig.about.AboutManager;
+import org.gvsig.andami.ui.mdiFrame.ThreadSafeDialogs;
+import org.gvsig.andami.ui.mdiManager.IWindow;
+import org.gvsig.andami.ui.mdiManager.MDIManager;
+import org.gvsig.app.extension.Version;
+import org.gvsig.app.gui.WizardPanel;
+import org.gvsig.app.prepareAction.PrepareContext;
+import org.gvsig.app.prepareAction.PrepareContextView;
+import org.gvsig.app.prepareAction.PrepareDataStore;
+import org.gvsig.app.prepareAction.PrepareDataStoreParameters;
+import org.gvsig.app.prepareAction.PrepareLayer;
+import org.gvsig.app.project.Project;
+import org.gvsig.app.project.ProjectManager;
+import org.gvsig.app.project.documents.Document;
+import org.gvsig.app.project.documents.gui.IDocumentWindow;
+import org.gvsig.fmap.dal.DataManager;
+import org.gvsig.fmap.dal.DataStore;
+import org.gvsig.fmap.dal.DataStoreParameters;
+import org.gvsig.fmap.geom.GeometryManager;
+import org.gvsig.fmap.mapcontext.MapContextManager;
+import org.gvsig.fmap.mapcontext.layers.FLayer;
+import org.gvsig.gui.ColorTablesFactory;
+import org.gvsig.tools.dataTypes.DataTypesManager;
+import org.gvsig.tools.dispose.DisposableManager;
+import org.gvsig.tools.dynobject.DynObjectManager;
+import org.gvsig.tools.extensionpoint.ExtensionPointManager;
+import org.gvsig.tools.persistence.PersistenceManager;
+import org.gvsig.tools.swing.icontheme.IconThemeManager;
+
+
+public interface ApplicationManager extends ThreadSafeDialogs {
+
+    /**
+     * Return the version of the application.
+     * 
+     * @return the version
+     */
+	public Version getVersion() ;
+
+    /**
+     * Return the active window, IWindow, in the application.
+     * 
+     * @return the active window
+     */
+	public IWindow getActiveWindow();
+
+	/**
+	 * Return the project that is loaded and in use in the application.
+	 * 
+	 * @return the project 
+	 */
+    public Project getCurrentProject();
+
+    /**
+     * Returns the active document of the application or null 
+     * if there is no active document.
+     * 
+     * @return the active document
+     */
+    public Document getActiveDocument();
+
+    /**
+     * Returns the active document of the application that is of the 
+     * requested type or null if there is no active document or the
+     * active document is not of the requested type.
+     * 
+     * @param documentTypeName, type name of the document requested.
+     * @return the active document
+     */
+    public Document getActiveDocument(String documentTypeName);
+
+    /**
+     * Returns the active document of the application that is of the 
+     * requested type or null if there is no active document or the
+     * active document is not of the requested type.
+     * 
+     * @param documentClass, class of the document requested.
+     * @return the active document
+     */
+    public Document getActiveDocument(Class<? extends Document> documentClass);
+    
+    /**
+     * Returns the window associated with the document passed as 
+     * parameter or null if there is no window associated with 
+     * the document.
+     * 
+     * @param document to search the window
+     * @return window associated to the document
+     */
+    public IDocumentWindow getDocumentWindow(Document document);
+    
+    
+    /**
+     * Return the root of the nodes of preferences in the application.
+     * 
+     * @return the root of preferences.
+     */
+    PreferencesNode getPreferences();
+	
+    /**
+     * Search and return the node of preferences required as nodeName.
+     *  
+     * @param nodeName, name of the node to return
+     * @return the preferences node requested
+     */
+	PreferencesNode getPreferences(String nodeName);
+	
+	/**
+	 * Return the arguments passed to the application in the command line
+	 *  
+	 * @return arguments as a string array
+	 */
+	public String[] getArguments();
+	
+	/**
+	 * Return the value of the argument passed in the command line by
+	 * the name indicated as the parameter. This is passed as:
+	 * <code>
+	 * application --name=value
+	 * </code>
+	 * @param name of the requested argument
+	 * @return value of the requested argument
+	 */
+	public String getArgument(String name);
+	
+	/**
+	 * Get the value of the system clipboard as a string.
+	 * 
+	 * @return the clipboard value
+	 */
+	public String getFromClipboard();
+	
+	/**
+	 * Put the string value passed as parameter in the clipboard of
+	 * the system.
+	 * 
+	 * @param data to put in the clipboard.
+	 */
+	public void putInClipboard(String data) ;
+
+	/**
+	 * Obtain the projection associated by the code of projection
+	 * Passed as parameter. If passed code of projection it not
+	 * a valid projection code null is returned.
+	 * 
+	 * @param code of the projection requested
+	 * @return the requested projection or null
+	 */
+    public IProjection getCRS(String code);
+    
+	/**
+     * Utility method to obtain the DataManager used in the application at this moment.
+     * 
+     * @return the DataManager
+	 */
+	public DataManager getDataManager();
+    
+    /**
+     * Utility method to obtain the ProjectManager used in the application at this moment.
+     * 
+     * @return the ProjectManager
+     */
+    public ProjectManager getProjectManager();
+
+    /**
+     * Utility method to obtain the UIManager used in the application at this moment.
+     * 
+     * @return the UIManager
+     */
+    public MDIManager getUIManager();
+    
+    /**
+     * Utility method to obtain the GeometryManager used in the application at this moment.
+     * 
+     * @return the GeometryManager
+     */
+    public GeometryManager getGeometryManager();
+    
+    /**
+     * Utility method to obtain the PersistenceManager used in the application at this moment.
+     * 
+     * @return the PersistenceManager
+     */
+    public PersistenceManager getPersistenceManager();
+    
+    /**
+     * Utility method to obtain the DisposableManager used in the application at this moment.
+     * 
+     * @return the DisposableManager
+     */
+    public DisposableManager getDisposableManager() ;
+
+    /**
+     * Utility method to obtain the DynObjectManager used in the application at this moment.
+     * 
+     * @return the DynObjectManager
+     */
+    public DynObjectManager getDynObjectManager() ;
+
+    /**
+     * Utility method to obtain the ExtensionPointManager used in the application at this moment.
+     * 
+     * @return the ExtensionPointManager
+     */
+    public ExtensionPointManager getExtensionPointManager();
+
+    /**
+     * Utility method to obtain the MapContextManager used in the application at this moment.
+     * 
+     * @return the MapContextManager
+     */
+    public MapContextManager getMapContextManager();
+    
+    /**
+     * Utility method to obtain the AboutManager used in the application at this moment.
+     * 
+     * @return the AboutManager
+     */
+    public AboutManager getAbout();
+
+    public DataTypesManager getDataTypesManager();
+    
+    /**
+     * Utility method to obtain the IconThemeManager used in the application at this moment.
+     * 
+     * @return the IconThemeManager
+     */
+    IconThemeManager getIconThemeManager();
+    
+	void registerAddTableWizard(String name, String description,
+			Class<? extends WizardPanel> wpClass);
+
+	List<WizardPanel> getWizardPanels() throws Exception;
+
+
+
+	void registerPrepareOpenDataStore(PrepareDataStore action);
+	void registerPrepareOpenDataStoreParameters(	PrepareDataStoreParameters action);
+	void registerPrepareOpenLayer(PrepareLayer action);
+
+	DataStore pepareOpenDataSource(DataStore store,
+			PrepareContext context)
+			throws Exception;
+
+	DataStoreParameters prepareOpenDataStoreParameters(
+			DataStoreParameters storeParameters, PrepareContext context)
+			throws Exception;
+	
+	List<DataStoreParameters> prepareOpenDataStoreParameters(
+			List<DataStoreParameters> storeParameters, PrepareContext context)
+			throws Exception;
+
+	FLayer prepareOpenLayer(FLayer layer,
+			PrepareContextView context)
+			throws Exception;
+	
+	
+	public ColorTablesFactory getColorTablesFactory();
+	
+	public void registerColorTablesFactory(ColorTablesFactory factory);
+
+	public String getLocaleLanguage();
+
+    /**
+     * sets message in status bar
+     * 
+     * This method is thread safe.
+     * 
+     * @param message
+     * @param message_type One of: JOptionPane.ERROR_MESSAGE,
+     * JOptionPane.WARNING_MESSAGE, JOptionPane.INFORMATION_MESSAGE 
+     */
+    public void message(String message, int message_type);
+	
+}

Property changes on: tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/app/ApplicationManager.java
___________________________________________________________________
Added: svn:mime-type
   + text/plain

Index: tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/app/sqlQueryValidation/SQLQueryValidation.java
===================================================================
--- tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/app/sqlQueryValidation/SQLQueryValidation.java	(revision 0)
+++ tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/app/sqlQueryValidation/SQLQueryValidation.java	(revision 38653)
@@ -0,0 +1,254 @@
+package org.gvsig.app.sqlQueryValidation;
+
+import java.io.ByteArrayInputStream;
+
+import org.gvsig.andami.PluginServices;
+
+import Zql.ZqlParser;
+
+
+/* gvSIG. Sistema de Informaci�n Geogr�fica de la Generalitat Valenciana
+ *
+ * Copyright (C) 2004 IVER T.I. and Generalitat Valenciana.
+ *
+ * This program is free software; you can redistribute it and/or
+ * modify it under the terms of the GNU General Public License
+ * as published by the Free Software Foundation; either version 2
+ * of the License, or (at your option) any later version.
+ *
+ * This program is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
+ * GNU General Public License for more details.
+ *
+ * You should have received a copy of the GNU General Public License
+ * along with this program; if not, write to the Free Software
+ * Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA  02111-1307,USA.
+ *
+ * For more information, contact:
+ *
+ *  Generalitat Valenciana
+ *   Conselleria d'Infraestructures i Transport
+ *   Av. Blasco Ib��ez, 50
+ *   46010 VALENCIA
+ *   SPAIN
+ *
+ *      +34 963862235
+ *   gvsig@gva.es
+ *      www.gvsig.gva.es
+ *
+ *    or
+ *
+ *   IVER T.I. S.A
+ *   Salamanca 50
+ *   46005 Valencia
+ *   Spain
+ *
+ *   +34 963163400
+ *   dac@iver.es
+ */
+
+/**
+ * Class for validate a complete query or the sentence of a query from WHERE 
+ *
+ * @author Pablo Piqueras Bartolom� (p_queras@hotmail.com)
+ */
+public class SQLQueryValidation {
+	private String query;
+	private boolean onlyWhereStatement;
+	private int[] errorPosition; //[0] -> line, [1] -> column        ( (-1, -1) -> no error ) ( (-2, -2) -> error: query = null)
+	private String errorMessage;
+	private String errorPositionAsMessage;
+	private String token;
+	private final String preQuery = "SELECT a FROM b WHERE ";
+	private final int preQueryLenght = preQuery.length();
+	
+	/**
+	 * Default constructor with a parameter
+	 * 
+	 * @param _query The query to validate
+	 * @param _onlyWhereStatement If the query is only the part of WHERE ... in a query
+	 */
+	public SQLQueryValidation(String _query, boolean _onlyWhereStatement) {
+		query = new String(_query);
+		onlyWhereStatement = _onlyWhereStatement;
+		
+		// By default no error position
+		errorPosition = new int[2];
+		errorPosition[0] = -1;
+		errorPosition[1] = -1;
+		
+		errorPositionAsMessage = null;
+		
+		// By default no error message
+		errorMessage = null;
+		
+		// By default no error symbol
+		token = null;
+	}
+		
+	/**
+	 * Validates a query
+	 * 
+	 * Returns 'null' if there has been some error
+	 */
+	public boolean validateQuery() {
+		String completeQuery = new String();
+		
+		// If the query is null -> error 
+		if (query == null)	{
+			errorPosition[0] = -2;
+			errorPosition[1] = -2;
+			defineErrorPositionAsMessageAttribute(errorPosition);
+			errorMessage = new String( PluginServices.getText(null, "queryIsNull"));
+			
+			return false;
+		}
+		
+		// If no query itsn't considered as a error
+		if ((query.compareTo("")) == 0) {
+			errorPosition[0] = -1;
+			errorPosition[1] = -1;
+			defineErrorPositionAsMessageAttribute(errorPosition);
+			errorMessage = null;
+			
+			return true;
+		}
+
+		// Converts all apostrophes between aphostrophes to double inverted commas ( " )
+		int index = 0;
+		boolean is_word = false; // by default isn't a word
+		String formatted_query = new String();
+		char c;
+		
+		while (index < query.length()) {
+			c = query.charAt(index);
+			if (c == '\'') {
+				if (is_word == false) {
+					if ((index > 0) && ((query.charAt(index-1) == ' ') || (query.charAt(index-1) == '(')) ) {
+						is_word = true;
+					}
+					
+					formatted_query += c;
+				}
+				else {
+					if (index == (query.length() -1)) {
+//						is_word = false;
+						formatted_query += c;
+					}
+					else {
+						if (((query.charAt(index+1) == ' ') || (query.charAt(index+1) == ')')) ) {
+							is_word = false;
+							formatted_query += c;
+						}
+						else {
+							formatted_query += "\""; // Convert ' to "
+						}
+					}
+				}
+			}
+			else {
+				formatted_query += c;
+			}
+			
+			index ++;
+		}		
+		
+		// Converts all ocurrences of the symbol " ( double inverted commas ) to space because Zql doesn't support that symbol
+		if (onlyWhereStatement)
+			completeQuery = preQuery + formatted_query.trim().replaceAll("\"", " ");
+		else
+			completeQuery = formatted_query.trim().replaceAll("\"", " ");
+
+		if ((completeQuery.length() > 0) && (completeQuery.charAt(completeQuery.length() - 1) != ';'))
+			completeQuery += ";";
+
+		try {
+			// Starts the parser
+			ZqlParser p = new ZqlParser();
+			p.initParser(new ByteArrayInputStream(completeQuery.getBytes()));
+	      
+			// Analyzes the query
+			p.readStatement();
+			
+			// If arrives here -> there has been no errors
+			errorPosition[0] = -1;
+			errorPosition[1] = -1;
+			defineErrorPositionAsMessageAttribute(errorPosition);
+			errorMessage = null;
+			return true;
+		} catch (Exception e) {
+			// Defines the error message
+			errorMessage = e.getMessage();
+			
+			// Get the token that produced the error
+			int ini_pos = e.getMessage().indexOf('\"') +1;
+			token = new String(errorMessage.substring(ini_pos, errorMessage.indexOf('\"', ini_pos)));
+
+			// Get the line an column where the syntax error starts
+			String line = new String(errorMessage.substring(e.getMessage().indexOf("line"), errorMessage.indexOf(',')));
+			line = line.substring(line.indexOf(' ')+1, line.length());
+			
+			String column = new String(e.getMessage().substring(errorMessage.indexOf("column"), errorMessage.indexOf('.')));
+			column = column.substring(column.indexOf(' ')+1, column.length());			
+
+			// Get the line an column of the error
+			errorPosition[0] = Integer.valueOf(line.trim()).intValue();			
+			errorPosition[1] = Integer.valueOf(column.trim()).intValue();
+			
+			if (onlyWhereStatement) {
+				this.errorPosition[1] -= this.preQueryLenght; // Substract the lenght of the pre-query added
+			}
+			
+			defineErrorPositionAsMessageAttribute(this.errorPosition);
+
+			return false;
+		}
+	}
+	
+	/**
+	 * Returns an string with an error message if there has been an error, or 'null' if there hasn't been
+	 * 
+	 * @return An string or null
+	 */
+	public String getErrorMessage() {
+		return this.errorMessage;
+	}
+	
+	/**
+	 * Returns an string with a text describing the (first) position of the error
+	 * 
+	 * @return An string or null
+	 */
+	public String getErrorPositionAsMessage() {
+		return this.errorPositionAsMessage;
+	}
+	
+	/**
+	 * Returns the error position (line, column) or (-1, -1) if there hasn't been any error
+	 * 
+	 * @return An array of 2 integer values (first: line, second: column) 
+	 */
+	public int[] getErrorPosition() {
+		return errorPosition;
+	}
+	
+	/**
+	 * Returns the token where the validator failed
+	 * 
+	 * @return An string
+	 */
+	public String getTokenThatProducedTheSyntacticError() {
+		return token;
+	}
+	
+	/**
+	 * Creates a message with information about the message
+	 * 
+	 * @param position An array with 2 elements: (row, column)
+	 */
+	private void defineErrorPositionAsMessageAttribute(int position[]) {
+		// Defines the error message
+		errorPositionAsMessage = new String( PluginServices.getText(null, "line") + ": " + errorPosition[0] + ", " + PluginServices.getText(null, "column") + ": " + errorPosition[1] );
+	}
+}
\ No newline at end of file

Property changes on: tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/app/sqlQueryValidation/SQLQueryValidation.java
___________________________________________________________________
Added: svn:eol-style
   + native

Index: tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/app/tools/swing/serv/field/crs/JCRSDynFieldComponent.java
===================================================================
--- tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/app/tools/swing/serv/field/crs/JCRSDynFieldComponent.java	(revision 0)
+++ tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/app/tools/swing/serv/field/crs/JCRSDynFieldComponent.java	(revision 38653)
@@ -0,0 +1,227 @@
+/* gvSIG. Geographic Information System of the Valencian Government
+ *
+ * Copyright (C) 2007-2008 Infrastructures and Transports Department
+ * of the Valencian Government (CIT)
+ * 
+ * This program is free software; you can redistribute it and/or
+ * modify it under the terms of the GNU General Public License
+ * as published by the Free Software Foundation; either version 2
+ * of the License, or (at your option) any later version.
+ * 
+ * This program is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
+ * GNU General Public License for more details.
+ * 
+ * You should have received a copy of the GNU General Public License
+ * along with this program; if not, write to the Free Software
+ * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, 
+ * MA  02110-1301, USA.
+ * 
+ */
+/*
+ * AUTHORS (In addition to CIT):
+ * 2010 Institute of New Imaging Technologies (INIT): 
+ *   http://www.init.uji.es
+ * Geographic Information research group: 
+ *   http://www.geoinfo.uji.es
+ * Universitat Jaume I, Spain
+ */
+
+/**
+ * 
+ */
+package org.gvsig.app.tools.swing.serv.field.crs;
+
+import java.awt.event.ActionEvent;
+import java.awt.event.ActionListener;
+
+import javax.swing.JButton;
+import javax.swing.JComponent;
+
+import org.cresques.cts.IProjection;
+import org.gvsig.andami.PluginServices;
+import org.gvsig.andami.ui.mdiManager.IWindow;
+import org.gvsig.andami.ui.mdiManager.WindowInfo;
+import org.gvsig.app.gui.panels.CRSSelectPanel;
+import org.gvsig.tools.dynobject.DynField;
+import org.gvsig.tools.service.ServiceException;
+import org.gvsig.tools.swing.api.dynobject.dynfield.JDynFieldComponent;
+import org.gvsig.tools.swing.api.dynobject.dynfield.ValueField;
+import org.gvsig.tools.swing.spi.AbstractJDynFieldComponent;
+
+/**
+ * @author <a href="mailto:reinhold@uji.es">cmartin</a>
+ * 
+ */
+public class JCRSDynFieldComponent extends AbstractJDynFieldComponent implements
+    JDynFieldComponent, IWindow, ActionListener {
+
+    private CRSSelectPanel panel;
+    private JButton button;
+
+    /**
+     * @param proj
+     */
+
+    public JCRSDynFieldComponent(DynField definition, ValueField value, boolean writeable)
+        throws ServiceException {
+        super(definition, value, writeable);
+    }
+    /*
+     * (non-Javadoc)
+     * 
+     * @see
+     * 
+     * org.gvsig.tools.swing.api.dynobject.dynfield.JDynFieldComponent#saveStatus
+     * ()
+     */
+    public void saveStatus() {
+    	if (isValid()){
+        	setFieldValue(this.getValue());    		
+    	}
+    }
+
+    /*
+     * (non-Javadoc)
+     * 
+     * @see org.gvsig.tools.swing.api.dynobject.dynfield.ValueField#getValue()
+     */
+    public Object getValue() {
+        return this.getCurProj();
+    }
+
+    /*
+     * (non-Javadoc)
+     * 
+     * @see
+     * org.gvsig.tools.swing.api.dynobject.dynfield.ValueField#setNullValue(java
+     * .lang.Object)
+     */
+    public void setNullValue() {
+        this.setCurProj(null);
+    }
+
+    public void setNonNullValue(Object value) {
+        if (value instanceof IProjection) {
+            setCurProj((IProjection) value);
+        } else {
+            setNullValue();
+        }
+    }
+
+    public void setCurProj(IProjection projection) {
+        panel.setCurProj(projection);
+        this.fireValueChangedEvent();
+    }
+
+    public IProjection getCurProj() {
+        return panel.getCurProj();
+    }
+
+    /*
+     * (non-Javadoc)
+     * 
+     * @see
+     * org.gvsig.tools.swing.api.dynobject.dynfield.JComponent#getComponent()
+     */
+    public Object getComponent() {
+        return panel;
+    }
+
+    @Override
+    protected void setJDynFieldComponentListeners() {
+
+    }
+    
+    public void setValue(Object value){
+    	Object oldValue = getValue();
+    	if (value == null){
+    		setNullValue();
+    	}else{
+    		setNonNullValue(value);
+    	}
+    	if (oldValue!=value){
+        	this.fireValueChangedEvent();    		
+    	}
+    }
+
+    @Override
+    protected void afterUI() {
+        this.panel.getJLabel().setVisible(false);
+    }
+
+    @Override
+    protected void initData() {
+    }
+
+    @Override
+    protected void initUI() {
+        IProjection proj = (IProjection) this.getFieldValue();
+        if (proj==null){
+            proj = (IProjection) this.getDefaultFieldValue();
+        }
+        panel = initJPanelProj(proj);
+    }
+
+    protected void setReadOnly() {
+        this.button.setVisible(false);
+    }
+
+    public void requestFocus() {
+        this.panel.requestFocus();
+    }
+
+    public void setEnabled(boolean isEnabled) {
+        this.panel.setEnabled(isEnabled);
+    }
+
+    public void actionPerformed(ActionEvent e) {
+        setValue(panel.getCurProj());
+    }
+
+
+    public WindowInfo getWindowInfo() {
+        WindowInfo m_ViewInfo =
+            new WindowInfo(WindowInfo.MODALDIALOG | WindowInfo.RESIZABLE);
+        m_ViewInfo.setTitle(PluginServices.getText(this, "acerca_de"));
+
+        return m_ViewInfo;
+    }
+
+    public Object getWindowProfile() {
+        return WindowInfo.DIALOG_PROFILE;
+    }
+
+    public JComponent asJComponent() {
+        return panel;
+    }
+    
+    /**
+     * This method initializes jPanel4
+     *
+     * @return javax.swing.JPanel
+     */
+    private CRSSelectPanel initJPanelProj(IProjection proj) {
+        if (panel == null) {
+            panel = CRSSelectPanel.getPanel(proj);
+            panel.setTransPanelActive(true);
+            panel.setPreferredSize(new java.awt.Dimension(330,35));
+            panel.addActionListener(new java.awt.event.ActionListener() {
+                public void actionPerformed(java.awt.event.ActionEvent e) {
+                    if (panel.isOkPressed()) {
+                        setValue(panel.getCurProj());
+                        fireValueChangedEvent();
+                    }
+                }
+            });
+        }
+        return panel;
+    }
+    
+	@Override
+	public boolean isValid() {
+		return this.getValue()!=null;
+	}
+
+}
Index: tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/app/tools/swing/serv/field/crs/JCRSDynFieldComponentFactory.java
===================================================================
--- tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/app/tools/swing/serv/field/crs/JCRSDynFieldComponentFactory.java	(revision 0)
+++ tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/app/tools/swing/serv/field/crs/JCRSDynFieldComponentFactory.java	(revision 38653)
@@ -0,0 +1,100 @@
+package org.gvsig.app.tools.swing.serv.field.crs;
+
+/* gvSIG. Geographic Information System of the Valencian Government
+ *
+ * Copyright (C) 2007-2008 Infrastructures and Transports Department
+ * of the Valencian Government (CIT)
+ * 
+ * This program is free software; you can redistribute it and/or
+ * modify it under the terms of the GNU General Public License
+ * as published by the Free Software Foundation; either version 2
+ * of the License, or (at your option) any later version.
+ * 
+ * This program is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
+ * GNU General Public License for more details.
+ * 
+ * You should have received a copy of the GNU General Public License
+ * along with this program; if not, write to the Free Software
+ * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, 
+ * MA  02110-1301, USA.
+ * 
+ */
+/*
+ * AUTHORS (In addition to CIT):
+ * 2010 Institute of New Imaging Technologies (INIT): 
+ *   http://www.init.uji.es
+ * Geographic Information research group: 
+ *   http://www.geoinfo.uji.es
+ * Universitat Jaume I, Spain
+ */
+
+/**
+ * 
+ */
+
+import org.gvsig.fmap.dal.DataTypes;
+import org.gvsig.tools.dynobject.DynField;
+import org.gvsig.tools.service.ServiceException;
+import org.gvsig.tools.swing.api.dynobject.dynfield.JDynFieldComponent;
+import org.gvsig.tools.swing.api.dynobject.dynfield.JDynFieldComponentFactory;
+import org.gvsig.tools.swing.api.dynobject.dynfield.ValueField;
+import org.gvsig.tools.swing.spi.AbstractJDynFieldComponentFactory;
+
+/**
+ * @author <a href="mailto:reinhold@uji.es">cmartin</a>
+ * 
+ */
+public class JCRSDynFieldComponentFactory extends
+    AbstractJDynFieldComponentFactory implements JDynFieldComponentFactory {
+
+    /*
+     * (non-Javadoc)
+     * 
+     * @see
+     * org.gvsig.tools.swing.spi.AbstractSwingServiceFactory#getFactoryDescription
+     * ()
+     */
+    @Override
+    public String getFactoryDescription() {
+        return null;
+    }
+
+    /*
+     * (non-Javadoc)
+     * 
+     * @see
+     * org.gvsig.tools.swing.spi.AbstractSwingServiceFactory#getFactorySubType()
+     */
+    @Override
+    public String getFactorySubType() {
+        return null;
+    }
+
+    /*
+     * (non-Javadoc)
+     * 
+     * @see
+     * org.gvsig.tools.swing.spi.AbstractSwingServiceFactory#getFactoryType()
+     */
+    @Override
+    public Integer getFactoryType() {
+        return DataTypes.CRS;
+    }
+
+    /*
+     * (non-Javadoc)
+     * 
+     * @see
+     * org.gvsig.tools.swing.api.dynobject.dynfield.JDynFieldComponentFactory
+     * #createJDynFieldComponent(org.gvsig.tools.dynobject.DynField,
+     * org.gvsig.tools.swing.api.dynobject.dynfield.ValueField)
+     */
+    public JDynFieldComponent createJDynFieldComponent(DynField definition, ValueField valueField,
+        boolean writable) throws ServiceException {
+        // TODO: take into account the writable flag
+        return new JCRSDynFieldComponent(definition, valueField, writable);
+    }
+
+}
Index: tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/app/gui/panels/TextFieldEdit.java
===================================================================
--- tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/app/gui/panels/TextFieldEdit.java	(revision 0)
+++ tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/app/gui/panels/TextFieldEdit.java	(revision 38653)
@@ -0,0 +1,123 @@
+package org.gvsig.app.gui.panels;
+
+import java.awt.Dimension;
+import java.awt.event.KeyEvent;
+import java.awt.event.KeyListener;
+import java.awt.geom.Point2D;
+
+import javax.swing.BorderFactory;
+import javax.swing.FocusManager;
+import javax.swing.JComponent;
+import javax.swing.JPopupMenu;
+import javax.swing.JTextField;
+
+
+/**
+ * DOCUMENT ME!
+ *
+ * @author Vicente Caballero Navarro
+ */
+//TODO comentado para que compile
+public class TextFieldEdit extends JPopupMenu implements KeyListener {
+    private JTextField txt = new JTextField();
+//    private FLyrAnnotation lyr;
+    /**
+     * This is the default constructor
+     */
+//    public TextFieldEdit(FLyrAnnotation lyr) {
+//        super();
+//        this.lyr=lyr;
+//        initialize();
+//    }
+
+    /**
+     * This method initializes this
+     */
+    private void initialize() {
+        this.setSize(100, 20);
+        txt.setPreferredSize(new Dimension(100, 20));
+//        txt.addActionListener(new java.awt.event.ActionListener() {
+//        	public void actionPerformed(java.awt.event.ActionEvent e) {
+//        		 try {
+//        				VectorialEditableAdapter vea=(VectorialEditableAdapter)lyr.getSource();
+//        				int index=lyr.getInEdition();
+//        				IRowEdited row = vea.getRow(index); //.getAttribute(columnIndex);
+//        		        Value[] values = row.getAttributes();
+//        		        int columnText=lyr.getMapping().getColumnText();
+//        		        int type=vea.getRecordset().getFieldType(columnText);
+//        		        values[columnText] = ValueFactory.createValueByType(txt.getText(),type);
+//
+//        		        IRow newRow = null;
+//
+//        		        if (row.getLinkedRow() instanceof IFeature) {
+//        		            IGeometry geometry = ((DefaultFeature) row.getLinkedRow()).getGeometry();
+//        		            newRow = new DefaultFeature(geometry, values);
+//        		        } else {
+//        		            newRow = new DefaultRow(values);
+//        		        }
+//
+//
+//        					vea.modifyRow(index, newRow,"Editar valor de texto", EditionEvent.GRAPHIC);
+//        				} catch (ReadDriverException e1) {
+//        					e1.printStackTrace();
+//        				}  catch (ParseException e1) {
+//							e1.printStackTrace();
+//						} catch (NumberFormatException e1) {
+//							NotificationManager.addError("no_es_de_tipo_numerico",e1);
+//						} catch (ValidateRowException e1) {
+//							e1.printStackTrace();
+//						}
+//        				View view=(View)PluginServices.getMDIManager().getActiveWindow();
+//        				TextFieldEdit.this.show(false);
+//        				// view.getMapControl().drawMap(true);
+//        				lyr.setDirty(true);
+//        				view.getMapControl().rePaintDirtyLayers();
+//
+//        				PluginServices.getMainFrame().enableControls();
+//        	}
+//        });
+        this.add(txt);
+        this.setBorderPainted(false);
+        this.setBorder(BorderFactory.createEmptyBorder());
+    }
+
+    /**
+     * DOCUMENT ME!
+     *
+     * @param p DOCUMENT ME!
+     * @param component DOCUMENT ME!
+     */
+    public void show(Point2D p, JComponent component) {
+
+//    	VectorialEditableAdapter vea=(VectorialEditableAdapter)lyr.getSource();
+//		int index=lyr.getInEdition();
+//		Value value=null;
+//		try {
+//			int columnText=lyr.getMapping().getColumnText();
+//			value = vea.getRecordset().getFieldValue(index,columnText);
+//			txt.setText(value.toString());
+//		} catch (ReadDriverException e) {
+//			e.printStackTrace();
+//		}
+
+		this.show(component, (int)p.getX(), (int)p.getY()-20);
+        FocusManager fm = FocusManager.getCurrentManager();
+        fm.focusPreviousComponent(txt);
+    }
+
+	public void keyPressed(KeyEvent arg0) {
+		// TODO Auto-generated method stub
+
+	}
+
+	public void keyReleased(KeyEvent arg0) {
+		 FocusManager fm = FocusManager.getCurrentManager();
+	     fm.focusPreviousComponent(txt);
+	}
+
+	public void keyTyped(KeyEvent arg0) {
+		// TODO Auto-generated method stub
+
+	}
+
+}

Property changes on: tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/app/gui/panels/TextFieldEdit.java
___________________________________________________________________
Added: svn:keywords
   + Author Date Id Revision
Added: svn:eol-style
   + native

Index: tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/app/gui/panels/FPanelAbout.java
===================================================================
--- tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/app/gui/panels/FPanelAbout.java	(revision 0)
+++ tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/app/gui/panels/FPanelAbout.java	(revision 38653)
@@ -0,0 +1,254 @@
+/*
+ * Created on 02-sep-2004
+ *
+ * TODO To change the template for this generated file go to
+ * Window - Preferences - Java - Code Generation - Code and Comments
+ */
+/* gvSIG. Sistema de Informaci�n Geogr�fica de la Generalitat Valenciana
+ *
+ * Copyright (C) 2004 IVER T.I. and Generalitat Valenciana.
+ *
+ * This program is free software; you can redistribute it and/or
+ * modify it under the terms of the GNU General Public License
+ * as published by the Free Software Foundation; either version 2
+ * of the License, or (at your option) any later version.
+ *
+ * This program is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
+ * GNU General Public License for more details.
+ *
+ * You should have received a copy of the GNU General Public License
+ * along with this program; if not, write to the Free Software
+ * Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA  02111-1307,USA.
+ *
+ * For more information, contact:
+ *
+ *  Generalitat Valenciana
+ *   Conselleria d'Infraestructures i Transport
+ *   Av. Blasco Ib��ez, 50
+ *   46010 VALENCIA
+ *   SPAIN
+ *
+ *      +34 963862235
+ *   gvsig@gva.es
+ *      www.gvsig.gva.es
+ *
+ *    or
+ *
+ *   IVER T.I. S.A
+ *   Salamanca 50
+ *   46005 Valencia
+ *   Spain
+ *
+ *   +34 963163400
+ *   dac@iver.es
+ */
+package org.gvsig.app.gui.panels;
+
+import java.awt.BorderLayout;
+import java.io.FileNotFoundException;
+import java.io.IOException;
+import java.net.URL;
+
+import javax.swing.JButton;
+import javax.swing.JDialog;
+import javax.swing.JEditorPane;
+import javax.swing.JLabel;
+import javax.swing.JPanel;
+import javax.swing.JScrollPane;
+import javax.swing.JTabbedPane;
+import javax.swing.event.HyperlinkEvent;
+
+import org.gvsig.andami.PluginServices;
+import org.gvsig.andami.ui.mdiManager.IWindow;
+import org.gvsig.andami.ui.mdiManager.WindowInfo;
+import org.gvsig.app.extension.Version;
+import org.gvsig.utils.BrowserControl;
+import org.slf4j.Logger;
+import org.slf4j.LoggerFactory;
+
+/**
+ * @author FJP
+ *
+ * A Window with panels showing web pages. A developer
+ * can write a web page with information about his/her plugin
+ * and call addAboutUrl to add his/her about to gvSIG's about and
+ * others.
+ * 
+ * @deprecated see the AboutManager
+ */
+public class FPanelAbout extends JPanel implements IWindow {
+    private static final Logger logger = LoggerFactory
+    .getLogger(FPanelAbout.class);
+    
+	private JEditorPane jEditorPane = null;
+	private JScrollPane jScrollPane = null;
+	private JEditorPane jEditorPane1 = null;
+	private JPanel jPanel = null;
+	private JButton jButton = null;
+
+	private JLabel jLblVersion = null;
+	private JLabel jLblJavaVersion = null;
+    private JTabbedPane jTabbedPane = null;
+	/**
+	 * This is the default constructor
+	 * @throws FileNotFoundException
+	 */
+	public FPanelAbout(){
+		super();
+		initialize();
+	}
+	/**
+	 * This method initializes this
+	 *
+	 * @return void
+	 * @throws FileNotFoundException
+	 */
+	private  void initialize(){
+		this.setLayout(new BorderLayout());
+		this.setSize(600, 450);
+		this.add(getJTabbedPane(), java.awt.BorderLayout.CENTER);
+
+		this.add(getJPanel(), java.awt.BorderLayout.SOUTH);
+	}
+
+	/**
+	 * This method initializes jScrollPane
+	 *
+	 * @return javax.swing.JScrollPane
+	 */
+	private JScrollPane getJScrollPane(URL url) {
+		// if (jScrollPane == null) {
+			jScrollPane = new JScrollPane();
+			jScrollPane.setPreferredSize(new java.awt.Dimension(300,400));
+			jScrollPane.setViewportView(getJEditorPane(url));
+		// }
+		return jScrollPane;
+	}
+	/**
+	 * This method initializes jEditorPane1
+	 *
+	 * @return javax.swing.JEditorPane
+	 */
+		private JEditorPane getJEditorPane(URL aboutURL) {
+			// if (jEditorPane == null) {
+				jEditorPane = new JEditorPane();
+
+				jEditorPane.setEditable(false);
+				jEditorPane.setContentType("text/html");
+				jEditorPane.setPreferredSize(new java.awt.Dimension(300,200));
+
+				if (aboutURL != null) {
+				    try {
+				    	jEditorPane.setPage(aboutURL);
+				    	jEditorPane.addHyperlinkListener(new javax.swing.event.HyperlinkListener() {
+				    		public void hyperlinkUpdate(javax.swing.event.HyperlinkEvent e) {
+				    			if (e.getEventType() == HyperlinkEvent.EventType.ACTIVATED)
+				    			{
+				    	 		      JEditorPane pane = (JEditorPane) e.getSource();
+				    	 		      System.out.println("hyperlinkUpdate()"); // TODO Auto-generated Event stub hyperlinkUpdate()
+				    	 		      BrowserControl.displayURL(e.getURL().toString());
+				    	 		      // if (e instanceof HTMLFrameHyperlinkEvent) {
+				    			}
+
+
+				    		}
+				    	});
+				    } catch (IOException e) {
+				        System.err.println("Attempted to read a bad URL: " + aboutURL);
+				    }
+				} else {
+				    System.err.println("Couldn't find file: about.html" + aboutURL.getPath());
+				}
+
+			// }
+			return jEditorPane;
+		}
+	/**
+	 * This method initializes jPanel
+	 *
+	 * @return javax.swing.JPanel
+	 */
+	private JPanel getJPanel() {
+		if (jPanel == null) {
+			jLblVersion = new JLabel();
+			jLblJavaVersion = new JLabel();
+			jPanel = new JPanel();
+			jPanel.setLayout(null);
+			jPanel.setPreferredSize(new java.awt.Dimension(10,50));
+			jLblVersion.setBounds(10, 16, 205, 17);
+			jLblVersion.setText("Version "+Version.longFormat());
+			jLblJavaVersion.setBounds(415, 16, 150, 17);
+			jLblJavaVersion.setText("Java "+System.getProperties().get("java.version"));
+			jPanel.add(getJButton(), null);
+			jPanel.add(jLblVersion, null);
+			jPanel.add(jLblJavaVersion, null);
+		}
+		return jPanel;
+	}
+	/**
+	 * This method initializes jButton
+	 *
+	 * @return javax.swing.JButton
+	 */
+	private JButton getJButton() {
+		if (jButton == null) {
+			jButton = new JButton();
+			jButton.setHorizontalTextPosition(javax.swing.SwingConstants.CENTER);
+			jButton.setText(PluginServices.getText(this,"Cerrar"));
+			jButton.setBounds(266, 12, 94, 25);
+			jButton.addActionListener(new java.awt.event.ActionListener() {
+				public void actionPerformed(java.awt.event.ActionEvent e) {
+					System.out.println("actionPerformed()"); // TODO Auto-generated Event stub actionPerformed()
+					if (PluginServices.getMainFrame() != null)
+					{
+						PluginServices.getMDIManager().closeWindow(FPanelAbout.this);
+					}
+					else
+					{
+						((JDialog) (getParent().getParent().getParent().getParent())).dispose();
+					}
+
+				}
+			});
+		}
+		return jButton;
+	}
+	/* (non-Javadoc)
+	 * @see com.iver.mdiApp.ui.MDIManager.View#getViewInfo()
+	 */
+	public WindowInfo getWindowInfo() {
+		WindowInfo m_ViewInfo = new WindowInfo(WindowInfo.MODALDIALOG|WindowInfo.RESIZABLE);
+		m_ViewInfo.setTitle(PluginServices.getText(this,"acerca_de"));
+
+		return m_ViewInfo;
+	}
+	/* (non-Javadoc)
+	 * @see com.iver.mdiApp.ui.MDIManager.View#viewActivated()
+	 */
+	public void viewActivated() {
+		// TODO Auto-generated method stub
+
+	}
+    public void addAboutUrl(String pluginName, URL url)
+    {
+        getJTabbedPane().addTab(pluginName, getJScrollPane(url));
+        // this.add(getJScrollPane(url), java.awt.BorderLayout.CENTER);
+    }
+    /**
+     * This method initializes jTabbedPane
+     *
+     * @return javax.swing.JTabbedPane
+     */
+    private JTabbedPane getJTabbedPane() {
+    	if (jTabbedPane == null) {
+    		jTabbedPane = new JTabbedPane();
+    		jTabbedPane.setPreferredSize(new java.awt.Dimension(5,50));
+    	}
+    	return jTabbedPane;
+    }
+	public Object getWindowProfile() {
+		return WindowInfo.DIALOG_PROFILE;
+	}
+}  //  @jve:decl-index=0:visual-constraint="10,10"

Property changes on: tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/app/gui/panels/FPanelAbout.java
___________________________________________________________________
Added: svn:eol-style
   + native
Added: svn:keywords
   + Author Date Id Revision

Index: tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/app/gui/panels/MappingFieldsToAnotation.java
===================================================================
--- tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/app/gui/panels/MappingFieldsToAnotation.java	(revision 0)
+++ tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/app/gui/panels/MappingFieldsToAnotation.java	(revision 38653)
@@ -0,0 +1,396 @@
+package org.gvsig.app.gui.panels;
+
+import javax.swing.ButtonGroup;
+import javax.swing.JButton;
+import javax.swing.JComboBox;
+import javax.swing.JLabel;
+import javax.swing.JPanel;
+import javax.swing.JRadioButton;
+import javax.swing.JTextField;
+
+import org.gvsig.andami.PluginServices;
+import org.gvsig.andami.ui.mdiManager.IWindow;
+import org.gvsig.andami.ui.mdiManager.WindowInfo;
+import org.gvsig.fmap.mapcontext.layers.MappingAnnotation;
+
+
+//TODO comentado para que compile
+public class MappingFieldsToAnotation extends JPanel implements IWindow{
+
+	private JComboBox cmbText = null;
+	private JComboBox cmbAngle = null;
+	private JLabel jLabel = null;
+	private JLabel jLabel1 = null;
+	private JLabel jLabel2 = null;
+	private JComboBox cmbColor = null;
+	private JLabel jLabel3 = null;
+	private JComboBox cmbHeight = null;
+	private JLabel jLabel4 = null;
+	private JComboBox cmbFont = null;
+	private JButton bOk = null;
+	private JButton bCancel = null;
+//	private SelectableDataSource sds=null;
+//	private FLyrAnnotation la;
+	private int[] mapText;
+	private int[] mapAngle;
+	private int[] mapColor;
+	private int[] mapHeight;
+	private int[] mapFont;
+	private JPanel jPanel = null;
+	private JLabel jLabel5 = null;
+	private JTextField txtName = null;
+	//private JCheckBox chbPixels = null;
+	private JRadioButton rbMapUnits = null;
+	private JRadioButton rbPixels = null;
+	private boolean isOk=false;
+	/**
+	 * This is the default constructor
+	 */
+//	public MappingFieldsToAnotation(FLyrAnnotation la) {
+//		super();
+//		this.la=la;
+//		try {
+//			this.sds=la.getRecordset();
+//			initialize();
+//		} catch (ReadDriverException e) {
+//			e.printStackTrace();
+//		}
+//
+//	}
+
+	/**
+	 * This method initializes this
+	 *
+	 * @return void
+	 */
+	private void initialize() {
+		jLabel4 = new JLabel();
+		jLabel4.setBounds(new java.awt.Rectangle(15,259,166,20));
+		jLabel4.setText("fuente");
+		jLabel3 = new JLabel();
+		jLabel3.setBounds(new java.awt.Rectangle(15,197,166,20));
+		jLabel3.setText("alto");
+		jLabel2 = new JLabel();
+		jLabel2.setBounds(new java.awt.Rectangle(15,135,166,20));
+		jLabel2.setText("color");
+		jLabel1 = new JLabel();
+		jLabel1.setBounds(new java.awt.Rectangle(15,73,166,20));
+		jLabel1.setText("angulo");
+		jLabel = new JLabel();
+		jLabel.setBounds(new java.awt.Rectangle(15,11,166,20));
+		jLabel.setText("texto");
+		this.setLayout(null);
+		this.setSize(544, 368);
+		this.add(getCmbText(), null);
+		this.add(getCmbAngle(), null);
+		this.add(jLabel, null);
+		this.add(jLabel1, null);
+		this.add(jLabel2, null);
+		this.add(getCmbColor(), null);
+		this.add(jLabel3, null);
+		this.add(getCmbHeight(), null);
+		this.add(jLabel4, null);
+		this.add(getCmbFont(), null);
+		this.add(getBOk(), null);
+		this.add(getBCancel(), null);
+		this.add(getJPanel(), null);
+	}
+
+	public WindowInfo getWindowInfo() {
+		WindowInfo m_viewinfo = new WindowInfo(WindowInfo.MODALDIALOG);
+		m_viewinfo.setTitle(PluginServices.getText(this,
+				"indexar_campos"));
+
+		return m_viewinfo;
+	}
+
+	/**
+	 * This method initializes cmbOrigin
+	 *
+	 * @return javax.swing.JComboBox
+	 */
+	private JComboBox getCmbText() {
+		if (cmbText == null) {
+			cmbText = new JComboBox();
+//			try {
+//				mapText=new int[sds.getFieldCount()];
+//				int num=-1;
+//				for (int i = 0; i < sds.getFieldCount(); i++) {
+//					cmbText.addItem(sds.getFieldName(i));
+//					num++;
+//					mapText[i]=num;
+//				}
+//				//cmbText.addItem("- Defaulf -");
+//			} catch (ReadDriverException e) {
+//				e.printStackTrace();
+//			}
+			cmbText.setBounds(new java.awt.Rectangle(15,42,166,20));
+
+		}
+		return cmbText;
+	}
+
+	/**
+	 * This method initializes cmbEnd
+	 *
+	 * @return javax.swing.JComboBox
+	 */
+	private JComboBox getCmbAngle() {
+		if (cmbAngle == null) {
+			cmbAngle = new JComboBox();
+//			try {
+//				mapAngle=new int[sds.getFieldCount()];
+//				int num=-1;
+//			for (int i = 0; i < sds.getFieldCount(); i++) {
+//				if (sds.getFieldType(i) == Types.DOUBLE){
+//					cmbAngle.addItem(sds.getFieldName(i));
+//					num++;
+//					mapAngle[i]=num;
+//				}
+//			}
+//			cmbAngle.addItem("- Default -");
+//			cmbAngle.setSelectedItem("- Default -");
+//			} catch (ReadDriverException e) {
+//				e.printStackTrace();
+//			}
+			cmbAngle.setBounds(new java.awt.Rectangle(15,104,166,20));
+		}
+		return cmbAngle;
+	}
+
+	/**
+	 * This method initializes cmbColor
+	 *
+	 * @return javax.swing.JComboBox
+	 */
+	private JComboBox getCmbColor() {
+		if (cmbColor == null) {
+			cmbColor = new JComboBox();
+			cmbColor.setBounds(new java.awt.Rectangle(15,166,166,20));
+//			try {
+//				mapColor=new int[sds.getFieldCount()];
+//				int num=-1;
+//				for (int i = 0; i < sds.getFieldCount(); i++) {
+//					if (sds.getFieldType(i) == Types.DOUBLE){
+//						cmbColor.addItem(sds.getFieldName(i));
+//						num++;
+//						mapColor[i]=num;
+//					}
+//				}
+//				cmbColor.addItem("- Default -");
+//				cmbColor.setSelectedItem("- Default -");
+//			} catch (ReadDriverException e) {
+//				e.printStackTrace();
+//			}
+		}
+		return cmbColor;
+	}
+
+	/**
+	 * This method initializes cmbHeight
+	 *
+	 * @return javax.swing.JComboBox
+	 */
+	private JComboBox getCmbHeight() {
+		if (cmbHeight == null) {
+			cmbHeight = new JComboBox();
+//			try {
+//				mapHeight=new int[sds.getFieldCount()];
+//				int num=-1;
+//				for (int i = 0; i < sds.getFieldCount(); i++) {
+//					if (sds.getFieldType(i) == Types.DOUBLE){
+//						cmbHeight.addItem(sds.getFieldName(i));
+//						num++;
+//						mapHeight[i]=num;
+//					}
+//				}
+//				cmbHeight.addItem("- Default -");
+//				cmbHeight.setSelectedItem("- Default -");
+//			} catch (ReadDriverException e) {
+//				e.printStackTrace();
+//			}
+			cmbHeight.setBounds(new java.awt.Rectangle(15,228,166,20));
+		}
+		return cmbHeight;
+	}
+
+	/**
+	 * This method initializes cmbFont
+	 *
+	 * @return javax.swing.JComboBox
+	 */
+	private JComboBox getCmbFont() {
+		if (cmbFont == null) {
+			cmbFont = new JComboBox();
+//			try {
+//				mapFont=new int[sds.getFieldCount()];
+//				int num=-1;
+//				for (int i = 0; i < sds.getFieldCount(); i++) {
+//					if (sds.getFieldType(i) == Types.VARCHAR){
+//						cmbFont.addItem(sds.getFieldName(i));
+//						num++;
+//						mapFont[i]=num;
+//					}
+//				}
+//				cmbFont.addItem("- Default -");
+//				cmbFont.setSelectedItem("- Default -");
+//			} catch (ReadDriverException e) {
+//				e.printStackTrace();
+//			}
+			cmbFont.setBounds(new java.awt.Rectangle(15,290,166,20));
+		}
+		return cmbFont;
+	}
+
+	/**
+	 * This method initializes bOk
+	 *
+	 * @return javax.swing.JButton
+	 */
+	private JButton getBOk() {
+		if (bOk == null) {
+			bOk = new JButton();
+			bOk.setBounds(new java.awt.Rectangle(119,326,92,24));
+			bOk.setText("Aceptar");
+			bOk.addActionListener(new java.awt.event.ActionListener() {
+				public void actionPerformed(java.awt.event.ActionEvent e) {
+					MappingAnnotation mapping=new MappingAnnotation();
+					if (getCmbText().getSelectedItem().equals("")) {
+						mapping.setColumnText(-1);
+					} else {
+						mapping.setColumnText(mapText[getCmbText().getSelectedIndex()]);
+					}
+					if (!getCmbAngle().getSelectedItem().equals("- Default -")) {
+						mapping.setColumnRotate(mapAngle[getCmbAngle().getSelectedIndex()]);
+					}
+					if (!getCmbColor().getSelectedItem().equals("- Default -")) {
+						mapping.setColumnColor(mapColor[getCmbColor().getSelectedIndex()]);
+					}
+					if (!getCmbHeight().getSelectedItem().equals("- Default -")) {
+						mapping.setColumnHeight(mapHeight[getCmbHeight().getSelectedIndex()]);
+					}
+					if (!getCmbFont().getSelectedItem().equals("- Default -")) {
+						mapping.setColumnTypeFont(mapFont[getCmbFont().getSelectedIndex()]);
+					}
+					//Falta el estilo, si es necesario.
+//					la.setInPixels(rbPixels.isSelected());
+//					la.setMapping(mapping);
+//					la.setName(getTxtName().getText());
+					isOk=true;
+					PluginServices.getMDIManager().closeWindow(MappingFieldsToAnotation.this);
+				}
+			});
+		}
+		return bOk;
+	}
+
+	/**
+	 * This method initializes bCancel
+	 *
+	 * @return javax.swing.JButton
+	 */
+	private JButton getBCancel() {
+		if (bCancel == null) {
+			bCancel = new JButton();
+			bCancel.setBounds(new java.awt.Rectangle(330,325,93,25));
+			bCancel.setText("cancelar");
+			bCancel.addActionListener(new java.awt.event.ActionListener() {
+				public void actionPerformed(java.awt.event.ActionEvent e) {
+					isOk=false;
+					PluginServices.getMDIManager().closeWindow(MappingFieldsToAnotation.this);
+				}
+			});
+		}
+		return bCancel;
+	}
+
+	/**
+	 * This method initializes jPanel
+	 *
+	 * @return javax.swing.JPanel
+	 */
+	private JPanel getJPanel() {
+		if (jPanel == null) {
+			jLabel5 = new JLabel();
+			jLabel5.setBounds(new java.awt.Rectangle(15,10,228,22));
+			jLabel5.setText("nombre");
+			jPanel = new JPanel();
+			jPanel.setLayout(null);
+			jPanel.setBounds(new java.awt.Rectangle(234,14,251,141));
+			jPanel.add(jLabel5, null);
+			jPanel.add(getTxtName(), null);
+			//jPanel.add(getChbPixels(), null);
+			jPanel.add(getRbMapUnits(), null);
+			jPanel.add(getRbPixels(), null);
+			ButtonGroup bg=new ButtonGroup();
+			bg.add(getRbMapUnits());
+			bg.add(getRbPixels());
+		}
+		return jPanel;
+	}
+
+	/**
+	 * This method initializes txtName
+	 *
+	 * @return javax.swing.JTextField
+	 */
+	private JTextField getTxtName() {
+		if (txtName == null) {
+			txtName = new JTextField();
+			//txtName.setText(la.get.getName());
+			txtName.setBounds(new java.awt.Rectangle(15,42,227,22));
+		}
+		return txtName;
+	}
+
+	/**
+	 * This method initializes chbPixels
+	 *
+	 * @return javax.swing.JCheckBox
+	 */
+	/*private JCheckBox getChbPixels() {
+		if (chbPixels == null) {
+			chbPixels = new JCheckBox();
+			chbPixels.setBounds(new java.awt.Rectangle(15,138,226,25));
+			chbPixels.setText("pixels");
+		}
+		return chbPixels;
+	}
+*/
+	/**
+	 * This method initializes rbMapUnits
+	 *
+	 * @return javax.swing.JRadioButton
+	 */
+	private JRadioButton getRbMapUnits() {
+		if (rbMapUnits == null) {
+			rbMapUnits = new JRadioButton();
+			rbMapUnits.setBounds(new java.awt.Rectangle(15,74,167,22));
+			rbMapUnits.setText("unidades_mapa");
+		}
+		return rbMapUnits;
+	}
+
+	/**
+	 * This method initializes rbPixels
+	 *
+	 * @return javax.swing.JRadioButton
+	 */
+	private JRadioButton getRbPixels() {
+		if (rbPixels == null) {
+			rbPixels = new JRadioButton();
+			rbPixels.setBounds(new java.awt.Rectangle(15,106,167,22));
+			rbPixels.setText("pixels");
+			rbPixels.setSelected(true);
+		}
+		return rbPixels;
+	}
+
+	public boolean isOk() {
+		return isOk;
+	}
+
+	public Object getWindowProfile() {
+		return WindowInfo.DIALOG_PROFILE;
+	}
+}  //  @jve:decl-index=0:visual-constraint="-150,10"

Property changes on: tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/app/gui/panels/MappingFieldsToAnotation.java
___________________________________________________________________
Added: svn:keywords
   + Author Date Id Revision
Added: svn:eol-style
   + native

Index: tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/app/gui/panels/CRSSelectPanel.java
===================================================================
--- tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/app/gui/panels/CRSSelectPanel.java	(revision 0)
+++ tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/app/gui/panels/CRSSelectPanel.java	(revision 38653)
@@ -0,0 +1,141 @@
+/* gvSIG. Sistema de Informaci�n Geogr�fica de la Generalitat Valenciana
+ *
+ * Copyright (C) 2006 IVER T.I. and Generalitat Valenciana.
+ *
+ * This program is free software; you can redistribute it and/or
+ * modify it under the terms of the GNU General Public License
+ * as published by the Free Software Foundation; either version 2
+ * of the License, or (at your option) any later version.
+ *
+ * This program is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
+ * GNU General Public License for more details.
+ *
+ * You should have received a copy of the GNU General Public License
+ * along with this program; if not, write to the Free Software
+ * Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA  02111-1307,USA.
+ *
+ * For more information, contact:
+ *
+ *  Generalitat Valenciana
+ *   Conselleria d'Infraestructures i Transport
+ *   Av. Blasco Ib��ez, 50
+ *   46010 VALENCIA
+ *   SPAIN
+ *
+ *      +34 963862235
+ *   gvsig@gva.es
+ *      www.gvsig.gva.es
+ *
+ *    or
+ *
+ *   IVER T.I. S.A
+ *   Salamanca 50
+ *   46005 Valencia
+ *   Spain
+ *
+ *   +34 963163400
+ *   dac@iver.es
+ */
+package org.gvsig.app.gui.panels;
+
+import java.awt.event.ActionListener;
+import java.lang.reflect.InvocationTargetException;
+
+import javax.swing.JLabel;
+import javax.swing.JPanel;
+
+import org.cresques.cts.IProjection;
+import org.gvsig.andami.PluginServices;
+import org.gvsig.app.gui.panels.crs.CrsUIFactory;
+import org.gvsig.app.gui.panels.crs.ICrsUIFactory;
+import org.gvsig.app.gui.panels.crs.ISelectCRSButton;
+import org.gvsig.app.gui.panels.crs.ISelectCrsPanel;
+import org.gvsig.app.project.documents.view.info.gui.CSSelectionDialog;
+import org.gvsig.gui.beans.swing.JButton;
+
+
+/**
+ * 
+ * @author Luis W. Sevilla <sevilla_lui@gva.es>
+ */
+public abstract class CRSSelectPanel extends JPanel 
+   implements ISelectCRSButton {
+	private static Class panelClass = ProjChooserPanel.class;
+	private static Class uiFactory = CrsUIFactory.class;
+	private boolean transPanelActive = false;
+
+	protected ActionListener actionListener = null;
+	
+	public static void registerPanelClass(Class panelClass) {
+		CRSSelectPanel.panelClass = panelClass;
+	}
+
+	public static void registerUIFactory(Class uiFactory) {
+		CRSSelectPanel.uiFactory = uiFactory;
+	}
+	
+	public static CRSSelectPanel getPanel(IProjection proj) {
+		CRSSelectPanel panel = null;
+		Class [] args = {IProjection.class};
+		Object [] params = {proj};
+		try {
+			panel = (CRSSelectPanel) panelClass.getConstructor(args).newInstance(params);
+		} catch (IllegalArgumentException e) {
+			PluginServices.getLogger().error("Error creating CRS selection button", e);
+		} catch (SecurityException e) {
+			PluginServices.getLogger().error("Error creating CRS selection button", e);
+		} catch (InstantiationException e) {
+			PluginServices.getLogger().error("Error creating CRS selection button", e);
+		} catch (IllegalAccessException e) {
+			PluginServices.getLogger().error("Error creating CRS selection button", e);
+		} catch (InvocationTargetException e) {
+			PluginServices.getLogger().error("Error creating CRS selection button", e);
+		} catch (NoSuchMethodException e) {
+			PluginServices.getLogger().error("Error creating CRS selection button", e);
+		}
+		return panel;
+	}
+	
+	public CRSSelectPanel(IProjection proj) {
+		super();
+	}
+	
+	abstract public JButton getJBtnChangeProj();
+	
+	abstract public JLabel getJLabel();
+	
+	abstract public IProjection getCurProj();
+	
+	abstract public boolean isOkPressed();
+	/**
+	 * @param actionListener The actionListener to set.
+	 */
+	public void addActionListener(ActionListener actionListener) {
+		this.actionListener = actionListener;
+	}
+
+	public boolean isTransPanelActive() {
+		return transPanelActive;
+	}
+
+	public void setTransPanelActive(boolean transPanelActive) {
+		this.transPanelActive = transPanelActive;
+	}
+	
+	public static ICrsUIFactory getUIFactory() {
+		ICrsUIFactory factory;
+		try {
+			factory = (ICrsUIFactory) uiFactory.newInstance();
+		} catch (InstantiationException e) {
+			PluginServices.getLogger().error("Error creating CRS UI factory. Switching to default factory", e);
+			 factory = new CrsUIFactory();
+		} catch (IllegalAccessException e) {
+			PluginServices.getLogger().error("Error creating CRS UI factory. Switching to default factory", e);
+			factory =  new CrsUIFactory();
+		}
+		return factory;
+	}
+	
+}

Property changes on: tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/app/gui/panels/CRSSelectPanel.java
___________________________________________________________________
Added: svn:eol-style
   + native

Index: tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/app/gui/panels/crs/ICrsUIFactory.java
===================================================================
--- tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/app/gui/panels/crs/ICrsUIFactory.java	(revision 0)
+++ tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/app/gui/panels/crs/ICrsUIFactory.java	(revision 38653)
@@ -0,0 +1,7 @@
+package org.gvsig.app.gui.panels.crs;
+
+import org.cresques.cts.IProjection;
+
+public interface ICrsUIFactory {
+	public ISelectCrsPanel getSelectCrsPanel(IProjection projection, boolean isTransPanelActive);
+}
Index: tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/app/gui/panels/crs/ISelectCRSButton.java
===================================================================
--- tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/app/gui/panels/crs/ISelectCRSButton.java	(revision 0)
+++ tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/app/gui/panels/crs/ISelectCRSButton.java	(revision 38653)
@@ -0,0 +1,13 @@
+package org.gvsig.app.gui.panels.crs;
+
+import javax.swing.JButton;
+
+import org.cresques.cts.IProjection;
+
+public interface ISelectCRSButton {
+	 public boolean isTransPanelActive();
+	 public void setTransPanelActive(boolean transPanelActive);
+	 public IProjection getCurProj();
+	 public boolean isOkPressed();
+	 public void setCurProj(IProjection curProj);
+}
Index: tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/app/gui/panels/crs/CrsUIFactory.java
===================================================================
--- tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/app/gui/panels/crs/CrsUIFactory.java	(revision 0)
+++ tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/app/gui/panels/crs/CrsUIFactory.java	(revision 38653)
@@ -0,0 +1,17 @@
+package org.gvsig.app.gui.panels.crs;
+
+import org.cresques.cts.IProjection;
+import org.gvsig.app.project.documents.view.info.gui.CSSelectionDialog;
+
+
+public class CrsUIFactory implements ICrsUIFactory {
+
+
+	public ISelectCrsPanel getSelectCrsPanel(IProjection projection,
+			boolean isTransPanelActive) {
+		CSSelectionDialog panel = new CSSelectionDialog();
+		panel.setProjection(projection);
+		return panel;
+	}
+
+}
Index: tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/app/gui/panels/crs/ISelectCrsPanel.java
===================================================================
--- tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/app/gui/panels/crs/ISelectCrsPanel.java	(revision 0)
+++ tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/app/gui/panels/crs/ISelectCrsPanel.java	(revision 38653)
@@ -0,0 +1,11 @@
+package org.gvsig.app.gui.panels.crs;
+
+import org.cresques.cts.IProjection;
+import org.gvsig.andami.ui.mdiManager.IWindow;
+
+
+public interface ISelectCrsPanel extends IWindow {
+	public IProjection getProjection();
+    public void setProjection(IProjection proj);
+    public boolean isOkPressed();
+}
Index: tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/app/gui/panels/TransparencyPanel.java
===================================================================
--- tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/app/gui/panels/TransparencyPanel.java	(revision 0)
+++ tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/app/gui/panels/TransparencyPanel.java	(revision 38653)
@@ -0,0 +1,126 @@
+/*
+ * The Unified Mapping Platform (JUMP) is an extensible, interactive GUI
+ * for visualizing and manipulating spatial features with geometry and attributes.
+ *
+ * Copyright (C) 2003 Vivid Solutions
+ *
+ * This program is free software; you can redistribute it and/or
+ * modify it under the terms of the GNU General Public License
+ * as published by the Free Software Foundation; either version 2
+ * of the License, or (at your option) any later version.
+ *
+ * This program is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
+ * GNU General Public License for more details.
+ *
+ * You should have received a copy of the GNU General Public License
+ * along with this program; if not, write to the Free Software
+ * Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA  02111-1307, USA.
+ *
+ * For more information, contact:
+ *
+ * Vivid Solutions
+ * Suite #1A
+ * 2328 Government Street
+ * Victoria BC  V8T 5G5
+ * Canada
+ *
+ * (250)385-6040
+ * www.vividsolutions.com
+ */
+/* gvSIG. Sistema de Informaci�n Geogr�fica de la Generalitat Valenciana
+ *
+ * Copyright (C) 2004 IVER T.I. and Generalitat Valenciana.
+ *
+ * This program is free software; you can redistribute it and/or
+ * modify it under the terms of the GNU General Public License
+ * as published by the Free Software Foundation; either version 2
+ * of the License, or (at your option) any later version.
+ *
+ * This program is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
+ * GNU General Public License for more details.
+ *
+ * You should have received a copy of the GNU General Public License
+ * along with this program; if not, write to the Free Software
+ * Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA  02111-1307,USA.
+ *
+ * For more information, contact:
+ *
+ *  Generalitat Valenciana
+ *   Conselleria d'Infraestructures i Transport
+ *   Av. Blasco Ib��ez, 50
+ *   46010 VALENCIA
+ *   SPAIN
+ *
+ *      +34 963862235
+ *   gvsig@gva.es
+ *      www.gvsig.gva.es
+ *
+ *    or
+ *
+ *   IVER T.I. S.A
+ *   Salamanca 50
+ *   46005 Valencia
+ *   Spain
+ *
+ *   +34 963163400
+ *   dac@iver.es
+ */
+package org.gvsig.app.gui.panels;
+
+import java.awt.Color;
+import java.awt.Dimension;
+import java.awt.GridBagConstraints;
+import java.awt.GridBagLayout;
+import java.awt.Insets;
+
+import javax.swing.JPanel;
+import javax.swing.JSlider;
+
+
+public class TransparencyPanel extends JPanel {
+    JPanel opaquePanel = new JPanel();
+    JPanel transparentPanel = new JPanel();
+    GridBagLayout gridBagLayout3 = new GridBagLayout();
+    JSlider transparencySlider = new JSlider();
+
+    public TransparencyPanel() {
+    	transparencySlider.setSize(100,30);
+    	transparencySlider.setPreferredSize(new Dimension(100,30));
+        transparencySlider.setMaximum(255);
+        transparencySlider.setPreferredSize(new Dimension(100, 24));
+        setLayout(gridBagLayout3);
+        add(opaquePanel,
+            new GridBagConstraints(1, 0, 1, 1, 0.0, 0.0,
+                GridBagConstraints.CENTER, GridBagConstraints.NONE,
+                new Insets(0, 0, 0, 0), 0, 0));
+        add(transparencySlider,
+            new GridBagConstraints(2, 0, 1, 1, 0.0, 0.0,
+                GridBagConstraints.CENTER, GridBagConstraints.NONE,
+                new Insets(0, 0, 0, 0), 0, 0));
+        add(transparentPanel,
+            new GridBagConstraints(3, 0, 1, 1, 0.0, 0.0,
+                GridBagConstraints.CENTER, GridBagConstraints.NONE,
+                new Insets(0, 0, 0, 0), 0, 0));
+        opaquePanel.setBackground(Color.black);
+        opaquePanel.setMinimumSize(new Dimension(11, 11));
+        opaquePanel.setMaximumSize(new Dimension(11, 11));
+        opaquePanel.setPreferredSize(new Dimension(11, 11));
+        transparentPanel.setBackground(Color.white);
+        transparentPanel.setForeground(Color.white);
+        transparentPanel.setMaximumSize(new Dimension(11, 11));
+        transparentPanel.setMinimumSize(new Dimension(11, 11));
+        transparentPanel.setPreferredSize(new Dimension(11, 11));
+    }
+
+    public void setColor(Color color) {
+        opaquePanel.setBackground(color);
+    }
+
+    public JSlider getSlider() {
+        return transparencySlider;
+    }
+}

Property changes on: tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/app/gui/panels/TransparencyPanel.java
___________________________________________________________________
Added: svn:keywords
   + Author Date Id Revision
Added: svn:eol-style
   + native

Index: tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/app/gui/panels/PanelLinkProperties.java
===================================================================
--- tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/app/gui/panels/PanelLinkProperties.java	(revision 0)
+++ tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/app/gui/panels/PanelLinkProperties.java	(revision 38653)
@@ -0,0 +1,189 @@
+package org.gvsig.app.gui.panels;
+
+import javax.swing.DefaultComboBoxModel;
+import javax.swing.JComboBox;
+import javax.swing.JLabel;
+import javax.swing.JPanel;
+import javax.swing.JTextField;
+
+import org.gvsig.andami.PluginServices;
+import org.gvsig.app.project.documents.view.ViewDocument;
+import org.gvsig.app.project.documents.view.gui.AbstractViewPanel;
+import org.gvsig.fmap.mapcontext.layers.FLayer;
+
+
+//TODO comentado para que compile
+public class PanelLinkProperties extends JPanel {
+
+	FLayer layer=null;
+	private JPanel jPanel1 = null;
+	private JLabel jLabelCampo1 = null;
+	private JComboBox jComboBoxCampo1 = null;
+	private JLabel jLabelExtension1 = null;
+	private JTextField jTextFieldExtension1 = null;
+	private JLabel jLabelAccion1 = null;
+	private JComboBox jComboBoxAccion1 = null;
+	private ViewDocument view;
+
+	/**
+	 * This is the default constructor
+	 */
+	public PanelLinkProperties(FLayer flayer, ViewDocument vista) {
+		super();
+//		this.setLayout(new GridBagLayout());
+		this.layer=flayer;
+		view=vista;
+		initialize();
+	}
+
+	/**
+	 * This method initializes this
+	 *
+	 * @return void
+	 */
+	private void initialize() {
+		this.setBorder(javax.swing.BorderFactory.createTitledBorder(javax.swing.BorderFactory.createEtchedBorder(javax.swing.border.EtchedBorder.LOWERED), PluginServices.getText(this, "Hiperenlace"), javax.swing.border.TitledBorder.DEFAULT_JUSTIFICATION, javax.swing.border.TitledBorder.DEFAULT_POSITION, null, null));
+		this.setBounds(315, 195, 313, 154);
+		this.add(getJPanel1(), null);
+	}
+
+	/**
+	 * This method initializes jPanel1
+	 *
+	 * @return javax.swing.JPanel
+	 */
+	private JPanel getJPanel1() {
+		if (jPanel1 == null) {
+			jLabelAccion1 = new JLabel();
+			jLabelAccion1.setText(PluginServices.getText(this, "Accion_Predefinida") + "  ");
+			jLabelExtension1 = new JLabel();
+			jLabelExtension1.setText(PluginServices.getText(this,"extension"));
+			jLabelCampo1 = new JLabel();
+			jLabelCampo1.setText(PluginServices.getText(this, "Campo") + "   ");
+			jPanel1 = new JPanel();
+		}
+		jPanel1.setBounds(315, 195, 313, 154);
+		jPanel1.setPreferredSize(new java.awt.Dimension(300,120));
+		//jPanel1.setBorder(javax.swing.BorderFactory.createBevelBorder(javax.swing.border.BevelBorder.LOWERED));
+		jPanel1.add(jLabelCampo1, null);
+		jPanel1.add(getJComboBoxCampo1(), null);
+		jPanel1.add(jLabelExtension1, null);
+		jPanel1.add(getJTextFieldExtension1(), null);
+		jPanel1.add(jLabelAccion1, null);
+		jPanel1.add(getJComboBoxAccion1(), null);
+		return jPanel1;
+	}
+
+	/**
+	 * This method initializes jComboBoxCampo1
+	 *
+	 * @return javax.swing.JComboBox
+	 */
+	private JComboBox getJComboBoxCampo1() {
+		if (jComboBoxCampo1 == null) {
+			jComboBoxCampo1 = new JComboBox();
+			jComboBoxCampo1.setPreferredSize(new java.awt.Dimension(80,25));
+
+			if (PluginServices.getMainFrame() != null) {
+				if  (PluginServices.getMDIManager().getActiveWindow() instanceof AbstractViewPanel ){
+				    AbstractViewPanel theView = (AbstractViewPanel)PluginServices.getMDIManager().getActiveWindow();
+				    view = theView.getModel();
+//				    try {
+//                		if (layer instanceof FLyrVect) {
+//                    		FLyrVect ad = (FLyrVect) layer;
+//                    		DataSource ds;
+//                    		ds = ad.getRecordset();
+//                    		String[] names = new String[ds.getFieldCount()];
+//                    		for (int i = 0; i < ds.getFieldCount(); i++) {
+//                    			names[i] = ds.getFieldName(i);
+//                    		}
+//                    		//jComboBox = new javax.swing.JComboBox(names);
+//                    		DefaultComboBoxModel defaultModel = new DefaultComboBoxModel(names);
+//                    		jComboBoxCampo1.setModel(defaultModel);
+//                    		if (view.getSelectedField() != null) {
+//                    			jComboBoxCampo1.setSelectedItem(view.getSelectedField());
+//                    			//layer.setField(view.getSelectedField());
+//                    		}
+//                			}else{
+//                				jComboBoxCampo1 = new javax.swing.JComboBox();
+//                			}
+//				    } catch (ReadException e) {
+//				    	NotificationManager.addError("No se pudo obtener la tabla", e);
+//				    }
+				}
+			}
+			}
+		return jComboBoxCampo1;
+	}
+
+	/**
+	 * This method initializes jTextFieldExtension1
+	 *
+	 * @return javax.swing.JTextField
+	 */
+	private JTextField getJTextFieldExtension1() {
+		if (jTextFieldExtension1 == null) {
+			jTextFieldExtension1 = new JTextField();
+			jTextFieldExtension1.setPreferredSize(new java.awt.Dimension(40,25));
+		}
+		return jTextFieldExtension1;
+	}
+
+	/**
+	 * This method initializes jComboBoxAccion1
+	 *
+	 * @return javax.swing.JComboBox
+	 */
+	private JComboBox getJComboBoxAccion1() {
+		if (jComboBoxAccion1 == null) {
+			jComboBoxAccion1 = new JComboBox();
+			jComboBoxAccion1.setPreferredSize(new java.awt.Dimension(120,25));
+			ComboActionModel t=new ComboActionModel();
+			DefaultComboBoxModel defaultModel1 = new DefaultComboBoxModel(t.getModel());
+			jComboBoxAccion1.setModel(defaultModel1);
+
+		}
+		return jComboBoxAccion1;
+	}
+}
+
+	class ComboActionModel{
+		private String types[] = null;
+
+		ComboActionModel(){
+			types[0]="Enlazar a ficheros de im�gen";
+			types[1]="Enlazar a ficheros de texto";
+		}
+		String toString(int ind){
+			return types[ind];
+		}
+		public String[] getModel(){
+			return types;
+		}
+
+		public int getOrder(String field){
+			if (field.compareTo(types[0])==0){
+				return 0;
+			}
+			else if (field.compareTo(types[1])==0) {
+				return 1;
+			}
+			return 1;
+		}
+
+
+	}
+
+	class ComboActionItem {
+		private String text=null;
+		private int cont;
+
+		public ComboActionItem(String texto, int contador){
+			text = texto;
+			cont = contador;
+		}
+
+		public String toString() {
+			return this.text;
+		}
+	}
\ No newline at end of file

Property changes on: tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/app/gui/panels/PanelLinkProperties.java
___________________________________________________________________
Added: svn:eol-style
   + native
Added: svn:keywords
   + Author Date Id Revision

Index: tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/app/gui/panels/annotation/SelectAnnotationLayerNameAndField.java
===================================================================
--- tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/app/gui/panels/annotation/SelectAnnotationLayerNameAndField.java	(revision 0)
+++ tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/app/gui/panels/annotation/SelectAnnotationLayerNameAndField.java	(revision 38653)
@@ -0,0 +1,183 @@
+package org.gvsig.app.gui.panels.annotation;
+
+import java.awt.Dimension;
+import java.awt.Rectangle;
+import java.awt.event.ItemEvent;
+import java.awt.event.ItemListener;
+
+import javax.swing.JComboBox;
+import javax.swing.JLabel;
+import javax.swing.JTextField;
+import javax.swing.event.CaretEvent;
+import javax.swing.event.CaretListener;
+
+import org.gvsig.andami.PluginServices;
+
+import jwizardcomponent.JWizardComponents;
+import jwizardcomponent.JWizardPanel;
+
+
+//TODO comentado para que compile
+public class SelectAnnotationLayerNameAndField extends JWizardPanel {
+//	private FLyrAnnotation layer;
+
+	public SelectAnnotationLayerNameAndField(JWizardComponents wizardComponents) {
+		super(wizardComponents);
+		// TODO Auto-generated constructor stub
+	}
+
+
+	private JLabel lblDescription = null;
+	private JLabel lblStep1 = null;
+	private JLabel lblNewLayerName = null;
+	private JLabel lblStep2 = null;
+	private JLabel lblField = null;
+
+	private JTextField txtNewLayerName = null;
+	private JComboBox cmbField = null;
+
+
+	private static final Rectangle lblDescriptionPosition = new Rectangle(4,4,355,75);
+
+	private static final Rectangle lblStep1Position = new Rectangle(4,90,15,15);
+	private static final Rectangle lblNewLayerNamePosition = new Rectangle(30,90,355,15);
+	private static final Rectangle txtNewLayerNamePosition = new Rectangle(30,109,250,18);
+
+
+	private static final Rectangle lblStep2Position = new Rectangle(4,135,15,12);
+	private static final Rectangle lblFieldPosition = new Rectangle(30,135,355,30);
+	private static final Rectangle cmbFieldPosition = new Rectangle(30,169,170,18);
+
+
+
+
+	private class EventsListener implements CaretListener,ItemListener
+	{
+		public void caretUpdate(CaretEvent arg0) {
+			updateButtonsState();
+		}
+
+		public void itemStateChanged(ItemEvent e) {
+			updateButtonsState();
+		}
+
+	}
+
+
+	private void updateButtonsState() {
+		setBackButtonEnabled(false);
+		boolean enabled =checkIsOkPanelData();
+		setNextButtonEnabled(enabled);
+		setFinishButtonEnabled(enabled);
+	}
+
+
+	private EventsListener eventsListener = new EventsListener();
+
+
+	protected boolean checkIsOkPanelData() {
+		if (txtNewLayerName.getText().trim().length() < 1) {
+			return false;
+		}
+		if (((String)cmbField.getSelectedItem()).trim().length() < 1) {
+			return false;
+		}
+		return true;
+	}
+
+
+//	public SelectAnnotationLayerNameAndField(JWizardComponents arg0,FLyrAnnotation layer) {
+//		super(arg0);
+//		this.layer =layer;
+//		this.initialize();
+//	}
+
+	protected void initialize() {
+		this.setLayout(null);
+		this.setSize(new Dimension(358,263));
+		this.addLabels();
+
+		this.add(getTxtNewLayerName(),null);
+		this.add(getCmbField(),null);
+
+		checkIsOkPanelData();
+	}
+
+	private JTextField getTxtNewLayerName() {
+		if (this.txtNewLayerName == null) {
+			this.txtNewLayerName = new JTextField();
+			this.txtNewLayerName.setBounds(txtNewLayerNamePosition);
+			this.txtNewLayerName.setText("NuevaCapa");
+			this.txtNewLayerName.addCaretListener(eventsListener);
+		}
+		return this.txtNewLayerName;
+	}
+
+	public String getNewLayerName() {
+		return this.getTxtNewLayerName().getText();
+	}
+
+
+	private JComboBox getCmbField() {
+		if (this.cmbField == null) {
+			this.cmbField = new JComboBox();
+			this.cmbField.setEditable(false);
+			this.cmbField.setBounds(cmbFieldPosition);
+			this.cmbField.addItemListener(this.eventsListener);
+			this.cmbField.addItem("");
+
+
+//			try {
+//				SelectableDataSource dataSource = this.layer.getRecordset();
+//
+//				String[] fieldsNames = dataSource.getFieldNames();
+//
+//				for (int i=0; i < fieldsNames.length; i++) {
+//					this.cmbField.addItem(fieldsNames[i]);
+//				}
+//
+//			} catch (ReadDriverException e) {
+//				// TODO Auto-generated catch block
+//				e.printStackTrace();
+//			}
+
+		}
+		return this.cmbField;
+	}
+
+	public String getField() {
+		return (String)this.getCmbField().getSelectedItem();
+	}
+
+
+	protected void addLabels() {
+		this.lblDescription = new JLabel();
+		this.lblStep1 = new JLabel();
+		this.lblNewLayerName = new JLabel();
+		this.lblStep2 = new JLabel();
+		this.lblField= new JLabel();
+
+		this.lblDescription.setText(PluginServices.getText(this,"descripcion_de_crear_capa_de_anotaciones"));
+		this.lblStep1.setText("1.");
+		this.lblNewLayerName.setText(PluginServices.getText(this,"introduzca_el_nombre_de_la_nueva_capa_de_anotaciones"));
+		this.lblStep2.setText("2.");
+		this.lblField.setText(PluginServices.getText(this,"seleccione_el_campo_de_texto_que_desea_que_se_utilize_para_mostrar_la_nueva_capa_virtual"));
+
+		this.lblDescription.setBounds(lblDescriptionPosition);
+		this.lblStep1.setBounds(lblStep1Position);
+		this.lblNewLayerName.setBounds(lblNewLayerNamePosition);
+		this.lblStep2.setBounds(lblStep2Position);
+		this.lblField.setBounds(lblFieldPosition);
+
+
+		this.add(lblDescription,null);
+		this.add(lblStep1,null);
+		this.add(lblNewLayerName,null);
+		this.add(lblStep2,null);
+		this.add(lblField,null);
+
+	}
+
+
+
+}

Property changes on: tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/app/gui/panels/annotation/SelectAnnotationLayerNameAndField.java
___________________________________________________________________
Added: svn:keywords
   + Author Date Id Revision
Added: svn:eol-style
   + native

Index: tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/app/gui/panels/annotation/ConfigureLabel.java
===================================================================
--- tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/app/gui/panels/annotation/ConfigureLabel.java	(revision 0)
+++ tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/app/gui/panels/annotation/ConfigureLabel.java	(revision 38653)
@@ -0,0 +1,326 @@
+package org.gvsig.app.gui.panels.annotation;
+
+import java.awt.Dimension;
+import java.awt.Rectangle;
+import java.awt.event.ItemEvent;
+import java.awt.event.ItemListener;
+import java.sql.Types;
+import java.util.ArrayList;
+import java.util.Collection;
+import java.util.HashMap;
+import java.util.Iterator;
+
+import javax.swing.JComboBox;
+import javax.swing.JLabel;
+
+import org.gvsig.andami.PluginServices;
+
+import jwizardcomponent.JWizardComponents;
+import jwizardcomponent.JWizardPanel;
+
+
+
+//TODO comentado para que compile
+public class ConfigureLabel extends JWizardPanel {
+
+	public ConfigureLabel(JWizardComponents wizardComponents) {
+		super(wizardComponents);
+		// TODO Auto-generated constructor stub
+	}
+
+	public static final String TEXT_FOR_DEFAULT_VALUE = "- Default -";
+
+//	private FLyrAnnotation layer;
+
+	private HashMap fieldsNames = new HashMap() ;
+	private JLabel lblDescription;
+
+	private JLabel lblAngle;
+
+	private JLabel lblColor;
+
+	private JLabel lblSize;
+
+	private JLabel lblSizeUnits;
+
+	private JLabel lblFont;
+
+	private JLabel lblStep1;
+
+	private JLabel lblStep2;
+
+	private JLabel lblStep3;
+
+	private JLabel lblStep4;
+
+	private JComboBox cmbAngle = null;
+	private JComboBox cmbColor = null;
+	private JComboBox cmbSize = null;
+	private JComboBox cmbSizeUnits = null;
+	private JComboBox cmbFont = null;
+
+
+
+	private static final Rectangle lblDescriptionPosition = new Rectangle(4,4,355,60);
+
+	private static final Rectangle lblStep1Position = new Rectangle(4,90,15,15);
+	private static final Rectangle lblAnglePosition = new Rectangle(30,90,355,30);
+	private static final Rectangle cmbAnglePosition = new Rectangle(30,124,170,18);
+
+
+	private static final Rectangle lblStep2Position = new Rectangle(4,150,15,15);
+	private static final Rectangle lblColorPosition = new Rectangle(30,150,355,30);
+	private static final Rectangle cmbColorPosition = new Rectangle(30,184,170,18);
+
+	private static final Rectangle lblStep3Position = new Rectangle(4,210,15,15);
+	private static final Rectangle lblSizePosition = new Rectangle(30,210,355,30);
+	private static final Rectangle cmbSizePosition = new Rectangle(30,244,170,18);
+	private static final Rectangle lblSizeUnitsPosition = new Rectangle(204,244,80,15);
+	private static final Rectangle cmbSizeUnitsPosition = new Rectangle(305,244,80,18);
+
+	private static final Rectangle lblStep4Position = new Rectangle(4,270,15,15);
+	private static final Rectangle lblFontPosition = new Rectangle(30,270,355,30);
+	private static final Rectangle cmbFontPosition = new Rectangle(30,304,170,18);
+
+
+	private void updateButtonsState() {
+		setBackButtonEnabled(true);
+		setNextButtonEnabled(false);
+		setFinishButtonEnabled(checkIsOkPanelData());
+	}
+
+
+
+	protected boolean checkIsOkPanelData() {
+		if (!((String)this.getCmbSize().getSelectedItem()).equals(ConfigureLabel.TEXT_FOR_DEFAULT_VALUE)) {
+			return (((String)this.getCmbSizeUnits().getSelectedItem()).trim().length() > 0);
+		}
+		return true;
+	}
+
+
+	private class EventsListener implements ItemListener
+	{
+
+		public void itemStateChanged(ItemEvent e) {
+			updateButtonsState();
+		}
+
+	}
+
+	private EventsListener eventsListener = new EventsListener();
+
+
+//	public ConfigureLabel(JWizardComponents arg0,FLyrAnnotation layer) {
+//		super(arg0);
+//		this.layer =layer;
+//		this.initialize();
+//	}
+
+	protected void initialize() {
+		this.setLayout(null);
+		this.setSize(new Dimension(358,263));
+		this.addLabels();
+
+		this.add(getCmbAngle(),null);
+		this.add(getCmbColor(),null);
+		this.add(getCmbSize(),null);
+		this.add(getCmbSizeUnits(),null);
+		this.add(getCmbFont(),null);
+
+		checkIsOkPanelData();
+	}
+
+
+	protected void addLabels() {
+		this.lblDescription = new JLabel();
+		this.lblStep1 = new JLabel();
+		this.lblAngle = new JLabel();
+		this.lblStep2 = new JLabel();
+		this.lblColor= new JLabel();
+		this.lblStep3 = new JLabel();
+		this.lblSize= new JLabel();
+		this.lblSizeUnits= new JLabel();
+		this.lblStep4 = new JLabel();
+		this.lblFont= new JLabel();
+
+		this.lblDescription.setText(PluginServices.getText(this,"descripcion_de_configuracion_capa_de_anotaciones"));
+		this.lblStep1.setText("1.");
+		this.lblAngle.setText(PluginServices.getText(this,"seleccione_el_campo_angulo_de_la_capa_de_anotaciones"));
+		this.lblStep2.setText("2.");
+		this.lblColor.setText(PluginServices.getText(this,"seleccione_el_campo_color_de_la_capa_de_anotaciones"));
+		this.lblStep3.setText("3.");
+		this.lblSize.setText(PluginServices.getText(this,"seleccione_el_campo_tamano_de_la_capa_de_anotaciones"));
+		this.lblSizeUnits.setText(PluginServices.getText(this,"en_unidades"));
+		this.lblStep4.setText("4.");
+		this.lblFont.setText(PluginServices.getText(this,"seleccione_el_campo_fuente_de_la_capa_de_anotaciones"));
+
+		//TODO: Posicionar
+		this.lblDescription.setBounds(lblDescriptionPosition);
+		this.lblStep1.setBounds(lblStep1Position);
+		this.lblAngle.setBounds(lblAnglePosition);
+		this.lblStep2.setBounds(lblStep2Position);
+		this.lblColor.setBounds(lblColorPosition);
+		this.lblStep3.setBounds(lblStep3Position);
+		this.lblSize.setBounds(lblSizePosition);
+		this.lblSizeUnits.setBounds(lblSizeUnitsPosition);
+		this.lblStep4.setBounds(lblStep4Position);
+		this.lblFont.setBounds(lblFontPosition);
+
+
+
+		this.add(lblDescription,null);
+		this.add(lblStep1,null);
+		this.add(lblAngle,null);
+		this.add(lblStep2,null);
+		this.add(lblColor,null);
+		this.add(lblStep3,null);
+		this.add(lblSize,null);
+		this.add(lblSizeUnits,null);
+		this.add(lblStep4,null);
+		this.add(lblFont,null);
+
+
+	}
+
+	private void fillFieldsNames(JComboBox cmb,int[] types) {
+		cmb.addItem(ConfigureLabel.TEXT_FOR_DEFAULT_VALUE);
+		Collection names;
+		if (types == null) {
+
+			String[] allNames = (String[])this.fieldsNames.get("ALL");
+//			if (allNames == null) {
+//				try {
+//					SelectableDataSource dataSource = this.layer.getRecordset();
+//
+//					allNames = dataSource.getFieldNames();
+//					this.fieldsNames.put("ALL",allNames);
+//
+//				} catch (ReadDriverException e) {
+//					e.printStackTrace();
+//				}
+//			}
+			for (int i=0; i < allNames.length; i++) {
+				cmb.addItem(allNames[i]);
+			}
+			return;
+		}
+		Integer typeKey;
+		for (int i=0; i < types.length; i++) {
+			typeKey = new Integer(types[i]);
+			if (!this.fieldsNames.containsKey(typeKey)){
+				names = this.getFieldsFromType(types[i]);
+				this.fieldsNames.put(typeKey,names);
+			}else{
+				names = (Collection)this.fieldsNames.get(typeKey);
+			}
+			if (names != null) {
+				Iterator name = names.iterator();
+				while (name.hasNext()){
+					cmb.addItem(name.next());
+				}
+			}
+
+		}
+	}
+	private Collection getFieldsFromType(int type){
+		ArrayList result = new ArrayList();
+//		try {
+//			SelectableDataSource dataSource = this.layer.getRecordset();
+//
+//			for (int i=0; i < dataSource.getFieldCount(); i++) {
+//				if (dataSource.getFieldType(i) == type){
+//					result.add(dataSource.getFieldName(i));
+//				}
+//			}
+//		} catch (ReadDriverException e) {
+//			e.printStackTrace();
+//		}
+		if (result.size() == 0){
+			return null;
+		}
+		return result;
+
+	}
+
+	private JComboBox getCmbAngle() {
+		if (this.cmbAngle == null) {
+			this.cmbAngle= new JComboBox();
+			this.cmbAngle.setEditable(false);
+			this.cmbAngle.setBounds(cmbAnglePosition);
+			this.fillFieldsNames(this.cmbAngle,new int[]{Types.INTEGER,Types.DOUBLE});
+			this.cmbAngle.addItemListener(this.eventsListener);
+		}
+		return this.cmbAngle;
+	}
+
+	public String getAngleFieldName(){
+		return (String)this.getCmbAngle().getSelectedItem();
+	}
+
+	private JComboBox getCmbColor() {
+		if (this.cmbColor == null) {
+			this.cmbColor= new JComboBox();
+			this.cmbColor.setEditable(false);
+			this.cmbColor.setBounds(cmbColorPosition);
+			this.fillFieldsNames(this.cmbColor,new int[]{Types.INTEGER});
+			this.cmbColor.addItemListener(this.eventsListener);
+		}
+		return this.cmbColor;
+	}
+
+	public String getColorFieldName(){
+		return (String)this.getCmbColor().getSelectedItem();
+	}
+
+
+	private JComboBox getCmbSize() {
+		if (this.cmbSize == null) {
+			this.cmbSize= new JComboBox();
+			this.cmbSize.setEditable(false);
+			this.cmbSize.setBounds(cmbSizePosition);
+			this.fillFieldsNames(this.cmbSize,new int[]{Types.INTEGER,Types.DOUBLE});
+			this.cmbSize.addItemListener(this.eventsListener);
+		}
+		return this.cmbSize;
+	}
+
+
+	public String getSizeFieldName(){
+		return (String)this.getCmbSize().getSelectedItem();
+	}
+
+	private JComboBox getCmbSizeUnits() {
+		if (this.cmbSizeUnits == null) {
+			this.cmbSizeUnits= new JComboBox();
+			this.cmbSizeUnits.setEditable(false);
+			this.cmbSizeUnits.setBounds(cmbSizeUnitsPosition);
+			this.cmbSizeUnits.addItem(PluginServices.getText(this,"pixels"));
+			this.cmbSizeUnits.addItem(PluginServices.getText(this,"metros"));
+			this.cmbSizeUnits.addItemListener(this.eventsListener);
+		}
+		return this.cmbSizeUnits;
+	}
+
+	public boolean sizeUnitsInPixels(){
+		return (this.getCmbSize().getSelectedIndex() == 0);
+	}
+
+
+	private JComboBox getCmbFont() {
+		if (this.cmbFont == null) {
+			this.cmbFont= new JComboBox();
+			this.cmbFont.setEditable(false);
+			this.cmbFont.setBounds(cmbFontPosition);
+			this.fillFieldsNames(this.cmbFont,new int[]{Types.VARCHAR,Types.LONGVARCHAR});
+			this.cmbFont.addItemListener(this.eventsListener);
+		}
+		return this.cmbFont;
+	}
+
+	public String getFontFieldName(){
+		return (String)this.getCmbFont().getSelectedItem();
+	}
+
+
+}

Property changes on: tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/app/gui/panels/annotation/ConfigureLabel.java
___________________________________________________________________
Added: svn:keywords
   + Author Date Id Revision
Added: svn:eol-style
   + native

Index: tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/app/gui/panels/ProjChooserPanel.java
===================================================================
--- tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/app/gui/panels/ProjChooserPanel.java	(revision 0)
+++ tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/app/gui/panels/ProjChooserPanel.java	(revision 38653)
@@ -0,0 +1,136 @@
+/*
+ * Created on 30-ene-2005
+ */
+package org.gvsig.app.gui.panels;
+
+import java.awt.FlowLayout;
+
+import javax.swing.JLabel;
+import javax.swing.JPanel;
+
+import org.cresques.cts.IProjection;
+
+import org.gvsig.andami.PluginServices;
+import org.gvsig.app.gui.panels.crs.ISelectCrsPanel;
+import org.gvsig.gui.beans.swing.JButton;
+
+/**
+ * @author Luis W. Sevilla (sevilla_lui@gva.es)
+ */
+public class ProjChooserPanel extends CRSSelectPanel {
+
+    private IProjection curProj = null;
+    private JLabel jLblProj = null;
+    private JLabel jLblProjName = null;
+    private JButton jBtnChangeProj = null;
+    private JPanel jPanelProj = null;
+    private boolean okPressed = false;
+
+    /**
+	 *
+	 */
+    public ProjChooserPanel(IProjection proj) {
+        super(proj);
+        setCurProj(proj);
+        initialize();
+    }
+
+    /**
+     * This method initializes this
+     * 
+     * @return void
+     */
+    private void initialize() {
+        this.setLayout(new FlowLayout(FlowLayout.LEFT, 15, 0));
+        this.add(getJLblProjName());
+        this.add(getJLblProj());
+        this.add(getJBtnChangeProj());
+        initBtnChangeProj();
+    }
+
+    private void initBtnChangeProj() {
+        getJBtnChangeProj().addActionListener(
+            new java.awt.event.ActionListener() {
+
+                public void actionPerformed(java.awt.event.ActionEvent e) {
+                    okPressed = false;
+
+                    ISelectCrsPanel csSelect =
+                        getUIFactory().getSelectCrsPanel(curProj, true);
+
+                    PluginServices.getMDIManager().addWindow(csSelect);
+
+                    if (csSelect.isOkPressed()) {
+                        curProj = csSelect.getProjection();
+                        jLblProj.setText(curProj.getAbrev());
+                        okPressed = true;
+                        if (actionListener != null) {
+                            actionListener.actionPerformed(e);
+                        }
+                    }
+                }
+            });
+    }
+
+    public JLabel getJLblProjName() {
+        if (jLblProjName == null) {
+            jLblProjName = new JLabel("Proyeccion actual");
+            jLblProjName.setText(PluginServices.getText(this,
+                "__proyeccion_actual")); //$NON-NLS-1$
+        }
+        return jLblProjName;
+    }
+
+    public JLabel getJLabel() {
+        return getJLblProjName();
+    }
+
+    public JLabel getJLblProj() {
+        if (jLblProj == null) {
+            jLblProj = new JLabel();
+            if (curProj != null)
+                jLblProj.setText(curProj.getAbrev());
+        }
+        return jLblProj;
+    }
+
+    public void addBtnChangeProjActionListener(java.awt.event.ActionListener al) {
+        jBtnChangeProj.addActionListener(al);
+    }
+
+    /**
+     * This method initializes jButton
+     * 
+     * @return javax.swing.JButton
+     */
+    public JButton getJBtnChangeProj() {
+        if (jBtnChangeProj == null) {
+            jBtnChangeProj = new JButton();
+            jBtnChangeProj.setText("..."); //$NON-NLS-1$
+            jBtnChangeProj.setPreferredSize(new java.awt.Dimension(26, 26));
+        }
+        return jBtnChangeProj;
+    }
+
+    /**
+     * @return Returns the curProj.
+     */
+    public IProjection getCurProj() {
+        return curProj;
+    }
+
+    /**
+     * @param curProj
+     *            The curProj to set.
+     */
+    public void setCurProj(IProjection curProj) {
+        this.curProj = curProj;
+    }
+
+    /**
+     * @return Returns the okPressed.
+     */
+    public boolean isOkPressed() {
+        return okPressed;
+    }
+} // @jve:decl-index=0:visual-constraint="10,10"

Property changes on: tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/app/gui/panels/ProjChooserPanel.java
___________________________________________________________________
Added: svn:keywords
   + Author Date Id Revision
Added: svn:eol-style
   + native

Index: tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/app/gui/selectionByTheme/MySelectionByThemeListener.java
===================================================================
--- tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/app/gui/selectionByTheme/MySelectionByThemeListener.java	(revision 0)
+++ tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/app/gui/selectionByTheme/MySelectionByThemeListener.java	(revision 38653)
@@ -0,0 +1,328 @@
+/* gvSIG. Sistema de Informaci�n Geogr�fica de la Generalitat Valenciana
+ *
+ * Copyright (C) 2004 IVER T.I. and Generalitat Valenciana.
+ *
+ * This program is free software; you can redistribute it and/or
+ * modify it under the terms of the GNU General Public License
+ * as published by the Free Software Foundation; either version 2
+ * of the License, or (at your option) any later version.
+ *
+ * This program is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
+ * GNU General Public License for more details.
+ *
+ * You should have received a copy of the GNU General Public License
+ * along with this program; if not, write to the Free Software
+ * Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA  02111-1307,USA.
+ *
+ * For more information, contact:
+ *
+ *  Generalitat Valenciana
+ *   Conselleria d'Infraestructures i Transport
+ *   Av. Blasco Ib��ez, 50
+ *   46010 VALENCIA
+ *   SPAIN
+ *
+ *      +34 963862235
+ *   gvsig@gva.es
+ *      www.gvsig.gva.es
+ *
+ *    or
+ *
+ *   IVER T.I. S.A
+ *   Salamanca 50
+ *   46005 Valencia
+ *   Spain
+ *
+ *   +34 963163400
+ *   dac@iver.es
+ */
+package org.gvsig.app.gui.selectionByTheme;
+
+import org.cresques.cts.IProjection;
+import org.gvsig.andami.messages.NotificationManager;
+import org.gvsig.fmap.dal.exception.DataException;
+import org.gvsig.fmap.dal.exception.ReadException;
+import org.gvsig.tools.dispose.DisposableIterator;
+import org.gvsig.fmap.dal.feature.Feature;
+import org.gvsig.fmap.dal.feature.FeatureQuery;
+import org.gvsig.fmap.dal.feature.FeatureSelection;
+import org.gvsig.fmap.dal.feature.FeatureSet;
+import org.gvsig.fmap.dal.feature.FeatureStore;
+import org.gvsig.fmap.dal.feature.FeatureType;
+import org.gvsig.fmap.geom.Geometry;
+import org.gvsig.fmap.mapcontext.layers.FLayer;
+import org.gvsig.fmap.mapcontext.layers.vectorial.ContainsGeometryEvaluator;
+import org.gvsig.fmap.mapcontext.layers.vectorial.CrossesGeometryEvaluator;
+import org.gvsig.fmap.mapcontext.layers.vectorial.DisjointGeometryEvaluator;
+import org.gvsig.fmap.mapcontext.layers.vectorial.EqualsGeometryEvaluator;
+import org.gvsig.fmap.mapcontext.layers.vectorial.FLyrVect;
+import org.gvsig.fmap.mapcontext.layers.vectorial.IntersectsGeometryEvaluator;
+import org.gvsig.fmap.mapcontext.layers.vectorial.OverlapsGeometryEvaluator;
+import org.gvsig.fmap.mapcontext.layers.vectorial.TouchesGeometryEvaluator;
+import org.gvsig.fmap.mapcontext.layers.vectorial.WithinGeometryEvaluator;
+import org.gvsig.tools.dispose.DisposeUtils;
+import org.gvsig.tools.evaluator.Evaluator;
+import org.gvsig.tools.evaluator.EvaluatorData;
+import org.gvsig.tools.evaluator.EvaluatorException;
+import org.gvsig.tools.evaluator.EvaluatorFieldsInfo;
+
+
+/**
+ * DOCUMENT ME!
+ *
+ * @author Fernando Gonz�lez Cort�s
+ */
+//TODO comentado para que compile
+public class MySelectionByThemeListener implements SelectionByThemeListener {
+	/**
+	 * @see org.gvsig.app.gui.selectionByTheme.SelectionByThemeListener#newSet(int,
+	 *      int, int)
+	 */
+	public void newSet(FLayer[] toSelect, FLayer selectionLayer, int action) {
+		long t1 = System.currentTimeMillis();
+
+		if (selectionLayer instanceof FLyrVect) {
+			try {
+				FeatureSelection selection=(FeatureSelection)((FLyrVect)selectionLayer).getFeatureStore().getSelection();
+				SelectByTheme filter=new SelectByTheme(selection,selectionLayer.getMapContext().getProjection(),selection.getDefaultFeatureType().getDefaultGeometryAttributeName(), action);
+
+				for (int i = 0; i < toSelect.length; i++) {
+					if (toSelect[i] instanceof FLyrVect) {
+//						if (!selectionLayer.getFullEnvelope().intersects(toSelect[i].getFullEnvelope())){
+//							continue;
+//						}
+						FeatureStore storeToQuery = ((FLyrVect) toSelect[i]).getFeatureStore();
+						FeatureQuery fQuery = storeToQuery
+								.createFeatureQuery();
+						filter.setData(storeToQuery.getDefaultFeatureType(),storeToQuery.getDefaultFeatureType().getDefaultGeometryAttributeName(),null);
+
+						fQuery.setFilter(filter);
+						FeatureSet featureSet = null;
+						try {
+							featureSet = storeToQuery.getFeatureSet(fQuery);
+							((FeatureSelection) storeToQuery.getSelection())
+									.deselectAll();
+							storeToQuery.setSelection(featureSet);
+						} finally {
+							if (featureSet != null) {
+								featureSet.dispose();
+							}
+						}
+					}
+				}
+			} catch (ReadException e) {
+				NotificationManager.addError("error_selection_by_theme", e);
+			} catch (DataException e) {
+				NotificationManager.addError("error_selection_by_theme", e);
+			}
+
+		}
+		long t2 = System.currentTimeMillis();
+		System.out
+				.println("Tiempo de consulta: " + (t2 - t1) + " milisegundos");
+		// doSelection(toSelect, selectionLayer, action, false);
+	}
+
+	/**
+	 * @see org.gvsig.app.gui.selectionByTheme.SelectionByThemeListener#addToSet(int,
+	 *      int, int)
+	 */
+	public void addToSet(FLayer[] toSelect, FLayer selectionLayer, int action) {
+		long t1 = System.currentTimeMillis();
+
+		if (selectionLayer instanceof FLyrVect) {
+			try {
+				FeatureSelection selection=(FeatureSelection)((FLyrVect)selectionLayer).getFeatureStore().getSelection();
+				SelectByTheme filter=new SelectByTheme(selection,selectionLayer.getMapContext().getProjection(),selection.getDefaultFeatureType().getDefaultGeometryAttributeName(), action);
+
+				for (int i = 0; i < toSelect.length; i++) {
+					if (toSelect[i] instanceof FLyrVect) {
+						if (!selectionLayer.getFullEnvelope().intersects(toSelect[i].getFullEnvelope())){
+							continue;
+						}
+						FeatureStore storeToQuery = ((FLyrVect) toSelect[i]).getFeatureStore();
+						FeatureQuery fQuery = storeToQuery
+								.createFeatureQuery();
+						filter.setData(storeToQuery.getDefaultFeatureType(),storeToQuery.getDefaultFeatureType().getDefaultGeometryAttributeName(),null);
+
+						fQuery.setFilter(filter);
+						FeatureSet featureSet = null;
+						try {
+							featureSet = storeToQuery.getFeatureSet(fQuery);
+							storeToQuery.setSelection(featureSet);
+						} finally {
+							if (featureSet != null) {
+								featureSet.dispose();
+							}
+						}
+					}
+				}
+			} catch (ReadException e) {
+				NotificationManager.addError("error_selection_by_theme", e);
+			} catch (DataException e) {
+				NotificationManager.addError("error_selection_by_theme", e);
+			}
+
+		}
+		long t2 = System.currentTimeMillis();
+		System.out
+				.println("Tiempo de consulta: " + (t2 - t1) + " milisegundos");
+	}
+
+	/**
+	 * @see org.gvsig.app.gui.selectionByTheme.SelectionByThemeListener#fromSet(int,
+	 *      int, int)
+	 */
+	public void fromSet(FLayer[] toSelect, FLayer selectionLayer, int action) {
+		long t1 = System.currentTimeMillis();
+		if (selectionLayer instanceof FLyrVect) {
+			try {
+				FeatureSelection selection=(FeatureSelection)((FLyrVect)selectionLayer).getFeatureStore().getSelection();
+				SelectByTheme filter=new SelectByTheme(selection,selectionLayer.getMapContext().getProjection(),selection.getDefaultFeatureType().getDefaultGeometryAttributeName(), action);
+
+				for (int i = 0; i < toSelect.length; i++) {
+					if (toSelect[i] instanceof FLyrVect) {
+						if (!selectionLayer.getFullEnvelope().intersects(toSelect[i].getFullEnvelope())){
+							continue;
+						}
+						FeatureStore storeToQuery = ((FLyrVect) toSelect[i]).getFeatureStore();
+						FeatureQuery fQuery = storeToQuery
+								.createFeatureQuery();
+						filter.setData(storeToQuery.getDefaultFeatureType(),storeToQuery.getDefaultFeatureType().getDefaultGeometryAttributeName(),(FeatureSelection)storeToQuery.getSelection());
+
+						fQuery.setFilter(filter);
+						FeatureSet featureSet = null;
+						try {
+							featureSet = storeToQuery.getFeatureSet(fQuery);
+							((FeatureSelection) storeToQuery.getSelection())
+									.deselectAll();
+							storeToQuery.setSelection(featureSet);
+						} finally {
+							if (featureSet != null) {
+								featureSet.dispose();
+							}
+
+						}
+					}
+				}
+			} catch (ReadException e) {
+				NotificationManager.addError("error_selection_by_theme", e);
+			} catch (DataException e) {
+				NotificationManager.addError("error_selection_by_theme", e);
+			}
+
+		}
+		long t2 = System.currentTimeMillis();
+		System.out
+				.println("Tiempo de consulta: " + (t2 - t1) + " milisegundos");
+	}
+	class SelectByTheme implements Evaluator{
+		private FeatureSelection selection=null;
+		private IProjection projection;
+		private FeatureType featureType;
+		private String geomName;
+		private EvaluatorFieldsInfo info;
+		private String nameSelectedGeom;
+		private FeatureSelection featureSelection;
+		private int action;
+		private int index;
+
+		public SelectByTheme(FeatureSelection selection, IProjection projection,String nameSelectedGeom, int action){
+			this.selection=selection;
+
+			this.projection=projection;
+			this.nameSelectedGeom=nameSelectedGeom;
+			this.action=action;
+			this.index=selection.getDefaultFeatureType().getIndex(nameSelectedGeom);
+		}
+		public void setData(FeatureType featureType, String geomName, FeatureSelection featureSelection){
+			this.featureType=featureType;
+			this.geomName=geomName;
+			this.featureSelection=featureSelection;
+			this.info=new EvaluatorFieldsInfo();
+			this.info.addFieldValue(geomName);
+		}
+
+		public Object evaluate(EvaluatorData data) throws EvaluatorException {
+			if (featureSelection!=null && !featureSelection.isSelected(((Feature)data.getContextValue("feature")))){
+				return new Boolean(false);
+			}
+			DisposableIterator features = null;
+			try {
+				features = selection.iterator();
+
+				while (features.hasNext()) {
+					Feature feature = (Feature) features.next();
+					Geometry geometry = feature.getGeometry(index);
+					Evaluator eval = null;
+					switch (action) {
+					case SelectionByTheme.INTERSECTS:
+						eval = new IntersectsGeometryEvaluator(geometry,
+								projection, featureType, geomName);
+						break;
+					case SelectionByTheme.CONTAINS:
+						eval = new ContainsGeometryEvaluator(geometry,
+								projection, featureType, geomName);
+						break;
+					case SelectionByTheme.CROSSES:
+						eval = new CrossesGeometryEvaluator(geometry,
+								projection, featureType, geomName);
+						break;
+					case SelectionByTheme.DISJOINT:
+						eval = new DisjointGeometryEvaluator(geometry,
+								projection, featureType, geomName);
+						break;
+					case SelectionByTheme.EQUALS:
+						eval = new EqualsGeometryEvaluator(geometry,
+								projection, featureType, geomName);
+						break;
+					case SelectionByTheme.OVERLAPS:
+						eval = new OverlapsGeometryEvaluator(geometry,
+								projection, featureType, geomName);
+						break;
+					case SelectionByTheme.TOUCHES:
+						eval = new TouchesGeometryEvaluator(geometry,
+								projection, featureType, geomName);
+						break;
+					case SelectionByTheme.WITHIN:
+						eval = new WithinGeometryEvaluator(geometry,
+								projection, featureType, geomName);
+						break;
+
+					default:
+						eval = new IntersectsGeometryEvaluator(geometry,
+								projection, featureType, geomName);
+					break;
+					}
+
+					Boolean evaluate = (Boolean) eval.evaluate(data);
+					if ((evaluate).booleanValue()) {
+						return evaluate;
+					}
+				}
+			} catch (DataException e) {
+				NotificationManager.addError("error_selection_by_theme", e);
+			} finally {
+				DisposeUtils.dispose(features);
+			}
+			return new Boolean(false);
+		}
+
+		public String getName() {
+			return "select by theme";
+		}
+
+		public String getSQL() {
+			// TODO Auto-generated method stub
+			return null;
+		}
+		public String getDescription() {
+			return getName();
+		}
+		public EvaluatorFieldsInfo getFieldsInfo() {
+			return info;
+		}
+	}
+}

Property changes on: tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/app/gui/selectionByTheme/MySelectionByThemeListener.java
___________________________________________________________________
Added: svn:eol-style
   + native
Added: svn:keywords
   + Author Date Id Revision

Index: tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/app/gui/selectionByTheme/SelectionByTheme.java
===================================================================
--- tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/app/gui/selectionByTheme/SelectionByTheme.java	(revision 0)
+++ tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/app/gui/selectionByTheme/SelectionByTheme.java	(revision 38653)
@@ -0,0 +1,362 @@
+/* gvSIG. Sistema de Informaci�n Geogr�fica de la Generalitat Valenciana
+ *
+ * Copyright (C) 2004 IVER T.I. and Generalitat Valenciana.
+ *
+ * This program is free software; you can redistribute it and/or
+ * modify it under the terms of the GNU General Public License
+ * as published by the Free Software Foundation; either version 2
+ * of the License, or (at your option) any later version.
+ *
+ * This program is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
+ * GNU General Public License for more details.
+ *
+ * You should have received a copy of the GNU General Public License
+ * along with this program; if not, write to the Free Software
+ * Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA  02111-1307,USA.
+ *
+ * For more information, contact:
+ *
+ *  Generalitat Valenciana
+ *   Conselleria d'Infraestructures i Transport
+ *   Av. Blasco Ib��ez, 50
+ *   46010 VALENCIA
+ *   SPAIN
+ *
+ *      +34 963862235
+ *   gvsig@gva.es
+ *      www.gvsig.gva.es
+ *
+ *    or
+ *
+ *   IVER T.I. S.A
+ *   Salamanca 50
+ *   46005 Valencia
+ *   Spain
+ *
+ *   +34 963163400
+ *   dac@iver.es
+ */
+package org.gvsig.app.gui.selectionByTheme;
+
+import java.awt.BorderLayout;
+import java.awt.GridLayout;
+import java.util.ArrayList;
+
+import javax.swing.DefaultComboBoxModel;
+import javax.swing.JLabel;
+import javax.swing.JPanel;
+
+import org.gvsig.andami.PluginServices;
+import org.gvsig.andami.ui.mdiManager.IWindow;
+import org.gvsig.andami.ui.mdiManager.WindowInfo;
+import org.gvsig.gui.beans.swing.JButton;
+import org.gvsig.utils.swing.JComboBox;
+
+
+
+public class SelectionByTheme extends JPanel implements IWindow {
+	public static final int EQUALS = 0;
+	public static final int DISJOINT = 1;
+	public static final int INTERSECTS = 2;
+	public static final int TOUCHES = 3;
+	public static final int CROSSES = 4;
+	public static final int WITHIN = 5;
+	public static final int CONTAINS = 6;
+	public static final int OVERLAPS = 7;
+	public final String[] textosAcciones = new String[] {
+    PluginServices.getText(this, "Sean_iguales_a"), //"sean iguales a",
+    PluginServices.getText(this, "Sean_disjuntos_a"), //"sean disjuntos a",
+    PluginServices.getText(this, "Intersecten_con"), //"intersecten con",
+    PluginServices.getText(this, "Toquen"), //"toquen",
+    PluginServices.getText(this, "Crucen_con"), //"crucen con",
+    PluginServices.getText(this, "Contengan"), //"contengan",
+    PluginServices.getText(this, "Esten_contenidos_en"), //"est�n contenidos en",
+    PluginServices.getText(this, "Se_superponen_a"), //"se superponen a"
+	};
+
+	private SelectionByThemeModel dataSource = null;
+
+	private ArrayList listeners = new ArrayList();
+
+	private JPanel jPanel = null;
+	private JPanel jPanel1 = null;
+	private JLabel jLabel = null;
+	private JComboBox cmbAction = null;
+	private JLabel jLabel1 = null;
+	private JComboBox cmbCapas = null;
+	private JButton btnNew = null;
+	private JButton btnAdd = null;
+	private JButton btnFrom = null;
+	private JButton btnCancel = null;
+	/**
+	 * This is the default constructor
+	 */
+	public SelectionByTheme() {
+		super();
+		initialize();
+	}
+	/**
+	 * This method initializes this
+	 *
+	 * @return void
+	 */
+	private void initialize() {
+		this.setLayout(new BorderLayout(10, 10));
+		this.add(new JLabel(), BorderLayout.NORTH);
+		this.add(new JLabel(), BorderLayout.WEST);
+		this.add(getJPanel(), BorderLayout.CENTER);
+		this.add(getJPanel1(), BorderLayout.EAST);
+		this.add(new JLabel(), BorderLayout.SOUTH);
+		this.setSize(540, 95);
+	}
+	/**
+	 * This method initializes jPanel
+	 *
+	 * @return JPanel
+	 */
+	private JPanel getJPanel() {
+		if(jPanel == null) {
+			jPanel = new JPanel();
+			java.awt.FlowLayout layFlowLayout1 = new java.awt.FlowLayout();
+			layFlowLayout1.setVgap(30);
+			jPanel.setLayout(new GridLayout(4, 2, 5, 5));
+			jPanel.add(getJLabel(), null);
+			jPanel.add(getCmbAction(), null);
+			jPanel.add(getJLabel1(), null);
+			jPanel.add(getCmbCapas(), null);
+
+		}
+		return jPanel;
+	}
+	/**
+	 * This method initializes jPanel1
+	 *
+	 * @return JPanel
+	 */
+	private JPanel getJPanel1() {
+		if(jPanel1 == null) {
+			jPanel1 = new JPanel();
+			jPanel1.setLayout(new GridLayout(4, 1, 5, 5));
+			jPanel1.add(getBtnNew(), null);
+			jPanel1.add(getBtnAdd(), null);
+			jPanel1.add(getBtnFrom(), null);
+			jPanel1.add(getBtnCancel(), null);
+			jPanel1.setPreferredSize(new java.awt.Dimension(200,220));
+		}
+		return jPanel1;
+	}
+	/**
+	 * This method initializes jLabel
+	 *
+	 * @return JLabel
+	 */
+	private JLabel getJLabel() {
+		if(jLabel == null) {
+			jLabel = new JLabel();
+			jLabel.setText(PluginServices.getText(this, "Seleccionar_de_las_capas_activas_los_elementos_que") + "... ");
+		}
+		return jLabel;
+	}
+	/**
+	 * This method initializes cmbAction
+	 *
+	 * @return JComboBox
+	 */
+	private JComboBox getCmbAction() {
+		if(cmbAction == null) {
+			cmbAction = new JComboBox();
+			cmbAction.setPreferredSize(new java.awt.Dimension(200,20));
+			DefaultComboBoxModel model = new DefaultComboBoxModel(textosAcciones);
+			cmbAction.setModel(model);
+		}
+		return cmbAction;
+	}
+	/**
+	 * This method initializes jLabel1
+	 *
+	 * @return JLabel
+	 */
+	private JLabel getJLabel1() {
+		if(jLabel1 == null) {
+			jLabel1 = new JLabel();
+			jLabel1.setText(PluginServices.getText(this, "Elementos_seleccionados_de_la_capa"));
+		}
+		return jLabel1;
+	}
+	/**
+	 * This method initializes cmbCapas
+	 *
+	 * @return JComboBox
+	 */
+	private JComboBox getCmbCapas() {
+		if(cmbCapas == null) {
+			cmbCapas = new JComboBox();
+			cmbCapas.setPreferredSize(new java.awt.Dimension(200,20));
+		}
+		return cmbCapas;
+	}
+	/**
+	 * This method initializes btnNew
+	 *
+	 * @return JButton
+	 */
+	private JButton getBtnNew() {
+		if(btnNew == null) {
+			btnNew = new JButton();
+			btnNew.setText(PluginServices.getText(this, "Nuevo_conjunto"));
+			btnNew.setMargin(new java.awt.Insets(2,2,2,2));
+			btnNew.addActionListener(new java.awt.event.ActionListener() {
+				public void actionPerformed(java.awt.event.ActionEvent e) {
+					callNewListeners(cmbCapas.getSelectedIndex(), cmbAction.getSelectedIndex());
+				}
+			});
+		}
+		return btnNew;
+	}
+	/**
+	 * This method initializes btnAdd
+	 *
+	 * @return JButton
+	 */
+	private JButton getBtnAdd() {
+		if(btnAdd == null) {
+			btnAdd = new JButton();
+			btnAdd.setText(PluginServices.getText(this, "Anadir_al_conjunto"));
+			btnAdd.setMargin(new java.awt.Insets(2,2,2,2));
+			btnAdd.addActionListener(new java.awt.event.ActionListener() {
+				public void actionPerformed(java.awt.event.ActionEvent e) {
+					callAddToListeners(cmbCapas.getSelectedIndex(), cmbAction.getSelectedIndex());
+				}
+			});
+		}
+		return btnAdd;
+	}
+	/**
+	 * This method initializes btnFrom
+	 *
+	 * @return JButton
+	 */
+	private JButton getBtnFrom() {
+		if(btnFrom == null) {
+			btnFrom = new JButton();
+			btnFrom.setText(PluginServices.getText(this, "Seleccionar_del_conjunto"));
+			btnFrom.setMargin(new java.awt.Insets(2,2,2,2));
+			btnFrom.addActionListener(new java.awt.event.ActionListener() {
+				public void actionPerformed(java.awt.event.ActionEvent e) {
+					callFromListeners(cmbCapas.getSelectedIndex(), cmbAction.getSelectedIndex());
+				}
+			});
+		}
+		return btnFrom;
+	}
+	/**
+	 * This method initializes btnCancel
+	 *
+	 * @return JButton
+	 */
+	private JButton getBtnCancel() {
+		if(btnCancel == null) {
+			btnCancel = new JButton();
+			btnCancel.setText(PluginServices.getText(this, "Cancel"));
+			btnCancel.setMargin(new java.awt.Insets(2,2,2,2));
+			btnCancel.addActionListener(new java.awt.event.ActionListener() {
+				public void actionPerformed(java.awt.event.ActionEvent e) {
+					PluginServices.getMDIManager().closeWindow(SelectionByTheme.this);
+				}
+			});
+		}
+		return btnCancel;
+	}
+
+	/**
+	 * @return
+	 */
+	public SelectionByThemeModel getModel() {
+		return dataSource;
+	}
+
+	/**
+	 * @param source
+	 */
+	public void setModel(SelectionByThemeModel source) {
+		dataSource = source;
+		String[] nameLayers = new String[dataSource.getLayers().getLayersCount()];
+		for (int i=0; i < nameLayers.length; i++) {
+			nameLayers[i] = dataSource.getLayers().getLayer(i).getName();
+		}
+		DefaultComboBoxModel model =
+			new DefaultComboBoxModel(nameLayers);
+		cmbCapas.setModel(model);
+	}
+	/**
+	 * @see com.iver.mdiApp.ui.MDIManager.IWindow#getWindowInfo()
+	 */
+	public WindowInfo getWindowInfo() {
+		WindowInfo vi = new WindowInfo(WindowInfo.MODALDIALOG);
+		vi.setWidth(this.getWidth()+8);
+		vi.setHeight(this.getHeight());
+		vi.setTitle(PluginServices.getText(this, "Seleccion_por_capa"));
+		return vi;
+	}
+
+	private void callNewListeners(int selection, int actionCode){
+		for (int i = 0; i < listeners.size();
+				i++) {
+			SelectionByThemeListener l = (SelectionByThemeListener) listeners.get(i);
+			l.newSet(dataSource.getLayers().getActives(), dataSource.getLayers().getLayer(selection), actionCode);
+		}
+
+	}
+
+	private void callAddToListeners(int selection, int actionCode){
+		for (int i = 0; i < listeners.size();
+				i++) {
+			SelectionByThemeListener l = (SelectionByThemeListener) listeners.get(i);
+			l.addToSet(dataSource.getLayers().getActives(), dataSource.getLayers().getLayer(selection), actionCode);
+		}
+
+	}
+
+	private void callFromListeners(int selection, int actionCode){
+		for (int i = 0; i < listeners.size();
+				i++) {
+			SelectionByThemeListener l = (SelectionByThemeListener) listeners.get(i);
+			l.fromSet(dataSource.getLayers().getActives(), dataSource.getLayers().getLayer(selection), actionCode);
+		}
+
+	}
+
+	/**
+	 * DOCUMENT ME!
+	 *
+	 * @param arg0
+	 *
+	 * @return
+	 */
+	public boolean addSelectionListener(SelectionByThemeListener arg0) {
+		return listeners.add(arg0);
+	}
+
+	/**
+	 * DOCUMENT ME!
+	 *
+	 * @param arg0
+	 *
+	 * @return
+	 */
+	public boolean removeSelectionListener(SelectionByThemeListener arg0) {
+		return listeners.remove(arg0);
+	}
+	/**
+	 * @see com.iver.mdiApp.ui.MDIManager.IWindow#windowActivated()
+	 */
+	public void viewActivated() {
+	}
+
+	public Object getWindowProfile() {
+		return WindowInfo.DIALOG_PROFILE;
+	}
+
+}  //  @jve:visual-info  decl-index=0 visual-constraint="10,10"

Property changes on: tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/app/gui/selectionByTheme/SelectionByTheme.java
___________________________________________________________________
Added: svn:keywords
   + Author Date Id Revision
Added: svn:eol-style
   + native

Index: tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/app/gui/selectionByTheme/SelectionByThemeModel.java
===================================================================
--- tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/app/gui/selectionByTheme/SelectionByThemeModel.java	(revision 0)
+++ tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/app/gui/selectionByTheme/SelectionByThemeModel.java	(revision 38653)
@@ -0,0 +1,48 @@
+/* gvSIG. Sistema de Informaci�n Geogr�fica de la Generalitat Valenciana
+ *
+ * Copyright (C) 2004 IVER T.I. and Generalitat Valenciana.
+ *
+ * This program is free software; you can redistribute it and/or
+ * modify it under the terms of the GNU General Public License
+ * as published by the Free Software Foundation; either version 2
+ * of the License, or (at your option) any later version.
+ *
+ * This program is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
+ * GNU General Public License for more details.
+ *
+ * You should have received a copy of the GNU General Public License
+ * along with this program; if not, write to the Free Software
+ * Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA  02111-1307,USA.
+ *
+ * For more information, contact:
+ *
+ *  Generalitat Valenciana
+ *   Conselleria d'Infraestructures i Transport
+ *   Av. Blasco Ib��ez, 50
+ *   46010 VALENCIA
+ *   SPAIN
+ *
+ *      +34 963862235
+ *   gvsig@gva.es
+ *      www.gvsig.gva.es
+ *
+ *    or
+ *
+ *   IVER T.I. S.A
+ *   Salamanca 50
+ *   46005 Valencia
+ *   Spain
+ *
+ *   +34 963163400
+ *   dac@iver.es
+ */
+package org.gvsig.app.gui.selectionByTheme;
+
+import org.gvsig.fmap.mapcontext.layers.FLayers;
+
+
+public interface SelectionByThemeModel {
+	public FLayers getLayers();
+}

Property changes on: tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/app/gui/selectionByTheme/SelectionByThemeModel.java
___________________________________________________________________
Added: svn:keywords
   + Author Date Id Revision
Added: svn:eol-style
   + native

Index: tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/app/gui/selectionByTheme/DefaultSelectionByThemeModel.java
===================================================================
--- tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/app/gui/selectionByTheme/DefaultSelectionByThemeModel.java	(revision 0)
+++ tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/app/gui/selectionByTheme/DefaultSelectionByThemeModel.java	(revision 38653)
@@ -0,0 +1,69 @@
+/* gvSIG. Sistema de Informaci�n Geogr�fica de la Generalitat Valenciana
+ *
+ * Copyright (C) 2004 IVER T.I. and Generalitat Valenciana.
+ *
+ * This program is free software; you can redistribute it and/or
+ * modify it under the terms of the GNU General Public License
+ * as published by the Free Software Foundation; either version 2
+ * of the License, or (at your option) any later version.
+ *
+ * This program is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
+ * GNU General Public License for more details.
+ *
+ * You should have received a copy of the GNU General Public License
+ * along with this program; if not, write to the Free Software
+ * Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA  02111-1307,USA.
+ *
+ * For more information, contact:
+ *
+ *  Generalitat Valenciana
+ *   Conselleria d'Infraestructures i Transport
+ *   Av. Blasco Ib��ez, 50
+ *   46010 VALENCIA
+ *   SPAIN
+ *
+ *      +34 963862235
+ *   gvsig@gva.es
+ *      www.gvsig.gva.es
+ *
+ *    or
+ *
+ *   IVER T.I. S.A
+ *   Salamanca 50
+ *   46005 Valencia
+ *   Spain
+ *
+ *   +34 963163400
+ *   dac@iver.es
+ */
+package org.gvsig.app.gui.selectionByTheme;
+
+import org.gvsig.andami.PluginServices;
+import org.gvsig.andami.ui.mdiManager.IWindow;
+import org.gvsig.fmap.mapcontext.layers.FLayers;
+
+
+
+
+public class DefaultSelectionByThemeModel
+	implements SelectionByThemeModel {
+
+	private FLayers layers;
+
+	/**
+	 * @see org.gvsig.app.gui.selectionByTheme.SelectionByThemeModel#getViews()
+	 */
+	public FLayers getLayers() {
+		IWindow v = PluginServices.getMDIManager().getActiveWindow();
+		if (v instanceof org.gvsig.app.project.documents.view.gui.DefaultViewPanel){
+			org.gvsig.app.project.documents.view.gui.DefaultViewPanel vista = (org.gvsig.app.project.documents.view.gui.DefaultViewPanel) v;
+			
+			return vista.getModel().getMapContext().getLayers();
+		}
+		
+		return null;
+	}
+
+}

Property changes on: tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/app/gui/selectionByTheme/DefaultSelectionByThemeModel.java
___________________________________________________________________
Added: svn:keywords
   + Author Date Id Revision
Added: svn:eol-style
   + native

Index: tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/app/gui/selectionByTheme/SelectionByThemeListener.java
===================================================================
--- tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/app/gui/selectionByTheme/SelectionByThemeListener.java	(revision 0)
+++ tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/app/gui/selectionByTheme/SelectionByThemeListener.java	(revision 38653)
@@ -0,0 +1,49 @@
+/* gvSIG. Sistema de Informaci�n Geogr�fica de la Generalitat Valenciana
+ *
+ * Copyright (C) 2004 IVER T.I. and Generalitat Valenciana.
+ *
+ * This program is free software; you can redistribute it and/or
+ * modify it under the terms of the GNU General Public License
+ * as published by the Free Software Foundation; either version 2
+ * of the License, or (at your option) any later version.
+ *
+ * This program is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
+ * GNU General Public License for more details.
+ *
+ * You should have received a copy of the GNU General Public License
+ * along with this program; if not, write to the Free Software
+ * Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA  02111-1307,USA.
+ *
+ * For more information, contact:
+ *
+ *  Generalitat Valenciana
+ *   Conselleria d'Infraestructures i Transport
+ *   Av. Blasco Ib��ez, 50
+ *   46010 VALENCIA
+ *   SPAIN
+ *
+ *      +34 963862235
+ *   gvsig@gva.es
+ *      www.gvsig.gva.es
+ *
+ *    or
+ *
+ *   IVER T.I. S.A
+ *   Salamanca 50
+ *   46005 Valencia
+ *   Spain
+ *
+ *   +34 963163400
+ *   dac@iver.es
+ */
+package org.gvsig.app.gui.selectionByTheme;
+
+import org.gvsig.fmap.mapcontext.layers.FLayer;
+
+public interface SelectionByThemeListener {
+	public void newSet(FLayer[] toSelect, FLayer selectionLayer, int action);
+	public void addToSet(FLayer[] toSelect, FLayer selectionLayer, int action);
+	public void fromSet(FLayer[] toSelect, FLayer selectionLayer, int action);
+}

Property changes on: tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/app/gui/selectionByTheme/SelectionByThemeListener.java
___________________________________________________________________
Added: svn:keywords
   + Author Date Id Revision
Added: svn:eol-style
   + native

Index: tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/app/gui/wizards/WizardListenerSupport.java
===================================================================
--- tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/app/gui/wizards/WizardListenerSupport.java	(revision 0)
+++ tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/app/gui/wizards/WizardListenerSupport.java	(revision 38653)
@@ -0,0 +1,95 @@
+/* gvSIG. Sistema de Informaci�n Geogr�fica de la Generalitat Valenciana
+ *
+ * Copyright (C) 2004 IVER T.I. and Generalitat Valenciana.
+ *
+ * This program is free software; you can redistribute it and/or
+ * modify it under the terms of the GNU General Public License
+ * as published by the Free Software Foundation; either version 2
+ * of the License, or (at your option) any later version.
+ *
+ * This program is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
+ * GNU General Public License for more details.
+ *
+ * You should have received a copy of the GNU General Public License
+ * along with this program; if not, write to the Free Software
+ * Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA  02111-1307,USA.
+ *
+ * For more information, contact:
+ *
+ *  Generalitat Valenciana
+ *   Conselleria d'Infraestructures i Transport
+ *   Av. Blasco Ib��ez, 50
+ *   46010 VALENCIA
+ *   SPAIN
+ *
+ *      +34 963862235
+ *   gvsig@gva.es
+ *      www.gvsig.gva.es
+ *
+ *    or
+ *
+ *   IVER T.I. S.A
+ *   Salamanca 50
+ *   46005 Valencia
+ *   Spain
+ *
+ *   +34 963163400
+ *   dac@iver.es
+ */
+package org.gvsig.app.gui.wizards;
+
+import java.util.ArrayList;
+import java.util.Iterator;
+
+
+/**
+ * DOCUMENT ME!
+ *
+ * @author Fernando Gonz�lez Cort�s
+ */
+public class WizardListenerSupport {
+    private ArrayList listeners = new ArrayList();
+
+    /**
+     * DOCUMENT ME!
+     *
+     * @param listener DOCUMENT ME!
+     */
+    public void addWizardListener(WizardListener listener) {
+        listeners.add(listener);
+    }
+
+    /**
+     * DOCUMENT ME!
+     *
+     * @param listener DOCUMENT ME!
+     */
+    public void removeWizardListener(WizardListener listener) {
+        listeners.remove(listener);
+    }
+
+	/**
+	 * DOCUMENT ME!
+	 * @param finishable TODO
+	 */
+	public void callStateChanged(boolean finishable) {
+		Iterator i = listeners.iterator();
+
+		while (i.hasNext()) {
+			((WizardListener) i.next()).wizardStateChanged(finishable);
+		}
+	}
+
+	/**
+	 * DOCUMENT ME!
+	 */
+	public void callError(Exception descripcion) {
+		Iterator i = listeners.iterator();
+
+		while (i.hasNext()) {
+			((WizardListener) i.next()).error(descripcion);
+		}
+	}
+}

Property changes on: tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/app/gui/wizards/WizardListenerSupport.java
___________________________________________________________________
Added: svn:keywords
   + Author Date Id Revision
Added: svn:eol-style
   + native

Index: tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/app/gui/wizards/FormatListModel.java
===================================================================
--- tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/app/gui/wizards/FormatListModel.java	(revision 0)
+++ tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/app/gui/wizards/FormatListModel.java	(revision 38653)
@@ -0,0 +1,76 @@
+/* gvSIG. Sistema de Informaci�n Geogr�fica de la Generalitat Valenciana
+ *
+ * Copyright (C) 2004 IVER T.I. and Generalitat Valenciana.
+ *
+ * This program is free software; you can redistribute it and/or
+ * modify it under the terms of the GNU General Public License
+ * as published by the Free Software Foundation; either version 2
+ * of the License, or (at your option) any later version.
+ *
+ * This program is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
+ * GNU General Public License for more details.
+ *
+ * You should have received a copy of the GNU General Public License
+ * along with this program; if not, write to the Free Software
+ * Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA  02111-1307,USA.
+ *
+ * For more information, contact:
+ *
+ *  Generalitat Valenciana
+ *   Conselleria d'Infraestructures i Transport
+ *   Av. Blasco Ib��ez, 50
+ *   46010 VALENCIA
+ *   SPAIN
+ *
+ *      +34 963862235
+ *   gvsig@gva.es
+ *      www.gvsig.gva.es
+ *
+ *    or
+ *
+ *   IVER T.I. S.A
+ *   Salamanca 50
+ *   46005 Valencia
+ *   Spain
+ *
+ *   +34 963163400
+ *   dac@iver.es
+ */
+package org.gvsig.app.gui.wizards;
+
+import javax.swing.AbstractListModel;
+
+
+/**
+ * DOCUMENT ME!
+ *
+ * @author Fernando Gonz�lez Cort�s
+ */
+public class FormatListModel extends AbstractListModel {
+    String[] formatos;
+
+    /**
+     * Creates a new FormatListModel object.
+     *
+     * @param f DOCUMENT ME!
+     */
+    public FormatListModel(String[] f) {
+        formatos = f;
+    }
+
+    /**
+     * @see javax.swing.ListModel#getSize()
+     */
+    public int getSize() {
+        return formatos.length;
+    }
+
+    /**
+     * @see javax.swing.ListModel#getElementAt(int)
+     */
+    public Object getElementAt(int index) {
+        return formatos[index];
+    }
+}

Property changes on: tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/app/gui/wizards/FormatListModel.java
___________________________________________________________________
Added: svn:keywords
   + Author Date Id Revision
Added: svn:eol-style
   + native

Index: tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/app/gui/wizards/WizardListener.java
===================================================================
--- tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/app/gui/wizards/WizardListener.java	(revision 0)
+++ tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/app/gui/wizards/WizardListener.java	(revision 38653)
@@ -0,0 +1,62 @@
+/* gvSIG. Sistema de Informaci�n Geogr�fica de la Generalitat Valenciana
+ *
+ * Copyright (C) 2004 IVER T.I. and Generalitat Valenciana.
+ *
+ * This program is free software; you can redistribute it and/or
+ * modify it under the terms of the GNU General Public License
+ * as published by the Free Software Foundation; either version 2
+ * of the License, or (at your option) any later version.
+ *
+ * This program is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
+ * GNU General Public License for more details.
+ *
+ * You should have received a copy of the GNU General Public License
+ * along with this program; if not, write to the Free Software
+ * Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA  02111-1307,USA.
+ *
+ * For more information, contact:
+ *
+ *  Generalitat Valenciana
+ *   Conselleria d'Infraestructures i Transport
+ *   Av. Blasco Ib��ez, 50
+ *   46010 VALENCIA
+ *   SPAIN
+ *
+ *      +34 963862235
+ *   gvsig@gva.es
+ *      www.gvsig.gva.es
+ *
+ *    or
+ *
+ *   IVER T.I. S.A
+ *   Salamanca 50
+ *   46005 Valencia
+ *   Spain
+ *
+ *   +34 963163400
+ *   dac@iver.es
+ */
+package org.gvsig.app.gui.wizards;
+
+/**
+ * DOCUMENT ME!
+ *
+ * @author $author$
+ */
+public interface WizardListener {
+
+	/**
+	 * Invocado cuando el wizard puede ser finalizado porque se
+	 * ha rellenado toda la informaci�n necesaria
+	 */
+	public void wizardStateChanged(boolean finishable);
+	
+	/**
+	 * Si se produce alg�n error
+	 *
+	 * @param e Excepci�n que se ha producido
+	 */
+	public void error(Exception e);
+}

Property changes on: tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/app/gui/wizards/WizardListener.java
___________________________________________________________________
Added: svn:keywords
   + Author Date Id Revision
Added: svn:eol-style
   + native

Index: tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/app/gui/wizards/LayerInfo.java
===================================================================
--- tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/app/gui/wizards/LayerInfo.java	(revision 0)
+++ tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/app/gui/wizards/LayerInfo.java	(revision 38653)
@@ -0,0 +1,107 @@
+/* gvSIG. Sistema de Informaci�n Geogr�fica de la Generalitat Valenciana
+ *
+ * Copyright (C) 2004 IVER T.I. and Generalitat Valenciana.
+ *
+ * This program is free software; you can redistribute it and/or
+ * modify it under the terms of the GNU General Public License
+ * as published by the Free Software Foundation; either version 2
+ * of the License, or (at your option) any later version.
+ *
+ * This program is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
+ * GNU General Public License for more details.
+ *
+ * You should have received a copy of the GNU General Public License
+ * along with this program; if not, write to the Free Software
+ * Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA  02111-1307,USA.
+ *
+ * For more information, contact:
+ *
+ *  Generalitat Valenciana
+ *   Conselleria d'Infraestructures i Transport
+ *   Av. Blasco Ib��ez, 50
+ *   46010 VALENCIA
+ *   SPAIN
+ *
+ *      +34 963862235
+ *   gvsig@gva.es
+ *      www.gvsig.gva.es
+ *
+ *    or
+ *
+ *   IVER T.I. S.A
+ *   Salamanca 50
+ *   46005 Valencia
+ *   Spain
+ *
+ *   +34 963163400
+ *   dac@iver.es
+ */
+package org.gvsig.app.gui.wizards;
+
+import java.util.ArrayList;
+
+
+//	Nodo[] nodos;
+public class LayerInfo {
+    public String text;
+    public String name;
+    public boolean queryable;
+    private ArrayList srs = new ArrayList();
+    
+    public ArrayList hijos = new ArrayList();
+    public LayerInfo padre;
+
+    /**
+     * DOCUMENT ME!
+     *
+     * @param srs DOCUMENT ME!
+     */
+    public void addSRS(String srs) {
+    	String[] srsArray = srs.split(" ");
+    	for (int i = 0; i < srsArray.length; i++){
+			this.srs.add(srsArray[i]);
+    	}
+    }
+
+    /**
+     * DOCUMENT ME!
+     *
+     * @return DOCUMENT ME!
+     */
+    public ArrayList getSRSs() {
+		ArrayList ret = new ArrayList();
+		ret.addAll(srs);
+
+        if (padre != null) {
+            ret.addAll(padre.getSRSs());
+        }
+
+        return ret;
+    }
+
+    /**
+     * DOCUMENT ME!
+     *
+     * @return DOCUMENT ME!
+     */
+    public String toString() {
+        return text;
+    }
+
+    /* (non-Javadoc)
+     * @see java.lang.Object#equals(java.lang.Object)
+     */
+    public boolean equals(Object obj) {
+    	try{
+	        LayerInfo objeto = (LayerInfo) obj;
+			return this.name.equals(objeto.name);
+		}catch(ClassCastException e){
+			e.printStackTrace();
+			return false;
+		}catch (NullPointerException e) {
+			return false;
+		}
+    }
+}

Property changes on: tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/app/gui/wizards/LayerInfo.java
___________________________________________________________________
Added: svn:keywords
   + Author Date Id Revision
Added: svn:eol-style
   + native

Index: tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/app/gui/wizards/LayerListModel.java
===================================================================
--- tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/app/gui/wizards/LayerListModel.java	(revision 0)
+++ tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/app/gui/wizards/LayerListModel.java	(revision 38653)
@@ -0,0 +1,144 @@
+/* gvSIG. Sistema de Informaci�n Geogr�fica de la Generalitat Valenciana
+ *
+ * Copyright (C) 2004 IVER T.I. and Generalitat Valenciana.
+ *
+ * This program is free software; you can redistribute it and/or
+ * modify it under the terms of the GNU General Public License
+ * as published by the Free Software Foundation; either version 2
+ * of the License, or (at your option) any later version.
+ *
+ * This program is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
+ * GNU General Public License for more details.
+ *
+ * You should have received a copy of the GNU General Public License
+ * along with this program; if not, write to the Free Software
+ * Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA  02111-1307,USA.
+ *
+ * For more information, contact:
+ *
+ *  Generalitat Valenciana
+ *   Conselleria d'Infraestructures i Transport
+ *   Av. Blasco Ib��ez, 50
+ *   46010 VALENCIA
+ *   SPAIN
+ *
+ *      +34 963862235
+ *   gvsig@gva.es
+ *      www.gvsig.gva.es
+ *
+ *    or
+ *
+ *   IVER T.I. S.A
+ *   Salamanca 50
+ *   46005 Valencia
+ *   Spain
+ *
+ *   +34 963163400
+ *   dac@iver.es
+ */
+package org.gvsig.app.gui.wizards;
+
+import java.util.ArrayList;
+import java.util.Collection;
+
+import javax.swing.AbstractListModel;
+
+
+/**
+ * DOCUMENT ME!
+ *
+ * @author Fernando Gonz�lez Cort�s
+ */
+public class LayerListModel extends AbstractListModel {
+    private ArrayList nodos = new ArrayList();
+
+    /**
+     * DOCUMENT ME!
+     *
+     * @param elemento DOCUMENT ME!
+     *
+     * @return DOCUMENT ME!
+     */
+    public boolean addElement(LayerInfo elemento) {
+        if (elemento == null) {
+            return false;
+        }
+
+        for (int i = 0; i < nodos.size(); i++) {
+            if (((LayerInfo) nodos.get(i)).equals(elemento)) {
+                return false;
+            }
+        }
+
+        nodos.add(elemento);
+
+        fireContentsChanged(this, nodos.size() - 1, nodos.size() - 1);
+
+        return true;
+    }
+
+	public void clear(){
+		nodos.clear();
+		fireContentsChanged(this, 0, 0);
+	}
+
+    /**
+     * DOCUMENT ME!
+     *
+     * @param index DOCUMENT ME!
+     *
+     * @return DOCUMENT ME!
+     */
+    public LayerInfo delElement(int index) {
+        LayerInfo ret = (LayerInfo) nodos.remove(index);
+        this.fireContentsChanged(this, index, index);
+
+        return ret;
+    }
+
+    /**
+     * DOCUMENT ME!
+     *
+     * @param c DOCUMENT ME!
+     */
+    public void delElements(Collection c) {
+        nodos.removeAll(c);
+        this.fireContentsChanged(this, 0, nodos.size());
+    }
+
+    /**
+     * @see javax.swing.ListModel#getSize()
+     */
+    public int getSize() {
+        return nodos.size();
+    }
+
+    /**
+     * @see javax.swing.ListModel#getElementAt(int)
+     */
+    public Object getElementAt(int index) {
+        return ((LayerInfo) nodos.get(index)).text;
+    }
+
+    /**
+     * DOCUMENT ME!
+     *
+     * @return DOCUMENT ME!
+     */
+    public LayerInfo[] getElements() {
+        return (LayerInfo[]) nodos.toArray(new LayerInfo[0]);
+    }
+
+    /**
+     * DOCUMENT ME!
+     *
+     * @param index DOCUMENT ME!
+     *
+     * @return DOCUMENT ME!
+     */
+    public LayerInfo getLayerInfo(int index) {
+        return (LayerInfo) nodos.get(index);
+    }
+}

Property changes on: tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/app/gui/wizards/LayerListModel.java
___________________________________________________________________
Added: svn:eol-style
   + native
Added: svn:keywords
   + Author Date Id Revision

Index: tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/app/gui/wizards/WizardData.java
===================================================================
--- tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/app/gui/wizards/WizardData.java	(revision 0)
+++ tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/app/gui/wizards/WizardData.java	(revision 38653)
@@ -0,0 +1,125 @@
+/* gvSIG. Sistema de Informaci�n Geogr�fica de la Generalitat Valenciana
+ *
+ * Copyright (C) 2004 IVER T.I. and Generalitat Valenciana.
+ *
+ * This program is free software; you can redistribute it and/or
+ * modify it under the terms of the GNU General Public License
+ * as published by the Free Software Foundation; either version 2
+ * of the License, or (at your option) any later version.
+ *
+ * This program is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
+ * GNU General Public License for more details.
+ *
+ * You should have received a copy of the GNU General Public License
+ * along with this program; if not, write to the Free Software
+ * Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA  02111-1307,USA.
+ *
+ * For more information, contact:
+ *
+ *  Generalitat Valenciana
+ *   Conselleria d'Infraestructures i Transport
+ *   Av. Blasco Ib��ez, 50
+ *   46010 VALENCIA
+ *   SPAIN
+ *
+ *      +34 963862235
+ *   gvsig@gva.es
+ *      www.gvsig.gva.es
+ *
+ *    or
+ *
+ *   IVER T.I. S.A
+ *   Salamanca 50
+ *   46005 Valencia
+ *   Spain
+ *
+ *   +34 963163400
+ *   dac@iver.es
+ */
+package org.gvsig.app.gui.wizards;
+
+/**
+ * DOCUMENT ME!
+ *
+ * @author Fernando Gonz�lez Cort�s
+ */
+public class WizardData {
+    private String title;
+    private String Abstract;
+    private LayerInfo layer;
+    private String[] formats;
+
+    /**
+     * DOCUMENT ME!
+     *
+     * @return
+     */
+    public String getAbstract() {
+        return Abstract;
+    }
+
+    /**
+     * DOCUMENT ME!
+     *
+     * @return
+     */
+    public String[] getFormats() {
+        return formats;
+    }
+
+    /**
+     * DOCUMENT ME!
+     *
+     * @return
+     */
+    public LayerInfo getLayer() {
+        return layer;
+    }
+
+    /**
+     * DOCUMENT ME!
+     *
+     * @return
+     */
+    public String getTitle() {
+        return title;
+    }
+
+    /**
+     * DOCUMENT ME!
+     *
+     * @param string
+     */
+    public void setAbstract(String string) {
+        Abstract = string;
+    }
+
+    /**
+     * DOCUMENT ME!
+     *
+     * @param strings
+     */
+    public void setFormats(String[] strings) {
+        formats = strings;
+    }
+
+    /**
+     * DOCUMENT ME!
+     *
+     * @param info
+     */
+    public void setLayer(LayerInfo info) {
+        layer = info;
+    }
+
+    /**
+     * DOCUMENT ME!
+     *
+     * @param string
+     */
+    public void setTitle(String string) {
+        title = string;
+    }
+}

Property changes on: tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/app/gui/wizards/WizardData.java
___________________________________________________________________
Added: svn:keywords
   + Author Date Id Revision
Added: svn:eol-style
   + native

Index: tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/app/gui/wizards/WizardDataSource.java
===================================================================
--- tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/app/gui/wizards/WizardDataSource.java	(revision 0)
+++ tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/app/gui/wizards/WizardDataSource.java	(revision 38653)
@@ -0,0 +1,69 @@
+/*
+ * Created on 09-sep-2004
+ *
+ * To change the template for this generated file go to
+ * Window&gt;Preferences&gt;Java&gt;Code Generation&gt;Code and Comments
+ */
+/* gvSIG. Sistema de Informaci�n Geogr�fica de la Generalitat Valenciana
+ *
+ * Copyright (C) 2004 IVER T.I. and Generalitat Valenciana.
+ *
+ * This program is free software; you can redistribute it and/or
+ * modify it under the terms of the GNU General Public License
+ * as published by the Free Software Foundation; either version 2
+ * of the License, or (at your option) any later version.
+ *
+ * This program is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
+ * GNU General Public License for more details.
+ *
+ * You should have received a copy of the GNU General Public License
+ * along with this program; if not, write to the Free Software
+ * Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA  02111-1307,USA.
+ *
+ * For more information, contact:
+ *
+ *  Generalitat Valenciana
+ *   Conselleria d'Infraestructures i Transport
+ *   Av. Blasco Ib��ez, 50
+ *   46010 VALENCIA
+ *   SPAIN
+ *
+ *      +34 963862235
+ *   gvsig@gva.es
+ *      www.gvsig.gva.es
+ *
+ *    or
+ *
+ *   IVER T.I. S.A
+ *   Salamanca 50
+ *   46005 Valencia
+ *   Spain
+ *
+ *   +34 963163400
+ *   dac@iver.es
+ */
+package org.gvsig.app.gui.wizards;
+
+import java.awt.geom.Rectangle2D;
+import java.io.IOException;
+import java.net.URL;
+
+import org.exolab.castor.xml.ValidationException;
+import org.gvsig.fmap.mapcontext.exceptions.UnsupportedVersionLayerException;
+
+
+/**
+ * @author fernando
+ *
+ * To change the template for this generated type comment go to
+ * Window&gt;Preferences&gt;Java&gt;Code Generation&gt;Code and Comments
+ */
+public interface WizardDataSource {
+	public WizardData detalles(URL host)throws IllegalStateException, ValidationException, 
+	UnsupportedVersionLayerException, IOException ;
+	
+	public Rectangle2D getBoundingBox(String[] layerName, String srs);
+
+}

Property changes on: tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/app/gui/wizards/WizardDataSource.java
___________________________________________________________________
Added: svn:keywords
   + Author Date Id Revision
Added: svn:eol-style
   + native

Index: tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/app/gui/ILayerPanel.java
===================================================================
--- tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/app/gui/ILayerPanel.java	(revision 0)
+++ tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/app/gui/ILayerPanel.java	(revision 38653)
@@ -0,0 +1,24 @@
+package org.gvsig.app.gui;
+
+import org.gvsig.fmap.mapcontext.layers.FLayer;
+
+/**
+ * @author fjp
+ *
+ * Interfaz que se usa por las nuevas capas que necesiten definir
+ * una capa que todav�a no existe en gvSIG.
+ * Para usarlo, en una extensi�n aparter, se define un JPanel
+ * que implemente este interfaz, y luego se a�ade al Wizard 
+ * correspondiente.
+ * Por ejemplo, cuando se crea una nueva capa, existe un Wizard
+ * del tipo JWizardComponents en la clase NewTheme de extCAD
+ * (o extEdition, como quiera que se llame al final)
+ */
+public interface ILayerPanel {
+	/**
+	 * Creates a FLyrWFS.
+	 * 
+	 * @return the layer
+	 */
+	public FLayer getLayer();
+}
\ No newline at end of file

Property changes on: tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/app/gui/ILayerPanel.java
___________________________________________________________________
Added: svn:keywords
   + Author Date Id Revision
Added: svn:eol-style
   + native

Index: tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/app/gui/filter/FilterException.java
===================================================================
--- tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/app/gui/filter/FilterException.java	(revision 0)
+++ tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/app/gui/filter/FilterException.java	(revision 38653)
@@ -0,0 +1,62 @@
+/* gvSIG. Sistema de Informaci�n Geogr�fica de la Generalitat Valenciana
+ *
+ * Copyright (C) 2004 IVER T.I. and Generalitat Valenciana.
+ *
+ * This program is free software; you can redistribute it and/or
+ * modify it under the terms of the GNU General Public License
+ * as published by the Free Software Foundation; either version 2
+ * of the License, or (at your option) any later version.
+ *
+ * This program is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
+ * GNU General Public License for more details.
+ *
+ * You should have received a copy of the GNU General Public License
+ * along with this program; if not, write to the Free Software
+ * Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA  02111-1307,USA.
+ *
+ * For more information, contact:
+ *
+ *  Generalitat Valenciana
+ *   Conselleria d'Infraestructures i Transport
+ *   Av. Blasco Ib��ez, 50
+ *   46010 VALENCIA
+ *   SPAIN
+ *
+ *      +34 963862235
+ *   gvsig@gva.es
+ *      www.gvsig.gva.es
+ *
+ *    or
+ *
+ *   IVER T.I. S.A
+ *   Salamanca 50
+ *   46005 Valencia
+ *   Spain
+ *
+ *   +34 963163400
+ *   dac@iver.es
+ */
+package org.gvsig.app.gui.filter;
+
+import java.util.Map;
+
+import org.gvsig.tools.exception.BaseException;
+
+
+public class FilterException extends BaseException {
+
+	/**
+	 *
+	 */
+	public FilterException() {
+		super();
+
+	}
+
+	protected Map values() {
+		// TODO Auto-generated method stub
+		return null;
+	}
+}

Property changes on: tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/app/gui/filter/FilterException.java
___________________________________________________________________
Added: svn:keywords
   + Author Date Id Revision
Added: svn:eol-style
   + native

Index: tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/app/gui/filter/ExpressionListener.java
===================================================================
--- tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/app/gui/filter/ExpressionListener.java	(revision 0)
+++ tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/app/gui/filter/ExpressionListener.java	(revision 38653)
@@ -0,0 +1,51 @@
+/* gvSIG. Sistema de Informaci�n Geogr�fica de la Generalitat Valenciana
+ *
+ * Copyright (C) 2004 IVER T.I. and Generalitat Valenciana.
+ *
+ * This program is free software; you can redistribute it and/or
+ * modify it under the terms of the GNU General Public License
+ * as published by the Free Software Foundation; either version 2
+ * of the License, or (at your option) any later version.
+ *
+ * This program is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
+ * GNU General Public License for more details.
+ *
+ * You should have received a copy of the GNU General Public License
+ * along with this program; if not, write to the Free Software
+ * Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA  02111-1307,USA.
+ *
+ * For more information, contact:
+ *
+ *  Generalitat Valenciana
+ *   Conselleria d'Infraestructures i Transport
+ *   Av. Blasco Ib��ez, 50
+ *   46010 VALENCIA
+ *   SPAIN
+ *
+ *      +34 963862235
+ *   gvsig@gva.es
+ *      www.gvsig.gva.es
+ *
+ *    or
+ *
+ *   IVER T.I. S.A
+ *   Salamanca 50
+ *   46005 Valencia
+ *   Spain
+ *
+ *   +34 963163400
+ *   dac@iver.es
+ */
+package org.gvsig.app.gui.filter;
+
+import org.gvsig.fmap.dal.exception.DataException;
+
+public interface ExpressionListener {
+	public void newSet(String expression) throws DataException;
+
+	public void addToSet(String expression) throws DataException;
+
+	public void fromSet(String expression) throws DataException;
+}

Property changes on: tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/app/gui/filter/ExpressionListener.java
___________________________________________________________________
Added: svn:eol-style
   + native
Added: svn:keywords
   + Author Date Id Revision

Index: tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/app/gui/filter/FilterDialog.java
===================================================================
--- tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/app/gui/filter/FilterDialog.java	(revision 0)
+++ tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/app/gui/filter/FilterDialog.java	(revision 38653)
@@ -0,0 +1,725 @@
+/* gvSIG. Sistema de Informaci�n Geogr�fica de la Generalitat Valenciana
+ *
+ * Copyright (C) 2004 IVER T.I. and Generalitat Valenciana.
+ *
+ * This program is free software; you can redistribute it and/or
+ * modify it under the terms of the GNU General Public License
+ * as published by the Free Software Foundation; either version 2
+ * of the License, or (at your option) any later version.
+ *
+ * This program is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
+ * GNU General Public License for more details.
+ *
+ * You should have received a copy of the GNU General Public License
+ * along with this program; if not, write to the Free Software
+ * Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA  02111-1307,USA.
+ *
+ * For more information, contact:
+ *
+ *  Generalitat Valenciana
+ *   Conselleria d'Infraestructures i Transport
+ *   Av. Blasco Ib��ez, 50
+ *   46010 VALENCIA
+ *   SPAIN
+ *
+ *      +34 963862235
+ *   gvsig@gva.es
+ *      www.gvsig.gva.es
+ *
+ *    or
+ *
+ *   IVER T.I. S.A
+ *   Salamanca 50
+ *   46005 Valencia
+ *   Spain
+ *
+ *   +34 963163400
+ *   dac@iver.es
+ */
+package org.gvsig.app.gui.filter;
+
+import java.awt.event.MouseAdapter;
+import java.awt.event.MouseEvent;
+import java.text.NumberFormat;
+import java.text.ParseException;
+import java.util.ArrayList;
+import java.util.Collection;
+import java.util.Comparator;
+import java.util.Date;
+import java.util.Iterator;
+import java.util.TreeSet;
+import java.util.regex.Matcher;
+import java.util.regex.Pattern;
+
+import javax.swing.tree.DefaultMutableTreeNode;
+import javax.swing.tree.DefaultTreeModel;
+
+import org.slf4j.Logger;
+import org.slf4j.LoggerFactory;
+
+import org.gvsig.andami.PluginServices;
+import org.gvsig.andami.messages.NotificationManager;
+import org.gvsig.andami.ui.mdiManager.IWindow;
+import org.gvsig.andami.ui.mdiManager.IWindowListener;
+import org.gvsig.andami.ui.mdiManager.WindowInfo;
+import org.gvsig.fmap.dal.exception.DataException;
+import org.gvsig.fmap.dal.feature.Feature;
+import org.gvsig.fmap.dal.feature.FeatureAttributeDescriptor;
+import org.gvsig.fmap.dal.feature.FeatureQuery;
+import org.gvsig.fmap.dal.feature.FeatureSet;
+import org.gvsig.fmap.dal.feature.FeatureStore;
+import org.gvsig.gui.beans.filterPanel.tableFilterQueryPanel.TableFilterQueryJPanel;
+import org.gvsig.tools.dispose.DisposableIterator;
+import org.gvsig.tools.dispose.DisposeUtils;
+import org.gvsig.utils.DefaultCharSet;
+import org.gvsig.utils.StringUtilities;
+import org.gvsig.utils.exceptionHandling.ExceptionHandlingSupport;
+import org.gvsig.utils.exceptionHandling.ExceptionListener;
+
+/**
+ * This class substitutes the old "FilterDialog" class made by
+ * "Fernando Gonz�lez Cort�s"
+ * The functionality is the same, but now the class is made from separately (and
+ * reusable) components
+ * 
+ * @author Pablo Piqueras Bartolom� (p_queras@hotmail.com)
+ */
+public class FilterDialog extends TableFilterQueryJPanel implements IWindow,
+    IWindowListener {
+
+    /**
+     * 
+     */
+    private static final long serialVersionUID = -149317534873551735L;
+    private static final Logger logger =
+        LoggerFactory.getLogger(FilterDialog.class);
+    private FeatureStore model = null;
+    private ArrayList expressionListeners = new ArrayList();
+    private ExceptionHandlingSupport exceptionHandlingSupport =
+        new ExceptionHandlingSupport();
+    private NumberFormat nf = NumberFormat.getNumberInstance();
+
+    private String title;
+
+    private final int filterDialog_Width = 500;
+    private final int filterDialog_Height = 362;
+    private final int widthIncrementForAndami = 20; // This is necessary because
+                                                    // when the panel is sent to
+                                                    // Andami, that needs a bit
+                                                    // more width-space to show
+                                                    // that panel.
+
+    /**
+     * This is the default constructor
+     */
+    public FilterDialog(String _title) {
+        super();
+        title = _title;
+        defaultTreeModel = (DefaultTreeModel) fieldsJTree.getModel();
+    }
+
+    /**
+     * This is the default constructor
+     */
+    public FilterDialog() {
+        super();
+        defaultTreeModel = (DefaultTreeModel) fieldsJTree.getModel();
+    }
+
+    /*
+     * (non-Javadoc)
+     * 
+     * @see
+     * org.gvsig.gui.beans.filterPanel.AbstractFilterQueryJPanel#initialize()
+     */
+    @Override
+    protected void initialize() {
+        super.initialize();
+
+        super.resizeHeight(filterDialog_Height);
+        super.resizeWidth(filterDialog_Width - widthIncrementForAndami);
+
+        this.addNewListeners();
+    }
+
+    /**
+     * Adds some listeners
+     */
+    private void addNewListeners() {
+        // Listener for "btnAdd"
+        // Adds more elements to the current set
+        getBtnAddToCurrentSet().addActionListener(
+            new java.awt.event.ActionListener() {
+
+                /*
+                 * (non-Javadoc)
+                 * 
+                 * @see
+                 * java.awt.event.ActionListener#actionPerformed(java.awt.event
+                 * .ActionEvent)
+                 */
+                public void actionPerformed(java.awt.event.ActionEvent e) {
+                    // final String expr = "select * from '" +
+                    // model.getName() + "' where " +
+                    // getTxtExpression().getText() + ";";
+                    final String expr = getTxtExpression().getText();
+                    logger.debug(expr);
+
+                    PluginServices.backgroundExecution(new Runnable() {
+
+                        public void run() {
+                            for (int i = 0; i < expressionListeners.size(); i++) {
+                                ExpressionListener l =
+                                    (ExpressionListener) expressionListeners
+                                        .get(i);
+                                try {
+                                    l.addToSet(expr);
+                                } catch (DataException e) {
+                                    e.printStackTrace();
+                                }
+                            }
+                        }
+                    });
+                }
+            });
+
+        // Listener for "btnNuevo"
+        // Adds a new set
+        getBtnNewSet().addActionListener(new java.awt.event.ActionListener() {
+
+            public void actionPerformed(java.awt.event.ActionEvent e) {
+                // final String expr = "select * from '" +
+                // model.getName() + "' where " +
+                // getTxtExpression().getText() + ";";
+                final String expr = getTxtExpression().getText();
+
+                logger.debug(expr);
+
+                PluginServices.backgroundExecution(new Runnable() {
+
+                    public void run() {
+                        for (int i = 0; i < expressionListeners.size(); i++) {
+                            ExpressionListener l =
+                                (ExpressionListener) expressionListeners.get(i);
+                            try {
+                                l.newSet(expr);
+                            } catch (DataException e) {
+                                // TODO Auto-generated catch block
+                                NotificationManager.addError(e);
+                            }
+                        }
+                    }
+                });
+            }
+        });
+
+        // Listener for "btnFromSet"
+        // Selects elements from the current filtered selection
+        getBtnFromSet().addActionListener(new java.awt.event.ActionListener() {
+
+            public void actionPerformed(java.awt.event.ActionEvent e) {
+                // final String expr = "select * from '" +
+                // model.getName() + "' where " +
+                // getTxtExpression().getText() + ";";
+                final String expr = getTxtExpression().getText();
+                logger.debug(expr);
+
+                PluginServices.backgroundExecution(new Runnable() {
+
+                    public void run() {
+                        for (int i = 0; i < expressionListeners.size(); i++) {
+                            ExpressionListener l =
+                                (ExpressionListener) expressionListeners.get(i);
+                            try {
+                                l.fromSet(expr);
+                            } catch (DataException e) {
+                                NotificationManager.addError(e);
+                            }
+                        }
+                    }
+                });
+            }
+        });
+
+        // Listener for "fieldsJTree"
+        getFieldsJTree().addMouseListener(new MouseAdapter() {
+
+            /*
+             * (non-Javadoc)
+             * 
+             * @see
+             * java.awt.event.MouseListener#mouseClicked(java.awt.event.MouseEvent
+             * )
+             */
+            @Override
+            public void mouseClicked(MouseEvent e) {
+                int row = fieldsJTree.getRowForLocation(e.getX(), e.getY());
+
+                if (row > -1) {
+                    switch (e.getClickCount()) {
+                    case 1:
+                        fillValues(row);
+                        break;
+                    case 2:
+                        putSymbol(jtreeRoot.getChildAt(row).toString());
+                        break;
+                    }
+                }
+            }
+        });
+
+        // Listener for "valuesJList"
+        getValuesJList().addMouseListener(new MouseAdapter() {
+
+            /*
+             * (non-Javadoc)
+             * 
+             * @see
+             * java.awt.event.MouseListener#mouseClicked(java.awt.event.MouseEvent
+             * )
+             */
+            @Override
+            public void mouseClicked(MouseEvent e) {
+                if (e.getClickCount() == 2) {
+                    Object valor =
+                        valuesListModel.getElementAt(getValuesJList()
+                            .getSelectedIndex());
+
+                    if (valor instanceof Date) {
+                        putSymbol("date('" + valor + "')");
+                    } else
+                        if (valor instanceof Boolean) {
+                            putSymbol("boolean('" + valor.toString() + "')");
+                        } else
+                            if (valor instanceof String) {
+                                putSymbol("'" + valor + "'");
+                            } else {
+                                putSymbol(valor.toString());
+                            }
+                }
+            }
+        });
+    }
+
+    /**
+     * Rellena la lista con los valores del campo seleccionado
+     */
+    private void fillValues(int row) {
+        // int index = lstCampos.getSelectedIndex();
+
+        // Index es ahora el �ndice del campo seleccionado
+        // Se eliminan los duplicados
+        Collection conjunto = new TreeSet(new Comparator() {
+
+            public int compare(Object o1, Object o2) {
+                return ((Comparable) o1).compareTo(o2);
+            }
+        }); // Para poder ordenar
+
+        valuesListModel.clear();
+        FeatureSet fs = null;
+        DisposableIterator iterator = null;
+        try {
+            String[] fieldName =
+                new String[] { ((FeatureAttributeDescriptor) model
+                    .getDefaultFeatureType().get(row)).getName() };
+
+            FeatureQuery query = model.createFeatureQuery();
+            query.setAttributeNames(fieldName);
+            fs = model.getFeatureSet(query);
+            iterator = fs.iterator();
+            while (iterator.hasNext()) {
+                Feature feature = (Feature) iterator.next();
+                Object value = feature.get(fieldName[0]);
+                if (value == null) {
+                    continue;
+                }
+
+                conjunto.add(value);
+            }
+
+            Iterator it = conjunto.iterator();
+
+            while (it.hasNext()) {
+                valuesListModel.addElement(it.next());
+            }
+        } catch (DataException e) {
+            throwException(e);
+        } finally {
+            DisposeUtils.dispose(iterator);
+            DisposeUtils.dispose(fs);
+        }
+    }
+
+    /**
+     * DOCUMENT ME!
+     * 
+     * @param t
+     *            DOCUMENT ME!
+     */
+    public void setModel(FeatureStore t) {
+        // try {
+        model = t;
+        // model.start();
+        // } catch (ReadException e1) {
+        // NotificationManager.addError(e1.getMessage(), e1);
+        // }
+
+        jtreeRoot.removeAllChildren();
+
+        try {
+            Iterator attributes = model.getDefaultFeatureType().iterator();
+            while (attributes.hasNext()) {
+                FeatureAttributeDescriptor descriptor =
+                    (FeatureAttributeDescriptor) attributes.next();
+                Object field = descriptor.getName();
+
+                if (field != null) {
+                    jtreeRoot.add(new DefaultMutableTreeNode(field.toString()));
+                }
+            }
+            // for (int i = 0; i < model.getFieldCount(); i++) {
+            // Object field = model.getFieldName(i);
+            //
+            // if (field != null) {
+            // jtreeRoot.add(new DefaultMutableTreeNode(field.toString()));
+            // }
+            // }
+
+            defaultTreeModel.setRoot(jtreeRoot);
+        } catch (DataException e) {
+            throwException(e);
+        }
+    }
+
+    /**
+     * DOCUMENT ME!
+     * 
+     * @return DOCUMENT ME!
+     * 
+     * @throws ParseException
+     *             DOCUMENT ME!
+     */
+    private String validateExpression() throws ParseException {
+        String expression = txtExpression.getText();
+        // HashSet variablesIndexes = new HashSet();
+        //
+        // StringBuffer traducida = new StringBuffer();
+
+        // Se transforman los nombres de los campos en las variables xix que
+        // analizar�n
+        // Se quitan los Date(fecha) y se mete la fecha correspondiente
+        expression = translateDates(expression);
+        expression = translateNumber(expression);
+        expression = translateWord(expression, "true", "1");
+        expression = translateWord(expression, "false", "0");
+
+        String replacement;
+        Pattern patron = Pattern.compile("[^<>!]=");
+        Matcher m = patron.matcher(expression);
+        int index = 0;
+
+        while (m.find(index)) {
+            index = m.start();
+            replacement = expression.charAt(index) + "==";
+            m.replaceFirst(replacement);
+            index++;
+        }
+
+        expression = expression.replaceAll("[^<>!]=", "==");
+
+        logger.debug(expression);
+
+        return expression;
+    }
+
+    /**
+     * Redefinition of the 'putSymbol' method of AbstractFilterQueryJPanel
+     * (I've made this redefinition for write the same code as the 'putSymbol'
+     * code of the original class (FilterDialog) that was in this project
+     * (appgvSIG) and didn't has path troubles to find 'StringUtilities').
+     * 
+     * Sets a symbol on the filter expression (JTextArea that stores and shows
+     * the current filter expression)
+     * 
+     * @param symbol
+     *            A symbol: character, characters, number, ...
+     */
+    @Override
+    protected void putSymbol(String symbol) {
+        int position = txtExpression.getCaretPosition();
+        txtExpression.setText(StringUtilities.insert(txtExpression.getText(),
+            position, symbol));
+
+        if (symbol.equals(" () ")) {
+            position = position + 2;
+        } else {
+            position = position + symbol.length();
+        }
+
+        txtExpression.setCaretPosition(position);
+    }
+
+    /**
+     * DOCUMENT ME!
+     * 
+     * @param expresion
+     *            DOCUMENT ME!
+     * @param substring
+     *            DOCUMENT ME!
+     * @param startingPos
+     *            DOCUMENT ME!
+     * 
+     * @return DOCUMENT ME!
+     */
+    private int getIndex(String expresion, String substring, int startingPos) {
+        int index = startingPos;
+
+        do {
+            index = expresion.indexOf(substring, index);
+        } while ((StringUtilities.isBetweenSymbols(expresion, index, "\""))
+            && (index != -1));
+
+        return index;
+    }
+
+    /**
+     * DOCUMENT ME!
+     * 
+     * @param expresion
+     *            DOCUMENT ME!
+     * @param word
+     *            DOCUMENT ME!
+     * @param translation
+     *            DOCUMENT ME!
+     * 
+     * @return DOCUMENT ME!
+     * 
+     * @throws ParseException
+     *             DOCUMENT ME!
+     */
+    private String translateWord(String expresion, String word,
+        String translation) throws ParseException {
+        int booleanIndex = 0;
+        int endIndex = 0;
+        StringBuffer res = new StringBuffer();
+
+        while ((booleanIndex = getIndex(expresion, word, booleanIndex)) != -1) {
+            res.append(expresion.substring(endIndex, booleanIndex));
+            endIndex = booleanIndex + word.length();
+            booleanIndex++;
+            res.append(translation);
+        }
+
+        if (endIndex < expresion.length()) {
+            res.append(expresion.substring(endIndex));
+        }
+
+        return res.toString();
+    }
+
+    /**
+     * DOCUMENT ME!
+     * 
+     * @param expresion
+     *            DOCUMENT ME!
+     * 
+     * @return DOCUMENT ME!
+     * 
+     * @throws ParseException
+     *             DOCUMENT ME!
+     */
+    private String translateDates(String expresion) throws ParseException {
+        // Se obtiene el valor de la fecha
+        String date =
+            StringUtilities.substringDelimited(expresion, "Date(", ")", 0);
+
+        if (date == null) {
+            return expresion;
+        }
+
+        // Se comprueba que no est� entre comillas
+        int startIndex = expresion.indexOf(date);
+
+        while (startIndex != -1) {
+            if (!StringUtilities.isBetweenSymbols(expresion, startIndex, "\"")) {
+                // Se sustituye por el valor ordinal de la fecha
+                expresion =
+                    expresion.substring(0, startIndex - 5)
+                        + expresion.substring(startIndex).replaceFirst(
+                            date + "\\)",
+                            new Long((filterButtonsJPanel.getDateFormat()
+                                .parse(date)).getTime()).toString());
+                ;
+            } else {
+                startIndex += date.length();
+            }
+
+            // Se obtiene el valor de la fecha
+
+            /*
+             * date = StringUtilities.substringDelimited(expresion, "Date(",
+             * ")",
+             * startIndex);
+             */
+            if (date == null) {
+                return expresion;
+            }
+
+            startIndex = expresion.indexOf(date, startIndex);
+        }
+
+        return expresion;
+    }
+
+    /**
+     * DOCUMENT ME!
+     * 
+     * @param expresion
+     *            DOCUMENT ME!
+     * 
+     * @return DOCUMENT ME!
+     * 
+     * @throws ParseException
+     *             DOCUMENT ME!
+     */
+    public String translateNumber(String expresion) throws ParseException {
+        DefaultCharSet ss = new DefaultCharSet();
+        ss.addInterval('0', '9');
+        ss.addCharacter(',');
+        ss.addCharacter('.');
+
+        String number = StringUtilities.substringWithSymbols(expresion, ss, 0);
+
+        if (number == null) {
+            return expresion;
+        }
+
+        int startIndex = expresion.indexOf(number);
+
+        while (startIndex != -1) {
+            Number n = nf.parse(number);
+
+            if (!StringUtilities.isBetweenSymbols(expresion, startIndex, "\"")) {
+                // Se sustituye por el valor ordinal de la fecha
+                expresion =
+                    expresion.substring(0, startIndex)
+                        + expresion.substring(startIndex).replaceFirst(number,
+                            n.toString());
+            } else {
+                startIndex += n.toString().length();
+            }
+
+            number =
+                StringUtilities.substringWithSymbols(expresion, ss, startIndex);
+
+            if (number == null) {
+                return expresion;
+            }
+
+            startIndex = expresion.indexOf(number, startIndex);
+        }
+
+        return expresion;
+    }
+
+    /**
+     * DOCUMENT ME!
+     * 
+     * @param arg0
+     * 
+     * @return
+     */
+    public boolean addExpressionListener(ExpressionListener arg0) {
+        return expressionListeners.add(arg0);
+    }
+
+    /**
+     * DOCUMENT ME!
+     * 
+     * @param arg0
+     * 
+     * @return
+     */
+    public boolean removeExpressionListener(ExpressionListener arg0) {
+        return expressionListeners.remove(arg0);
+    }
+
+    /**
+     * @see com.iver.mdiApp.ui.MDIManager.IWindow#getWindowInfo()
+     */
+    public WindowInfo getWindowInfo() {
+        WindowInfo vi = new WindowInfo(WindowInfo.ICONIFIABLE);
+
+        // if (System.getProperty("os.name")co.compareTo(arg0))
+        vi.setHeight(this.filterDialog_Height);
+        vi.setWidth(this.filterDialog_Width);
+
+        // Old instructions
+        // vi.setWidth(480);
+        // vi.setHeight(362);
+        vi
+            .setTitle(PluginServices.getText(this, "filtro") + " (" + title
+                + ")");
+        return vi;
+    }
+
+    /**
+     * DOCUMENT ME!
+     * 
+     * @param o
+     *            DOCUMENT ME!
+     */
+    public void addExceptionListener(ExceptionListener o) {
+        exceptionHandlingSupport.addExceptionListener(o);
+    }
+
+    /**
+     * DOCUMENT ME!
+     * 
+     * @param o
+     *            DOCUMENT ME!
+     * 
+     * @return DOCUMENT ME!
+     */
+    public boolean removeExceptionListener(ExceptionListener o) {
+        return exceptionHandlingSupport.removeExceptionListener(o);
+    }
+
+    /**
+     * DOCUMENT ME!
+     * 
+     * @param t
+     *            DOCUMENT ME!
+     */
+    private void throwException(Throwable t) {
+        exceptionHandlingSupport.throwException(t);
+    }
+
+    /*
+     * (non-Javadoc)
+     * 
+     * @see com.iver.andami.ui.mdiManager.ViewListener#viewActivated()
+     */
+    public void windowActivated() {
+    }
+
+    /*
+     * (non-Javadoc)
+     * 
+     * @see com.iver.andami.ui.mdiManager.ViewListener#viewClosed()
+     */
+    public void windowClosed() {
+        // try {
+        // model.stop();
+        // } catch (ReadDriverException e) {
+        // NotificationManager.addError(e.getMessage(), e);
+        // }
+    }
+
+    public Object getWindowProfile() {
+        return WindowInfo.TOOL_PROFILE;
+    }
+}

Property changes on: tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/app/gui/filter/FilterDialog.java
___________________________________________________________________
Added: svn:keywords
   + Author Date Id Revision
Added: svn:eol-style
   + native

Index: tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/app/gui/filter/ExpressionDataSource.java
===================================================================
--- tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/app/gui/filter/ExpressionDataSource.java	(revision 0)
+++ tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/app/gui/filter/ExpressionDataSource.java	(revision 38653)
@@ -0,0 +1,103 @@
+/* gvSIG. Sistema de Informaci�n Geogr�fica de la Generalitat Valenciana
+ *
+ * Copyright (C) 2004 IVER T.I. and Generalitat Valenciana.
+ *
+ * This program is free software; you can redistribute it and/or
+ * modify it under the terms of the GNU General Public License
+ * as published by the Free Software Foundation; either version 2
+ * of the License, or (at your option) any later version.
+ *
+ * This program is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
+ * GNU General Public License for more details.
+ *
+ * You should have received a copy of the GNU General Public License
+ * along with this program; if not, write to the Free Software
+ * Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA  02111-1307,USA.
+ *
+ * For more information, contact:
+ *
+ *  Generalitat Valenciana
+ *   Conselleria d'Infraestructures i Transport
+ *   Av. Blasco Ib��ez, 50
+ *   46010 VALENCIA
+ *   SPAIN
+ *
+ *      +34 963862235
+ *   gvsig@gva.es
+ *      www.gvsig.gva.es
+ *
+ *    or
+ *
+ *   IVER T.I. S.A
+ *   Salamanca 50
+ *   46005 Valencia
+ *   Spain
+ *
+ *   +34 963163400
+ *   dac@iver.es
+ */
+package org.gvsig.app.gui.filter;
+
+
+
+/**
+ * DOCUMENT ME!
+ *
+ * @author $author$
+ * @version $Revision$
+ */
+public interface ExpressionDataSource {
+	/**
+	 * DOCUMENT ME!
+	 *
+	 * @param row DOCUMENT ME!
+	 * @param idField DOCUMENT ME!
+	 *
+	 * @return DOCUMENT ME!
+	 *
+	 * @throws FilterException DOCUMENT ME!
+	 */
+	public Object getFieldValue(int row, int idField) throws FilterException;
+
+	/**
+	 * DOCUMENT ME!
+	 *
+	 * @return DOCUMENT ME!
+	 *
+	 * @throws FilterException DOCUMENT ME!
+	 */
+	public int getFieldCount() throws FilterException;
+
+	/**
+	 * DOCUMENT ME!
+	 *
+	 * @param idField DOCUMENT ME!
+	 *
+	 * @return DOCUMENT ME!
+	 *
+	 * @throws FilterException DOCUMENT ME!
+	 */
+	public String getFieldName(int idField) throws FilterException;
+
+	/**
+	 * DOCUMENT ME!
+	 *
+	 * @return DOCUMENT ME!
+	 *
+	 * @throws FilterException DOCUMENT ME!
+	 */
+	public int getRowCount() throws FilterException;
+
+	/**
+	 * DOCUMENT ME!
+	 *
+	 * @return DOCUMENT ME!
+	 */
+	public String getDataSourceName();
+
+//    public void start() throws ReadDriverException;
+//    public void stop() throws ReadDriverException;
+
+}

Property changes on: tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/app/gui/filter/ExpressionDataSource.java
___________________________________________________________________
Added: svn:keywords
   + Author Date Id Revision
Added: svn:eol-style
   + native

Index: tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/app/gui/TableSorter.java
===================================================================
--- tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/app/gui/TableSorter.java	(revision 0)
+++ tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/app/gui/TableSorter.java	(revision 38653)
@@ -0,0 +1,538 @@
+/* gvSIG. Sistema de Informaci�n Geogr�fica de la Generalitat Valenciana
+ *
+ * Copyright (C) 2004 IVER T.I. and Generalitat Valenciana.
+ *
+ * This program is free software; you can redistribute it and/or
+ * modify it under the terms of the GNU General Public License
+ * as published by the Free Software Foundation; either version 2
+ * of the License, or (at your option) any later version.
+ *
+ * This program is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
+ * GNU General Public License for more details.
+ *
+ * You should have received a copy of the GNU General Public License
+ * along with this program; if not, write to the Free Software
+ * Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA  02111-1307,USA.
+ *
+ * For more information, contact:
+ *
+ *  Generalitat Valenciana
+ *   Conselleria d'Infraestructures i Transport
+ *   Av. Blasco Ib��ez, 50
+ *   46010 VALENCIA
+ *   SPAIN
+ *
+ *      +34 963862235
+ *   gvsig@gva.es
+ *      www.gvsig.gva.es
+ *
+ *    or
+ *
+ *   IVER T.I. S.A
+ *   Salamanca 50
+ *   46005 Valencia
+ *   Spain
+ *
+ *   +34 963163400
+ *   dac@iver.es
+ */
+package org.gvsig.app.gui;
+
+import java.awt.Color;
+import java.awt.Component;
+import java.awt.Graphics;
+import java.awt.event.MouseAdapter;
+import java.awt.event.MouseEvent;
+import java.awt.event.MouseListener;
+import java.util.ArrayList;
+import java.util.Arrays;
+import java.util.Comparator;
+import java.util.HashMap;
+import java.util.Iterator;
+import java.util.List;
+import java.util.Map;
+
+import javax.swing.Icon;
+import javax.swing.JLabel;
+import javax.swing.JTable;
+import javax.swing.event.TableModelEvent;
+import javax.swing.event.TableModelListener;
+import javax.swing.table.AbstractTableModel;
+import javax.swing.table.JTableHeader;
+import javax.swing.table.TableCellRenderer;
+import javax.swing.table.TableColumnModel;
+import javax.swing.table.TableModel;
+
+/**
+ * TableSorter is a decorator for TableModels; adding sorting
+ * functionality to a supplied TableModel. TableSorter does
+ * not store or copy the data in its TableModel; instead it maintains
+ * a map from the row indexes of the view to the row indexes of the
+ * model. As requests are made of the sorter (like getValueAt(row, col))
+ * they are passed to the underlying model after the row numbers
+ * have been translated via the internal mapping array. This way,
+ * the TableSorter appears to hold another copy of the table
+ * with the rows in a different order.
+ * <p/>
+ * TableSorter registers itself as a listener to the underlying model,
+ * just as the JTable itself would. Events recieved from the model
+ * are examined, sometimes manipulated (typically widened), and then
+ * passed on to the TableSorter's listeners (typically the JTable).
+ * If a change to the model has invalidated the order of TableSorter's
+ * rows, a note of this is made and the sorter will resort the
+ * rows the next time a value is requested.
+ * <p/>
+ * When the tableHeader property is set, either by using the
+ * setTableHeader() method or the two argument constructor, the
+ * table header may be used as a complete UI for TableSorter.
+ * The default renderer of the tableHeader is decorated with a renderer
+ * that indicates the sorting status of each column. In addition,
+ * a mouse listener is installed with the following behavior:
+ * <ul>
+ * <li>
+ * Mouse-click: Clears the sorting status of all other columns
+ * and advances the sorting status of that column through three
+ * values: {NOT_SORTED, ASCENDING, DESCENDING} (then back to
+ * NOT_SORTED again).
+ * <li>
+ * SHIFT-mouse-click: Clears the sorting status of all other columns
+ * and cycles the sorting status of the column through the same
+ * three values, in the opposite order: {NOT_SORTED, DESCENDING, ASCENDING}.
+ * <li>
+ * CONTROL-mouse-click and CONTROL-SHIFT-mouse-click: as above except
+ * that the changes to the column do not cancel the statuses of columns
+ * that are already sorting - giving a way to initiate a compound
+ * sort.
+ * </ul>
+ * <p/>
+ * This is a long overdue rewrite of a class of the same name that
+ * first appeared in the swing table demos in 1997.
+ * 
+ * @author Philip Milne
+ * @author Brendon McLean 
+ * @author Dan van Enckevort
+ * @author Parwinder Sekhon
+ * @version 2.0 02/27/04
+ */
+
+public class TableSorter extends AbstractTableModel {
+    protected TableModel tableModel;
+
+    public static final int DESCENDING = -1;
+    public static final int NOT_SORTED = 0;
+    public static final int ASCENDING = 1;
+
+    private static Directive EMPTY_DIRECTIVE = new Directive(-1, NOT_SORTED);
+
+    public static final Comparator COMPARABLE_COMAPRATOR = new Comparator() {
+        public int compare(Object o1, Object o2) {
+            return ((Comparable) o1).compareTo(o2);
+        }
+    };
+    public static final Comparator LEXICAL_COMPARATOR = new Comparator() {
+        public int compare(Object o1, Object o2) {
+            return o1.toString().compareTo(o2.toString());
+        }
+    };
+
+    private Row[] viewToModel;
+    private int[] modelToView;
+
+    private JTableHeader tableHeader;
+    private MouseListener mouseListener;
+    private TableModelListener tableModelListener;
+    private Map columnComparators = new HashMap();
+    private List sortingColumns = new ArrayList();
+
+    public TableSorter() {
+        this.mouseListener = new MouseHandler();
+        this.tableModelListener = new TableModelHandler();
+    }
+
+    public TableSorter(TableModel tableModel) {
+        this();
+        setTableModel(tableModel);
+    }
+
+    public TableSorter(TableModel tableModel, JTableHeader tableHeader) {
+        this();
+        setTableHeader(tableHeader);
+        setTableModel(tableModel);
+    }
+
+    private void clearSortingState() {
+        viewToModel = null;
+        modelToView = null;
+    }
+
+    public TableModel getTableModel() {
+        return tableModel;
+    }
+
+    public void setTableModel(TableModel tableModel) {
+        if (this.tableModel != null) {
+            this.tableModel.removeTableModelListener(tableModelListener);
+        }
+
+        this.tableModel = tableModel;
+        if (this.tableModel != null) {
+            this.tableModel.addTableModelListener(tableModelListener);
+        }
+
+        clearSortingState();
+        fireTableStructureChanged();
+    }
+
+    public JTableHeader getTableHeader() {
+        return tableHeader;
+    }
+
+    public void setTableHeader(JTableHeader tableHeader) {
+        if (this.tableHeader != null) {
+            this.tableHeader.removeMouseListener(mouseListener);
+            TableCellRenderer defaultRenderer = this.tableHeader.getDefaultRenderer();
+            if (defaultRenderer instanceof SortableHeaderRenderer) {
+                this.tableHeader.setDefaultRenderer(((SortableHeaderRenderer) defaultRenderer).tableCellRenderer);
+            }
+        }
+        this.tableHeader = tableHeader;
+        if (this.tableHeader != null) {
+            this.tableHeader.addMouseListener(mouseListener);
+            this.tableHeader.setDefaultRenderer(
+                    new SortableHeaderRenderer(this.tableHeader.getDefaultRenderer()));
+        }
+    }
+
+    public boolean isSorting() {
+        return sortingColumns.size() != 0;
+    }
+
+    private Directive getDirective(int column) {
+        for (int i = 0; i < sortingColumns.size(); i++) {
+            Directive directive = (Directive)sortingColumns.get(i);
+            if (directive.column == column) {
+                return directive;
+            }
+        }
+        return EMPTY_DIRECTIVE;
+    }
+
+    public int getSortingStatus(int column) {
+        return getDirective(column).direction;
+    }
+
+    private void sortingStatusChanged() {
+        clearSortingState();
+        fireTableDataChanged();
+        if (tableHeader != null) {
+            tableHeader.repaint();
+        }
+    }
+
+    public void setSortingStatus(int column, int status) {
+        Directive directive = getDirective(column);
+        if (directive != EMPTY_DIRECTIVE) {
+            sortingColumns.remove(directive);
+        }
+        if (status != NOT_SORTED) {
+            sortingColumns.add(new Directive(column, status));
+        }
+        sortingStatusChanged();
+    }
+
+    protected Icon getHeaderRendererIcon(int column, int size) {
+        Directive directive = getDirective(column);
+        if (directive == EMPTY_DIRECTIVE) {
+            return null;
+        }
+        return new Arrow(directive.direction == DESCENDING, size, sortingColumns.indexOf(directive));
+    }
+
+    private void cancelSorting() {
+        sortingColumns.clear();
+        sortingStatusChanged();
+    }
+
+    public void setColumnComparator(Class type, Comparator comparator) {
+        if (comparator == null) {
+            columnComparators.remove(type);
+        } else {
+            columnComparators.put(type, comparator);
+        }
+    }
+
+    protected Comparator getComparator(int column) {
+        Class columnType = tableModel.getColumnClass(column);
+        Comparator comparator = (Comparator) columnComparators.get(columnType);
+        if (comparator != null) {
+            return comparator;
+        }
+        if (Comparable.class.isAssignableFrom(columnType)) {
+            return COMPARABLE_COMAPRATOR;
+        }
+        return LEXICAL_COMPARATOR;
+    }
+
+    private Row[] getViewToModel() {
+        if (viewToModel == null) {
+            int tableModelRowCount = tableModel.getRowCount();
+            viewToModel = new Row[tableModelRowCount];
+            for (int row = 0; row < tableModelRowCount; row++) {
+                viewToModel[row] = new Row(row);
+            }
+
+            if (isSorting()) {
+                Arrays.sort(viewToModel);
+            }
+        }
+        return viewToModel;
+    }
+
+    public int modelIndex(int viewIndex) {
+        return getViewToModel()[viewIndex].modelIndex;
+    }
+
+    private int[] getModelToView() {
+        if (modelToView == null) {
+            int n = getViewToModel().length;
+            modelToView = new int[n];
+            for (int i = 0; i < n; i++) {
+                modelToView[modelIndex(i)] = i;
+            }
+        }
+        return modelToView;
+    }
+
+    // TableModel interface methods 
+
+    public int getRowCount() {
+        return (tableModel == null) ? 0 : tableModel.getRowCount();
+    }
+
+    public int getColumnCount() {
+        return (tableModel == null) ? 0 : tableModel.getColumnCount();
+    }
+
+    public String getColumnName(int column) {
+        return tableModel.getColumnName(column);
+    }
+
+    public Class getColumnClass(int column) {
+        return tableModel.getColumnClass(column);
+    }
+
+    public boolean isCellEditable(int row, int column) {
+        return tableModel.isCellEditable(modelIndex(row), column);
+    }
+
+    public Object getValueAt(int row, int column) {
+        return tableModel.getValueAt(modelIndex(row), column);
+    }
+
+    public void setValueAt(Object aValue, int row, int column) {
+        tableModel.setValueAt(aValue, modelIndex(row), column);
+    }
+
+    // Helper classes
+    
+    private class Row implements Comparable {
+        private int modelIndex;
+
+        public Row(int index) {
+            this.modelIndex = index;
+        }
+
+        public int compareTo(Object o) {
+            int row1 = modelIndex;
+            int row2 = ((Row) o).modelIndex;
+
+            for (Iterator it = sortingColumns.iterator(); it.hasNext();) {
+                Directive directive = (Directive) it.next();
+                int column = directive.column;
+                Object o1 = tableModel.getValueAt(row1, column);
+                Object o2 = tableModel.getValueAt(row2, column);
+
+                int comparison = 0;
+                // Define null less than everything, except null.
+                if (o1 == null && o2 == null) {
+                    comparison = 0;
+                } else if (o1 == null) {
+                    comparison = -1;
+                } else if (o2 == null) {
+                    comparison = 1;
+                } else {
+                    comparison = getComparator(column).compare(o1, o2);
+                }
+                if (comparison != 0) {
+                    return directive.direction == DESCENDING ? -comparison : comparison;
+                }
+            }
+            return 0;
+        }
+    }
+
+    private class TableModelHandler implements TableModelListener {
+        public void tableChanged(TableModelEvent e) {
+            // If we're not sorting by anything, just pass the event along.             
+            if (!isSorting()) {
+                clearSortingState();
+                fireTableChanged(e);
+                return;
+            }
+                
+            // If the table structure has changed, cancel the sorting; the             
+            // sorting columns may have been either moved or deleted from             
+            // the model. 
+            if (e.getFirstRow() == TableModelEvent.HEADER_ROW) {
+                cancelSorting();
+                fireTableChanged(e);
+                return;
+            }
+
+            // We can map a cell event through to the view without widening             
+            // when the following conditions apply: 
+            // 
+            // a) all the changes are on one row (e.getFirstRow() == e.getLastRow()) and, 
+            // b) all the changes are in one column (column != TableModelEvent.ALL_COLUMNS) and,
+            // c) we are not sorting on that column (getSortingStatus(column) == NOT_SORTED) and, 
+            // d) a reverse lookup will not trigger a sort (modelToView != null)
+            //
+            // Note: INSERT and DELETE events fail this test as they have column == ALL_COLUMNS.
+            // 
+            // The last check, for (modelToView != null) is to see if modelToView 
+            // is already allocated. If we don't do this check; sorting can become 
+            // a performance bottleneck for applications where cells  
+            // change rapidly in different parts of the table. If cells 
+            // change alternately in the sorting column and then outside of             
+            // it this class can end up re-sorting on alternate cell updates - 
+            // which can be a performance problem for large tables. The last 
+            // clause avoids this problem. 
+            int column = e.getColumn();
+            if (e.getFirstRow() == e.getLastRow()
+                    && column != TableModelEvent.ALL_COLUMNS
+                    && getSortingStatus(column) == NOT_SORTED
+                    && modelToView != null) {
+                int viewIndex = getModelToView()[e.getFirstRow()];
+                fireTableChanged(new TableModelEvent(TableSorter.this, 
+                                                     viewIndex, viewIndex, 
+                                                     column, e.getType()));
+                return;
+            }
+
+            // Something has happened to the data that may have invalidated the row order. 
+            clearSortingState();
+            fireTableDataChanged();
+            return;
+        }
+    }
+
+    private class MouseHandler extends MouseAdapter {
+        public void mouseClicked(MouseEvent e) {
+            JTableHeader h = (JTableHeader) e.getSource();
+            TableColumnModel columnModel = h.getColumnModel();
+            int viewColumn = columnModel.getColumnIndexAtX(e.getX());
+            int column = columnModel.getColumn(viewColumn).getModelIndex();
+            if (column != -1) {
+                int status = getSortingStatus(column);
+                if (!e.isControlDown()) {
+                    cancelSorting();
+                }
+                // Cycle the sorting states through {NOT_SORTED, ASCENDING, DESCENDING} or 
+                // {NOT_SORTED, DESCENDING, ASCENDING} depending on whether shift is pressed. 
+                status = status + (e.isShiftDown() ? -1 : 1);
+                status = (status + 4) % 3 - 1; // signed mod, returning {-1, 0, 1}
+                setSortingStatus(column, status);
+            }
+        }
+    }
+
+    private static class Arrow implements Icon {
+        private boolean descending;
+        private int size;
+        private int priority;
+
+        public Arrow(boolean descending, int size, int priority) {
+            this.descending = descending;
+            this.size = size;
+            this.priority = priority;
+        }
+
+        public void paintIcon(Component c, Graphics g, int x, int y) {
+            Color color = c == null ? Color.GRAY : c.getBackground();             
+            // In a compound sort, make each succesive triangle 20% 
+            // smaller than the previous one. 
+            int dx = (int)(size/2*Math.pow(0.8, priority));
+            int dy = descending ? dx : -dx;
+            // Align icon (roughly) with font baseline. 
+            y = y + 5*size/6 + (descending ? -dy : 0);
+            int shift = descending ? 1 : -1;
+            g.translate(x, y);
+
+            // Right diagonal. 
+            g.setColor(color.darker());
+            g.drawLine(dx / 2, dy, 0, 0);
+            g.drawLine(dx / 2, dy + shift, 0, shift);
+            
+            // Left diagonal. 
+            g.setColor(color.brighter());
+            g.drawLine(dx / 2, dy, dx, 0);
+            g.drawLine(dx / 2, dy + shift, dx, shift);
+            
+            // Horizontal line. 
+            if (descending) {
+                g.setColor(color.darker().darker());
+            } else {
+                g.setColor(color.brighter().brighter());
+            }
+            g.drawLine(dx, 0, 0, 0);
+
+            g.setColor(color);
+            g.translate(-x, -y);
+        }
+
+        public int getIconWidth() {
+            return size;
+        }
+
+        public int getIconHeight() {
+            return size;
+        }
+    }
+
+    private class SortableHeaderRenderer implements TableCellRenderer {
+        private TableCellRenderer tableCellRenderer;
+
+        public SortableHeaderRenderer(TableCellRenderer tableCellRenderer) {
+            this.tableCellRenderer = tableCellRenderer;
+        }
+
+        public Component getTableCellRendererComponent(JTable table, 
+                                                       Object value,
+                                                       boolean isSelected, 
+                                                       boolean hasFocus,
+                                                       int row, 
+                                                       int column) {
+            Component c = tableCellRenderer.getTableCellRendererComponent(table, 
+                    value, isSelected, hasFocus, row, column);
+            if (c instanceof JLabel) {
+                JLabel l = (JLabel) c;
+                l.setHorizontalTextPosition(JLabel.LEFT);
+                int modelColumn = table.convertColumnIndexToModel(column);
+                l.setIcon(getHeaderRendererIcon(modelColumn, l.getFont().getSize()));
+            }
+            return c;
+        }
+    }
+
+    private static class Directive {
+        private int column;
+        private int direction;
+
+        public Directive(int column, int direction) {
+            this.column = column;
+            this.direction = direction;
+        }
+    }
+}

Property changes on: tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/app/gui/TableSorter.java
___________________________________________________________________
Added: svn:keywords
   + Author Date Id Revision
Added: svn:eol-style
   + native

Index: tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/app/gui/simpleWizard/SimpleWizard.java
===================================================================
--- tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/app/gui/simpleWizard/SimpleWizard.java	(revision 0)
+++ tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/app/gui/simpleWizard/SimpleWizard.java	(revision 38653)
@@ -0,0 +1,80 @@
+package org.gvsig.app.gui.simpleWizard;
+
+import java.awt.BorderLayout;
+
+import javax.swing.ImageIcon;
+import javax.swing.JPanel;
+
+import org.gvsig.andami.PluginServices;
+import org.gvsig.andami.ui.mdiManager.IWindow;
+import org.gvsig.andami.ui.mdiManager.WindowInfo;
+
+import jwizardcomponent.CancelAction;
+import jwizardcomponent.DefaultJWizardComponents;
+import jwizardcomponent.FinishAction;
+
+
+public class SimpleWizard extends JPanel implements IWindow {
+	WindowInfo viewInfo = null;
+	WizardPanelWithLogo wizardPanel;
+
+	// No deber�an necesitarse un FinishAction y un CancelAction, pero bueno,
+	// lo mantengo por ahora.
+	private class CloseAction extends FinishAction
+	{
+		IWindow v;
+		public CloseAction(IWindow view)
+		{
+			super(wizardPanel.getWizardComponents());
+			v = view;
+		}
+		public void performAction() {
+			PluginServices.getMDIManager().closeWindow(v);
+		}
+
+	}
+	private class CloseAction2 extends CancelAction
+	{
+
+		IWindow v;
+		public CloseAction2(IWindow view)
+		{
+			super(wizardPanel.getWizardComponents());
+			v = view;
+		}
+		public void performAction() {
+			PluginServices.getMDIManager().closeWindow(v);
+		}
+
+	}
+
+
+	public SimpleWizard(ImageIcon logo)
+	{
+		wizardPanel = new WizardPanelWithLogo(logo);
+		CloseAction closeAction = new CloseAction(this);
+		CloseAction2 closeAction2 = new CloseAction2(this);
+		wizardPanel.getWizardComponents().setFinishAction(closeAction);
+		wizardPanel.getWizardComponents().setCancelAction(closeAction2);
+
+		this.setLayout(new BorderLayout());
+		this.add(wizardPanel, BorderLayout.CENTER);
+	}
+
+	public DefaultJWizardComponents getWizardComponents()
+	{
+		return wizardPanel.getWizardComponents();
+	}
+
+
+	public WindowInfo getWindowInfo() {
+		if (viewInfo == null)
+		{
+			viewInfo = new WindowInfo(WindowInfo.MODALDIALOG|WindowInfo.RESIZABLE);
+		}
+		return viewInfo;
+	}
+	public Object getWindowProfile() {
+		return WindowInfo.DIALOG_PROFILE;
+	}
+}

Property changes on: tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/app/gui/simpleWizard/SimpleWizard.java
___________________________________________________________________
Added: svn:eol-style
   + native
Added: svn:keywords
   + Author Date Id Revision

Index: tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/app/gui/simpleWizard/WizardPanelWithLogo.java
===================================================================
--- tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/app/gui/simpleWizard/WizardPanelWithLogo.java	(revision 0)
+++ tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/app/gui/simpleWizard/WizardPanelWithLogo.java	(revision 38653)
@@ -0,0 +1,84 @@
+package org.gvsig.app.gui.simpleWizard;
+
+import java.awt.BorderLayout;
+import java.awt.Color;
+
+import javax.swing.ImageIcon;
+import javax.swing.JLabel;
+import javax.swing.JPanel;
+import javax.swing.JSeparator;
+
+import jwizardcomponent.CancelAction;
+import jwizardcomponent.DefaultJWizardComponents;
+import jwizardcomponent.FinishAction;
+import jwizardcomponent.common.SimpleButtonPanel;
+
+public class WizardPanelWithLogo extends JPanel {
+	  DefaultJWizardComponents wizardComponents;
+
+	  JPanel buttonPanel;
+	  JLabel statusLabel = new JLabel();
+
+	  ImageIcon logo;
+
+	  public WizardPanelWithLogo(ImageIcon logo) {
+	    this.logo = logo;
+	    wizardComponents = new DefaultJWizardComponents();
+	    init();
+	  }
+
+	  private void init() {
+	    
+
+	    JPanel logoPanel = new JPanel();
+
+	    String fileString;
+	    if (logo.toString().indexOf("file:") < 0 &&
+	        logo.toString().indexOf("http:") < 0) {
+	      fileString = "file:///" +System.getProperty("user.dir") +"/"
+	                        +logo.toString();
+	      fileString = fileString.replaceAll("\\\\", "/");
+	    } else {
+	      fileString = logo.toString();
+	    }
+	    logoPanel.add(new JLabel(logo));
+	    logoPanel.setBackground(Color.WHITE);
+	    this.setLayout(new BorderLayout());
+	    this.add(logoPanel, BorderLayout.WEST);
+	    this.add(wizardComponents.getWizardPanelsContainer(),
+	    							BorderLayout.CENTER);
+
+	    JPanel auxPanel = new JPanel(new BorderLayout());
+	    auxPanel.add(new JSeparator(), BorderLayout.NORTH);
+
+	    buttonPanel = new SimpleButtonPanel(wizardComponents);
+	    auxPanel.add(buttonPanel);
+	    this.add(auxPanel, BorderLayout.SOUTH);
+	    
+
+	    wizardComponents.setFinishAction(new FinishAction(wizardComponents) {
+	      public void performAction() {
+	        // dispose();
+	      }
+	    });
+	    wizardComponents.setCancelAction(new CancelAction(wizardComponents) {
+	      public void performAction() {
+	        // dispose();
+	      }
+	    });
+	  }
+
+	  public DefaultJWizardComponents getWizardComponents(){
+	    return wizardComponents;
+	  }
+
+	  public void setWizardComponents(DefaultJWizardComponents aWizardComponents){
+	    wizardComponents = aWizardComponents;
+	  }
+
+	  public void show() {
+	    wizardComponents.updateComponents();
+	    super.setVisible(true);
+	  }
+
+}

Property changes on: tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/app/gui/simpleWizard/WizardPanelWithLogo.java
___________________________________________________________________
Added: svn:eol-style
   + native
Added: svn:keywords
   + Author Date Id Revision

Index: tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/app/gui/command/CommandStackDialog.java
===================================================================
--- tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/app/gui/command/CommandStackDialog.java	(revision 0)
+++ tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/app/gui/command/CommandStackDialog.java	(revision 38653)
@@ -0,0 +1,376 @@
+package org.gvsig.app.gui.command;
+
+import java.awt.BorderLayout;
+import java.awt.Color;
+import java.awt.Component;
+import java.awt.Dimension;
+
+import javax.swing.ImageIcon;
+import javax.swing.JLabel;
+import javax.swing.JPanel;
+import javax.swing.JScrollBar;
+import javax.swing.JScrollPane;
+import javax.swing.JSlider;
+import javax.swing.JTable;
+import javax.swing.ListSelectionModel;
+import javax.swing.table.DefaultTableCellRenderer;
+import javax.swing.table.TableColumn;
+
+import org.gvsig.andami.IconThemeHelper;
+import org.gvsig.andami.PluginServices;
+import org.gvsig.andami.ui.mdiManager.IWindowListener;
+import org.gvsig.andami.ui.mdiManager.SingletonWindow;
+import org.gvsig.andami.ui.mdiManager.WindowInfo;
+import org.gvsig.app.ApplicationLocator;
+import org.gvsig.fmap.dal.feature.FeatureStoreNotification;
+import org.gvsig.gui.beans.DefaultBean;
+import org.gvsig.tools.observer.Observable;
+import org.gvsig.tools.observer.Observer;
+import org.gvsig.tools.undo.UndoRedoInfo;
+import org.gvsig.tools.undo.UndoRedoStack;
+
+
+@SuppressWarnings("serial")
+public class CommandStackDialog extends DefaultBean implements SingletonWindow, IWindowListener, Observer{
+
+	private JTable commandTable = null;
+	private JPanel topPanel = null;
+	private UndoRedoStack undoRedoStack;
+	private JSlider commandSlider = null;
+	
+	private int lowLimit;
+	private int currentValue = -1;
+	private int currentSliderValue = -1;
+	private JPanel sliderPanel = null;
+	protected boolean refreshing;
+	private JPanel centerPanel = null;
+	private JScrollPane jScrollPane = null;
+	private JPanel tablePanel = null;
+	
+	private static final ImageIcon imodify = IconThemeHelper.getImageIcon("layout-tool-undo-redo-actions-modify"); 
+	private static final ImageIcon iadd = IconThemeHelper.getImageIcon("layout-tool-undo-redo-actions-add");
+	private static final ImageIcon idel = IconThemeHelper.getImageIcon("layout-tool-undo-redo-actions-delete");
+
+	private CommandTableModel commandTableModel = null;
+	/**
+	 * This is the default constructor
+	 */
+	public CommandStackDialog() {
+		super();
+		initialize();
+	}
+	
+	public void setModel(UndoRedoStack cr1) {
+        if (this.undoRedoStack != null) {
+            if (this.undoRedoStack.equals(cr1)) {
+                return;
+            } else {
+                this.undoRedoStack.deleteObserver(this);
+            }
+		}
+		this.undoRedoStack = cr1;
+		this.undoRedoStack.addObserver(this);
+		initTable();
+		initSlider();
+		currentValue = commandTableModel.getPos();
+    	refreshControls();
+		refreshSliderSize();
+	}
+	
+	/**
+	 * This method initializes this
+	 *
+	 * @return void
+	 */
+	private void initialize() {
+		this.setLayout(new BorderLayout());
+		this.setSize(328, 229);		
+		this.add(getJScrollPane(), java.awt.BorderLayout.CENTER);
+	}
+
+	/**
+	 * This method initializes jList
+	 *
+	 * @return javax.swing.JList
+	 */
+	private JTable getTable() {
+		if (commandTable == null) {
+			commandTable = new JTable();
+		}
+		return commandTable;
+	}
+	
+	private void initTable(){
+		commandTableModel = new CommandTableModel(undoRedoStack);
+		commandTable.setModel(commandTableModel);
+		commandTable.setSelectionMode(ListSelectionModel.SINGLE_SELECTION);
+		commandTable.setSelectionBackground(Color.orange);
+		commandTable.setSelectionForeground(Color.black);
+		commandTable.setShowGrid(false);
+		commandTable.getTableHeader().setBackground(Color.white);
+		TableColumn tc = commandTable.getColumnModel().getColumn(0);
+		tc.setCellRenderer(new DefaultTableCellRenderer() {
+			   public Component getTableCellRendererComponent(JTable table,
+			                                               Object value,
+			                                               boolean isSelected,
+			                                               boolean hasFocus,
+			                                               int row,
+			                                               int column)
+			      {
+			         JLabel label = (JLabel)
+			            super.getTableCellRendererComponent
+			               (table, value, isSelected, hasFocus, row, column);
+			            UndoRedoInfo info = (UndoRedoInfo) value;
+			            switch (info.getType()) {
+                            case UndoRedoInfo.INSERT:
+                                label.setIcon(iadd);
+                                break;
+                            case UndoRedoInfo.DELETE:
+                                label.setIcon(idel);
+                                break;
+                            default:
+                                label.setIcon(imodify);
+                        }
+			         if (commandTableModel.getPos()<row){
+			        	 label.setBackground(Color.lightGray);
+			         }else {
+			       		 label.setBackground(Color.orange);
+			         }
+			            return label;
+			      }
+			});
+
+		commandTable.addMouseListener(new java.awt.event.MouseAdapter() {
+			public void mousePressed(java.awt.event.MouseEvent e) {
+				int newpos = commandTable.getSelectedRow();	
+				if (newpos >= 0){
+    				commandTableModel.setPos(newpos);				
+    				PluginServices.getMainFrame().enableControls();
+				}
+			}
+		});
+	}
+	/**
+	 * This method initializes jPanel
+	 *
+	 * @return javax.swing.JPanel
+	 */
+	private JPanel getTopPanel() {
+		if (topPanel == null) {
+			topPanel = new JPanel();	
+		}
+		return topPanel;
+	}
+
+	public WindowInfo getWindowInfo() {
+		WindowInfo m_viewinfo = new WindowInfo(WindowInfo.ICONIFIABLE |
+				WindowInfo.MODELESSDIALOG | WindowInfo.RESIZABLE | WindowInfo.PALETTE);
+		m_viewinfo.setTitle(PluginServices.getText(this,
+				"pila_de_comandos"));
+		return m_viewinfo;
+	}
+
+	public Object getWindowModel() {
+		return commandTableModel.getClass().getName();
+	}
+
+	public void windowActivated() {
+		this.validateTree();
+	}
+
+	public void windowClosed() {
+		
+	}
+
+	public void commandRepaint() {
+		setValue(commandTableModel.getPos(), true);
+		refreshSliderSize();
+	}
+
+    /**
+     * Refreshes all the mutable controls in this component.
+     */
+    private void refreshControls() {
+        int normalizedValue = (int) (((commandTableModel.getRowCount() - (currentValue + 1)) / (float)commandTableModel.getRowCount()) * 100);
+        //Adding the 50% od the interval
+        if (commandTableModel.getRowCount() > 0){
+            normalizedValue = normalizedValue + (100 / (commandTableModel.getRowCount() * 2));
+        }
+        refreshSlider(normalizedValue);
+        commandTable.repaint();
+    }
+    
+    /**
+     * Sets the slider to the correct (scaled) position.
+     * @param normalizedValue
+     */
+    private void refreshSlider(int normalizedValue) {
+        if (!refreshing){
+            refreshing = true;
+            getJSlider().setValue(normalizedValue);
+            refreshing = false; 
+        }
+    }    
+    
+    private void refreshSliderSize(){
+        if (!refreshing){
+            Dimension size = new Dimension(commandSlider.getPreferredSize().width,
+                ((commandTableModel.getRowCount() + 1) * getTable().getRowHeight()));
+            JScrollBar verticalScrollBar = getJScrollPane().getVerticalScrollBar();
+            verticalScrollBar.setValue(commandTableModel.getPos()*getTable().getRowHeight());
+            commandSlider.setPreferredSize(size);
+            commandSlider.setSize(size);
+            validateTree();
+        }
+    }
+    
+	
+	/**
+	 * This method initializes jSlider
+	 *
+	 * @return javax.swing.JSlider
+	 */
+	private JSlider getJSlider() {
+		if (commandSlider == null) {
+			commandSlider = new JSlider(JSlider.VERTICAL, 0, 100, 0);	
+		}
+		return commandSlider;
+	}
+	
+	private void initSlider(){		
+		commandSlider.setPreferredSize(
+		    new Dimension(commandSlider.getPreferredSize().width,
+		        ((getTable().getRowCount())*getTable().getRowHeight())));
+
+		commandSlider.addChangeListener(new javax.swing.event.ChangeListener() {
+				public synchronized void stateChanged(javax.swing.event.ChangeEvent e) {
+				    if (!refreshing){
+				        int value = getTablePosFromSlider();  
+				        //currentSliderValue controls the same event thrown by the
+				        //slider. currentValue controls the event thrown by the table
+				        if (currentSliderValue != value){
+				            refreshing = true;	
+				            currentSliderValue = value;
+				            commandTableModel.setPos(value);
+				            refreshing = false;    
+				        }
+				    }
+			    }
+    		});
+    	setValue(commandTableModel.getRowCount() - 1 - commandTableModel.getPos(),true);
+	}
+	
+	private int getTablePosFromSlider(){	  
+	    if (commandTableModel.getRowCount() == 0){
+	        return -1;
+	    }
+	    
+	    int value = getJSlider().getValue();
+	    value = (int) ((value * 0.01) * commandTableModel.getRowCount());
+
+	    //The bottom part of the slider starts in 100: take the reverse value
+	    value = (commandTableModel.getRowCount() - 1) - value;
+	    
+	    if (value == -1){
+	        return 0;
+	    }
+	    return value;
+	}
+	
+    public void setValue(int number, boolean fireEvent) {
+        int rowCount = commandTableModel.getRowCount();
+               
+        if (number < lowLimit) {
+			number = lowLimit;
+		}
+        if (number > (rowCount - 1)) {
+			number = rowCount;
+		}
+        if (number != currentValue) {
+        	currentValue = number;
+        	refreshControls();
+        	if (fireEvent) {
+				callValueChanged(new Integer(currentValue));
+			}
+        }     
+    }
+
+	/**
+	 * This method initializes jPanel1
+	 *
+	 * @return javax.swing.JPanel
+	 */
+	private JPanel getSliderPanel() {
+		if (sliderPanel == null) {
+			sliderPanel = new JPanel();
+			sliderPanel.add(getJSlider());
+		}
+		return sliderPanel;
+	}
+
+	/**
+	 * This method initializes pCenter
+	 *
+	 * @return javax.swing.JPanel
+	 */
+	private JPanel getCenterPanel() {
+		if (centerPanel == null) {
+			centerPanel = new JPanel();
+			centerPanel.setLayout(new BorderLayout());			
+			centerPanel.add(getTablePanel(), java.awt.BorderLayout.CENTER);
+			centerPanel.add(getSliderPanel(), java.awt.BorderLayout.WEST);
+		}
+		return centerPanel;
+	}
+	
+	private JPanel getTablePanel() {
+	    if (tablePanel == null) {
+	        tablePanel = new JPanel();
+	        tablePanel.setLayout(new BorderLayout());
+	        tablePanel.add(getTable(), java.awt.BorderLayout.CENTER);	        
+	        tablePanel.add(getTopPanel(), java.awt.BorderLayout.NORTH);
+	    }
+	    return tablePanel;
+	}
+
+	/**
+	 * This method initializes jScrollPane
+	 *
+	 * @return javax.swing.JScrollPane
+	 */
+	private JScrollPane getJScrollPane() {
+		if (jScrollPane == null) {
+			jScrollPane = new JScrollPane();
+			jScrollPane.setViewportView(getCenterPanel());
+		}
+		return jScrollPane;
+	}
+	
+	public void update(Observable observable, Object notification) {
+		if (notification instanceof FeatureStoreNotification){
+			FeatureStoreNotification featureStoreNotification =
+					(FeatureStoreNotification) notification;
+			//If the edition finish the command stack disappears
+			String type = featureStoreNotification.getType();
+			if (FeatureStoreNotification.AFTER_FINISHEDITING.equals(type) ||
+					FeatureStoreNotification.AFTER_CANCELEDITING.equals(type)){							
+				ApplicationLocator.getManager().getUIManager().closeWindow(this);				
+				featureStoreNotification.getSource().deleteObserver(this);
+				return;
+			}
+			//Only repaint if the event is a selection event or an edition event
+			if (FeatureStoreNotification.AFTER_INSERT.equals(type) ||
+                FeatureStoreNotification.AFTER_DELETE.equals(type) ||
+                FeatureStoreNotification.AFTER_UPDATE.equals(type) ||
+                FeatureStoreNotification.SELECTION_CHANGE.equals(type) ||
+                FeatureStoreNotification.AFTER_REDO.equals(type) ||
+                FeatureStoreNotification.AFTER_UNDO.equals(type)) {                   
+			    commandRepaint();
+			}			
+		}
+	}
+
+	public Object getWindowProfile() {
+		return WindowInfo.DIALOG_PROFILE;
+	}
+}  

Property changes on: tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/app/gui/command/CommandStackDialog.java
___________________________________________________________________
Added: svn:eol-style
   + native

Index: tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/app/gui/command/ColorRenderer.java
===================================================================
--- tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/app/gui/command/ColorRenderer.java	(revision 0)
+++ tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/app/gui/command/ColorRenderer.java	(revision 38653)
@@ -0,0 +1,49 @@
+package org.gvsig.app.gui.command;
+import java.awt.Color;
+import java.awt.Component;
+
+import javax.swing.BorderFactory;
+import javax.swing.JLabel;
+import javax.swing.JTable;
+import javax.swing.border.Border;
+import javax.swing.table.TableCellRenderer;
+
+public class ColorRenderer extends JLabel
+                           implements TableCellRenderer {
+    Border unselectedBorder = null;
+    Border selectedBorder = null;
+    boolean isBordered = true;
+
+    public ColorRenderer(boolean isBordered) {
+        this.isBordered = isBordered;
+        setOpaque(true); //MUST do this for background to show up.
+    }
+
+    public Component getTableCellRendererComponent(
+                            JTable table, Object color,
+                            boolean isSelected, boolean hasFocus,
+                            int row, int column) {
+        Color newColor = (Color)color;
+        setBackground(newColor);
+        if (isBordered) {
+            if (isSelected) {
+                if (selectedBorder == null) {
+                    selectedBorder = BorderFactory.createMatteBorder(2,5,2,5,
+                                              table.getSelectionBackground());
+                }
+                setBorder(selectedBorder);
+            } else {
+                if (unselectedBorder == null) {
+                    unselectedBorder = BorderFactory.createMatteBorder(2,5,2,5,
+                                              table.getBackground());
+                }
+                setBorder(unselectedBorder);
+            }
+        }
+
+        setToolTipText("RGB value: " + newColor.getRed() + ", "
+                                     + newColor.getGreen() + ", "
+                                     + newColor.getBlue());
+        return this;
+    }
+}

Property changes on: tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/app/gui/command/ColorRenderer.java
___________________________________________________________________
Added: svn:eol-style
   + native

Index: tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/app/gui/command/CommandTableModel.java
===================================================================
--- tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/app/gui/command/CommandTableModel.java	(revision 0)
+++ tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/app/gui/command/CommandTableModel.java	(revision 38653)
@@ -0,0 +1,70 @@
+package org.gvsig.app.gui.command;
+
+import javax.swing.table.AbstractTableModel;
+
+import org.slf4j.Logger;
+import org.slf4j.LoggerFactory;
+
+import org.gvsig.tools.undo.RedoException;
+import org.gvsig.tools.undo.UndoException;
+import org.gvsig.tools.undo.UndoRedoStack;
+import org.gvsig.tools.undo.command.Command;
+
+
+@SuppressWarnings("serial")
+public class CommandTableModel extends AbstractTableModel{
+    private static final Logger LOG = 
+        LoggerFactory.getLogger(CommandTableModel.class);
+    
+    private UndoRedoStack undoRedoStack;
+        
+    public CommandTableModel(UndoRedoStack undoRedoStack) {
+        this.undoRedoStack = undoRedoStack;
+	}
+
+	public int getPos() {
+		if ((undoRedoStack == null) || undoRedoStack.getUndoInfos() == null){
+		    return 0;
+		}
+	    return undoRedoStack.getUndoInfos().size() - 1;
+	}
+	
+	public int getColumnCount() {
+		return 1;
+	}
+	
+	public int getRowCount() {
+		if ((undoRedoStack == null) || undoRedoStack.getUndoInfos() == null || undoRedoStack.getRedoInfos() == null){
+		    return 0;
+		}
+		return undoRedoStack.getRedoInfos().size() + undoRedoStack.getUndoInfos().size();
+	}
+	
+	@SuppressWarnings("unchecked")
+    public Object getValueAt(int i, int j) {
+		Command[] undos=(Command[])undoRedoStack.getUndoInfos().toArray(new Command[0]);
+		Command[] redos=(Command[])undoRedoStack.getRedoInfos().toArray(new Command[0]);
+		if (i<undos.length){
+			//System.out.println("undo i=" + i + " index=" + (undos.length-1-i));
+			return undos[undos.length-1-i];
+		}else{
+			//System.out.println("redo i=" + i + " index=" + (i-undos.length));
+			return redos[i-undos.length];
+		}
+	}
+	
+	public void setPos(int newpos) {
+		try {
+		    int currentPos = getPos();
+			if (newpos > getPos()) {
+				undoRedoStack.redo(newpos - getPos());
+			}else if (newpos < getPos()) {
+				undoRedoStack.undo(getPos() - newpos);
+			}
+		} catch (RedoException e) {
+			LOG.error("Error executing the command", e);
+		} catch (UndoException e) {
+		    LOG.error("Error executing the command", e);
+		}
+	}
+}

Property changes on: tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/app/gui/command/CommandTableModel.java
___________________________________________________________________
Added: svn:eol-style
   + native

Index: tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/app/gui/preferencespage/ViewBehaviorPage.java
===================================================================
--- tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/app/gui/preferencespage/ViewBehaviorPage.java	(revision 0)
+++ tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/app/gui/preferencespage/ViewBehaviorPage.java	(revision 38653)
@@ -0,0 +1,229 @@
+/* gvSIG. Sistema de Informaci�n Geogr�fica de la Generalitat Valenciana
+ *
+ * Copyright (C) 2004 IVER T.I. and Generalitat Valenciana.
+ *
+ * This program is free software; you can redistribute it and/or
+ * modify it under the terms of the GNU General Public License
+ * as published by the Free Software Foundation; either version 2
+ * of the License, or (at your option) any later version.
+ *
+ * This program is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
+ * GNU General Public License for more details.
+ *
+ * You should have received a copy of the GNU General Public License
+ * along with this program; if not, write to the Free Software
+ * Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA  02111-1307,USA.
+ *
+ * For more information, contact:
+ *
+ *  Generalitat Valenciana
+ *   Conselleria d'Infraestructures i Transport
+ *   Av. Blasco Ib��ez, 50
+ *   46010 VALENCIA
+ *   SPAIN
+ *
+ *      +34 963862235
+ *   gvsig@gva.es
+ *      www.gvsig.gva.es
+ *
+ *    or
+ *
+ *   IVER T.I. S.A
+ *   Salamanca 50
+ *   46005 Valencia
+ *   Spain
+ *
+ *   +34 963163400
+ *   dac@iver.es
+ */
+package org.gvsig.app.gui.preferencespage;
+
+import java.awt.BorderLayout;
+import java.awt.Dimension;
+import java.awt.FlowLayout;
+
+import javax.swing.BorderFactory;
+import javax.swing.ImageIcon;
+import javax.swing.JLabel;
+import javax.swing.JPanel;
+import javax.swing.JSlider;
+import javax.swing.border.Border;
+
+import org.gvsig.andami.PluginServices;
+import org.gvsig.andami.preferences.AbstractPreferencePage;
+import org.gvsig.andami.preferences.StoreException;
+import org.gvsig.andami.ui.mdiManager.IWindow;
+import org.gvsig.app.project.documents.view.gui.AbstractViewPanel;
+import org.gvsig.fmap.mapcontext.MapContext;
+import org.gvsig.fmap.mapcontrol.MapControl;
+import org.gvsig.gui.beans.swing.JBlank;
+import org.gvsig.utils.XMLEntity;
+
+
+/**
+ * @author jaume dominguez faus - jaume.dominguez@iver.es
+ */
+public class ViewBehaviorPage extends AbstractPreferencePage{
+	private static final int FACTORY_DEFAULT_MAPCONTEXT_FRAME_RATE = 3;
+	protected String id = ViewBehaviorPage.class.getName();
+	private ScreenRefreshRatePanel refreshRate;
+	private static final String MAPCONTROL_ENABLE_ANIMATION_KEY_NAME = "MapControlEnableAnimation";
+	private static final String MAPCONTROL_REFRESH_RATE_KEY_NAME = "MapControlRefreshRate";
+
+	public ViewBehaviorPage() {
+		super();
+		setParentID(ViewPage.id);
+		addComponent(new JBlank(1,1));
+		refreshRate = new ScreenRefreshRatePanel();
+		addComponent(refreshRate);
+	}
+
+	@Override
+	public void setChangesApplied() {
+		setChanged(false);
+	}
+
+	@Override
+	public void storeValues() throws StoreException {
+		final int frameRate = refreshRate.getFrameRate();
+		final boolean bAnimationEnabled = frameRate>0;
+		if (frameRate > 0) {
+			MapContext.setDrawFrameRate(frameRate);
+		}
+		MapControl.setDrawAnimationEnabled(bAnimationEnabled);
+
+		// Apply on-the-fly to all already created views
+		IWindow[] windows = PluginServices.getMDIManager().getAllWindows();
+		for (int i = 0; i < windows.length; i++) {
+			if (windows[i] instanceof AbstractViewPanel) {
+				AbstractViewPanel view = (AbstractViewPanel) windows[i];
+				view.getMapControl().applyFrameRate();
+			}
+		}
+
+		PluginServices ps = PluginServices.getPluginServices(this);
+		XMLEntity xml = ps.getPersistentXML();
+		xml.putProperty(
+				MAPCONTROL_REFRESH_RATE_KEY_NAME,
+				MapContext.getDrawFrameRate());
+		xml.putProperty(
+				MAPCONTROL_ENABLE_ANIMATION_KEY_NAME,
+				MapControl.isDrawAnimationEnabled());
+
+	}
+
+	public String getID() {
+		return id;
+	}
+
+	public ImageIcon getIcon() {
+		return null;
+	}
+
+	public JPanel getPanel() {
+		return this;
+	}
+
+	public String getTitle() {
+		return PluginServices.getText(this, "behavior");
+	}
+
+	public void initializeDefaults() {
+		refreshRate.setFrameRate(FACTORY_DEFAULT_MAPCONTEXT_FRAME_RATE);
+	}
+
+	public void initializeValues() {
+		PluginServices ps = PluginServices.getPluginServices(this);
+		XMLEntity xml = ps.getPersistentXML();
+
+		// View refresh rate
+		if (xml.contains(MAPCONTROL_REFRESH_RATE_KEY_NAME)) {
+			MapContext.setDrawFrameRate(xml.getIntProperty(MAPCONTROL_REFRESH_RATE_KEY_NAME));
+		}
+
+		// View animation enabled
+		if (xml.contains(MAPCONTROL_ENABLE_ANIMATION_KEY_NAME)) {
+			MapControl.setDrawAnimationEnabled(xml.getBooleanProperty(MAPCONTROL_ENABLE_ANIMATION_KEY_NAME));
+		}
+
+
+		int frameRate = MapContext.getDrawFrameRate();
+		if (!MapControl.isDrawAnimationEnabled())
+			frameRate = 0;
+		refreshRate.setFrameRate(frameRate);
+	}
+
+	public boolean isValueChanged() {
+		return super.hasChanged();
+	}
+
+	private class ScreenRefreshRatePanel extends JPanel {
+		private static final long serialVersionUID = -68376902499946576L;
+		private JSlider sldRefreshRate;
+
+		public ScreenRefreshRatePanel() {
+    		setPreferredSize(new Dimension(500, 200));
+            Border border=BorderFactory.createTitledBorder(
+            		PluginServices.getText(this, "options.view.behavior.screen_refreshrate"));
+            setBorder(border);
+    		setLayout(new BorderLayout(15, 15));
+
+    		JPanel aux = new JPanel(new BorderLayout());
+    		aux.add(new JLabel(
+    				PluginServices.getText(
+    						this,
+    						"options.view.behavior.screen_refreshrate.none")),
+    				BorderLayout.WEST);
+    		JPanel aux2 = new JPanel(new FlowLayout(FlowLayout.CENTER));
+    		aux2.add(new JLabel(
+    				PluginServices.getText(
+    						this,
+    						"options.view.behavior.screen_refreshrate.half")),
+    				BorderLayout.CENTER);
+    		aux.add(aux2);
+    		aux.add(new JLabel(
+    				PluginServices.getText(
+    						this,
+    						"options.view.behavior.screen_refreshrate.full")),
+    				BorderLayout.EAST);
+
+    		add(aux, BorderLayout.NORTH);
+    		aux = new JPanel(new BorderLayout());
+    		aux.add(getSldRefreshRate(), BorderLayout.NORTH);
+    		aux.add(new JBlank(10, 20), BorderLayout.SOUTH);
+    		add(aux, BorderLayout.CENTER);
+    		add(new JLabel(PluginServices.
+    				getText(this, "options.view.behavior.screen_refresh_rate.help")),
+    				BorderLayout.SOUTH);
+    	}
+
+		private JSlider getSldRefreshRate() {
+			if (sldRefreshRate == null) {
+				sldRefreshRate = new JSlider(0, 30);
+
+			}
+
+			return sldRefreshRate;
+		}
+
+		public int getFrameRate() {
+			return getSldRefreshRate().getValue();
+		}
+
+		public void setFrameRate(int sampleRate) {
+			if (sampleRate<=30)
+				getSldRefreshRate().setValue(sampleRate);
+		}
+
+    }
+
+	@Override
+	public String getParentID() {
+		if (super.getParentID()==null) {
+			setParentID(ViewPage.id);
+		}
+		return super.getParentID();
+	}
+}

Property changes on: tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/app/gui/preferencespage/ViewBehaviorPage.java
___________________________________________________________________
Added: svn:keywords
   + Author Date Id Revision
Added: svn:eol-style
   + native

Index: tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/app/gui/preferencespage/ViewPage.java
===================================================================
--- tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/app/gui/preferencespage/ViewPage.java	(revision 0)
+++ tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/app/gui/preferencespage/ViewPage.java	(revision 38653)
@@ -0,0 +1,611 @@
+/* gvSIG. Sistema de Informaci�n Geogr�fica de la Generalitat Valenciana
+ *
+ * Copyright (C) 2005 IVER T.I. and Generalitat Valenciana.
+ *
+ * This program is free software; you can redistribute it and/or
+ * modify it under the terms of the GNU General Public License
+ * as published by the Free Software Foundation; either version 2
+ * of the License, or (at your option) any later version.
+ *
+ * This program is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
+ * GNU General Public License for more details.
+ *
+ * You should have received a copy of the GNU General Public License
+ * along with this program; if not, write to the Free Software
+ * Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA  02111-1307,USA.
+ *
+ * For more information, contact:
+ *
+ *  Generalitat Valenciana
+ *   Conselleria d'Infraestructures i Transport
+ *   Av. Blasco Ib��ez, 50
+ *   46010 VALENCIA
+ *   SPAIN
+ *
+ *      +34 963862235
+ *   gvsig@gva.es
+ *      www.gvsig.gva.es
+ *
+ *    or
+ *
+ *   IVER T.I. S.A
+ *   Salamanca 50
+ *   46005 Valencia
+ *   Spain
+ *
+ *   +34 963163400
+ *   dac@iver.es
+ */
+
+/* CVS MESSAGES:
+*
+* $Id$
+* $Log$
+* Revision 1.27  2007-09-17 09:22:10  jaume
+* view draw frame rate now customizable
+*
+* Revision 1.26  2007/05/09 16:08:14  jaume
+* *** empty log message ***
+*
+* Revision 1.25  2007/03/06 16:35:02  caballero
+* Exceptions
+*
+* Revision 1.24  2007/02/20 15:52:32  caballero
+* *** empty log message ***
+*
+* Revision 1.23  2007/01/25 11:04:07  caballero
+* comprobar que el factor no es cero
+*
+* Revision 1.22  2006/12/20 14:41:12  caballero
+* Remodelado Layout
+*
+* Revision 1.21  2006/11/08 10:57:55  jaume
+* remove unecessary imports
+*
+* Revision 1.20  2006/10/25 08:34:06  jmvivo
+* LLamado al PluginServices.getText para las unidades de medida del los combo
+*
+* Revision 1.19  2006/10/04 07:23:31  jaume
+* refactored ambiguous methods and field names and added some more features for preference pages
+*
+* Revision 1.18  2006/10/03 09:52:38  jaume
+* restores to meters
+*
+* Revision 1.17  2006/10/03 09:19:12  jaume
+* *** empty log message ***
+*
+* Revision 1.16  2006/10/03 07:26:08  jaume
+* *** empty log message ***
+*
+* Revision 1.15  2006/10/02 15:30:29  jaume
+* *** empty log message ***
+*
+* Revision 1.14  2006/10/02 13:52:34  jaume
+* organize impots
+*
+* Revision 1.13  2006/10/02 13:38:23  jaume
+* *** empty log message ***
+*
+* Revision 1.12  2006/10/02 11:49:23  jaume
+* *** empty log message ***
+*
+* Revision 1.11  2006/09/28 12:04:21  jaume
+* default selection color now configurable
+*
+* Revision 1.10  2006/09/25 10:17:15  caballero
+* Projection
+*
+* Revision 1.9  2006/09/15 10:41:30  caballero
+* extensibilidad de documentos
+*
+* Revision 1.8  2006/09/14 15:43:48  jaume
+* *** empty log message ***
+*
+* Revision 1.7  2006/09/14 15:42:38  jaume
+* *** empty log message ***
+*
+* Revision 1.6  2006/09/14 06:57:18  jaume
+* *** empty log message ***
+*
+* Revision 1.5  2006/09/12 15:56:50  jaume
+* Default Projection now customizable
+*
+* Revision 1.4  2006/08/29 07:21:08  cesar
+* Rename com.iver.cit.gvsig.fmap.Fmap class to com.iver.cit.gvsig.fmap.MapContext
+*
+* Revision 1.3  2006/08/22 12:30:59  jaume
+* *** empty log message ***
+*
+* Revision 1.2  2006/08/22 07:36:04  jaume
+* *** empty log message ***
+*
+* Revision 1.1  2006/08/04 11:41:05  caballero
+* poder especificar el zoom a aplicar en las vistas
+*
+* Revision 1.3  2006/07/31 10:02:31  jaume
+* *** empty log message ***
+*
+* Revision 1.2  2006/06/13 07:43:08  fjp
+* Ajustes sobre los cuadros de dialogos de preferencias
+*
+* Revision 1.1  2006/06/12 16:04:28  caballero
+* Preferencias
+*
+* Revision 1.11  2006/06/06 10:26:31  jaume
+* *** empty log message ***
+*
+* Revision 1.10  2006/06/05 17:07:17  jaume
+* *** empty log message ***
+*
+* Revision 1.9  2006/06/05 17:00:44  jaume
+* *** empty log message ***
+*
+* Revision 1.8  2006/06/05 16:57:59  jaume
+* *** empty log message ***
+*
+* Revision 1.7  2006/06/05 14:45:06  jaume
+* *** empty log message ***
+*
+* Revision 1.6  2006/06/05 11:00:09  jaume
+* *** empty log message ***
+*
+* Revision 1.5  2006/06/05 10:39:02  jaume
+* *** empty log message ***
+*
+* Revision 1.4  2006/06/05 10:13:40  jaume
+* *** empty log message ***
+*
+* Revision 1.3  2006/06/05 10:06:08  jaume
+* *** empty log message ***
+*
+* Revision 1.2  2006/06/05 09:51:56  jaume
+* *** empty log message ***
+*
+* Revision 1.1  2006/06/02 10:50:18  jaume
+* *** empty log message ***
+*
+*
+*/
+package org.gvsig.app.gui.preferencespage;
+
+import java.awt.Color;
+import java.awt.Dimension;
+import java.awt.FlowLayout;
+import java.awt.event.ActionEvent;
+import java.awt.event.ActionListener;
+import java.util.Enumeration;
+
+import javax.swing.DefaultComboBoxModel;
+import javax.swing.ImageIcon;
+import javax.swing.JCheckBox;
+import javax.swing.JLabel;
+import javax.swing.JPanel;
+import javax.swing.JTextField;
+import javax.swing.UIManager;
+import javax.swing.plaf.FontUIResource;
+
+import org.cresques.cts.IProjection;
+import org.gvsig.andami.PluginServices;
+import org.gvsig.andami.preferences.AbstractPreferencePage;
+import org.gvsig.andami.preferences.StoreException;
+import org.gvsig.app.addlayer.AddLayerDialog;
+import org.gvsig.app.gui.panels.CRSSelectPanel;
+import org.gvsig.app.gui.panels.ColorChooserPanel;
+import org.gvsig.app.gui.panels.crs.ISelectCrsPanel;
+import org.gvsig.app.project.DefaultProject;
+import org.gvsig.app.project.documents.view.gui.DefaultViewPanel;
+import org.gvsig.fmap.crs.CRSFactory;
+import org.gvsig.fmap.mapcontext.MapContext;
+import org.gvsig.gui.beans.swing.JButton;
+import org.gvsig.utils.StringUtilities;
+import org.gvsig.utils.XMLEntity;
+import org.gvsig.utils.swing.JComboBox;
+
+/**
+ *  View document configuration page.
+ *  <b><b>
+ *  Here the user can establish what settings wants to use by default regarding to
+ *  the document View.
+ *
+ *
+ * @author jaume dominguez faus - jaume.dominguez@iver.es
+ */
+public class ViewPage extends AbstractPreferencePage {
+
+	private static final String DEFAULT_PROJECTION_KEY_NAME = "DefaultProjection";
+	private static final String FACTORY_DEFAULT_PROJECTION = "EPSG:23030";
+	private static final String ZOOM_IN_FACTOR_KEY_NAME = "ZoomInFactor";
+	private static final String ZOOM_OUT_FACTOR_KEY_NAME = "ZoomOutFactor";
+	public static final String ADD_NEW_LAYERS_IN_INVISIBLE_MODE_KEY_NAME = "NewLayersInInvisibleMode";
+	private static final String KEEP_SCALE_ON_RESIZING_KEY_NAME = "KeepScaleOnResizing";
+	private static final String DEFAULT_SELECTION_COLOR_KEY_NAME = "DefaultSelectionColor";
+	private static final String DEFAULT_VIEW_BACK_COLOR_KEY_NAME = "DefaultViewBackColor";
+	private static final String DEFAULT_DISTANCE_AREA_KEY_NAME = "DefaultDistanceArea";
+	private static final String DEFAULT_DISTANCE_UNITS_KEY_NAME = "DefaultDistanceUnits";
+	private static final String DEFAULT_MAP_UNITS_KEY_NAME = "DefaultMapUnits";
+	/*
+	 * Locator's background color, for when we let it be possible
+	 * private static final String DEFAULT_MAP_OVERVIEW_BACK_COLOR_KEY_NAME = "DefaultMapOverViewBackColor";
+	 */
+	private static final double DEFAULT_ZOOM_IN_FACTOR = 2.0;
+	private static final double DEFAULT_ZOOM_OUT_FACTOR = 0.5;
+	private static final Color FACTORY_DEFAULT_SELECTION_COLOR = Color.YELLOW;
+	private static final Color FACTORY_DEFAULT_VIEW_BACK_COLOR = Color.WHITE;
+	/*
+	 * Locator's background color, for when we let it be possible
+	 * private static final Color FACTORY_DEFAULT_MAP_OVERVIEW_BACK_COLOR = Color.WHITE;
+	 */
+
+	private static String[] unitsNames = null;
+
+	private static int FACTORY_DEFAULT_MAP_UNITS;
+	private static int FACTORY_DEFAULT_DISTANCE_UNITS;
+	private static int FACTORY_DEFAULT_DISTANCE_AREA;
+
+	private JTextField txtZoomInFactor;
+	private JTextField txtZoomOutFactor;
+	protected static String id = ViewPage.class.getName();
+	private ImageIcon icon;
+	private JLabel lblDefaultProjection;
+	private JButton btnChangeProjection;
+	private String fontName;
+	private JCheckBox chkInvisibleNewLayers;
+	private JCheckBox chkKeepScaleOnResizing;
+	private ColorChooserPanel jccDefaultSelectionColor;
+	private ColorChooserPanel jccDefaultViewBackColor;
+	private JComboBox jCmbMapUnits;
+	private JComboBox jCmbDistanceUnits;
+	private JComboBox jCmbDistanceArea;
+	
+	CRSSelectPanel jPanelProj = null;
+	
+	
+	/*
+	 * Locator's background color, for when we let it be possible
+	 * private ColorChooserPanel jccDefaultMapOverViewBackColor;
+	 */
+
+	{
+		Enumeration keys = UIManager.getDefaults().keys();
+		while (keys.hasMoreElements()) {
+			Object key = keys.nextElement();
+			Object value = UIManager.get (key);
+			if (value instanceof FontUIResource) {
+				FontUIResource fur = (FontUIResource) value;
+				fontName = fur.getFontName();
+
+			}
+		}
+
+		String[] unitNames = MapContext.getDistanceNames();
+		for (int i = 0; i < unitNames.length; i++) {
+			if (unitNames[i].equals("Metros")) {
+				FACTORY_DEFAULT_DISTANCE_UNITS = i;
+				FACTORY_DEFAULT_DISTANCE_AREA = i;
+				FACTORY_DEFAULT_MAP_UNITS = i;
+				break;
+			}
+		}
+
+	}
+
+	/**
+	 * Creates a new panel containing View preferences settings.
+	 *
+	 */
+	public ViewPage() {
+		super();
+
+		icon = PluginServices.getIconTheme().get("vista-icono");
+
+		// default projection
+		lblDefaultProjection = new JLabel();
+		lblDefaultProjection.setFont(new java.awt.Font(
+			fontName, java.awt.Font.BOLD, 11));
+		btnChangeProjection = new JButton(PluginServices.getText(this, "change"));
+		btnChangeProjection.addActionListener(new ActionListener() {
+			public void actionPerformed(ActionEvent e) {
+				ISelectCrsPanel panel = CRSSelectPanel.getUIFactory().getSelectCrsPanel(
+						CRSFactory.getCRS(lblDefaultProjection.getText()), false);
+				PluginServices.getMDIManager().addWindow(panel);
+		        if (panel.isOkPressed()) {
+		        	IProjection proj = panel.getProjection();
+		        	lblDefaultProjection.setText(proj.getAbrev());
+		        }
+			}
+		});
+
+		addComponent(PluginServices.getText(this, "default_projection") + ":", lblDefaultProjection );
+		
+		IProjection proj = CRSFactory.getCRS("EPSG:23030");
+		if (PluginServices.getMainFrame() != null) {
+			proj = AddLayerDialog.getLastProjection();
+		}
+
+		jPanelProj = CRSSelectPanel.getPanel(proj);
+		jPanelProj.setTransPanelActive(true);
+		jPanelProj.setBounds(11, 400, 448, 35);
+		jPanelProj.setPreferredSize(new Dimension(448, 35));
+		jPanelProj.addActionListener(new ActionListener() {
+			public void actionPerformed(ActionEvent e) {
+				if (jPanelProj.isOkPressed()) {
+					lblDefaultProjection.setText(jPanelProj.getCurProj().getAbrev());
+				}
+			}
+		});
+		
+		
+		JPanel aux = new JPanel(new FlowLayout(FlowLayout.LEFT, 0, 0));
+		aux.add(btnChangeProjection);
+		addComponent("", aux);
+
+		// just a separator
+		addComponent(new JLabel(" "));
+
+		// Adding Invisible New Layers
+		chkInvisibleNewLayers = new JCheckBox(
+				PluginServices.getText(this, "options.view.invisible_new_layers"));
+
+		addComponent("", chkInvisibleNewLayers);
+		chkKeepScaleOnResizing = new JCheckBox(
+				PluginServices.getText(this, "options.view.keep_scale_on_resizing"));
+		chkKeepScaleOnResizing.setEnabled(false);
+		addComponent("", chkKeepScaleOnResizing);
+
+		// just a separator
+		addComponent(new JLabel(" "));
+
+		// zoom in factor
+		addComponent(PluginServices.getText(this, "zoom_in_factor") + ":",
+			txtZoomInFactor = new JTextField("", 15));
+		// zoom out factor
+		addComponent(PluginServices.getText(this, "zoom_out_factor") + ":",
+			txtZoomOutFactor = new JTextField("", 15));
+
+		// just a separator
+		addComponent(new JLabel(" "));
+
+		// default back color chooser
+		addComponent(PluginServices.getText(this, "options.view.default_view_back_color"),
+				jccDefaultViewBackColor = new ColorChooserPanel());
+
+		/*
+		 * Locator's background color, for when we let it be possible
+		 * // default back color chooser
+		 * addComponent(PluginServices.getText(this, "options.view.default_map_overview_back_color"), jccDefaultMapOverViewBackColor = new ColorChooserPanel());
+		 */
+
+		// default selection color chooser
+		addComponent(PluginServices.getText(this, "options.view.default_selection_color"),
+				jccDefaultSelectionColor = new ColorChooserPanel());
+
+		// just a separator
+		addComponent(new JLabel(" "));
+
+		// default map units
+		addComponent(PluginServices.getText(this, "map_units"),
+				jCmbMapUnits = new JComboBox());
+
+		// default distance units
+		addComponent(PluginServices.getText(this, "distance_units"),
+				jCmbDistanceUnits = new JComboBox());
+
+		// default distance area
+		addComponent(PluginServices.getText(this, "distance_area"),
+				jCmbDistanceArea = new JComboBox());
+
+		initializeValues();
+	}
+
+	public void initializeValues() {
+		PluginServices ps = PluginServices.getPluginServices(this);
+		XMLEntity xml = ps.getPersistentXML();
+
+		// Default Projection
+		if (xml.contains(DEFAULT_PROJECTION_KEY_NAME)) {
+			lblDefaultProjection.setText(
+				xml.getStringProperty(DEFAULT_PROJECTION_KEY_NAME));
+		} else {
+			lblDefaultProjection.setText(FACTORY_DEFAULT_PROJECTION);
+		}
+		DefaultProject.setDefaultProjection( CRSFactory.getCRS(lblDefaultProjection.getText()));
+
+		// Adding invisible new layers
+		if (xml.contains(ADD_NEW_LAYERS_IN_INVISIBLE_MODE_KEY_NAME)) {
+			chkInvisibleNewLayers.setSelected(
+				xml.getBooleanProperty(ADD_NEW_LAYERS_IN_INVISIBLE_MODE_KEY_NAME));
+		}
+
+		// Keep scale on resizing
+		if (xml.contains(KEEP_SCALE_ON_RESIZING_KEY_NAME)) {
+			chkKeepScaleOnResizing.setSelected(
+				xml.getBooleanProperty(KEEP_SCALE_ON_RESIZING_KEY_NAME));
+		}
+
+		// Zoom-in factor
+		if (xml.contains(ZOOM_IN_FACTOR_KEY_NAME)) {
+			double zoomInFactor = xml.getDoubleProperty(ZOOM_IN_FACTOR_KEY_NAME);
+			txtZoomInFactor.setText(String.valueOf( zoomInFactor ));
+		} else {
+			txtZoomInFactor.setText(
+				String.valueOf( MapContext.ZOOMINFACTOR ));
+		}
+		MapContext.ZOOMINFACTOR = Double.parseDouble(txtZoomInFactor.getText());
+
+		// Zoom-out factor
+		if (xml.contains(ZOOM_OUT_FACTOR_KEY_NAME)) {
+			double zoomOutFactor = xml.getDoubleProperty(ZOOM_OUT_FACTOR_KEY_NAME);
+			txtZoomOutFactor.setText(String.valueOf( zoomOutFactor ));
+		} else {
+			txtZoomOutFactor.setText(
+				String.valueOf( MapContext.ZOOMOUTFACTOR ));
+		}
+		MapContext.ZOOMOUTFACTOR = Double.parseDouble(txtZoomOutFactor.getText());;
+
+		// Default back color
+		jccDefaultViewBackColor.setColor(DefaultViewPanel.getDefaultBackColor());
+		jccDefaultViewBackColor.setAlpha(255);
+		/*
+		 * Locator's background color, for when we let it be possible
+		 * // Default map overview back color
+		 * jccDefaultMapOverViewBackColor.setColor(Project.getDefaultMapOverViewBackColor());
+		 * jccDefaultMapOverViewBackColor.setAlpha(255);
+		 */
+
+		// Default selection color
+		jccDefaultSelectionColor.setColor(DefaultProject.getDefaultSelectionColor());
+		jccDefaultSelectionColor.setAlpha(255);
+		String[] distanceNames=MapContext.getDistanceNames();
+		// Map units
+		if (DefaultProject.getDefaultMapUnits()<=distanceNames.length && distanceNames.length != jCmbMapUnits.getItemCount()){
+			((DefaultComboBoxModel)jCmbMapUnits.getModel()).removeAllElements();
+			//			 default map units
+			for (int i = 0; i < distanceNames.length; i++) {
+				((DefaultComboBoxModel)jCmbMapUnits.getModel()).addElement(PluginServices.getText(this,distanceNames[i]));
+			}
+			jCmbMapUnits.setSelectedIndex(DefaultProject.getDefaultMapUnits());
+		}
+
+		// Distance units
+		if (DefaultProject.getDefaultDistanceUnits()<=distanceNames.length&& distanceNames.length != jCmbDistanceUnits.getItemCount()){
+			((DefaultComboBoxModel)jCmbDistanceUnits.getModel()).removeAllElements();
+			// default distance units
+			for (int i = 0; i < distanceNames.length; i++) {
+				((DefaultComboBoxModel)jCmbDistanceUnits.getModel()).addElement(PluginServices.getText(this,distanceNames[i]));
+			}
+			jCmbDistanceUnits.setSelectedIndex(DefaultProject.getDefaultDistanceUnits());
+		}
+		String[] names=MapContext.getAreaNames();
+
+		// Distance area
+		if (DefaultProject.getDefaultDistanceArea()<=names.length && names.length != jCmbDistanceArea.getItemCount()){
+			((DefaultComboBoxModel)jCmbDistanceArea.getModel()).removeAllElements();
+			for (int i = 0; i < names.length; i++) {
+				((DefaultComboBoxModel)jCmbDistanceArea.getModel()).addElement(PluginServices.getText(this,names[i])+MapContext.getOfLinear(i));
+			}
+			jCmbDistanceArea.setSelectedIndex(DefaultProject.getDefaultDistanceArea());
+		}
+	}
+
+	public String getID() {
+		return id;
+	}
+
+	public String getTitle() {
+		return PluginServices.getText(this, "Vista");
+	}
+
+	public JPanel getPanel() {
+		return this;
+	}
+
+	public void storeValues() throws StoreException {
+		String projName = lblDefaultProjection.getText();
+		double zif=1;
+		double zof=1;
+		boolean invisibleNewLayers, keepScaleOnResize;
+		Color selectionColor, viewBackColor;
+		/*
+		 * Locator's background color, for when we let it be possible
+		 * Color mapOverViewBackColor;
+		 */
+
+		try {
+//			try {
+				zif=Double.parseDouble(txtZoomInFactor.getText());
+				zof=Double.parseDouble(txtZoomOutFactor.getText());
+				if (zif==0 || zof==0) {
+					throw new NumberFormatException();
+				}
+//			}catch (NumberFormatException e) {
+//				//JOptionPane.showMessageDialog((Component)PluginServices.getMainFrame(),PluginServices.getText(this,"numero_incorrecto")+" = "+ txtZoomInFactor.getText()+ ", "+txtZoomOutFactor.getText());
+//				throw new StoreException(PluginServices.getText(this,"numero_incorrecto")+" = "+ txtZoomInFactor.getText()+ ", "+txtZoomOutFactor.getText());
+//			}
+			DefaultProject.setDefaultProjection( CRSFactory.getCRS(projName));
+
+			selectionColor = jccDefaultSelectionColor.getColor();
+			DefaultProject.setDefaultSelectionColor( selectionColor );
+
+			viewBackColor = jccDefaultViewBackColor.getColor();
+			DefaultViewPanel.setDefaultBackColor( viewBackColor );
+			/*
+			 * Locator's background color, for when we let it be possible
+			 * mapOverViewBackColor = jccDefaultMapOverViewBackColor.getColor();
+			 * View.setDefaultMapOverViewBackColor( mapOverViewBackColor );
+			 */
+
+			DefaultProject.setDefaultMapUnits(jCmbMapUnits.getSelectedIndex());
+			DefaultProject.setDefaultDistanceUnits(jCmbDistanceUnits.getSelectedIndex());
+			DefaultProject.setDefaultDistanceArea(jCmbDistanceArea.getSelectedIndex());
+			invisibleNewLayers = chkInvisibleNewLayers.isSelected();
+			keepScaleOnResize = chkKeepScaleOnResizing.isSelected();
+		} catch (Exception e) {
+			throw new StoreException(PluginServices.getText(this,"factor_zoom_incorrecto"));
+		}
+		MapContext.ZOOMINFACTOR=zif;
+		MapContext.ZOOMOUTFACTOR=zof;
+		// MapControl.setScalingOnResize(!keepScaleOnResize);
+
+		PluginServices ps = PluginServices.getPluginServices(this);
+		XMLEntity xml = ps.getPersistentXML();
+		xml.putProperty(DEFAULT_PROJECTION_KEY_NAME, projName);
+		xml.putProperty(ZOOM_IN_FACTOR_KEY_NAME, zif);
+		xml.putProperty(ZOOM_OUT_FACTOR_KEY_NAME, zof);
+		xml.putProperty(ADD_NEW_LAYERS_IN_INVISIBLE_MODE_KEY_NAME, invisibleNewLayers);
+		xml.putProperty(KEEP_SCALE_ON_RESIZING_KEY_NAME, keepScaleOnResize);
+		xml.putProperty(DEFAULT_VIEW_BACK_COLOR_KEY_NAME, StringUtilities.color2String(viewBackColor));
+		/*
+		 * Locator's background color, for when we let it be possible
+		 * xml.putProperty(DEFAULT_MAP_OVERVIEW_BACK_COLOR_KEY_NAME, StringUtilities.color2String(mapOverViewBackColor));
+		 */
+		xml.putProperty(DEFAULT_SELECTION_COLOR_KEY_NAME, StringUtilities.color2String(selectionColor));
+		xml.putProperty(DEFAULT_MAP_UNITS_KEY_NAME, jCmbMapUnits.getSelectedIndex());
+		xml.putProperty(DEFAULT_DISTANCE_UNITS_KEY_NAME, jCmbDistanceUnits.getSelectedIndex());
+		xml.putProperty(DEFAULT_DISTANCE_AREA_KEY_NAME, jCmbDistanceArea.getSelectedIndex());
+	}
+
+
+	public void initializeDefaults() {
+		lblDefaultProjection.setText(FACTORY_DEFAULT_PROJECTION);
+		txtZoomInFactor.setText(String.valueOf(DEFAULT_ZOOM_IN_FACTOR));
+		txtZoomOutFactor.setText(String.valueOf(DEFAULT_ZOOM_OUT_FACTOR));
+		chkInvisibleNewLayers.setSelected(false);
+		chkKeepScaleOnResizing.setSelected(false);
+		jccDefaultViewBackColor.setColor(FACTORY_DEFAULT_VIEW_BACK_COLOR);
+		/*
+		 * Locator's background color, for when we let it be possible
+		 * jccDefaultMapOverViewBackColor.setColor(FACTORY_DEFAULT_VIEW_BACK_COLOR);
+		 */
+		jccDefaultSelectionColor.setColor(FACTORY_DEFAULT_SELECTION_COLOR);
+		jCmbMapUnits.setSelectedIndex(FACTORY_DEFAULT_MAP_UNITS);
+		jCmbDistanceUnits.setSelectedIndex(FACTORY_DEFAULT_DISTANCE_UNITS);
+		jCmbDistanceArea.setSelectedIndex(FACTORY_DEFAULT_DISTANCE_AREA);
+
+	}
+
+	public ImageIcon getIcon() {
+		return icon;
+	}
+
+	public boolean isValueChanged() {
+		return super.hasChanged();
+	}
+
+	public void setChangesApplied() {
+		setChanged(false);
+	}
+
+
+//	private String[] getUnitsNames() {
+//		if (unitsNames == null) {
+//			String[] names=MapContext.getDistanceNames();
+//			unitsNames = new String[names.length];
+//			for (int i=0;i<names.length;i++) {
+//				unitsNames[i]=PluginServices.getText(this, names[i]);
+//			}
+//		}
+//		return unitsNames;
+//	}
+}

Property changes on: tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/app/gui/preferencespage/ViewPage.java
___________________________________________________________________
Added: svn:eol-style
   + native
Added: svn:keywords
   + Author Date Id Revision

Index: tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/app/gui/preferencespage/AppSymbolPreferences.java
===================================================================
--- tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/app/gui/preferencespage/AppSymbolPreferences.java	(revision 0)
+++ tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/app/gui/preferencespage/AppSymbolPreferences.java	(revision 38653)
@@ -0,0 +1,195 @@
+/* gvSIG. Geographic Information System of the Valencian Government
+*
+* Copyright (C) 2007-2008 Infrastructures and Transports Department
+* of the Valencian Government (CIT)
+* 
+* This program is free software; you can redistribute it and/or
+* modify it under the terms of the GNU General Public License
+* as published by the Free Software Foundation; either version 2
+* of the License, or (at your option) any later version.
+* 
+* This program is distributed in the hope that it will be useful,
+* but WITHOUT ANY WARRANTY; without even the implied warranty of
+* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
+* GNU General Public License for more details.
+* 
+* You should have received a copy of the GNU General Public License
+* along with this program; if not, write to the Free Software
+* Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, 
+* MA  02110-1301, USA.
+* 
+*/
+
+/*
+* AUTHORS (In addition to CIT):
+* 2009 {}  {{Task}}
+*/
+package org.gvsig.app.gui.preferencespage;
+
+import java.awt.Color;
+import java.awt.Font;
+import java.io.File;
+
+import org.gvsig.andami.PluginServices;
+import org.gvsig.fmap.mapcontext.MapContextLocator;
+import org.gvsig.fmap.mapcontext.rendering.symbols.CartographicSupport;
+import org.gvsig.fmap.mapcontext.rendering.symbols.SymbolPreferences;
+import org.gvsig.tools.dynobject.DynObject;
+
+/**
+ * Default {@link SymbolPreferences} implementation based on object attributes.
+ * 
+ * @author 2009- <a href="cordinyana@gvsig.org">C�sar Ordi�ana</a> - gvSIG team
+ */
+public class AppSymbolPreferences implements SymbolPreferences {
+	private static final String SYMBOL_COLOR                   = "defaultSymbolColor";
+	private static final String SYMBOL_FILL_COLOR              = "defaultSymbolFillColor";
+	private static final String SYMBOL_FILL_COLOR_ALEATORY     = "defaultSymbolFillColorAleatory";
+	private static final String SYMBOL_FONT                    = "defaultSymbolFont";
+	private static final String SYMBOL_LIBRARY_PATH            = "symbolLibraryPath";
+	
+	private DynObject           values                         = null;
+	
+	private String symbolFileExtension = ".gvssym";
+	private Color defaultSymbolColor;
+	private Color defaultSymbolFillColor;
+	private boolean defaultSymbolFillColorAleatory;
+	private Font defaultSymbolFont;
+	private String symbolLibraryPath;
+
+	/**
+	 * The unit that will be used when creating new symbols with Cartographic
+	 * support.
+	 */
+	private int defaultCartographicSupportMeasureUnit = -1;
+
+	/**
+	 * The reference system that will be used when creating new symbols with
+	 * Cartographic support.
+	 */
+	private int defaultCartographicSupportReferenceSystem = CartographicSupport.WORLD;
+
+	public AppSymbolPreferences() {
+		values = PluginServices.getPluginServices(this).getPluginProperties();
+		initDefaults();
+	}
+	
+	private void initDefaults() {
+		resetDefaultSymbolColor();
+		resetDefaultSymbolFillColor();
+		resetDefaultSymbolFillColorAleatory();
+		resetSymbolLibraryPath();
+		resetDefaultSymbolFont();
+		
+		if(getDefaultSymbolFont() == null)
+			setDefaultSymbolFont(defaultSymbolFont);
+		if(getDefaultSymbolColor() == null)
+			setDefaultSymbolColor(defaultSymbolColor);
+		if(getDefaultSymbolFillColor() == null)
+			setDefaultSymbolFillColor(defaultSymbolFillColor);
+		if(getSymbolLibraryPath() == null)
+			setSymbolLibraryPath(symbolLibraryPath);
+		setSymbolFileExtension(symbolFileExtension);
+		setDefaultCartographicSupportMeasureUnit(defaultCartographicSupportMeasureUnit);
+		setDefaultCartographicSupportReferenceSystem(defaultCartographicSupportReferenceSystem);
+	}
+
+	public String getSymbolFileExtension() {
+		return symbolFileExtension;
+	}
+
+	public void setSymbolFileExtension(String symbolFileExtension) {
+		this.symbolFileExtension = symbolFileExtension;
+	}
+	
+	public String getSymbolLibraryPath() {
+		return (String)values.getDynValue(SYMBOL_LIBRARY_PATH);
+	}
+
+	public void setSymbolLibraryPath(String symbolLibraryPath) {
+		values.setDynValue(SYMBOL_LIBRARY_PATH, symbolLibraryPath);
+		PluginServices.getPluginServices(this).savePluginProperties();
+	}
+
+	public Color getDefaultSymbolColor() {
+		return (Color)values.getDynValue(SYMBOL_COLOR);
+	}
+
+	public void setDefaultSymbolColor(Color symbolColor) {
+		values.setDynValue(SYMBOL_COLOR, symbolColor);
+		PluginServices.getPluginServices(this).savePluginProperties();
+	}
+
+	public Color getDefaultSymbolFillColor() {
+		return (Color)values.getDynValue(SYMBOL_FILL_COLOR);
+	}
+
+	public void setDefaultSymbolFillColor(Color symbolFillColor) {
+		values.setDynValue(SYMBOL_FILL_COLOR, symbolFillColor);
+		PluginServices.getPluginServices(this).savePluginProperties();
+	}
+
+	public boolean isDefaultSymbolFillColorAleatory() {
+		if(values.getDynValue(SYMBOL_FILL_COLOR_ALEATORY) == null) {
+			setDefaultSymbolFillColorAleatory(defaultSymbolFillColorAleatory);
+		}
+		return (Boolean)values.getDynValue(SYMBOL_FILL_COLOR_ALEATORY);
+	}
+
+	public void setDefaultSymbolFillColorAleatory(boolean defaultSymbolFillColorAleatory) {
+		values.setDynValue(SYMBOL_FILL_COLOR_ALEATORY, defaultSymbolFillColorAleatory);
+		PluginServices.getPluginServices(this).savePluginProperties();
+	}
+
+	public Font getDefaultSymbolFont() {
+		return (Font)values.getDynValue(SYMBOL_FONT);
+	}
+
+	public void setDefaultSymbolFont(Font defaultSymbolFont) {
+		values.setDynValue(SYMBOL_FONT, defaultSymbolFont);
+		PluginServices.getPluginServices(this).savePluginProperties();
+	}
+
+
+	public int getDefaultCartographicSupportMeasureUnit() {
+		return defaultCartographicSupportMeasureUnit;
+	}
+
+	public void setDefaultCartographicSupportMeasureUnit(
+			int defaultCartographicSupportMeasureUnit) {
+		this.defaultCartographicSupportMeasureUnit =
+				defaultCartographicSupportMeasureUnit;
+	}
+
+	public int getDefaultCartographicSupportReferenceSystem() {
+		return defaultCartographicSupportReferenceSystem;
+	}
+
+	public void setDefaultCartographicSupportReferenceSystem(
+			int defaultCartographicSupportReferenceSystem) {
+		this.defaultCartographicSupportReferenceSystem =
+				defaultCartographicSupportReferenceSystem;
+	}
+
+	public void resetDefaultSymbolColor() {
+		defaultSymbolColor = Color.GRAY;
+	}
+
+	public void resetDefaultSymbolFillColor() {
+		defaultSymbolFillColor = new Color(60, 235, 235);
+	}
+
+	public void resetDefaultSymbolFillColorAleatory() {
+		defaultSymbolFillColorAleatory = true;
+	}
+
+	public void resetDefaultSymbolFont() {
+		defaultSymbolFont = new Font("Serif", Font.PLAIN, 8);
+	}
+
+	public void resetSymbolLibraryPath() {
+		symbolLibraryPath =
+			System.getProperty("user.home") + File.separator + "gvSIG"
+					+ File.separator + "Symbols";
+	}
+}
\ No newline at end of file

Property changes on: tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/app/gui/preferencespage/AppSymbolPreferences.java
___________________________________________________________________
Added: svn:mime-type
   + text/plain

Index: tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/app/gui/preferencespage/DriversPages.java
===================================================================
--- tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/app/gui/preferencespage/DriversPages.java	(revision 0)
+++ tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/app/gui/preferencespage/DriversPages.java	(revision 38653)
@@ -0,0 +1,75 @@
+package org.gvsig.app.gui.preferencespage;
+
+import java.awt.BorderLayout;
+
+import javax.swing.ImageIcon;
+import javax.swing.JLabel;
+import javax.swing.JPanel;
+
+import org.gvsig.andami.PluginServices;
+import org.gvsig.andami.preferences.AbstractPreferencePage;
+
+
+
+/**
+ * P�gina de preferencias de donde cuelgan todos los drivers.
+ *
+ * @author Vicente Caballero Navarro
+ */
+public class DriversPages extends AbstractPreferencePage {
+    private JLabel jLabel = null;
+    private ImageIcon icon;
+
+    /**
+     * This is the default constructor
+     */
+    public DriversPages() {
+        super();
+        icon=PluginServices.getIconTheme().get("layout-insert-view");
+        initialize();
+    }
+
+    /**
+     * This method initializes this
+     */
+    private void initialize() {
+        jLabel = new JLabel();
+        jLabel.setText(PluginServices.getText(this,
+                "configurar_todos_los_drivers"));
+        this.setLayout(new BorderLayout());
+        this.setSize(300, 200);
+        this.add(jLabel, java.awt.BorderLayout.CENTER);
+    }
+
+    public String getID() {
+        return this.getClass().getName();
+    }
+
+    public String getTitle() {
+        return PluginServices.getText(this, "drivers");
+    }
+
+    public JPanel getPanel() {
+        return this;
+    }
+
+    public void initializeValues() {
+    }
+
+    public void storeValues() {
+    }
+
+    public void initializeDefaults() {
+    }
+
+    public ImageIcon getIcon() {
+        return icon;
+    }
+
+    public boolean isValueChanged() {
+        return false; // Because it does not manage values
+    }
+
+    public void setChangesApplied() {
+    }
+}

Property changes on: tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/app/gui/preferencespage/DriversPages.java
___________________________________________________________________
Added: svn:keywords
   + Author Date Id Revision
Added: svn:eol-style
   + native

Index: tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/app/gui/preferencespage/CartographicSupportPage.java
===================================================================
--- tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/app/gui/preferencespage/CartographicSupportPage.java	(revision 0)
+++ tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/app/gui/preferencespage/CartographicSupportPage.java	(revision 38653)
@@ -0,0 +1,106 @@
+package org.gvsig.app.gui.preferencespage;
+
+import javax.swing.ImageIcon;
+import javax.swing.JPanel;
+import javax.swing.JSeparator;
+
+import org.gvsig.andami.PluginServices;
+import org.gvsig.andami.preferences.AbstractPreferencePage;
+import org.gvsig.andami.preferences.StoreException;
+import org.gvsig.app.gui.JComboBoxUnits;
+import org.gvsig.app.gui.styling.JComboBoxUnitsReferenceSystem;
+import org.gvsig.fmap.mapcontext.rendering.symbols.CartographicSupport;
+import org.gvsig.symbology.fmap.mapcontext.rendering.symbol.impl.CartographicSupportToolkit;
+import org.gvsig.utils.XMLEntity;
+
+
+/**
+ *
+ * @author jaume dominguez faus - jaume.dominguez@iver.es
+ */
+public class CartographicSupportPage extends AbstractPreferencePage {
+	private static final String DefaultMeasureUnitKey = "DefaultMeasureUnitKey";
+	private static final String DefaultUnitReferenceSystemKey = "DefaultUnitReferenceSystemKey";
+	private JComboBoxUnits cmbUnits;
+	private JComboBoxUnitsReferenceSystem cmbReferenceSystem;
+	
+	public CartographicSupportPage() {
+		super();
+		initialize();
+	}
+	
+	private void initialize() {
+		addComponent(PluginServices.getText(this, "default_measure_units"),
+				cmbUnits = new JComboBoxUnits(true));
+		addComponent(PluginServices.getText(this, "default_measure_units_reference_system"),
+				cmbReferenceSystem = new JComboBoxUnitsReferenceSystem());
+		addComponent(new JSeparator(JSeparator.HORIZONTAL));
+	}
+
+	// pending of a proposed refactor, don't erase
+//	@Override
+//	public void persistPreferences() throws StoreException {
+//		PluginServices ps = PluginServices.getPluginServices(this);
+//		XMLEntity xml = ps.getPersistentXML();
+//		xml.putProperty(DefaultMeasureUnitKey, cmbUnits.getSelectedUnitIndex());
+//		xml.putProperty(DefaultUnitReferenceSystemKey, cmbReferenceSystem.getSelectedIndex());
+//	}
+
+	@Override
+	public void setChangesApplied() {
+		setChanged(false);
+	}
+
+	public void applyValuesFromPersistence() throws StoreException {
+		PluginServices ps = PluginServices.getPluginServices(this);
+		XMLEntity xml = ps.getPersistentXML();
+		if (xml.contains(DefaultMeasureUnitKey))
+			CartographicSupportToolkit.DefaultMeasureUnit = xml.getIntProperty(DefaultMeasureUnitKey);
+		if (xml.contains(DefaultUnitReferenceSystemKey))
+			CartographicSupportToolkit.DefaultReferenceSystem = xml.getIntProperty(DefaultUnitReferenceSystemKey);
+	}
+
+	public String getID() {
+		return getClass().getName();
+	}
+
+	public ImageIcon getIcon() {
+		// TODO Auto-generated method stub
+		return null;
+	}
+
+	public JPanel getPanel() {
+		return this;
+	}
+
+	public String getTitle() {
+		return PluginServices.getText(this, "cartographic_support");
+	}
+
+	// pending of a refactoring do not delete (swap commented lines)
+//	public void initializeComponents() {
+	public void initializeValues() {
+		cmbUnits.setSelectedUnitIndex(CartographicSupportToolkit.DefaultMeasureUnit);
+		cmbReferenceSystem.setSelectedIndex(CartographicSupportToolkit.DefaultReferenceSystem);
+	}
+
+	public void initializeDefaults() {
+		CartographicSupportToolkit.DefaultMeasureUnit = -1; // pixel
+		CartographicSupportToolkit.DefaultReferenceSystem = CartographicSupport.WORLD;
+		initializeValues();
+		// pending of a refactoring do not delete (swap commented lines)
+//		initializeComponents();
+	}
+	
+	// pending of a refactoring, following method would be removed
+	@Override
+	public void storeValues() throws StoreException {
+		// TODO Auto-generated method stub
+		
+	}
+
+	public boolean isValueChanged() {
+		return super.hasChanged();
+	}
+
+}
Index: tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/app/gui/preferencespage/SymbologyPage.java
===================================================================
--- tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/app/gui/preferencespage/SymbologyPage.java	(revision 0)
+++ tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/app/gui/preferencespage/SymbologyPage.java	(revision 38653)
@@ -0,0 +1,283 @@
+package org.gvsig.app.gui.preferencespage;
+
+import java.awt.Color;
+import java.awt.Dimension;
+import java.awt.FlowLayout;
+import java.awt.Font;
+import java.awt.GridBagLayout;
+import java.awt.event.ActionEvent;
+import java.awt.event.ActionListener;
+import java.io.File;
+
+import javax.swing.ImageIcon;
+import javax.swing.JButton;
+import javax.swing.JCheckBox;
+import javax.swing.JLabel;
+import javax.swing.JPanel;
+import javax.swing.JSlider;
+import javax.swing.JTextField;
+import javax.swing.border.TitledBorder;
+import javax.swing.event.ChangeEvent;
+import javax.swing.event.ChangeListener;
+import javax.swing.filechooser.FileFilter;
+
+import org.gvsig.andami.PluginServices;
+import org.gvsig.andami.preferences.AbstractPreferencePage;
+import org.gvsig.andami.preferences.StoreException;
+import org.gvsig.app.gui.panels.ColorChooserPanel;
+import org.gvsig.fmap.mapcontext.MapContextLocator;
+import org.gvsig.fmap.mapcontext.rendering.symbols.SymbolPreferences;
+import org.gvsig.gui.beans.swing.GridBagLayoutPanel;
+import org.gvsig.gui.beans.swing.JBlank;
+import org.gvsig.gui.beans.swing.JComboBoxFontSizes;
+import org.gvsig.gui.beans.swing.JComboBoxFonts;
+import org.gvsig.gui.beans.swing.JFileChooser;
+
+
+
+/**
+ * This class extends AbstractPreferencesPage. This component is a preferences page for
+ * symbology and allows select default fore color, fill color, font and size text and
+ * the path where the images that compound symbols are located.
+ *
+ */
+public class SymbologyPage extends AbstractPreferencePage {
+
+	private static final long serialVersionUID = 1L;
+	
+	private SymbolPreferences preferences = null;
+
+	private ColorChooserPanel defaultColor = null;
+	private ColorChooserPanel defaultFillColor = null;
+	private JSlider jsDefaultSelectionAlpha = null;
+	private JSlider jsFillSelelctionAlpha = null;
+	protected String id;
+	private boolean panelStarted = false;
+	private JButton btnSelectProjectsFolder=null;
+	private ActionListener btnFileChooserAction=null;
+	private JTextField txtProjectsFolder=null;
+	private JComboBoxFonts fonts= null;
+	private JComboBoxFontSizes sizes= null;
+	private ImageIcon icon=null;
+	private JCheckBox aleatoryFillColor;
+
+	public SymbologyPage(){
+		super();
+		id = this.getClass().getName();
+	}
+	
+	public SymbolPreferences getPreferences() {
+		if(preferences == null) 	
+			preferences = MapContextLocator.getSymbolManager().getSymbolPreferences();
+		return preferences;
+	}
+
+	@Override
+	public void setChangesApplied() {
+		setChanged(false);
+
+	}
+
+	public String getID() {
+		return id;
+	}
+
+	public ImageIcon getIcon() {
+		if (icon == null){
+			icon=PluginServices.getIconTheme().get("symbol-pref");
+		}
+		return icon;
+	}
+
+	public JPanel getPanel() {
+		if(panelStarted)return this;
+		panelStarted=true;
+		addComponent(new JLabel(" "));
+
+		GridBagLayoutPanel selectionDefaultColorPanel = new GridBagLayoutPanel();
+		selectionDefaultColorPanel.setBorder(new TitledBorder(PluginServices.getText(this, "default_color")));
+		selectionDefaultColorPanel.setLayout(new GridBagLayout());
+		selectionDefaultColorPanel.add(new JLabel(PluginServices.getText(this,"fill")));
+		selectionDefaultColorPanel.add(defaultColor = new ColorChooserPanel());
+
+		selectionDefaultColorPanel.add(new JLabel(PluginServices.getText(this,"alpha")));
+		selectionDefaultColorPanel.add(jsDefaultSelectionAlpha = new JSlider(0,255));
+		selectionDefaultColorPanel.add(new JBlank(50,50));
+
+		jsDefaultSelectionAlpha.setPreferredSize(new Dimension(100,30));
+		jsDefaultSelectionAlpha.addChangeListener(new ChangeListener(){
+			public void stateChanged(ChangeEvent e) {
+				defaultColor.setAlpha(((JSlider)e.getSource()).getValue());
+		}});
+		addComponent(new JLabel(" "));
+		addComponent(selectionDefaultColorPanel);
+
+		GridBagLayoutPanel selectionFillColor = new GridBagLayoutPanel();
+		selectionFillColor.setBorder(new TitledBorder(PluginServices.getText(this, "default_fill_color")));
+		selectionFillColor.setLayout(new GridBagLayout());
+		selectionFillColor.add(new JLabel(PluginServices.getText(this,"fill")));
+		selectionFillColor.add(defaultFillColor = new ColorChooserPanel());
+
+		selectionFillColor.add(new JLabel(PluginServices.getText(this,"alpha")));
+		selectionFillColor.add(jsFillSelelctionAlpha = new JSlider(0,255));
+
+		jsFillSelelctionAlpha.setPreferredSize(new Dimension(100,30));
+		jsFillSelelctionAlpha.addChangeListener(new ChangeListener(){
+			public void stateChanged(ChangeEvent e) {
+				defaultFillColor.setAlpha(((JSlider)e.getSource()).getValue());
+		}});
+
+		selectionFillColor.add(new JBlank(50,50));
+		selectionFillColor.add(aleatoryFillColor = new JCheckBox());
+		selectionFillColor.add(new JLabel("   " + PluginServices.getText(this,"aleatory")));
+
+
+		aleatoryFillColor.addActionListener(new ActionListener(){
+
+			public void actionPerformed(ActionEvent e) {
+				if(e.getSource() == aleatoryFillColor){
+					defaultFillColor.setEnabled(!aleatoryFillColor.isSelected());
+					jsFillSelelctionAlpha.setEnabled(!aleatoryFillColor.isSelected());
+				}
+			}
+
+		});
+
+		addComponent(new JLabel(" "));
+		addComponent(selectionFillColor);
+
+		btnFileChooserAction = new ActionListener() {
+			public void actionPerformed(ActionEvent e) {
+				String path;
+				if (e.getSource().equals(btnSelectProjectsFolder)) {
+					path = txtProjectsFolder.getText();
+
+
+				FileFilter def =  new FileFilter(){
+					public boolean accept(File f) {
+						return (f.isDirectory());
+					}
+
+					public String getDescription() {
+						return null;
+					}
+				};
+
+				File file = new File(path);
+				JFileChooser fc;
+				if (file.exists()) {
+					fc = new JFileChooser("SYMBOLOGY_PREFERENCE_PAGE_FILECHOOSER", file);
+				} else {
+					fc= new JFileChooser("SYMBOLOGY_PREFERENCE_PAGE_FILECHOOSER",JFileChooser.getLastPath("SYMBOLOGY_PREFERENCE_PAGE_FILECHOOSER", file));
+				}
+
+
+				fc.setFileSelectionMode(JFileChooser.DIRECTORIES_ONLY);
+                fc.setMultiSelectionEnabled(false);
+                fc.setAcceptAllFileFilterUsed(false);
+                fc.addChoosableFileFilter(def);
+                int result = fc.showOpenDialog(SymbologyPage.this);
+
+                if (result == JFileChooser.APPROVE_OPTION && (file = fc.getSelectedFile()) != null)
+                	if (e.getSource().equals(btnSelectProjectsFolder))
+    					txtProjectsFolder.setText(file.getAbsolutePath());
+                }
+			}
+
+		};
+		btnSelectProjectsFolder = new JButton(PluginServices.getText(this, "browse"));
+		btnSelectProjectsFolder.addActionListener(btnFileChooserAction);
+
+		JPanel panelBrowser = new JPanel();
+		panelBrowser.setBorder(new TitledBorder(PluginServices.getText(this, "folder_images")));
+
+		panelBrowser.add(txtProjectsFolder = new JTextField(30));
+		panelBrowser.add(btnSelectProjectsFolder);
+
+		addComponent(panelBrowser);
+
+		fonts= new JComboBoxFonts();
+		sizes = new JComboBoxFontSizes();
+
+		JPanel panelFont = new JPanel(new FlowLayout());
+		panelFont.setBorder(new TitledBorder(PluginServices.getText(this, "default_font")));
+		panelFont.add(fonts);
+		panelFont.add(sizes);
+
+		addComponent(panelFont);
+		initializeValues();
+		return this;
+	}
+
+	public String getTitle() {
+		return PluginServices.getText(this, "symbology");
+	}
+	
+	public void initializeValues() {
+		if (!panelStarted) 
+			getPanel();
+
+		defaultColor.setColor(getPreferences().getDefaultSymbolColor());
+		defaultColor.setAlpha(getPreferences().getDefaultSymbolColor().getAlpha());
+		jsDefaultSelectionAlpha.setValue(getPreferences().getDefaultSymbolColor().getAlpha());
+		
+		aleatoryFillColor.setSelected(getPreferences().isDefaultSymbolFillColorAleatory());
+
+		defaultFillColor.setColor(getPreferences().getDefaultSymbolFillColor());
+		defaultFillColor.setAlpha(getPreferences().getDefaultSymbolFillColor().getAlpha());
+		jsFillSelelctionAlpha.setValue(getPreferences().getDefaultSymbolFillColor().getAlpha());
+		
+		txtProjectsFolder.setText(getPreferences().getSymbolLibraryPath());
+
+		fonts.setSelectedItem(getPreferences().getDefaultSymbolFont().getFamily());
+		sizes.setSelectedItem(getPreferences().getDefaultSymbolFont().getSize());
+		
+		defaultFillColor.setEnabled(!aleatoryFillColor.isSelected());
+		jsFillSelelctionAlpha.setEnabled(!aleatoryFillColor.isSelected());
+
+	}
+
+	public void initializeDefaults() {
+		
+	}
+	
+	public boolean isValueChanged() {
+		return super.hasChanged();
+	}
+
+	@Override
+	public void storeValues() throws StoreException {
+		persistPreferences();
+	}
+
+	private void persistPreferences() {
+		if(defaultColor.getColor() != null) {
+			Color color = defaultColor.getColor();
+			color = new Color(color.getRed(), 
+					color.getGreen(), 
+					color.getBlue(), 
+					jsDefaultSelectionAlpha.getValue());
+			getPreferences().setDefaultSymbolColor(color);
+		}
+
+		if(aleatoryFillColor != null) {
+			getPreferences().setDefaultSymbolFillColorAleatory(aleatoryFillColor.isSelected());
+		}
+		
+		if (defaultFillColor.getColor()  !=  null) {
+			Color color = defaultFillColor.getColor();
+			color = new Color(color.getRed(),color.getGreen(),color.getBlue(),jsFillSelelctionAlpha.getValue());
+			getPreferences().setDefaultSymbolFillColor(color);
+		}
+
+		if (txtProjectsFolder.getText() != null) {
+			getPreferences().setSymbolLibraryPath(txtProjectsFolder.getText());
+		}
+
+		if(fonts.getFont() != null && sizes.getSelectedItem() != null){
+			String f = (String)fonts.getSelectedItem();
+			Font font = new Font(f, Font.PLAIN, (Integer)sizes.getSelectedItem());
+			getPreferences().setDefaultSymbolFont(font);
+		}
+	}
+}
Index: tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/app/gui/preferencespage/GridPage.java
===================================================================
--- tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/app/gui/preferencespage/GridPage.java	(revision 0)
+++ tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/app/gui/preferencespage/GridPage.java	(revision 38653)
@@ -0,0 +1,259 @@
+/* gvSIG. Sistema de Informaci�n Geogr�fica de la Generalitat Valenciana
+ *
+ * Copyright (C) 2005 IVER T.I. and Generalitat Valenciana.
+ *
+ * This program is free software; you can redistribute it and/or
+ * modify it under the terms of the GNU General Public License
+ * as published by the Free Software Foundation; either version 2
+ * of the License, or (at your option) any later version.
+ *
+ * This program is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
+ * GNU General Public License for more details.
+ *
+ * You should have received a copy of the GNU General Public License
+ * along with this program; if not, write to the Free Software
+ * Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA  02111-1307,USA.
+ *
+ * For more information, contact:
+ *
+ *  Generalitat Valenciana
+ *   Conselleria d'Infraestructures i Transport
+ *   Av. Blasco Ib��ez, 50
+ *   46010 VALENCIA
+ *   SPAIN
+ *
+ *      +34 963862235
+ *   gvsig@gva.es
+ *      www.gvsig.gva.es
+ *
+ *    or
+ *
+ *   IVER T.I. S.A
+ *   Salamanca 50
+ *   46005 Valencia
+ *   Spain
+ *
+ *   +34 963163400
+ *   dac@iver.es
+ */
+
+/* CVS MESSAGES:
+*
+* $Id: GridPage.java 21668 2008-06-19 09:05:14Z vcaballero $
+* $Log$
+* Revision 1.4  2006-08-22 12:27:53  jaume
+* improved performances when saving
+*
+* Revision 1.3  2006/08/22 07:37:32  jaume
+* *** empty log message ***
+*
+* Revision 1.2  2006/08/10 11:13:02  caballero
+* mostrar unidades
+*
+* Revision 1.1  2006/08/10 08:18:35  caballero
+* configurar grid
+*
+* Revision 1.1  2006/08/04 11:41:05  caballero
+* poder especificar el zoom a aplicar en las vistas
+*
+* Revision 1.3  2006/07/31 10:02:31  jaume
+* *** empty log message ***
+*
+* Revision 1.2  2006/06/13 07:43:08  fjp
+* Ajustes sobre los cuadros de dialogos de preferencias
+*
+* Revision 1.1  2006/06/12 16:04:28  caballero
+* Preferencias
+*
+* Revision 1.11  2006/06/06 10:26:31  jaume
+* *** empty log message ***
+*
+* Revision 1.10  2006/06/05 17:07:17  jaume
+* *** empty log message ***
+*
+* Revision 1.9  2006/06/05 17:00:44  jaume
+* *** empty log message ***
+*
+* Revision 1.8  2006/06/05 16:57:59  jaume
+* *** empty log message ***
+*
+* Revision 1.7  2006/06/05 14:45:06  jaume
+* *** empty log message ***
+*
+* Revision 1.6  2006/06/05 11:00:09  jaume
+* *** empty log message ***
+*
+* Revision 1.5  2006/06/05 10:39:02  jaume
+* *** empty log message ***
+*
+* Revision 1.4  2006/06/05 10:13:40  jaume
+* *** empty log message ***
+*
+* Revision 1.3  2006/06/05 10:06:08  jaume
+* *** empty log message ***
+*
+* Revision 1.2  2006/06/05 09:51:56  jaume
+* *** empty log message ***
+*
+* Revision 1.1  2006/06/02 10:50:18  jaume
+* *** empty log message ***
+*
+*
+*/
+package org.gvsig.app.gui.preferencespage;
+
+import java.util.prefs.Preferences;
+
+import javax.swing.ImageIcon;
+import javax.swing.JCheckBox;
+import javax.swing.JLabel;
+import javax.swing.JPanel;
+import javax.swing.JTextField;
+
+import org.gvsig.andami.PluginServices;
+import org.gvsig.andami.preferences.AbstractPreferencePage;
+import org.gvsig.andami.preferences.StoreException;
+import org.gvsig.andami.ui.mdiManager.IWindow;
+import org.gvsig.app.project.documents.view.gui.DefaultViewPanel;
+import org.gvsig.fmap.mapcontrol.MapControl;
+import org.gvsig.fmap.mapcontrol.tools.grid.Grid;
+
+
+public class GridPage extends AbstractPreferencePage {
+	public static Preferences prefs = Preferences.userRoot().node( "cadtooladapter" );
+	private org.gvsig.fmap.mapcontrol.MapControl mapControl;
+	private JCheckBox chkShowGrid;
+	private JCheckBox chkAdjustGrid;
+	private JTextField txtDistanceX;
+	private JTextField txtDistanceY;
+	private JLabel lblUnits=new JLabel();
+	private ImageIcon icon;
+
+	public GridPage() {
+		super();
+		icon = PluginServices.getIconTheme().get("grid-icon");
+		chkShowGrid=new JCheckBox(PluginServices.getText(this,"mostrar_rejilla"));
+		addComponent(chkShowGrid);
+		chkAdjustGrid=new JCheckBox(PluginServices.getText(this,"ajustar_rejilla"));
+		addComponent(chkAdjustGrid);
+		addComponent(lblUnits);
+
+		// distance x
+		addComponent(PluginServices.getText(this, "distance_x") + ":",
+			txtDistanceX = new JTextField("", 15));
+		// distance y
+		addComponent(PluginServices.getText(this, "distance_y") + ":",
+			txtDistanceY = new JTextField("", 15));
+		setParentID(ViewPage.id);
+
+	}
+
+	public void initializeValues() {
+		boolean showGrid = prefs.getBoolean("grid.showgrid",Grid.DefaultShowGrid);
+		boolean adjustGrid = prefs.getBoolean("grid.adjustgrid",Grid.DefaultAdjustGrid);
+
+		double dx = prefs.getDouble("grid.distancex",Grid.DefaultGridSizeX);
+		double dy = prefs.getDouble("grid.distancey",Grid.DefaultGridSizeY);
+
+		Grid.SHOWGRID=showGrid;
+		Grid.ADJUSTGRID=adjustGrid;
+		Grid.GRIDSIZEX=dx;
+		Grid.GRIDSIZEY=dy;
+
+//		setGridVisibility(showGrid);
+//		setAdjustGrid(adjustGrid);
+//		cadgrid.setGridSizeX(dx);
+//		cadgrid.setGridSizeY(dy);
+//		cta=CADExtension.getCADToolAdapter();
+//		cta.initializeGrid();
+//		ViewPort vp=cta.getMapControl().getViewPort();
+//		boolean showGrid = prefs.getBoolean("grid.showgrid",cta.getGrid().isShowGrid());
+//		boolean adjustGrid = prefs.getBoolean("grid.adjustgrid",cta.getGrid().isAdjustGrid());
+//
+//		double dx = prefs.getDouble("grid.distancex",cta.getGrid().getGridSizeX());
+//		double dy = prefs.getDouble("grid.distancey",cta.getGrid().getGridSizeY());
+//		CADGrid cg=cta.getGrid();
+		chkShowGrid.setSelected(showGrid);
+		chkAdjustGrid.setSelected(adjustGrid);
+		txtDistanceX.setText(String.valueOf(dx));
+		txtDistanceY.setText(String.valueOf(dy));
+//		lblUnits.setText(PluginServices.getText(this,"Unidades")+ "           "+PluginServices.getText(this,MapContext.getDistanceNames()[vp.getDistanceUnits()]));
+
+//		cta.setGridVisibility(showGrid);
+//		cta.setAdjustGrid(adjustGrid);
+//		cta.getGrid().setGridSizeX(dx);
+//		cta.getGrid().setGridSizeY(dy);
+
+	}
+
+	public String getID() {
+		return this.getClass().getName();
+	}
+
+	public String getTitle() {
+		return PluginServices.getText(this, "Grid");
+	}
+
+	public JPanel getPanel() {
+		return this;
+	}
+
+	public void storeValues() throws StoreException {
+		boolean showGrid;
+		boolean adjustGrid;
+		double dx;
+		double dy;
+
+			showGrid=chkShowGrid.isSelected();
+			adjustGrid=chkAdjustGrid.isSelected();
+		try{
+			dx=Double.parseDouble(txtDistanceX.getText());
+			dy=Double.parseDouble(txtDistanceY.getText());
+		}catch (Exception e) {
+			throw new StoreException(PluginServices.getText(this,"distancia_malla_incorrecta"));
+		}
+		prefs.putBoolean("grid.showgrid",showGrid);
+		prefs.putBoolean("grid.adjustgrid",adjustGrid);
+		prefs.putDouble("grid.distancex", dx);
+		prefs.putDouble("grid.distancey", dy);
+
+		Grid.SHOWGRID=showGrid;
+		Grid.ADJUSTGRID=adjustGrid;
+		Grid.GRIDSIZEX=dx;
+		Grid.GRIDSIZEY=dy;
+
+		IWindow window=PluginServices.getMDIManager().getActiveWindow();
+		if (window instanceof DefaultViewPanel){
+			MapControl mc=((DefaultViewPanel)window).getMapControl();
+			Grid cadGrid=mc.getGrid();
+			cadGrid.setShowGrid(showGrid);
+			cadGrid.setAdjustGrid(adjustGrid);
+			cadGrid.setGridSizeX(dx);
+			cadGrid.setGridSizeY(dy);
+		}
+
+	}
+
+	public void initializeDefaults() {
+		chkShowGrid.setSelected(Grid.DefaultShowGrid);
+		chkAdjustGrid.setSelected(Grid.DefaultAdjustGrid);
+//		ViewPort vp=cta.getMapControl().getViewPort();
+//		lblUnits.setText(PluginServices.getText(this,"Unidades")+ "           "+PluginServices.getText(this,MapContext.getDistanceNames()[vp.getDistanceUnits()]));
+		txtDistanceX.setText(String.valueOf(Grid.DefaultGridSizeX));
+		txtDistanceY.setText(String.valueOf(Grid.DefaultGridSizeY));
+	}
+
+	public ImageIcon getIcon() {
+		return icon;
+	}
+
+	public boolean isValueChanged() {
+		return super.hasChanged();
+	}
+
+	public void setChangesApplied() {
+		setChanged(false);
+	}
+}
Index: tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/app/gui/preferencespage/DriverCSVPage.java
===================================================================
--- tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/app/gui/preferencespage/DriverCSVPage.java	(revision 0)
+++ tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/app/gui/preferencespage/DriverCSVPage.java	(revision 38653)
@@ -0,0 +1,133 @@
+/* gvSIG. Sistema de Informaci�n Geogr�fica de la Generalitat Valenciana
+ *
+ * Copyright (C) 2005 IVER T.I. and Generalitat Valenciana.
+ *
+ * This program is free software; you can redistribute it and/or
+ * modify it under the terms of the GNU General Public License
+ * as published by the Free Software Foundation; either version 2
+ * of the License, or (at your option) any later version.
+ *
+ * This program is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
+ * GNU General Public License for more details.
+ *
+ * You should have received a copy of the GNU General Public License
+ * along with this program; if not, write to the Free Software
+ * Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA  02111-1307,USA.
+ *
+ * For more information, contact:
+ *
+ *  Generalitat Valenciana
+ *   Conselleria d'Infraestructures i Transport
+ *   Av. Blasco Ib��ez, 50
+ *   46010 VALENCIA
+ *   SPAIN
+ *
+ *      +34 963862235
+ *   gvsig@gva.es
+ *      www.gvsig.gva.es
+ *
+ *    or
+ *
+ *   IVER T.I. S.A
+ *   Salamanca 50
+ *   46005 Valencia
+ *   Spain
+ *
+ *   +34 963163400
+ *   dac@iver.es
+ */
+
+package org.gvsig.app.gui.preferencespage;
+
+import javax.swing.ImageIcon;
+import javax.swing.JPanel;
+import javax.swing.JTextField;
+
+import org.gvsig.andami.PluginServices;
+import org.gvsig.andami.preferences.AbstractPreferencePage;
+import org.gvsig.andami.preferences.StoreException;
+import org.gvsig.utils.XMLEntity;
+
+/**
+ * CSV Driver preference page where the user can establish default values for
+ * <ol>
+ *  <li><b>separator</b></li>
+ * </ol>
+ * @author Vicente Caballero Navarro
+ *
+ */
+//TODO comentado para que compile
+public class DriverCSVPage extends AbstractPreferencePage{
+	private static final String DEFAULT_SEPARATOR_CSV_DRIVER = "DefaultSeparatorCSVDriver";
+	static String id = DriverCSVPage.class.getName();;
+	private ImageIcon icon;
+	private JTextField txtSeparator;
+
+	/**
+	 * Builds preference page where the user can establish default values for
+	 * <ol>
+	 *  <li><b>separator</b></li>
+	 * </ol>
+	 */
+	public DriverCSVPage() {
+		super();
+		icon=PluginServices.getIconTheme().get("mapa-icono");
+		addComponent(PluginServices.getText(this, "separador"), txtSeparator = new JTextField(5));
+		setParentID(DriversPages.class.getName());
+	}
+
+	public void storeValues() throws StoreException {
+		String separator;
+		separator = txtSeparator.getText();
+//		DriverManager dm=LayerFactory.getDM();
+//		CSVStringDriver cvsDriver=null;
+//		try {
+//			cvsDriver = (CSVStringDriver)dm.getDriver("csv string");
+//		} catch (DriverLoadException e) {
+//			throw new StoreException();
+//		}
+//		cvsDriver.setSeparator(separator);
+		PluginServices ps = PluginServices.getPluginServices(this);
+		XMLEntity xml = ps.getPersistentXML();
+		xml.putProperty(DEFAULT_SEPARATOR_CSV_DRIVER, separator);
+	}
+
+	public String getID() {
+		return id;
+	}
+
+	public String getTitle() {
+		return PluginServices.getText(this, "CSVStringDriver");
+	}
+
+	public JPanel getPanel() {
+		return this;
+	}
+
+	public void initializeValues() {
+		PluginServices ps = PluginServices.getPluginServices(this);
+		XMLEntity xml = ps.getPersistentXML();
+		if (xml.contains(DEFAULT_SEPARATOR_CSV_DRIVER)) {
+			txtSeparator.setText(xml.getStringProperty(DEFAULT_SEPARATOR_CSV_DRIVER));
+		}
+
+	}
+
+	public void initializeDefaults() {
+		txtSeparator.setText(",");
+	}
+
+	public ImageIcon getIcon() {
+		return icon;
+	}
+
+	public boolean isValueChanged() {
+		return super.hasChanged();
+	}
+
+	public void setChangesApplied() {
+		setChanged(false);
+	}
+}

Property changes on: tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/app/gui/preferencespage/DriverCSVPage.java
___________________________________________________________________
Added: svn:eol-style
   + native
Added: svn:keywords
   + Author Date Id Revision

Index: tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/app/gui/WizardPanel.java
===================================================================
--- tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/app/gui/WizardPanel.java	(revision 0)
+++ tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/app/gui/WizardPanel.java	(revision 38653)
@@ -0,0 +1,178 @@
+/* gvSIG. Geographic Information System of the Valencian Government
+ *
+ * Copyright (C) 2007-2008 Infrastructures and Transports Department
+ * of the Valencian Government (CIT)
+ *
+ * This program is free software; you can redistribute it and/or
+ * modify it under the terms of the GNU General Public License
+ * as published by the Free Software Foundation; either version 2
+ * of the License, or (at your option) any later version.
+ *
+ * This program is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
+ * GNU General Public License for more details.
+ *
+ * You should have received a copy of the GNU General Public License
+ * along with this program; if not, write to the Free Software
+ * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston,
+ * MA  02110-1301, USA.
+ *
+ */
+package org.gvsig.app.gui;
+
+import java.awt.Window;
+
+import javax.swing.JPanel;
+
+import org.cresques.cts.IProjection;
+import org.gvsig.andami.messages.NotificationManager;
+import org.gvsig.app.ApplicationLocator;
+import org.gvsig.app.ApplicationManager;
+import org.gvsig.app.gui.wizards.WizardListener;
+import org.gvsig.app.gui.wizards.WizardListenerSupport;
+import org.gvsig.app.prepareAction.PrepareContextView;
+import org.gvsig.fmap.dal.DataStoreParameters;
+import org.gvsig.fmap.mapcontext.MapContext;
+import org.gvsig.fmap.mapcontext.MapContextLocator;
+import org.gvsig.fmap.mapcontext.MapContextManager;
+import org.gvsig.fmap.mapcontext.layers.FLayer;
+import org.gvsig.fmap.mapcontrol.MapControl;
+import org.slf4j.Logger;
+import org.slf4j.LoggerFactory;
+
+public abstract class WizardPanel extends JPanel {
+
+	private static final Logger logger = LoggerFactory.getLogger(WizardPanel.class);
+    private static final long serialVersionUID = 5317749209668850863L;
+    private String tabName = "TabName";
+    private MapControl mapCtrl = null;
+    private WizardListenerSupport listenerSupport = new WizardListenerSupport();
+
+    public void addWizardListener(WizardListener listener) {
+        listenerSupport.addWizardListener(listener);
+    }
+
+    public void callError(Exception descripcion) {
+        listenerSupport.callError(descripcion);
+    }
+
+    public void removeWizardListener(WizardListener listener) {
+        listenerSupport.removeWizardListener(listener);
+    }
+
+    public void callStateChanged(boolean finishable) {
+        listenerSupport.callStateChanged(finishable);
+    }
+
+    protected void setTabName(String name) {
+        tabName = name;
+    }
+
+    public String getTabName() {
+        return tabName;
+    }
+
+    abstract public void initWizard();
+
+    /**
+     * @deprecated use {@link #executeWizard()} instead.
+     */
+    abstract public void execute();
+
+    /**
+     * Executes the wizard and returns anything created in the process.
+     * 
+     * @return anything created in the process
+     */
+    public Object executeWizard() {
+        execute();
+        return null;
+    }
+
+    abstract public void close();
+
+    abstract public DataStoreParameters[] getParameters();
+
+    /**
+     * You can use it to extract information from
+     * the mapControl that will receive the new layer.
+     * For example, projection to use, or visible extent.
+     * 
+     * @return Returns the mapCtrl.
+     */
+    public MapControl getMapCtrl() {
+        return mapCtrl;
+    }
+
+    /**
+     * @param mapCtrl
+     *            The mapCtrl to set.
+     */
+    public void setMapCtrl(MapControl mapCtrl) {
+        this.mapCtrl = mapCtrl;
+    }
+
+    protected void doAddLayer(final MapControl mapControl,
+        final String layerName, final DataStoreParameters parameters) {
+        final ApplicationManager application = ApplicationLocator.getManager();
+        final MapContextManager manager =
+            MapContextLocator.getMapContextManager();
+        final MapContext mapContext = mapControl.getMapContext();
+
+        logger.info("addLayer('{}','{}')", layerName, parameters.toString());
+        Thread task = new Thread(new Runnable() {
+
+            public void run() {
+                FLayer layer = null;
+                FLayer preparedLayer = null;
+                try {
+                    layer = manager.createLayer(layerName, parameters);
+                    preparedLayer =
+                        application.prepareOpenLayer(layer,
+                            new PrepareContextView() {
+
+                                public Window getOwnerWindow() {
+                                    return null;
+                                }
+
+                                public MapControl getMapControl() {
+                                    return mapControl;
+                                }
+
+								public IProjection getViewProjection() {
+									return mapControl.getProjection();
+								}
+                            });
+                    if (preparedLayer != null) {
+                        mapContext.getLayers().addLayer(preparedLayer);
+                    }
+                } catch (Exception e) {
+                    NotificationManager.addError(e);
+                    return;
+                } finally {
+                    if (preparedLayer != null && preparedLayer != layer) {
+                        preparedLayer.dispose();
+                        preparedLayer = null;
+                    }
+                    if (layer != null) {
+                        layer.dispose();
+                        layer = null;
+                    }
+                }
+            }
+        });
+        task.start();
+    }
+    
+    /**
+     * This method is called for example when user changes
+     * tab in add layer dialog (new tab's settings are valid?)
+     * 
+     * @return whether current wizard settings are enough
+     * (for example, to enable an Accept button in a container)
+     */
+    public boolean areSettingsValid() {
+        return true;
+    }
+}

Property changes on: tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/app/gui/WizardPanel.java
___________________________________________________________________
Added: svn:keywords
   + Author Date Id Revision
Added: svn:eol-style
   + native

Index: tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/app/gui/utils/FontChooser.java
===================================================================
--- tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/app/gui/utils/FontChooser.java	(revision 0)
+++ tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/app/gui/utils/FontChooser.java	(revision 38653)
@@ -0,0 +1,40 @@
+
+package org.gvsig.app.gui.utils;
+
+import java.awt.Component;
+import java.awt.Dialog;
+import java.awt.Dimension;
+import java.awt.Font;
+import java.awt.Toolkit;
+
+import org.jfree.ui.FontChooserDialog;
+
+
+
+public class FontChooser {
+    public static Font showDialog(String title, Font font) {
+    	
+    	FontChooserDialog dlg = new FontChooserDialog(
+    	    (Dialog)null,title, true,font);
+    	
+    	dlg.pack();
+    	centerComponent(dlg);
+    	
+    	dlg.setVisible(true);
+    	if( dlg.isCancelled() ) {
+    		return null;
+    	}
+    	return dlg.getSelectedFont();
+    }
+    
+    public static void centerComponent(Component comp) {
+        
+        Dimension scr_dim = Toolkit.getDefaultToolkit().getScreenSize();
+        Dimension comp_dim = comp.getSize();
+        
+        comp.setLocation(
+            (scr_dim.width - comp_dim.width) / 2,
+            (scr_dim.height - comp_dim.height) / 2
+            );
+    }
+}

Property changes on: tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/app/gui/utils/FontChooser.java
___________________________________________________________________
Added: svn:keywords
   + Author Date Id Revision
Added: svn:eol-style
   + native

Index: tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/app/gui/utils/ColorScheme.txt
===================================================================
--- tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/app/gui/utils/ColorScheme.txt	(revision 0)
+++ tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/app/gui/utils/ColorScheme.txt	(revision 38653)
@@ -0,0 +1,53 @@
+BuGn (ColorBrewer),range,f7fcfd,e5f5f9,ccece6,99d8c9,66c2a4,41ae76,238b45,006d2c,00441b
+BuPu (ColorBrewer),range,f7fcfd,e0ecf4,bfd3e6,9ebcda,8c96c6,8c6bb1,88419d,810f7c,4d004b
+GnBu (ColorBrewer),range,f7fcf0,e0f3db,ccebc5,a8ddb5,7bccc4,4eb3d3,2b8cbe,0868ac,084081
+OrRd (ColorBrewer),range,fff7ec,fee8c8,fdd49e,fdbb84,fc8d59,ef6548,d7301f,b30000,7f0000
+PuBu (ColorBrewer),range,fff7fb,ece7f2,d0d1e6,a6bddb,74a9cf,3690c0,0570b0,045a8d,023858
+PuBuGn (ColorBrewer),range,fff7fb,ece2f0,d0d1e6,a6bddb,67a9cf,3690c0,02818a,016c59,014636
+PuRd (ColorBrewer),range,f7f4f9,e7e1ef,d4b9da,c994c7,df65b0,e7298a,ce1256,980043,67001f
+RdPu (ColorBrewer),range,fff7f3,fde0dd,fcc5c0,fa9fb5,f768a1,dd3497,b0017e,7a0177,49006a
+YlGn (ColorBrewer),range,ffffe5,f7fcb9,d9f0a3,addd8e,78c679,41ab5d,238443,006837,004529
+YlGnBu (ColorBrewer),range,ffffd9,edf8b0,c7e9b4,7fcdbb,41b6c3,1d91c0,225ea8,253494,081d58
+YlOrBr (ColorBrewer),range,ffffe5,fff7bc,fee391,fec44f,fe9929,ec7014,cc4c02,993404,662506
+YlOrRd (ColorBrewer),range,ffffcc,ffeda0,fed976,feb24c,fd8d3c,fc4e2a,e31a1a,bd0026,b00026
+Blues (ColorBrewer),range,f7fbff,deebf7,c6dbef,9ecae1,6baed6,4292c6,2171b5,08519c,08306b
+Greens (ColorBrewer),range,f7fcf5,e5f5e0,c7e9c0,a1d99b,74c476,41ab5d,238b45,006d2c,00441b
+Greys (ColorBrewer),range,ffffff,f0f0f0,d9d9d9,bdbdbd,969696,737373,525252,252525,000000
+Oranges (ColorBrewer),range,fff5eb,fee6ce,fdd0a2,fdae6b,fd8d3c,f16913,d94801,a63603,7f2704
+Purples (ColorBrewer),range,fcfbfd,efedf5,dadaeb,bbbddc,9e9ac8,807dba,6a51a3,54278f,3f007d
+Reds (ColorBrewer),range,fff5f0,fee0d2,fcbba1,fc9272,fb6a4a,ef3b2c,cb181d,a50f15,67000d
+BrBG (ColorBrewer),range,543005,8c510a,bf812d,dfc27d,f6e8c3,f5f5f5,c7eae5,80cdc1,35978f,01665e,003c30
+PRGn (ColorBrewer),range,40004b,762a83,9970ab,c2a5cf,e7d4e8,f7f7f7,d9f0d3,a8d8b7,5aae61,1b7837,00441b
+PiYG (ColorBrewer),range,8e0152,c51b7d,de77ae,f1b6da,fde0ef,f7f7f7,e6f5d0,b8e186,7fbc41,4d9221,276419
+PuOr (ColorBrewer),range,7f3b08,b35806,e08214,fdb863,fee0b6,f7f7f7,d8daeb,b2abd2,8073ac,542788,2d004b
+RYB (ColorBrewer),range,a50026,d73027,f46d43,fdae61,fee090,ffffbf,e0f3f8,abd9e9,74add1,4575b4,313695
+RYG (ColorBrewer),range,a50026,d73027,f46d43,fdae61,fee08b,ffffbf,d9ef8b,a6d96a,66bd63,1a9850,006837
+RdBu (ColorBrewer),range,67001f,b2182b,d6604d,f4a582,fddbc7,f7f7f7,d1e5f0,92c5de,4393c3,2166ac,053061
+RdGy (ColorBrewer),range,67001f,b2182b,d6604d,f4a582,fddbc7,ffffff,e0e0e0,bababa,878787,4d4d4d,1a1a1a
+spectral (ColorBrewer),range,9e0142,d53e4f,f46d43,fdae61,fee08b,ffffbf,e6f598,abdda4,66c2a5,3288bd,5e4fa2
+Accents (ColorBrewer),discrete,7fc97f,beaed4,fdc086,ffff99,386cb0,f0027f,bf5b17,666666
+Dark 2 (ColorBrewer),discrete,1b9e77,d95f02,7570b3,e7298a,66a61e,e6ab02,a6761d,666666
+Paired (ColorBrewer),discrete,a6cee3,1f77b4,b2df8a,33a02c,fb9a99,e31a1c,fdbf6f,ff7f00,cab2d6,6a3d9a,ffff99
+Pastel 1 (ColorBrewer),discrete,fbb3ad,b2cce2,ccebc5,decbe4,fed9a5,ffffcc,e4d7bc,fddaec,f2f2f2
+Pastel 2 (ColorBrewer),discrete,b3e2cd,fdcdac,cbd5e8,f4cae4,e6f5c9,fff2ae,f1e2cc,cccccc
+Set 1 (ColorBrewer),discrete,e31a1c,377db8,4daf4a,984ea3,ff7f00,ffff33,a65628,f781bf,999999
+Set 2 (ColorBrewer),discrete,66c2a5,fc8d62,8da0cb,e78ac3,a6d854,ffd92f,e5c494,b3b3b3
+Set 3 (ColorBrewer),discrete,8dd3c7,ffffbc,bebada,fb8072,80b1d3,fdb462,b3de69,fccde5,d9d9d9,bc80bd,ccebc5,ffed6f
+Autumn Evening (Visual Mining Inc.),discrete,993300,6B5E4F,934266,629191,93928F,485EB4,B5A689
+Azalea Garden (Visual Mining Inc.),discrete,755CB7,BABA66,255CC9,375437,007DA3,A10346,758C27
+Cool and Crisp (Visual Mining Inc.),discrete,005699,99CCCC,008B87,C2C4C6,68AEE0,00B09B,9691C7
+Crackling Rosy (Visual Mining Inc.),discrete,99007E,BE99CC,9600A7,C6C2C5,E068CE,6C00B0,C7919A
+Earthy (Visual Mining Inc.),discrete,999966,213321,C3C3E6,333366,DACE98,AA0036,291441
+Expanded Earth Tones (Visual Mining Inc.),discrete,284B53,005699,B8BC9C,271651,AA0036,ECF0B9,999966,333366,C3C3E6,594330,A0BDC4,005699,999966,213321,DACE98
+Festival (Visual Mining Inc.),discrete,CC33CC,FFFF66,62449B,FF9933,999933,FFFFCC,B31646
+Garden Party (Visual Mining Inc.),discrete,FFCC33,33FFCC,9999FF,FF6600,00008B,CC9900,8B0000
+Gold Amber (Visual Mining Inc.),discrete,998300,CCAE99,A76100,C6C6C2,E0CB68,B03400,ABC791
+Lilies and Chrysanthemums (Visual Mining Inc.),discrete,D6B8D9,7D0440,CCD29C,CD672F,8F7DA0,E9E497,A9A67E,D8D7F1,5C776B,5C1F4D
+Moon Lake (Visual Mining Inc.),discrete,E3D782,C7555A,7D1242,51779C,82CBD9,1A2A67,BCCCC1
+Post-Modern (Visual Mining Inc.),discrete,ECEFB8,576728,FFEFCF,386AB3,E2EBF0,C77640,E9ECD9,284B53
+Rose and Jade (Visual Mining Inc.),discrete,D6B8D9,C7D38E,93785F,CBAC9F,EB769A,A74F78
+Soft and Warm (Visual Mining Inc.),discrete,FFF4D6,D7BAD6,A1BBEE,C0C1A1,F0CBAE,958F91,BFA9AC,DBCE99,C8C8C8
+Sophisticated Shades (Visual Mining Inc.),discrete,6C5D94,999966,315394,213321,00566F,690931,515F23
+Summer Smoothie (Visual Mining Inc.),discrete,EBF0F3,5E8109,F7BB83,B55290,1A4C8F,00AB9C,758EC5
+Super-Chill (Visual Mining Inc.),discrete,01559B,68FCFF,008AA7,BAC2CF,49B3FF,00B09B,6A59FF
+Swimming Pool (Visual Mining Inc.),discrete,AC0000,E76C42,99CC99,CC3300,C6FCFB,64BCB7,2F3293,FF6666,339276
\ No newline at end of file

Property changes on: tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/app/gui/utils/ColorScheme.txt
___________________________________________________________________
Added: svn:eol-style
   + native
Added: svn:keywords
   + Author Date Id Revision

Index: tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/app/gui/utils/ColorRenderer.java
===================================================================
--- tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/app/gui/utils/ColorRenderer.java	(revision 0)
+++ tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/app/gui/utils/ColorRenderer.java	(revision 38653)
@@ -0,0 +1,123 @@
+/*
+ * Created on 15-mar-2004
+ *
+ * To change the template for this generated file go to
+ * Window&gt;Preferences&gt;Java&gt;Code Generation&gt;Code and Comments
+ */
+/* gvSIG. Sistema de Informaci�n Geogr�fica de la Generalitat Valenciana
+ *
+ * Copyright (C) 2004 IVER T.I. and Generalitat Valenciana.
+ *
+ * This program is free software; you can redistribute it and/or
+ * modify it under the terms of the GNU General Public License
+ * as published by the Free Software Foundation; either version 2
+ * of the License, or (at your option) any later version.
+ *
+ * This program is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
+ * GNU General Public License for more details.
+ *
+ * You should have received a copy of the GNU General Public License
+ * along with this program; if not, write to the Free Software
+ * Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA  02111-1307,USA.
+ *
+ * For more information, contact:
+ *
+ *  Generalitat Valenciana
+ *   Conselleria d'Infraestructures i Transport
+ *   Av. Blasco Ib��ez, 50
+ *   46010 VALENCIA
+ *   SPAIN
+ *
+ *      +34 963862235
+ *   gvsig@gva.es
+ *      www.gvsig.gva.es
+ *
+ *    or
+ *
+ *   IVER T.I. S.A
+ *   Salamanca 50
+ *   46005 Valencia
+ *   Spain
+ *
+ *   +34 963163400
+ *   dac@iver.es
+ */
+package org.gvsig.app.gui.utils;
+
+import java.awt.Color;
+import java.awt.Component;
+
+import javax.swing.BorderFactory;
+import javax.swing.JLabel;
+import javax.swing.JTable;
+import javax.swing.border.Border;
+import javax.swing.table.TableCellRenderer;
+
+
+/**
+ * DOCUMENT ME!
+ *
+ * @author vcn
+ */
+public class ColorRenderer extends JLabel implements TableCellRenderer {
+    Border unselectedBorder = null;
+    Border selectedBorder = null;
+    boolean isBordered = true;
+
+    /**
+     * Creates a new ColorRenderer object.
+     *
+     * @param isBordered DOCUMENT ME!
+     */
+    public ColorRenderer(boolean isBordered) {
+        this.isBordered = isBordered;
+        setOpaque(true); //MUST do this for background to show up.
+    }
+
+    /**
+     * DOCUMENT ME!
+     *
+     * @param table DOCUMENT ME!
+     * @param color DOCUMENT ME!
+     * @param isSelected DOCUMENT ME!
+     * @param hasFocus DOCUMENT ME!
+     * @param row DOCUMENT ME!
+     * @param column DOCUMENT ME!
+     *
+     * @return DOCUMENT ME!
+     */
+    public Component getTableCellRendererComponent(JTable table, Object color,
+        boolean isSelected, boolean hasFocus, int row, int column) {
+        Color newColor = (Color) color;
+        setBackground(newColor);
+
+        //JLabel boton=new JLabel("si");
+        //boton.setBackground(new Color(10,10,100));
+        //add(boton);
+        //System.out.println("dentro de Color Renderer");
+        if (isBordered) {
+            if (isSelected) {
+                if (selectedBorder == null) {
+                    selectedBorder = BorderFactory.createMatteBorder(2, 5, 2,
+                            5, table.getSelectionBackground());
+                }
+
+                setBorder(selectedBorder);
+            } else {
+                if (unselectedBorder == null) {
+                    unselectedBorder = BorderFactory.createMatteBorder(2, 5, 2,
+                            5, table.getBackground());
+                }
+
+                setBorder(unselectedBorder);
+            }
+        }
+
+      /*  setToolTipText("RGB value: " + newColor.getRed() + ", " +
+            newColor.getGreen() + ", " + newColor.getBlue());
+*/
+        return this;
+    }
+}

Property changes on: tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/app/gui/utils/ColorRenderer.java
___________________________________________________________________
Added: svn:keywords
   + Author Date Id Revision
Added: svn:eol-style
   + native

Index: tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/app/addlayer/AddLayerDialog.java
===================================================================
--- tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/app/addlayer/AddLayerDialog.java	(revision 0)
+++ tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/app/addlayer/AddLayerDialog.java	(revision 38653)
@@ -0,0 +1,253 @@
+/* gvSIG. Sistema de Informaci�n Geogr�fica de la Generalitat Valenciana
+ *
+ * Copyright (C) 2004 IVER T.I. and Generalitat Valenciana.
+ *
+ * This program is free software; you can redistribute it and/or
+ * modify it under the terms of the GNU General Public License
+ * as published by the Free Software Foundation; either version 2
+ * of the License, or (at your option) any later version.
+ *
+ * This program is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
+ * GNU General Public License for more details.
+ *
+ * You should have received a copy of the GNU General Public License
+ * along with this program; if not, write to the Free Software
+ * Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA  02111-1307,USA.
+ */
+package org.gvsig.app.addlayer;
+
+import java.awt.BorderLayout;
+import java.awt.Component;
+import java.awt.Dimension;
+import java.awt.event.ActionEvent;
+import java.awt.event.ActionListener;
+
+import javax.swing.JDialog;
+import javax.swing.JPanel;
+import javax.swing.JTabbedPane;
+import javax.swing.event.ChangeEvent;
+import javax.swing.event.ChangeListener;
+
+import org.cresques.cts.IProjection;
+import org.gvsig.andami.PluginServices;
+import org.gvsig.andami.ui.mdiManager.WindowInfo;
+import org.gvsig.app.gui.WizardPanel;
+import org.gvsig.app.gui.wizards.WizardListener;
+import org.gvsig.app.project.DefaultProject;
+import org.gvsig.gui.beans.AcceptCancelPanel;
+import org.gvsig.tools.ToolsLocator;
+import org.gvsig.tools.dispose.Disposable;
+
+/**
+ * Frame del cuadro de dialogo que contendra los tabs de aperturas de ficheros
+ *
+ * @version 04/09/2007
+ * @author BorSanZa - Borja S�nchez Zamorano (borja.sanchez@iver.es)
+ */
+public class AddLayerDialog extends JPanel implements org.gvsig.andami.ui.mdiManager.IWindow , Disposable{
+	static private IProjection proj           = null;
+	private JTabbedPane        jTabbedPane    = null;
+	private AcceptCancelPanel  jPanel         = null;
+	private boolean            accepted       = false;
+	private String             title          = PluginServices.getText(this, "add_layer");
+	private WizardListener     wizardListener = new DialogWizardListener();
+
+	/**
+   * Creates a new FOpenDialog object.
+   * @param view Vista que vamos a refrescar
+   * @param mapControl MapControl que recibe la capa (te puede interesar
+   *          a�adirla al principal o al Overview.
+   */
+	public AddLayerDialog() {
+		initialize();
+	}
+
+	/**
+	 * Constructor con un nombre de Frame
+	 * @param title
+	 */
+	public AddLayerDialog(String title) {
+		this.title = title;
+		initialize();
+	}
+
+	/**
+   * This method initializes this
+   */
+	private void initialize() {
+		ToolsLocator.getDisposableManager().bind(this);
+		
+		this.setLayout(new BorderLayout());
+		this.setSize(523, 385);
+		this.setPreferredSize(new Dimension(523, 385));
+		this.add(getJTabbedPane(), BorderLayout.CENTER);
+		this.add(getJPanel(), BorderLayout.SOUTH);
+	}
+
+	/**
+   * This method initializes jTabbedPane
+   * @return javax.swing.JTabbedPane
+   */
+	private JTabbedPane getJTabbedPane() {
+		if (jTabbedPane == null) {
+			jTabbedPane = new JTabbedPane();
+			jTabbedPane.setBounds(0, 0, getWindowInfo().getWidth() - 10, getWindowInfo().getHeight() - 10);
+			jTabbedPane.addChangeListener(new ChangeListener() {
+				public void stateChanged(ChangeEvent e) {
+					JTabbedPane tabs = (JTabbedPane) e.getSource();
+					Component sel_tab = tabs.getSelectedComponent();
+					if (sel_tab instanceof WizardPanel) {
+					    WizardPanel wipa = (WizardPanel) sel_tab;
+					    wizardListener.wizardStateChanged(
+					        wipa.areSettingsValid());
+					}
+					// getJPanel().setOkButtonEnabled(!(tabs.getSelectedComponent() instanceof WizardPanel));
+				}
+			});
+		}
+
+		return jTabbedPane;
+	}
+
+	/**
+	 * A�ade en una pesta�a un Jpanel con un titulo
+	 * @param title
+	 * @param panel
+	 */
+	public void addTab(String title, JPanel panel) {
+		getJTabbedPane().addTab(title, panel);
+	}
+
+	/**
+	 * A�ade en una pesta�a un WizardPanel con un titulo
+	 * @param title
+	 * @param panel
+	 */
+	public void addWizardTab(String title, WizardPanel panel) {
+		panel.addWizardListener(wizardListener);
+		getJTabbedPane().addTab(title, panel);
+	}
+
+	/**
+	 * Devuelve el JPanel seleccionado en las pesta�as
+	 * @return
+	 */
+	public JPanel getSelectedTab() {
+		return (JPanel) getJTabbedPane().getSelectedComponent();
+	}
+
+	/*
+	 * (non-Javadoc)
+	 * @see com.iver.andami.ui.mdiManager.IWindow#getWindowInfo()
+	 */
+	public WindowInfo getWindowInfo() {
+		WindowInfo m_viewinfo = new WindowInfo(WindowInfo.MODALDIALOG);
+		m_viewinfo.setTitle(this.title);
+		m_viewinfo.setHeight(500);
+		m_viewinfo.setWidth(520);
+		return m_viewinfo;
+	}
+
+	/**
+   * This method initializes jPanel
+   * @return javax.swing.JPanel
+   */
+	private AcceptCancelPanel getJPanel() {
+		if (jPanel == null) {
+			ActionListener okAction = new ActionListener() {
+				public void actionPerformed(ActionEvent e) {
+					accepted = true;
+					closeWindow();
+				}
+			};
+			ActionListener cancelAction = new ActionListener() {
+				public void actionPerformed(ActionEvent e) {
+					closeWindow();
+				}
+			};
+			jPanel = new AcceptCancelPanel(okAction, cancelAction);
+			jPanel.setOkButtonEnabled(false);
+		}
+		return jPanel;
+	}
+
+	/**
+	 * @return
+	 */
+	public boolean isAccepted() {
+		return accepted;
+	}
+
+	/**
+	 * Listener para el Wizard de apertura de fichero
+	 * @version 05/09/2007
+	 * @author BorSanZa - Borja S�nchez Zamorano (borja.sanchez@iver.es)
+	 */
+	public class DialogWizardListener implements WizardListener {
+		/*
+		 * (non-Javadoc)
+		 * @see com.iver.cit.gvsig.gui.wizards.WizardListener#error(java.lang.Exception)
+		 */
+		public void error(Exception e) {}
+
+		/*
+		 * (non-Javadoc)
+		 * @see com.iver.cit.gvsig.gui.wizards.WizardListener#wizardStateChanged(boolean)
+		 */
+		public void wizardStateChanged(boolean finishable) {
+			getJPanel().setOkButtonEnabled(finishable);
+		}
+	}
+
+	/**
+	 * Devuelve la ultima proyecci�n usada
+	 * @return
+	 */
+	public static IProjection getLastProjection() {
+		if (proj == null) {
+			proj = DefaultProject.getDefaultProjection();
+		}
+		return proj;
+	}
+
+	/**
+	 * Define la ultima proyeccion
+	 * @param proj
+	 */
+	public static void setLastProjection(IProjection proj) {
+		AddLayerDialog.proj = proj;
+	}
+
+	public Object getWindowProfile() {
+		return WindowInfo.DIALOG_PROFILE;
+	}
+
+	private void closeWindow() {
+//		JTabbedPane tabbed = getJTabbedPane();
+//		for (int i = 0; i < tabbed.getTabCount(); i++) {
+//			Component component = tabbed.getComponentAt(i);
+//			if (component instanceof WizardPanel) {
+//				((WizardPanel) component).close();
+//			}
+//		}
+		if (PluginServices.getMainFrame() == null) {
+			((JDialog) (getParent().getParent().getParent().getParent())).dispose();
+		} else {
+			PluginServices.getMDIManager().closeWindow(AddLayerDialog.this);
+		}
+	}
+
+	public void dispose() {
+		JTabbedPane tabbed = getJTabbedPane();
+		for (int i = 0; i < tabbed.getTabCount(); i++) {
+			Component component = tabbed.getComponentAt(i);
+			if (component instanceof WizardPanel) {
+				((WizardPanel) component).close();
+			}
+		}
+		ToolsLocator.getDisposableManager().release(this);
+	}
+	
+}
\ No newline at end of file

Property changes on: tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/app/addlayer/AddLayerDialog.java
___________________________________________________________________
Added: svn:keywords
   + Author Date Id Revision
Added: svn:eol-style
   + native

Index: tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/app/imp/AppgvSIGDefaultImplLibrary.java
===================================================================
--- tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/app/imp/AppgvSIGDefaultImplLibrary.java	(revision 0)
+++ tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/app/imp/AppgvSIGDefaultImplLibrary.java	(revision 38653)
@@ -0,0 +1,58 @@
+/* gvSIG. Geographic Information System of the Valencian Government
+ *
+ * Copyright (C) 2007-2008 Infrastructures and Transports Department
+ * of the Valencian Government (CIT)
+ * 
+ * This program is free software; you can redistribute it and/or
+ * modify it under the terms of the GNU General Public License
+ * as published by the Free Software Foundation; either version 2
+ * of the License, or (at your option) any later version.
+ * 
+ * This program is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
+ * GNU General Public License for more details.
+ * 
+ * You should have received a copy of the GNU General Public License
+ * along with this program; if not, write to the Free Software
+ * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, 
+ * MA  02110-1301, USA.
+ * 
+ */
+
+/*
+ * AUTHORS (In addition to CIT):
+ * 2009 {DiSiD Technologies}  {{Task}}
+ */
+package org.gvsig.app.imp;
+
+import org.gvsig.app.ApplicationLibrary;
+import org.gvsig.app.ApplicationLocator;
+import org.gvsig.installer.lib.api.InstallerLibrary;
+import org.gvsig.tools.library.AbstractLibrary;
+import org.gvsig.tools.library.LibraryException;
+
+/**
+ * Registers the default implementation for the AppGvSigManager.
+ * @author <a href="mailto:cordinyana@gvsig.org">C�sar Ordi�ana</a>
+ */
+public class AppgvSIGDefaultImplLibrary extends AbstractLibrary {
+
+    @Override
+    public void doRegistration() {
+        registerAsImplementationOf(ApplicationLibrary.class);
+        require(InstallerLibrary.class);
+    }
+
+	@Override
+	protected void doInitialize() throws LibraryException {
+		ApplicationLocator
+				.registerDefaultAppgvSIGManager(DefaultAppgvSIGManager.class);
+	}
+
+	@Override
+	protected void doPostInitialize() throws LibraryException {
+		// do nothing
+	}
+
+}
\ No newline at end of file
Index: tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/app/imp/DefaultPreferencesNode.java
===================================================================
--- tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/app/imp/DefaultPreferencesNode.java	(revision 0)
+++ tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/app/imp/DefaultPreferencesNode.java	(revision 38653)
@@ -0,0 +1,197 @@
+package org.gvsig.app.imp;
+
+import java.awt.Color;
+
+import org.gvsig.andami.PluginServices;
+import org.gvsig.app.PreferencesNode;
+import org.gvsig.utils.StringUtilities;
+import org.gvsig.utils.XMLEntity;
+
+public class DefaultPreferencesNode implements PreferencesNode {
+
+	private String name;
+	private XMLEntity node;
+	
+	public DefaultPreferencesNode() {
+		this.name = null;
+	}
+	
+	public DefaultPreferencesNode(String nodeName) {
+		this.name = nodeName;
+	}
+	
+	protected XMLEntity getRootNode() {
+		XMLEntity node = PluginServices.getPluginServices("org.gvsig.app")	.getPersistentXML();
+		return node;
+	}
+	
+	protected XMLEntity getNode() {
+		if( this.node == null ) {
+			if( this.name == null ) {
+				this.node = this.getRootNode();
+			} else {
+		        this.node = this.getRootNode().firstChild(this.name);		
+			}
+		}
+        return this.node;
+	}
+	
+	public String name() {
+		return this.name;
+	}
+
+	public String[] keys() throws Exception {
+		XMLEntity node = this.getNode();
+		int count = node.getChildrenCount();
+		String[] keys = new String[count];
+		for(int  i=0 ; i<count ; i++ ) {
+			keys[i] = node.getChild(i).getName();
+		}
+		return keys;
+	}
+
+	public void clear() throws Exception {
+		XMLEntity node = this.getNode();
+		node.removeAllChildren();
+	}
+
+	public void flush() throws Exception {
+		// do nothing
+	}
+
+	public String get(String name, String defaultValue) {
+		XMLEntity node = this.getNode();
+		
+		if (!node.contains(name)) {
+			return defaultValue;
+		}
+		String value = node.getStringProperty(name);
+		return value;
+	}
+
+	public boolean getBoolean(String name, boolean defaultValue) {
+		XMLEntity node = this.getNode();
+		
+		if (!node.contains(name)) {
+			return defaultValue;
+		}
+		boolean value = node.getBooleanProperty(name);
+		return value;
+	}
+
+	public byte[] getByteArray(String name, byte[] defaultValue) {
+		XMLEntity node = this.getNode();
+		
+		if (!node.contains(name)) {
+			return defaultValue;
+		}
+		byte[] value = node.getByteArrayProperty(name);
+		return value;
+	}
+
+	public double getDouble(String name, double defaultValue) {
+		XMLEntity node = this.getNode();
+		
+		if (!node.contains(name)) {
+			return defaultValue;
+		}
+		double value = node.getDoubleProperty(name);
+		return value;
+	}
+
+	public float getFloat(String name, float defaultValue) {
+		XMLEntity node = this.getNode();
+		
+		if (!node.contains(name)) {
+			return defaultValue;
+		}
+		float value = node.getFloatProperty(name);
+		return value;
+	}
+
+	public int getInt(String name, int defaultValue) {
+		XMLEntity node = this.getNode();
+		
+		if (!node.contains(name)) {
+			return defaultValue;
+		}
+		int value = node.getIntProperty(name);
+		return value;
+	}
+
+	public long getLong(String name, long defaultValue) {
+		XMLEntity node = this.getNode();
+		
+		if (!node.contains(name)) {
+			return defaultValue;
+		}
+		long value = node.getLongProperty(name);
+		return value;
+	}
+
+	public Color getColor(String name, Color defaultValue) {
+		XMLEntity node = this.getNode();
+		
+		if (!node.contains(name)) {
+			return defaultValue;
+		}
+		String value = node.getStringProperty(name);
+		return  StringUtilities.string2Color(value);
+	}
+
+	public void put(String name, String value) {
+		XMLEntity node = this.getNode();
+		
+		node.putProperty(name, value);
+	}
+
+	public void putBoolean(String name, boolean value) {
+		XMLEntity node = this.getNode();
+		
+		node.putProperty(name, value);
+	}
+
+	public void putByteArray(String name, byte[] value) {
+		XMLEntity node = this.getNode();
+		
+		node.putProperty(name, value);
+	}
+
+	public void putDouble(String name, double value) {
+		XMLEntity node = this.getNode();
+		
+		node.putProperty(name, value);
+	}
+
+	public void putFloat(String name, float value) {
+		XMLEntity node = this.getNode();
+		
+		node.putProperty(name, value);
+	}
+
+	public void putInt(String name, int value) {
+		XMLEntity node = this.getNode();
+		
+		node.putProperty(name, value);
+	}
+
+	public void putLong(String name, long value) {
+		XMLEntity node = this.getNode();
+		
+		node.putProperty(name, value);
+	}
+
+	public void remove(String name) {
+		XMLEntity node = this.getNode();
+
+		if (!node.contains(name)) {
+			return;
+		}
+		node.remove(name);
+	}
+
+	public void sync() throws Exception {
+		// do nothing
+	}
+
+}

Property changes on: tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/app/imp/DefaultPreferencesNode.java
___________________________________________________________________
Added: svn:mime-type
   + text/plain

Index: tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/app/imp/DefaultAppgvSIGManager.java
===================================================================
--- tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/app/imp/DefaultAppgvSIGManager.java	(revision 0)
+++ tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/app/imp/DefaultAppgvSIGManager.java	(revision 38653)
@@ -0,0 +1,467 @@
+/* gvSIG. Geographic Information System of the Valencian Government
+*
+* Copyright (C) 2007-2008 Infrastructures and Transports Department
+* of the Valencian Government (CIT)
+*
+* This program is free software; you can redistribute it and/or
+* modify it under the terms of the GNU General Public License
+* as published by the Free Software Foundation; either version 2
+* of the License, or (at your option) any later version.
+*
+* This program is distributed in the hope that it will be useful,
+* but WITHOUT ANY WARRANTY; without even the implied warranty of
+* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
+* GNU General Public License for more details.
+*
+* You should have received a copy of the GNU General Public License
+* along with this program; if not, write to the Free Software
+* Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston,
+* MA  02110-1301, USA.
+*
+*/
+
+/*
+* AUTHORS (In addition to CIT):
+* 2009 IVER T.I   {{Task}}
+*/
+
+/**
+ *
+ */
+package org.gvsig.app.imp;
+
+import java.awt.Component;
+import java.util.ArrayList;
+import java.util.Iterator;
+import java.util.List;
+
+import javax.swing.JComponent;
+
+import org.cresques.cts.IProjection;
+import org.gvsig.about.AboutLocator;
+import org.gvsig.about.AboutManager;
+import org.gvsig.andami.Launcher;
+import org.gvsig.andami.PluginServices;
+import org.gvsig.andami.ui.mdiFrame.MainFrame;
+import org.gvsig.andami.ui.mdiManager.IWindow;
+import org.gvsig.andami.ui.mdiManager.MDIManager;
+import org.gvsig.app.ApplicationManager;
+import org.gvsig.app.PreferencesNode;
+import org.gvsig.app.extension.Version;
+import org.gvsig.app.gui.WizardPanel;
+import org.gvsig.app.prepareAction.PrepareContext;
+import org.gvsig.app.prepareAction.PrepareContextView;
+import org.gvsig.app.prepareAction.PrepareDataStore;
+import org.gvsig.app.prepareAction.PrepareDataStoreParameters;
+import org.gvsig.app.prepareAction.PrepareLayer;
+import org.gvsig.app.project.DefaultProject;
+import org.gvsig.app.project.Project;
+import org.gvsig.app.project.ProjectManager;
+import org.gvsig.app.project.documents.Document;
+import org.gvsig.app.project.documents.gui.IDocumentWindow;
+import org.gvsig.fmap.crs.CRSFactory;
+import org.gvsig.fmap.dal.DALLocator;
+import org.gvsig.fmap.dal.DataManager;
+import org.gvsig.fmap.dal.DataStore;
+import org.gvsig.fmap.dal.DataStoreParameters;
+import org.gvsig.fmap.geom.GeometryLocator;
+import org.gvsig.fmap.geom.GeometryManager;
+import org.gvsig.fmap.mapcontext.MapContextLocator;
+import org.gvsig.fmap.mapcontext.MapContextManager;
+import org.gvsig.fmap.mapcontext.layers.FLayer;
+import org.gvsig.gui.ColorTablesFactory;
+import org.gvsig.symbology.swing.SymbologySwingLocator;
+import org.gvsig.tools.ToolsLocator;
+import org.gvsig.tools.dataTypes.DataTypesManager;
+import org.gvsig.tools.dispose.DisposableManager;
+import org.gvsig.tools.dynobject.DynObjectManager;
+import org.gvsig.tools.extensionpoint.ExtensionPoint;
+import org.gvsig.tools.extensionpoint.ExtensionPoint.Extension;
+import org.gvsig.tools.extensionpoint.ExtensionPointManager;
+import org.gvsig.tools.persistence.PersistenceManager;
+import org.gvsig.tools.swing.api.ToolsSwingLocator;
+import org.gvsig.tools.swing.icontheme.IconThemeManager;
+import org.slf4j.Logger;
+import org.slf4j.LoggerFactory;
+
+
+
+
+/**
+ * @author jmvivo
+ *
+ */
+public class DefaultAppgvSIGManager implements ApplicationManager {
+
+    @SuppressWarnings("unused")
+	private static Logger logger = LoggerFactory.getLogger(DefaultAppgvSIGManager.class);
+    
+	private static final String EPNAME_PREPARE_OPEN_DATASTORE = "org.gvsig.datastore.open.prepare"; //"PrepareOpenDataStore";
+	private static final String EPNAME_PREPARE_OPEN_DATASTOREPARAMETERS = "org.gvsig.datastoreparameters.open.prepare"; //"PrepareOpenDataStoreParameters";
+	private static final String EPNAME_PREPARE_OPEN_LAYER = "org.gvsig.layer.open.prepare"; // "PrepareOpenLayer";
+
+	private static final String EPNAME_ADD_TABLE_WIZARD = "AddLayerWizard";
+
+	private ExtensionPointManager epManager;
+
+    private Version version;
+
+	public DefaultAppgvSIGManager() {
+		epManager = ToolsLocator.getExtensionPointManager();
+		epManager.add(EPNAME_PREPARE_OPEN_DATASTORE,
+				"Actions to do when open a DataStore");
+		epManager.add(EPNAME_PREPARE_OPEN_DATASTOREPARAMETERS,
+				"Actions to do before open a DataStore with parameters");
+		epManager.add(EPNAME_PREPARE_OPEN_LAYER,
+			"Actions to do after create a Layer");
+		epManager.add(EPNAME_ADD_TABLE_WIZARD,
+				"Wizards to add new document table");
+
+        version = new Version();
+	}
+
+	/* (non-Javadoc)
+	 * @see org.gvsig.appGvSigManager#pepareOpenDataSource(org.gvsig.fmap.dal.DataStore)
+	 */
+	@SuppressWarnings("unchecked")
+	public DataStore pepareOpenDataSource(DataStore store,
+			PrepareContext context) throws Exception {
+		ExtensionPoint ep = epManager.get(EPNAME_PREPARE_OPEN_DATASTORE);
+		if (ep.getCount() == 0) {
+			return store;
+		}
+		DataStore result = store;
+		Iterator<ExtensionPoint.Extension> iter = ep.iterator();
+		PrepareDataStore prepare;
+		while (iter.hasNext()) {
+			prepare = (PrepareDataStore) iter.next().create();
+			result = prepare.prepare(store, context);
+		}
+		return result;
+	}
+
+	/* (non-Javadoc)
+	 * @see org.gvsig.appGvSigManager#prepareOpenDataStoreParameters(org.gvsig.fmap.dal.DataStoreParameters)
+	 */
+	@SuppressWarnings("unchecked")
+	public DataStoreParameters prepareOpenDataStoreParameters(
+			DataStoreParameters storeParameters, PrepareContext context)
+			throws Exception {
+
+		ExtensionPoint ep = epManager
+				.get(EPNAME_PREPARE_OPEN_DATASTOREPARAMETERS);
+		if (ep.getCount() == 0) {
+			return storeParameters;
+		}
+		DataStoreParameters result = storeParameters;
+		Iterator<ExtensionPoint.Extension> iter = ep.iterator();
+		PrepareDataStoreParameters prepare;
+		while (iter.hasNext()) {
+			prepare = (PrepareDataStoreParameters) iter.next().create();
+			result = prepare.prepare(storeParameters, context);
+		}
+
+		return result;
+	}
+	
+	/*
+	 * (non-Javadoc)
+	 * @see org.gvsig.app.ApplicationManager#prepareOpenDataStoreParameters(java.util.List, org.gvsig.app.prepareAction.PrepareContext)
+	 */
+	@SuppressWarnings("unchecked")
+	public List<DataStoreParameters> prepareOpenDataStoreParameters(
+			List<DataStoreParameters> storeParameters, PrepareContext context)
+			throws Exception {
+
+		ExtensionPoint ep = epManager
+				.get(EPNAME_PREPARE_OPEN_DATASTOREPARAMETERS);
+		if (ep.getCount() == 0) {
+			return storeParameters;
+		}
+		
+		List<DataStoreParameters> result = new ArrayList<DataStoreParameters>();
+		
+		Iterator<ExtensionPoint.Extension> iter = ep.iterator();
+		List<PrepareDataStoreParameters> prepareList = new ArrayList<PrepareDataStoreParameters>();
+		while (iter.hasNext()) {
+			prepareList.add((PrepareDataStoreParameters) iter.next().create());
+		}
+		
+		for (int i = 0; i < storeParameters.size(); i++) {
+			DataStoreParameters param = storeParameters.get(i);
+			for (int j = 0; j < prepareList.size(); j++) {
+				prepareList.get(j).pre(param, context);
+			}
+		}
+		
+		for (int i = 0; i < storeParameters.size(); i++) {
+			DataStoreParameters param = storeParameters.get(i);
+			if(param != null) {
+				for (int j = 0; j < prepareList.size(); j++) {
+					param = prepareList.get(j).prepare(param, context);
+					if(param == null)
+						break;
+				}
+				if(param != null)
+					result.add(param);
+			}
+		}
+		
+		for (int i = 0; i < storeParameters.size(); i++) {
+			DataStoreParameters param = storeParameters.get(i);
+			for (int j = 0; j < prepareList.size(); j++) {
+				prepareList.get(j).post(param, context);
+			}
+		}
+
+		return result;
+	}
+
+	public void registerPrepareOpenDataStore(PrepareDataStore action) {
+		ExtensionPoint ep = epManager.get(EPNAME_PREPARE_OPEN_DATASTORE);
+		ep.append(action.getName(), action.getDescription(), action);
+	}
+
+	public void registerPrepareOpenDataStoreParameters(
+			PrepareDataStoreParameters action) {
+		ExtensionPoint ep = epManager
+				.get(EPNAME_PREPARE_OPEN_DATASTOREPARAMETERS);
+		ep.append(action.getName(), action.getDescription(), action);
+
+
+	}
+
+	@SuppressWarnings("unchecked")
+	public FLayer prepareOpenLayer(FLayer layer,
+			PrepareContextView context)
+			throws Exception {
+
+		ExtensionPoint ep = epManager.get(EPNAME_PREPARE_OPEN_LAYER);
+
+		if (ep.getCount() == 0) {
+			return layer;
+		}
+		FLayer result = layer;
+		Iterator<ExtensionPoint.Extension> iter = ep.iterator();
+		PrepareLayer prepare;
+		while (iter.hasNext()) {
+			prepare = (PrepareLayer) iter.next().create();
+			result = prepare.prepare(result, context);
+		}
+
+		return result;
+
+	}
+
+	public void registerPrepareOpenLayer(PrepareLayer action) {
+		ExtensionPoint ep = epManager.get(EPNAME_PREPARE_OPEN_LAYER);
+		ep.append(action.getName(), action.getDescription(), action);
+	}
+
+	public void registerAddTableWizard(String name, String description,
+			Class<? extends WizardPanel> wpClass) {
+		ExtensionPoint ep = epManager.get(EPNAME_ADD_TABLE_WIZARD);
+		ep.append(name, description, wpClass);
+	}
+
+	@SuppressWarnings("unchecked")
+	public List<WizardPanel> getWizardPanels() throws Exception {
+		ExtensionPoint ep = epManager.get(EPNAME_ADD_TABLE_WIZARD);
+		List<WizardPanel> result = new ArrayList<WizardPanel>();
+		Iterator<Extension> iter = ep.iterator();
+		while (iter.hasNext()) {
+			result.add((WizardPanel) iter.next().create());
+		}
+		return result;
+	}
+
+	public DataManager getDataManager() {
+		return DALLocator.getDataManager();
+	}
+
+	public GeometryManager getGeometryManager() {
+		return GeometryLocator.getGeometryManager();
+	}
+
+	public PersistenceManager getPersistenceManager() {
+		return ToolsLocator.getPersistenceManager();
+	}
+
+	public DisposableManager getDisposableManager() {
+		return ToolsLocator.getDisposableManager();
+	}
+
+	public DynObjectManager getDynObjectManager() {
+		return ToolsLocator.getDynObjectManager();
+	}
+
+	public ExtensionPointManager getExtensionPointManager() {
+		return ToolsLocator.getExtensionPointManager();
+	}
+
+	public ProjectManager getProjectManager() {
+		return ProjectManager.getInstance();
+	}
+
+	public MDIManager getUIManager() {
+		return PluginServices.getMDIManager();
+	}
+
+	public MapContextManager getMapContextManager() {
+		return MapContextLocator.getMapContextManager();
+	}
+
+	public DataTypesManager getDataTypesManager() {
+		return ToolsLocator.getDataTypesManager();
+	}
+	
+	public IProjection getCRS(String code) {
+		return CRSFactory.getCRS(code);
+	}
+
+	public IconThemeManager getIconThemeManager() {
+		return ToolsSwingLocator.getIconThemeManager();
+	}
+
+	public String getArgument(String name) {
+		return PluginServices.getArgumentByName(name);
+	}
+
+	public String[] getArguments() {
+		return PluginServices.getArguments();
+	}
+
+	public String getFromClipboard() {
+		return PluginServices.getFromClipboard();
+	}
+
+	public void putInClipboard(String data) {
+		PluginServices.putInClipboard(data);
+	}
+
+	public Project getCurrentProject() {
+		return ProjectManager.getInstance().getCurrentProject();
+	}
+
+	public PreferencesNode getPreferences(String node) {
+		if( node.equalsIgnoreCase("project")) {
+			return DefaultProject.getPreferences();
+		}
+		return new DefaultPreferencesNode(node);
+	}
+
+	public PreferencesNode getPreferences() {
+		return new DefaultPreferencesNode();
+	}
+
+	public Version getVersion() {
+        return version;
+	}
+	
+	public AboutManager getAbout() {
+		AboutManager manager = AboutLocator.getManager();
+		return manager;
+	}
+
+	public ColorTablesFactory getColorTablesFactory() {
+		return SymbologySwingLocator.getSwingManager().getColorTablesFactory();
+	}
+
+	public void registerColorTablesFactory(ColorTablesFactory factory) {
+		SymbologySwingLocator.getSwingManager().setColorTablesFactory(factory);
+		
+	}
+
+    public IWindow getActiveWindow() {
+        try {
+            IWindow window = PluginServices.getMDIManager().getActiveWindow();
+            return window;
+        } catch (Exception ex) {
+            return null;
+        }
+    }
+
+    public Document getActiveDocument() {
+        Project project = this.getCurrentProject();
+        if( project == null ) {
+            return null;
+        }
+        return project.getActiveDocument();
+    }
+    
+    public Document getActiveDocument(String documentTypeName) {
+        Document document = this.getActiveDocument();
+        if( document!= null && document.getTypeName().equalsIgnoreCase(documentTypeName) ) {
+            return document;
+        }
+        return null;
+    }
+    
+    public Document getActiveDocument(Class<? extends Document> documentClass) {
+        Document document = this.getActiveDocument();
+        if( documentClass.isInstance(document) ) {
+            return document;
+        }
+        return null;
+    }
+    
+    public IDocumentWindow getDocumentWindow(Document document) {
+        Class<? extends IDocumentWindow> defaultDocumentClass =
+            document.getFactory().getMainWindowClass();
+        return (IDocumentWindow) this.getUIManager().getSingletonWindow(defaultDocumentClass, document);
+    }
+
+	public String getLocaleLanguage() {
+		return Launcher.getAndamiConfig().getLocaleLanguage();
+	}
+
+	public void message(String message, int message_type) {
+		MainFrame main = PluginServices.getMainFrame();
+		main.message(message, message_type);
+	}
+
+	public void messageDialog(String message, String title, int messageType) {
+		MainFrame main = PluginServices.getMainFrame();
+		main.messageDialog(message, title, messageType);
+	}
+
+	public void messageDialog(String message, String[] messageArgs,
+			String title, int messageType) {
+		MainFrame main = PluginServices.getMainFrame();
+		main.messageDialog(message, messageArgs, title, messageType);
+	}
+
+	public int confirmDialog(String message, String title, int optionType,
+			int messageType) {
+		MainFrame main = PluginServices.getMainFrame();
+		return main.confirmDialog(message, title, optionType, messageType);
+	}
+
+	public String inputDialog(String message, String title, int messageType,
+			String initialValue) {
+		MainFrame main = PluginServices.getMainFrame();
+		return main.inputDialog(message, title, messageType, initialValue);
+	}
+
+	public String inputDialog(String message, String title) {
+		MainFrame main = PluginServices.getMainFrame();
+		return main.inputDialog(message, title);
+	}
+
+	public void showDialog(Component contents, String title) {
+		MainFrame main = PluginServices.getMainFrame();
+		main.showDialog(contents, title);
+	}
+
+	public Component createComponent(Class<? extends Component> theClass,
+			Object... parameters) {
+		MainFrame main = PluginServices.getMainFrame();
+		return main.createComponentWithParams(theClass, parameters);
+	}
+
+	public Component createComponentWithParams(
+			Class<? extends Component> theClass, Object[] parameters) {
+		MainFrame main = PluginServices.getMainFrame();
+		return main.createComponentWithParams(theClass, parameters);
+	}
+}

Property changes on: tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/app/imp/DefaultAppgvSIGManager.java
___________________________________________________________________
Added: svn:mime-type
   + text/plain

Index: tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/app/project/DefaultProject.java
===================================================================
--- tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/app/project/DefaultProject.java	(revision 0)
+++ tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/app/project/DefaultProject.java	(revision 38653)
@@ -0,0 +1,1135 @@
+/* gvSIG. Geographic Information System of the Valencian Government
+ *
+ * Copyright (C) 2007-2009 Infrastructures and Transports Department
+ * of the Valencian Government (CIT)
+ * 
+ * This program is free software; you can redistribute it and/or
+ * modify it under the terms of the GNU General Public License
+ * as published by the Free Software Foundation; either version 2
+ * of the License, or (at your option) any later version.
+ * 
+ * This program is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
+ * GNU General Public License for more details.
+ * 
+ * You should have received a copy of the GNU General Public License
+ * along with this program; if not, write to the Free Software
+ * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, 
+ * MA  02110-1301, USA.
+ * 
+ */
+
+/*
+ * AUTHORS (In addition to CIT):
+ * 2004-2009 IVER TI
+ *   
+ */
+
+package org.gvsig.app.project;
+
+import java.awt.Color;
+import java.beans.PropertyChangeEvent;
+import java.beans.PropertyChangeListener;
+import java.beans.PropertyChangeSupport;
+import java.io.File;
+import java.io.FileInputStream;
+import java.io.FileNotFoundException;
+import java.io.FileOutputStream;
+import java.io.InputStream;
+import java.io.OutputStream;
+import java.io.Serializable;
+import java.net.MalformedURLException;
+import java.net.URI;
+import java.net.URISyntaxException;
+import java.net.URL;
+import java.text.DateFormat;
+import java.text.MessageFormat;
+import java.util.ArrayList;
+import java.util.Collections;
+import java.util.Date;
+import java.util.HashMap;
+import java.util.Iterator;
+import java.util.List;
+import java.util.Map;
+import java.util.regex.Pattern;
+
+import org.cresques.cts.IProjection;
+import org.slf4j.Logger;
+import org.slf4j.LoggerFactory;
+
+import org.gvsig.andami.PluginServices;
+import org.gvsig.andami.ui.mdiManager.IWindow;
+import org.gvsig.andami.ui.mdiManager.MDIManager;
+import org.gvsig.andami.ui.mdiManager.SingletonWindow;
+import org.gvsig.andami.ui.mdiManager.WindowInfo;
+import org.gvsig.app.ApplicationLocator;
+import org.gvsig.app.ApplicationManager;
+import org.gvsig.app.extension.ProjectExtension;
+import org.gvsig.app.extension.Version;
+import org.gvsig.app.project.documents.AbstractDocument;
+import org.gvsig.app.project.documents.Document;
+import org.gvsig.app.project.documents.exceptions.SaveException;
+import org.gvsig.app.project.documents.gui.IDocumentWindow;
+import org.gvsig.app.project.documents.gui.ProjectWindow;
+import org.gvsig.app.project.documents.view.DefaultViewDocument;
+import org.gvsig.app.project.documents.view.ViewManager;
+import org.gvsig.fmap.dal.DataTypes;
+import org.gvsig.fmap.mapcontext.MapContext;
+import org.gvsig.fmap.mapcontext.layers.FLayer;
+import org.gvsig.fmap.mapcontext.layers.FLayers;
+import org.gvsig.tools.ToolsLocator;
+import org.gvsig.tools.dynobject.DynField;
+import org.gvsig.tools.dynobject.DynStruct;
+import org.gvsig.tools.persistence.PersistenceManager;
+import org.gvsig.tools.persistence.Persistent;
+import org.gvsig.tools.persistence.PersistentContext;
+import org.gvsig.tools.persistence.PersistentState;
+import org.gvsig.tools.persistence.exception.PersistenceException;
+import org.gvsig.utils.StringUtilities;
+
+/**
+ * Clase que representa un proyecto de gvSIG
+ * 
+ * @author 2004-2005 Fernando Gonz�lez Cort�s
+ * @author 2006-2009 Jose Manuel Vivo
+ * @author 2005- Vicente Caballero
+ * @author 2009- Joaquin del Cerro
+ * 
+ */
+
+public class DefaultProject implements Serializable, PropertyChangeListener,
+		Project {
+
+	private Logger LOG = LoggerFactory.getLogger(DefaultProject.class);
+	/**
+	 * @deprecated see ApplicationLocator.getManager().getVersion()
+	 */
+	public static String VERSION = Version.format();
+
+	/**
+	 * 
+	 */
+	private static final long serialVersionUID = -4449622027521773178L;
+
+	private static final Logger logger = LoggerFactory.getLogger(Project.class);
+
+	private static ProjectPreferences preferences = new ProjectPreferences();
+
+	/**
+	 * Index used by the generator of unique names of documents.
+	 */
+	private Map<String, Integer> nextDocumentIndexByType = new HashMap<String, Integer>();
+
+	private PropertyChangeSupport change;
+
+	private boolean modified = false;
+
+	private String name = null;
+
+	private String creationDate = null;
+
+	private String modificationDate = null;
+
+	private String owner = null;
+
+	private String comments = null;
+
+	private Color selectionColor = null;
+
+	private List<Document> documents = null;
+
+	private List<ProjectExtent> extents = null;
+
+	private IProjection projection;
+
+	/**
+	 * Creates a new Project object.
+	 */
+	DefaultProject() {
+		this.change = new PropertyChangeSupport(this);
+		this.clean();
+	}
+
+	protected void clean() {
+		this.owner = "";
+		this.comments = "";
+		this.name = PluginServices.getText(this, "untitled");
+		this.creationDate = DateFormat.getDateInstance().format(new Date());
+		this.modificationDate = this.creationDate;
+
+		this.documents = new ArrayList<Document>();
+		this.extents = new ArrayList<ProjectExtent>();
+
+		this.setSelectionColor(getPreferences().getDefaultSelectionColor());
+
+		this.projection = null; // se inicializa en el getProjection()
+	}
+
+	public static ProjectPreferences getPreferences() {
+		return preferences;
+	}
+
+	public void propertyChange(PropertyChangeEvent evt) {
+		change.firePropertyChange(evt);
+	}
+
+	public synchronized void addPropertyChangeListener(
+			PropertyChangeListener arg0) {
+		change.addPropertyChangeListener(arg0);
+	}
+
+	/**
+	 * Return the creation date of the project
+	 * 
+	 * @return
+	 */
+	public String getCreationDate() {
+		return creationDate;
+	}
+
+	protected void setCreationDate(String creationDate) {
+		this.creationDate = creationDate;
+		change.firePropertyChange("setCreationDate", null, null);
+	}
+
+    public Document createDocument(String type) {
+    	logger.info("createDocument('{}')",type);
+        return ProjectManager.getInstance().createDocument(type);
+    }
+
+    /**
+     * Return the name of the project
+     * 
+     * @return
+     */
+    public String getName() {
+        return name;
+    }
+
+	/**
+	 * Set the name of he project.
+	 * 
+	 * @param string
+	 */
+	public void setName(String name) {
+		this.name = name;
+		change.firePropertyChange("setName", null, null);
+	}
+
+	/**
+	 * Return the comments associateds with the project
+	 * 
+	 * @return comments
+	 */
+	public String getComments() {
+		return comments;
+	}
+
+	/**
+	 * Set the comments associateds with the project
+	 * 
+	 * @param comments
+	 *            as string
+	 */
+	public void setComments(String string) {
+		comments = string;
+		change.firePropertyChange("setComments", null, null);
+	}
+
+	/**
+	 * Retuen the modification date of the project.
+	 * 
+	 * @return modification date as string
+	 */
+	public String getModificationDate() {
+		return modificationDate;
+	}
+
+	protected void setModificationDate(String string) {
+		modificationDate = string;
+		change.firePropertyChange("setModificationDate", null, null);
+	}
+
+	/**
+	 * Return the author of the project,
+	 * 
+	 * @return author as string
+	 */
+	public String getOwner() {
+		return owner;
+	}
+
+	/**
+	 * Sets the author of the project
+	 * 
+	 * @param author
+	 *            name as string
+	 */
+	public void setOwner(String owner) {
+		this.owner = owner;
+		change.firePropertyChange("setOwner", null, null);
+	}
+
+	/**
+	 * Obtiene el color de selecci�n que se usar� en el proyecto
+	 * 
+	 * @return
+	 */
+	public Color getSelectionColor() {
+		if (selectionColor == null) {
+			selectionColor = getPreferences().getDefaultSelectionColor();
+		}
+		return selectionColor;
+	}
+
+	/**
+	 * Sets the selecction color
+	 * 
+	 * @param selection
+	 *            color as string
+	 */
+	public void setSelectionColor(String selectionColor) {
+		this.setSelectionColor(StringUtilities.string2Color(selectionColor));
+	}
+
+	/**
+	 * Sets the selecction color
+	 * 
+	 * @param selection
+	 *            color as Color
+	 */
+	public void setSelectionColor(Color selectionColor) {
+		this.selectionColor = selectionColor;
+		MapContext.setSelectionColor(selectionColor);
+		change.firePropertyChange("selectionColor", null, selectionColor);
+	}
+
+	public IProjection getProjection() {
+		if (projection == null) {
+			projection = getPreferences().getDefaultProjection();
+		}
+		return projection;
+	}
+
+	public void setProjection(IProjection projection) {
+		this.projection = projection;
+	}
+
+	/**
+	 * Sets the modified state of project.
+	 * 
+	 * Can't set to not modified.
+	 * 
+	 * @param modified
+	 *            as boolean
+	 */
+	public void setModified(boolean modified) {
+		this.modified = modified;
+		if (modified == false) {
+			List<Document> documents = this.getDocuments();
+			for (int i = 0; i < documents.size(); i++) {
+				documents.get(i).setModified(false);
+			}
+		}
+	}
+
+	public boolean hasChanged() {
+		// we return true if the project is not empty (until we have a better
+		// method...)
+		if ((this.getDocuments().size() != 0) || modified) {
+			return true;
+		}
+		return false;
+	}
+
+	/**
+	 * Return a list of documents in the project.
+	 * 
+	 * @return documents as List of IProjectDocument
+	 */
+	public List<Document> getDocuments() {
+		return Collections.unmodifiableList(documents);
+	}
+
+	/**
+	 * Return a list with all documents of especified type.
+	 * 
+	 * @param type
+	 *            of document
+	 * 
+	 * @return List of IProjectDocument
+	 */
+	public List<Document> getDocuments(String type) {
+		List<Document> docs = new ArrayList<Document>();
+		if (type != null) {
+			for (Document document : this.documents) {
+				if (type.equalsIgnoreCase(document.getTypeName())) {
+					docs.add(document);
+				}
+			}
+		}
+		return Collections.unmodifiableList(docs);
+	}
+
+	/**
+	 * Adds a document to the project
+	 * 
+	 * @param document
+	 *            as IProjectDocument
+	 */
+	public void add(Document document) {
+        logger.info("add('{}')", document.toString());
+
+		document.addPropertyChangeListener(this);
+		document.setProject(this);
+		document.setName(this.getUniqueNameForDocument(document.getTypeName(),
+				document.getName()));
+		documents.add(document);
+		document.afterAdd();
+		this.setModified(true);
+        change.firePropertyChange("addDocument", null, document);
+	}
+
+	/**
+	 * Remove a document of the project
+	 * 
+	 * @param document
+	 *            as IProjectDocument
+	 */
+	public void remove(Document doc) {
+        logger.info("remove('{}')", doc.toString());
+		documents.remove(doc);
+		this.setModified(true);
+        change.firePropertyChange("delDocument", doc, null);
+		doc.afterRemove();
+	}
+
+	public Iterator<Document> iterator() {
+		return documents.iterator();
+	}
+
+	public boolean isEmpty() {
+		return documents.isEmpty();
+	}
+
+	/**
+	 * Return the view that contains the especified layer.
+	 * 
+	 * @param layer
+	 * 
+	 * @return name of the view that contains the layer
+	 * 
+	 * @throws RuntimeException
+	 *             Si la capa que se pasa como par�metro no se encuentra en
+	 *             ninguna vista
+	 */
+	public String getViewName(FLayer layer) {
+		List<Document> views = getDocuments(ViewManager.TYPENAME);
+		for (int v = 0; v < views.size(); v++) {
+			DefaultViewDocument pView = (DefaultViewDocument) views.get(v);
+			FLayers layers = pView.getMapContext().getLayers();
+			if (isView(layers, layer)) {
+				return pView.getName();
+			}
+		}
+
+		throw new RuntimeException(MessageFormat.format(
+				"The layer '{1}' is not in a view", layer.getName()));
+	}
+
+	private boolean isView(FLayers layers, FLayer layer) {
+		for (int i = 0; i < layers.getLayersCount(); i++) {
+			if (layers.getLayer(i) instanceof FLayers) {
+				if (isView((FLayers) layers.getLayer(i), layer)) {
+					return true;
+				}
+			}
+			if (layers.getLayer(i) == layer) {
+				return true;
+			}
+		}
+		return false;
+	}
+
+	public void addExtent(ProjectExtent arg1) {
+		extents.add(arg1);
+		change.firePropertyChange("addExtent", null, null);
+	}
+
+	public ProjectExtent removeExtent(int arg0) {
+		change.firePropertyChange("delExtent", null, null);
+		return extents.remove(arg0);
+	}
+
+	public ProjectExtent[] getExtents() {
+		return (ProjectExtent[]) extents.toArray(new ProjectExtent[0]);
+	}
+
+	/**
+	 * Obtiene un documento a partir de su nombre y el nombre de registro en el
+	 * pointExtension, este �ltimo se puede obtener del
+	 * Project****Factory.registerName.
+	 * 
+	 * @param name
+	 *            Nombre del documento
+	 * @param type
+	 *            nombre de registro en el extensionPoint
+	 * 
+	 * @return Documento
+	 */
+	public Document getDocument(String name, String type) {
+		if (type != null) {
+			for (int i = 0; i < documents.size(); i++) {
+				Document document = documents.get(i);
+				if (type.equalsIgnoreCase(document.getTypeName())
+						&& name.equalsIgnoreCase(document.getName())) {
+					return document;
+				}
+			}
+		}
+		return null;
+	}
+
+	public String getUniqueNameForDocument(String type, String name) {
+		Document document = getDocument(name, type);
+		if (document == null) {
+			return name;
+		}
+
+		String newName = null;
+		int num = this.getNextDocumentIndex(type);
+		while (document != null) {
+			newName = name + " - " + num++;
+			document = getDocument(newName, type);
+		}
+		this.setNextDocumentIndex(type, num);
+		return newName;
+	}
+
+	private int getNextDocumentIndex(String type) {
+		if (nextDocumentIndexByType.get(type) == null) {
+			nextDocumentIndexByType.put(type, new Integer(1));
+			return 1;
+		}
+		return nextDocumentIndexByType.get(type).intValue();
+	}
+
+	private void setNextDocumentIndex(String type, int newIndex) {
+		if (nextDocumentIndexByType.get(type) == null) {
+			nextDocumentIndexByType.put(type, new Integer(newIndex));
+		} else {
+			nextDocumentIndexByType.put(type, new Integer(newIndex));
+		}
+	}
+
+	public void saveState(File out) throws PersistenceException {
+		FileOutputStream fout;
+		try {
+			fout = new FileOutputStream(out);
+			saveState(fout, new File(out.getParent()));
+		} catch (FileNotFoundException e) {
+			throw new PersistenceException(e);
+		}
+	}
+
+	public void saveState(OutputStream out) throws PersistenceException {
+		saveState(out, null);
+	}
+
+	public void saveState(OutputStream out, File rootFolder)
+			throws PersistenceException {
+		PersistenceManager manager = ToolsLocator.getPersistenceManager();
+		PersistentState state = null;
+		state = manager.getState(this, true);
+		try {
+			if (rootFolder != null) {
+				relativizeFiles(state, rootFolder);
+			}
+		} catch (Exception ex) {
+			state.getContext().addError(ex);
+		}
+		manager.saveState(state, out);
+		if (state.getContext().getErrors() != null) {
+			throw state.getContext().getErrors();
+		}
+	}
+
+	private void relativizeFiles(PersistentState state, File rootFolder) {
+		PersistentContext context = state.getContext();
+
+		URI cwd = new File(System.getProperty("user.dir")).toURI();
+		@SuppressWarnings("unchecked")
+		Iterator<PersistentState> statesIterator = context.iterator();
+		while (statesIterator.hasNext()) {
+			PersistentState aState = statesIterator.next();
+			DynStruct definition = aState.getDefinition();
+			DynField[] fields = definition.getDynFields();
+			for (DynField field : fields) {
+				if (field.getType() == DataTypes.FILE
+						|| field.getType() == DataTypes.FOLDER) {
+					try {
+						File value = aState.getFile(field.getName());
+						value = relativizeFile(value, rootFolder);
+						aState.set(field.getName(), value);
+					} catch (PersistenceException e) {
+						LOG.warn(
+								"Can't relativice field '" + field.getName()
+										+ "' for class '"
+										+ definition.getName() + "'.", e);
+					}
+				} else if (field.getType() == DataTypes.URL) {
+					try {
+						URL value = aState.getURL(field.getName());
+						if ("FILE".equalsIgnoreCase(value.getProtocol())) {
+							File file = new File(value.toURI());
+							file = relativizeFile(file, rootFolder);
+							value = new URL("file","",file.toURI().toString().substring(cwd.toString().length()));
+							aState.set(field.getName(), value);
+						}
+					} catch (PersistenceException e) {
+						// do nothind
+					} catch (MalformedURLException e) {
+						// do nothind
+					} catch (URISyntaxException e) {
+						// do nothind
+					}
+				}
+			}
+		}
+	}
+
+	private File relativizeFile(File file, File rootFolder) {
+		if (rootFolder == null) {
+			return file;
+		}
+		if (file == null) {
+			return null;
+		}
+		boolean isDir = false;
+		// isDir = file.isDirectory();
+		isDir = rootFolder.isDirectory();
+		String basePath = rootFolder.getAbsolutePath();
+		String targetPath = file.getPath();
+		String pathSeparator = File.separator;
+		// We need the -1 argument to split to make sure we get a trailing
+		// "" token if the base ends in the path separator and is therefore
+		// a directory. We require directory paths to end in the path
+		// separator -- otherwise they are indistinguishable from files.
+		String[] base = basePath.split(Pattern.quote(pathSeparator), -1);
+		String[] target = targetPath.split(Pattern.quote(pathSeparator), 0);
+
+		// First get all the common elements. Store them as a string,
+		// and also count how many of them there are.
+		String common = "";
+		int commonIndex = 0;
+		for (int i = 0; i < target.length && i < base.length; i++) {
+			if (target[i].equals(base[i])) {
+				common += target[i] + pathSeparator;
+				commonIndex++;
+			} else
+				break;
+		}
+
+		if (commonIndex == 0) {
+			// Whoops -- not even a single common path element. This most
+			// likely indicates differing drive letters, like C: and D:.
+			// These paths cannot be relativized. Return the target path.
+			return file;
+			// This should never happen when all absolute paths
+			// begin with / as in *nix.
+		}
+
+		String relative = "";
+		if (base.length == commonIndex) {
+			// Comment this out if you prefer that a relative path not start
+			// with ./
+			relative = "." + pathSeparator;
+		} else {
+			int numDirsUp = base.length - commonIndex - (isDir ? 0 : 1); /*
+																		 * only
+																		 * subtract
+																		 * 1 if
+																		 * it is
+																		 * a
+																		 * file.
+																		 */
+			// The number of directories we have to backtrack is the length of
+			// the base path MINUS the number of common path elements, minus
+			// one because the last element in the path isn't a directory.
+			for (int i = 1; i <= (numDirsUp); i++) {
+				relative += ".." + pathSeparator;
+			}
+		}
+		// if we are comparing directories then we
+		if (targetPath.length() > common.length()) {
+			// it's OK, it isn't a directory
+			relative += targetPath.substring(common.length());
+		}
+
+		return new File(relative);
+	}
+
+	private void fixFiles(PersistentState state, File rootFolder) {
+		PersistentContext context = state.getContext();
+		URI cwd = new File(System.getProperty("user.dir")).toURI();
+
+		@SuppressWarnings("unchecked")
+		Iterator<PersistentState> statesIterator = context.iterator();
+		while (statesIterator.hasNext()) {
+			PersistentState aState = statesIterator.next();
+			DynStruct definition = aState.getDefinition();
+			DynField[] fields = definition.getDynFields();
+			for (DynField field : fields) {
+				if (field.getType() == DataTypes.FILE
+						|| field.getType() == DataTypes.FOLDER) {
+					try {
+						File value = aState.getFile(field.getName());
+						value = fixFile(value, rootFolder);
+						aState.set(field.getName(), value);
+					} catch (PersistenceException e) {
+						LOG.warn(
+								"Can't fix field '" + field.getName()
+										+ "' for class '"
+										+ definition.getName() + "'.", e);
+					}
+				} else if (field.getType() == DataTypes.URL) {
+					try {
+						URL value = aState.getURL(field.getName());
+						if ("FILE".equalsIgnoreCase(value.getProtocol())) {
+							if (!value.getFile().startsWith("/")){
+								value = new URL("file","",cwd.getRawPath()+value.getFile());
+								File file = new File(value.toURI().getPath().substring(cwd.getPath().length()));
+								file = fixFile(file, rootFolder);
+								aState.set(field.getName(), file.toURI().toURL());
+							}
+						}
+					} catch (PersistenceException e) {
+						// do nothing
+					} catch (MalformedURLException e) {
+						// do nothing
+					} catch (URISyntaxException e) {
+						// do nothing
+					}
+
+				}
+			}
+		}
+	}
+
+	private File fixFile(File file, File rootFolder) {
+		if (file.isAbsolute()) {
+			return file;
+		}
+		return new File(rootFolder, file.getPath()).getAbsoluteFile();
+	}
+
+	public void loadState(InputStream in) {
+		loadState(in, null);
+	}
+
+	public void loadState(InputStream in, File rootFolder) {
+		PersistenceManager manager = ToolsLocator.getPersistenceManager();
+		try {
+			PersistentState state = manager.loadState(in);
+			try {
+				if (rootFolder != null) {
+					fixFiles(state, rootFolder);
+				}
+			} catch (Exception ex) {
+				state.getContext().addError(ex);
+			}
+			this.loadFromState(state);
+		} catch (PersistenceException e) {
+			// TODO Auto-generated catch block
+			e.printStackTrace();
+		}
+
+	}
+
+	public void loadState(File in) {
+		FileInputStream fin;
+		try {
+			fin = new FileInputStream(in);
+			loadState(fin, new File(in.getParent()));
+		} catch (FileNotFoundException e) {
+			// TODO Auto-generated catch block
+			e.printStackTrace();
+		}
+	}
+
+	@SuppressWarnings("unchecked")
+	public void loadFromState(PersistentState state)
+			throws PersistenceException {
+		this.clean();
+
+		this.setComments(state.getString("comments"));
+		this.setCreationDate(state.getString("creationDate"));
+		this.setModificationDate(state.getString("modificationDate"));
+		this.setName(state.getString("name"));
+		this.setOwner(state.getString("owner"));
+		this.setSelectionColor((Color) state.get("selectionColor"));
+		this.setProjection((IProjection) state.get("projection"));
+
+		List<ProjectExtent> extents = (List<ProjectExtent>) state
+				.get("extents");
+		for (int i = 0; i < extents.size(); i++) {
+			this.addExtent(extents.get(i));
+		}
+
+		List<AbstractDocument> documents = (List<AbstractDocument>) state
+				.get("documents");
+		for (int i = 0; i < documents.size(); i++) {
+			this.add(documents.get(i));
+		}
+
+		List<DocumentWindowInfo> persistentWindows = (List<DocumentWindowInfo>) state.get("documentWindowsInformation");
+				
+		for (int i = 0; i < persistentWindows.size(); i++) {
+			DocumentWindowInfo persistentWindow = persistentWindows.get(i);
+			String docName = persistentWindow.getDocumentName();
+			String docType = persistentWindow.getDocumentType();
+			Document doc = this.getDocument(docName, docType);
+			IWindow win = doc.getFactory().getMainWindow(doc);
+			win.getWindowInfo().setWindowInfo(persistentWindow.getWindowInfo());
+			PluginServices.getMDIManager().addWindow(win);
+		}
+		
+		if (state.hasValue("projectWindowInfo")){
+			WindowInfo projectWindowInfo = (WindowInfo)state.get("projectWindowInfo"); 
+			ProjectExtension pe = (ProjectExtension) PluginServices.getExtension(org.gvsig.app.extension.ProjectExtension.class);
+			pe.setProject(this);
+			pe.showProjectWindow(projectWindowInfo);
+		}
+
+	}
+
+	public void saveToState(PersistentState state) throws PersistenceException {
+		state.set("version", VERSION);
+		state.set("comments", getComments());
+		state.set("creationDate", this.getCreationDate());
+
+		state.set("modificationDate", this.getModificationDate());
+		state.set("name", this.getName());
+		state.set("owner", this.getOwner());
+		state.set("selectionColor", this.getSelectionColor());
+
+		state.set("projection", this.getProjection());
+
+		state.set("extents", this.extents);
+		state.set("documents", this.getDocuments());
+
+		List<DocumentWindowInfo> persistentWindows = new ArrayList<DocumentWindowInfo>();
+		MDIManager mdiMan = PluginServices.getMDIManager();
+		IWindow[] windows = mdiMan.getOrderedWindows();
+		for (int i = windows.length - 1; i >= 0; i--) {
+			IWindow window = windows[i];
+			if (window instanceof IDocumentWindow){
+				WindowInfo wi =  mdiMan.getWindowInfo(window);
+				DocumentWindowInfo dwi = new DocumentWindowInfo(
+						wi,
+						((IDocumentWindow) window).getDocument().getTypeName(),
+						((IDocumentWindow) window).getDocument().getName());
+				persistentWindows.add(dwi);
+			} else if (window instanceof ProjectWindow){
+				state.set("projectWindowInfo", mdiMan.getWindowInfo(window));
+			}
+		}
+		state.set("documentWindowsInformation", persistentWindows);
+
+	}
+
+	public static class DocumentWindowInfo implements Persistent {
+
+		public static final String PERSISTENCE_DEFINITION_NAME = "DocumentWindowInfo";
+
+		private WindowInfo windowInfo;
+		private String documentType;
+		private String documentName;
+
+		public DocumentWindowInfo(){
+		}
+		
+		DocumentWindowInfo(WindowInfo wi, String docType, String docName){
+			windowInfo = wi;
+			documentType = docType;
+			documentName = docName;
+		}
+
+		public WindowInfo getWindowInfo() {
+			return windowInfo;
+		}
+		
+		public String getDocumentType() {
+			return documentType;
+		}
+
+		public String getDocumentName() {
+			return documentName;
+		}
+
+		public void saveToState(PersistentState state)
+				throws PersistenceException {
+			state.set("windowInfo", this.windowInfo);
+			state.set("documentType", this.documentType);
+			state.set("documentName", this.documentName);
+		}
+
+		public void loadFromState(PersistentState state)
+				throws PersistenceException {
+			this.windowInfo = (WindowInfo) state.get("windowInfo");
+			this.documentType = state.getString("documentType");
+			this.documentName = state.getString("documentName");
+		}
+		
+		public static void registerPersistent() {
+			PersistenceManager manager = ToolsLocator.getPersistenceManager();
+			DynStruct definition = manager.getDefinition(PERSISTENCE_DEFINITION_NAME);
+			if ( definition == null ){
+				definition = manager.addDefinition(
+						DocumentWindowInfo.class,
+						PERSISTENCE_DEFINITION_NAME,
+						"DocumentWindowInfo persistence definition",
+						null, 
+						null
+				);
+				definition.addDynFieldObject("windowInfo").setMandatory(true).setClassOfValue(WindowInfo.class);
+				definition.addDynFieldString("documentType").setMandatory(true);
+				definition.addDynFieldString("documentName").setMandatory(true);
+			}
+
+		}
+	}
+	
+	public static void registerPersistent() {
+		AbstractDocument.registerPersistent();
+		DocumentWindowInfo.registerPersistent();
+
+		PersistenceManager manager = ToolsLocator.getPersistenceManager();
+		DynStruct definition = manager.addDefinition(DefaultProject.class,
+				"Project", "Project Persistence definition", null, null);
+		definition.addDynFieldString("version").setMandatory(true);
+		definition.addDynFieldString("comments").setMandatory(true);
+		definition.addDynFieldString("creationDate").setMandatory(true);
+		definition.addDynFieldString("modificationDate").setMandatory(true);
+		definition.addDynFieldString("name").setMandatory(true);
+		definition.addDynFieldString("owner").setMandatory(true);
+
+		definition.addDynFieldObject("selectionColor")
+				.setClassOfValue(Color.class).setMandatory(true);
+		definition.addDynFieldObject("projection")
+				.setClassOfValue(IProjection.class).setMandatory(true);
+
+		definition.addDynFieldList("extents")
+				.setClassOfItems(ProjectExtent.class).setMandatory(true);
+
+		definition.addDynFieldList("documents").setClassOfItems(Document.class)
+				.setMandatory(true);
+
+		definition.addDynFieldObject("projectWindowInfo").setClassOfValue(WindowInfo.class).setMandatory(false);
+
+		definition.addDynFieldList("documentWindowsInformation").setClassOfItems(WindowInfo.class).setMandatory(false);
+
+	}
+
+	/**
+	 * @deprecated use getPreferences().setDefaultSelectionColor()
+	 */
+	public static void setDefaultSelectionColor(Color color) {
+		getPreferences().setDefaultSelectionColor(color);
+	}
+
+	/**
+	 * @deprecated use getPreferences().getDefaultSelectionColor()
+	 */
+
+	public static Color getDefaultSelectionColor() {
+		return getPreferences().getDefaultSelectionColor();
+	}
+
+	/**
+	 * @deprecated use getPreferences().getDefaultMapUnits()
+	 */
+	public static int getDefaultMapUnits() {
+		return getPreferences().getDefaultMapUnits();
+	}
+
+	/**
+	 * @deprecated use getPreferences().getDefaultDistanceUnits()
+	 */
+	public static int getDefaultDistanceUnits() {
+		return getPreferences().getDefaultDistanceUnits();
+	}
+
+	/**
+	 * @deprecated use getPreferences().getDefaultDistanceArea()
+	 */
+	public static int getDefaultDistanceArea() {
+		return getPreferences().getDefaultDistanceArea();
+	}
+
+	/**
+	 * @deprecated use getPreferences().setDefaultMapUnits()
+	 */
+	public static void setDefaultMapUnits(int mapUnits) {
+		getPreferences().setDefaultMapUnits(mapUnits);
+	}
+
+	/**
+	 * @deprecated use getPreferences().setDefaultDistanceUnits()
+	 */
+	public static void setDefaultDistanceUnits(int distanceUnits) {
+		getPreferences().setDefaultDistanceUnits(distanceUnits);
+	}
+
+	/**
+	 * @deprecated use getPreferences().setDefaultDistanceArea()
+	 */
+	public static void setDefaultDistanceArea(int distanceArea) {
+		getPreferences().setDefaultDistanceArea(distanceArea);
+	}
+
+	/**
+	 * @deprecated use getPreferences().setDefaultProjection()
+	 */
+	public static void setDefaultProjection(IProjection defaultProjection) {
+		getPreferences().setDefaultProjection(defaultProjection);
+	}
+
+	/**
+	 * @deprecated use getPreferences().getDefaultProjection()
+	 */
+	public static IProjection getDefaultProjection() {
+		return getPreferences().getDefaultProjection();
+	}
+
+	/**
+	 * @deprecated see {@link #setSelectionColor(String)}, to be remove in gvSIG
+	 *             2.1.0
+	 */
+	public void setColor(String color) {
+		this.setSelectionColor(StringUtilities.string2Color(color));
+	}
+
+	/**
+	 * Return the selection color
+	 * 
+	 * @return selection color as string
+	 * @deprecated use {@link #getSelectionColor()}
+	 */
+	public String getColor() {
+		return StringUtilities.color2String(selectionColor);
+	}
+
+	/**
+	 * Return the list of views of the project
+	 * 
+	 * @return views as ArrayList of ProjectDocument
+	 * 
+	 * @deprecated see {@link #getDocumentsByType(String)}
+	 */
+	public List<Document> getViews() {
+		return getDocuments(ViewManager.TYPENAME);
+	}
+
+	/**
+	 * Add a view to the project
+	 * 
+	 * @deprecated see {@link #add(AbstractDocument)}
+	 */
+	public void addView(DefaultViewDocument v) {
+		add(v);
+	}
+
+	/**
+	 * Remove a view of the project
+	 * 
+	 * @param index
+	 *            of the view as integer
+	 * 
+	 * @deprecated see {@link #remove(AbstractDocument)}
+	 */
+	public void delView(int i) {
+		List<Document> list = getDocuments(ViewManager.TYPENAME);
+		remove(list.get(i));
+	}
+
+	/**
+	 * @deprecated see {@link #getDocument(String, String)}
+	 */
+	public Document getProjectDocumentByName(String name, String type) {
+		return this.getDocument(name, type);
+	}
+
+	/**
+	 * @deprecated see {@link #getDocuments(String)}
+	 */
+	public List<Document> getDocumentsByType(String type) {
+		return this.getDocuments(type);
+	}
+
+	/**
+	 * @deprecated aun por decidir que API darle al copy/paste
+	 */
+	public String exportToXML(AbstractDocument[] selectedItems)
+			throws SaveException {
+		// FIXME jjdc:hay que decirdir que API darle al copy/paste
+		throw new UnsupportedOperationException("This method is not supported");
+	}
+
+	/**
+	 * @deprecated aun por decidir que API darle al copy/paste
+	 */
+	public void importFromXML(String sourceString, String docType) {
+		// FIXME jjdc:hay que decirdir que API darle al copy/paste
+		throw new UnsupportedOperationException("This method is not supported");
+	}
+
+	/**
+	 * @deprecated aun por decidir que API darle al copy/paste
+	 */
+	public boolean isValidXMLForImport(String sourceString, String docType) {
+		// FIXME jjdc:hay que decirdir que API darle al copy/paste
+		throw new UnsupportedOperationException("This method is not supported");
+	}
+
+	public boolean canImportDocuments(String data, String doctype) {
+		// TODO Auto-generated method stub
+		return false;
+	}
+
+	public String exportDocumentsAsText(List<Document> documents) {
+		// TODO Auto-generated method stub
+		return null;
+	}
+
+	public void importDocuments(String data, String doctype) {
+		// TODO Auto-generated method stub
+
+	}
+
+	public Document getActiveDocument() {
+		ApplicationManager application = ApplicationLocator.getManager();
+
+		Document document = null;
+		IWindow[] windows = application.getUIManager().getOrderedWindows();
+		IWindow window = null;
+		for (int i = 0; i < windows.length; i++) {
+		    window = windows[i];
+			if (window instanceof SingletonWindow) {
+				// Cogemos no la primera ventana, si no la primera
+				// ventana de tipo documento (SingletonWindow).
+				// Y por si las mosca no es un documento, atrapamos
+				// los errores y continuamos si no puede hacer un cast
+				// del Model a Document
+				try {
+					document = (Document) ((SingletonWindow) window).getWindowModel();
+					return document;
+				} catch (ClassCastException e) {
+					// Do nothing, skip this window
+				}
+			}
+		}
+		return null;
+	} 
+}

Property changes on: tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/app/project/DefaultProject.java
___________________________________________________________________
Added: svn:mime-type
   + text/plain

Index: tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/app/project/ProjectExtent.java
===================================================================
--- tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/app/project/ProjectExtent.java	(revision 0)
+++ tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/app/project/ProjectExtent.java	(revision 38653)
@@ -0,0 +1,147 @@
+/* gvSIG. Geographic Information System of the Valencian Government
+*
+* Copyright (C) 2007-2009 Infrastructures and Transports Department
+* of the Valencian Government (CIT)
+* 
+* This program is free software; you can redistribute it and/or
+* modify it under the terms of the GNU General Public License
+* as published by the Free Software Foundation; either version 2
+* of the License, or (at your option) any later version.
+* 
+* This program is distributed in the hope that it will be useful,
+* but WITHOUT ANY WARRANTY; without even the implied warranty of
+* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
+* GNU General Public License for more details.
+* 
+* You should have received a copy of the GNU General Public License
+* along with this program; if not, write to the Free Software
+* Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, 
+* MA  02110-1301, USA.
+* 
+*/
+
+/*
+* AUTHORS (In addition to CIT):
+* 2004-2009 IVER TI
+*   
+*/
+package org.gvsig.app.project;
+
+import java.awt.geom.Rectangle2D;
+
+import org.gvsig.fmap.geom.Geometry;
+import org.gvsig.fmap.geom.GeometryLocator;
+import org.gvsig.fmap.geom.GeometryManager;
+import org.gvsig.fmap.geom.exception.CreateEnvelopeException;
+import org.gvsig.fmap.geom.primitive.Envelope;
+import org.gvsig.fmap.geom.primitive.Point;
+import org.gvsig.tools.persistence.Persistent;
+import org.gvsig.tools.persistence.PersistentState;
+import org.gvsig.tools.persistence.exception.PersistenceException;
+import org.slf4j.Logger;
+import org.slf4j.LoggerFactory;
+
+
+/**
+ *
+ * @author 2006-2009 Jose Manuel Vivo
+ * @author 2005-         Vicente Caballero
+ * @author 2009-         Joaquin del Cerro
+ * 
+ */
+
+public class ProjectExtent implements Persistent {
+	private static final GeometryManager geomManager = GeometryLocator.getGeometryManager();
+	private static final Logger logger = LoggerFactory.getLogger(ProjectExtent.class);
+
+	private Envelope extent;
+    private String description;
+
+    public ProjectExtent() {
+    	this.extent = null;
+    	this.description = null;
+    }
+    
+    public String getDescription() {
+        return description;
+    }
+
+    public void setDescription(String string) {
+        description = string;
+    }
+
+    public Envelope getExtent() {
+    	if( this.extent == null ) {
+    		try {
+				this.extent = geomManager.createEnvelope(Geometry.SUBTYPES.GEOM2D);
+			} catch (CreateEnvelopeException e) {
+				logger.warn("Can't create envelop.", e);
+			}
+    	}
+    	return this.extent;
+    }
+
+    public void setExtent(Envelope envelope) {
+        this.extent = envelope;
+    }
+
+    /**
+     * @deprecated use {link {@link #setExtent(Envelope)}
+     */
+    public void setExtent(Rectangle2D rectangle2D) {
+        try {
+			this.extent = geomManager.createEnvelope(
+					rectangle2D.getMinX(),
+					rectangle2D.getMinY(),
+					rectangle2D.getMaxX(),
+					rectangle2D.getMaxY(),
+					Geometry.SUBTYPES.GEOM2D);
+		} catch (CreateEnvelopeException e) {
+			logger.warn("Can't create envelope.", e);
+			throw new RuntimeException("Can't create envelope.",e);
+		}
+    }
+
+    public String getEncuadre() {
+    	Point lower = extent.getLowerCorner();
+    	Point upper = extent.getUpperCorner();
+    	return lower.getX() + "," + lower.getY() + "," + upper.getX() + "," + upper.getY(); 
+    }
+
+    public void setEncuadre(String encuadre) {
+        String[] coords = encuadre.split(",");
+        try {
+			this.extent = geomManager.createEnvelope(
+					Double.parseDouble(coords[0]),
+					Double.parseDouble(coords[1]),
+					Double.parseDouble(coords[2]),
+					Double.parseDouble(coords[3]),
+					Geometry.SUBTYPES.GEOM2D);
+		} catch (NumberFormatException e) {
+			logger.warn("Incorrect format string.", e);
+			throw new RuntimeException("Incorrect format string.",e);
+		} catch (CreateEnvelopeException e) {
+			logger.warn("Can't create envelope.", e);
+			throw new RuntimeException("Can't create envelope.",e);
+		}
+    }
+
+    /**
+     * @see java.lang.Object#toString()
+     */
+    public String toString() {
+        return description;
+    }
+
+    public void loadFromState(PersistentState state)
+			throws PersistenceException {
+		this.extent = (Envelope) state.get("envelope");
+		this.description = state.getString("description");
+	}
+
+	public void saveToState(PersistentState state) throws PersistenceException {
+        state.set("description", description);
+        state.set("envelope", extent);
+	}
+
+}

Property changes on: tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/app/project/ProjectExtent.java
___________________________________________________________________
Added: svn:keywords
   + Author Date Id Revision
Added: svn:eol-style
   + native

Index: tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/app/project/ProjectManager.java
===================================================================
--- tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/app/project/ProjectManager.java	(revision 0)
+++ tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/app/project/ProjectManager.java	(revision 38653)
@@ -0,0 +1,283 @@
+/* gvSIG. Geographic Information System of the Valencian Government
+ *
+ * Copyright (C) 2007-2008 Infrastructures and Transports Department
+ * of the Valencian Government (CIT)
+ * 
+ * This program is free software; you can redistribute it and/or
+ * modify it under the terms of the GNU General Public License
+ * as published by the Free Software Foundation; either version 2
+ * of the License, or (at your option) any later version.
+ * 
+ * This program is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
+ * GNU General Public License for more details.
+ * 
+ * You should have received a copy of the GNU General Public License
+ * along with this program; if not, write to the Free Software
+ * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, 
+ * MA  02110-1301, USA.
+ * 
+ */
+package org.gvsig.app.project;
+
+import java.text.MessageFormat;
+import java.util.ArrayList;
+import java.util.Collections;
+import java.util.Comparator;
+import java.util.HashMap;
+import java.util.Iterator;
+import java.util.List;
+import java.util.Map;
+
+import org.slf4j.Logger;
+import org.slf4j.LoggerFactory;
+
+import org.gvsig.andami.PluginServices;
+import org.gvsig.app.extension.ProjectExtension;
+import org.gvsig.app.project.documents.DefaultDocumentActionGroup;
+import org.gvsig.app.project.documents.Document;
+import org.gvsig.app.project.documents.DocumentAction;
+import org.gvsig.app.project.documents.DocumentActionGroup;
+import org.gvsig.app.project.documents.DocumentManager;
+import org.gvsig.app.project.documents.gui.ProjectWindow;
+import org.gvsig.tools.ToolsLocator;
+import org.gvsig.tools.extensionpoint.ExtensionPoint;
+import org.gvsig.tools.extensionpoint.ExtensionPoint.Extension;
+import org.gvsig.tools.extensionpoint.ExtensionPointManager;
+import org.gvsig.tools.observer.impl.BaseWeakReferencingObservable;
+
+public class ProjectManager extends BaseWeakReferencingObservable {
+
+    private static final Logger logger = LoggerFactory
+        .getLogger(ProjectManager.class);
+    private static ProjectManager factory = null;
+
+    // private static final String KEY_PROJECT = "app.project";
+    // private static final String KEY_DOCUMENTS = "app.project.documents";
+    private static final String KEY_DOCUMENTS_FACTORIES =
+        "app.project.documents.factories";
+    private static final String KEY_DOCUMENTS_ACTIONS =
+        "app.project.documents.actions";
+
+    private Map<String, DocumentActionGroup> documentActionGroups;
+
+    public static ProjectManager getInstance() {
+        if (factory == null) {
+            factory = new ProjectManager();
+        }
+        return factory;
+    }
+
+    private ProjectManager() {
+        this.documentActionGroups = new HashMap<String, DocumentActionGroup>();
+    }
+
+    public Project getCurrentProject() {
+        return ((ProjectExtension) PluginServices
+            .getExtension(ProjectExtension.class)).getProject();
+    }
+
+    public ProjectWindow getCurrentProjectWindow() {
+        ProjectExtension projectExtension =
+            (ProjectExtension) PluginServices
+                .getExtension(ProjectExtension.class);
+        ProjectWindow window =
+            (ProjectWindow) projectExtension.getProjectWindow();
+        return window;
+    }
+
+    /**
+     * @deprecated use {@link #getDocumentManagers()} instead.
+     */
+    public List<DocumentManager> getDocumentManager() {
+        return getDocumentManagers();
+    }
+
+    @SuppressWarnings("unchecked")
+    public List<DocumentManager> getDocumentManagers() {
+        Iterator<Extension> iterator =
+            ToolsLocator.getExtensionPointManager()
+                .get(KEY_DOCUMENTS_FACTORIES).iterator();
+        List<DocumentManager> factories = new ArrayList<DocumentManager>();
+        while (iterator.hasNext()) {
+            Extension extension = iterator.next();
+            try {
+                factories.add((DocumentManager) extension.create());
+            } catch (InstantiationException e) {
+                logger.error("Can't access to project document factory ("
+                    + extension.getName() + ").");
+            } catch (IllegalAccessException e) {
+                logger.error("Can't access to project document factory ("
+                    + extension.getName() + ").");
+            }
+        }
+        return factories;
+    }
+
+    /**
+     * @deprecated use {@link #getDocumentManager(String)} instead.
+     */
+    public DocumentManager getDocumentManagers(String type) {
+        return getDocumentManager(type);
+    }
+
+    public DocumentManager getDocumentManager(String type) {
+        DocumentManager factory = null;
+        try {
+            factory =
+                (DocumentManager) ToolsLocator.getExtensionPointManager()
+                    .get(KEY_DOCUMENTS_FACTORIES).create(type);
+        } catch (Exception ex) {
+            logger
+                .warn(
+                    MessageFormat.format(
+                        "Unable to locate factory for documents of type {0}",
+                        type), ex);
+        }
+        return factory;
+    }
+
+    public Document createDocument(String type) {
+        Document doc = getDocumentManager(type).createDocument();
+        return doc;
+    }
+
+    public Document createDocument(String type, String name) {
+        Document doc = createDocument(type);
+        doc.setName(name);
+        return doc;
+    }
+
+    /**
+     * @deprecated use {@link #createDocumentsByUser(String)} instead
+     */
+    public Document createDocumentByUser(String type) {
+        Document doc = getDocumentManager(type).createDocumentByUser();
+        return doc;
+    }
+
+    /**
+     * Creates a group of documents of a given type through the user interface.
+     * 
+     * @param type
+     *            the type of documents to create
+     * @return the created documents
+     */
+    public Iterator<? extends Document> createDocumentsByUser(String type) {
+        logger.info("createDocumentsByUser('{}')", type);
+        return getDocumentManager(type).createDocumentsByUser();
+    }
+
+    public Project createProject() {
+        return new DefaultProject();
+    }
+
+    public ProjectExtent createExtent() {
+        return new ProjectExtent();
+    }
+
+    public void registerDocumentFactory(DocumentManager documentManager) {
+        ExtensionPointManager manager = ToolsLocator.getExtensionPointManager();
+        manager.add(KEY_DOCUMENTS_FACTORIES).append(
+            documentManager.getTypeName(), null, documentManager);
+        notifyObservers();
+    }
+
+    public void registerDocumentFactoryAlias(String typeName, String alias) {
+        ExtensionPointManager manager = ToolsLocator.getExtensionPointManager();
+
+        manager.get(KEY_DOCUMENTS_FACTORIES).addAlias(typeName, alias);
+    }
+
+    public void registerDocumentAction(String typeName, DocumentAction action) {
+        ExtensionPointManager manager = ToolsLocator.getExtensionPointManager();
+
+        String key = KEY_DOCUMENTS_ACTIONS + "." + typeName;
+        String description =
+            MessageFormat.format("Actions for {1} documents ", typeName);
+
+        manager.add(key, description).append(action.getId(),
+            action.getDescription(), action);
+    }
+
+    /**
+     * Gets a list of actions for the document type especified.
+     * 
+     * La lista esta ordenada deacuerdo al orden especificado en
+     * las acciones y grupos de acciones involucrados.
+     * 
+     * @param doctype
+     * @return list of actions as List<DocumentAction>
+     */
+    @SuppressWarnings("unchecked")
+    public List<DocumentAction> getDocumentActions(String doctype) {
+
+        ExtensionPointManager manager = ToolsLocator.getExtensionPointManager();
+
+        String key = KEY_DOCUMENTS_ACTIONS + "." + doctype;
+        ExtensionPoint extensionPoint = manager.get(key);
+        if (extensionPoint == null) {
+            // No hay acciones registradas para ese tipo de documento
+            return null;
+        }
+        List<DocumentAction> actions = new ArrayList<DocumentAction>();
+        Iterator<Extension> it = extensionPoint.iterator();
+        while (it.hasNext()) {
+            try {
+                DocumentAction action;
+                action = (DocumentAction) it.next().create();
+                actions.add(action);
+            } catch (InstantiationException e) {
+                logger.warn("Can't retrieve document action", e);
+            } catch (IllegalAccessException e) {
+                logger.warn("Can't retrieve document action", e);
+            }
+        }
+        if (actions.size() < 1) {
+            return null;
+        }
+        Collections.sort(actions, new CompareAction());
+        return actions;
+    }
+
+    private class CompareAction implements Comparator<DocumentAction> {
+
+        public int compare(DocumentAction action1, DocumentAction action2) {
+            // FIXME: flata formatear los enteros!!!!
+            String key1 =
+                MessageFormat.format("{1}.{2}.{3}", action1.getGroup()
+                    .getOrder(), action1.getGroup().getTitle(), action1
+                    .getOrder());
+            String key2 =
+                MessageFormat.format("{1}.{2}.{3}", action2.getGroup()
+                    .getOrder(), action2.getGroup().getTitle(), action2
+                    .getOrder());
+            return key1.compareTo(key2);
+        }
+    }
+
+    /**
+     * Create, add and return a new action for documents.
+     * 
+     * If action already exists don't create and return this.
+     * 
+     * @param unique
+     *            identifier for the action
+     * @param title
+     * @param description
+     * @param order
+     * @return
+     */
+    public DocumentActionGroup addDocumentActionGroup(String id, String title,
+        String description, int order) {
+        DocumentActionGroup group = this.documentActionGroups.get(id);
+        if (group != null) {
+            return group;
+        }
+        group = new DefaultDocumentActionGroup(id, title, description, order);
+        this.documentActionGroups.put(id, group);
+        return group;
+    }
+
+}

Property changes on: tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/app/project/ProjectManager.java
___________________________________________________________________
Added: svn:eol-style
   + native
Added: svn:keywords
   + Author Date Id Revision

Index: tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/app/project/documents/AbstractDocumentAction.java
===================================================================
--- tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/app/project/documents/AbstractDocumentAction.java	(revision 0)
+++ tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/app/project/documents/AbstractDocumentAction.java	(revision 38653)
@@ -0,0 +1,54 @@
+package org.gvsig.app.project.documents;
+
+import java.util.Arrays;
+
+import org.gvsig.app.project.ProjectManager;
+
+
+public abstract class AbstractDocumentAction implements DocumentAction {
+
+	private String id;
+	protected DocumentActionGroup group;
+	protected String title; 
+	protected String description;
+	protected int order;
+	
+	public AbstractDocumentAction(String id) {
+		this.group = ProjectManager.getInstance().addDocumentActionGroup("default","Default action group", null, 1000);
+		this.id = id;
+		this.title= id;
+		this.description = null;
+		this.order = 1000;
+	}
+
+	public AbstractDocumentAction(DocumentActionGroup group, String id, String title, String description, int order) {
+		this(id);
+		if( group!= null ) {
+			this.group = group;
+		}
+		this.title= title;
+		this.description = description;
+		this.order = order;
+	}
+	
+	public String getDescription() {
+		return this.description;
+	}
+
+	public DocumentActionGroup getGroup() {
+		return this.group;
+	}
+
+	public String getId() {
+		return this.id;
+	}
+
+	public int getOrder() {
+		return this.order;
+	}
+
+	public String getTitle() {
+		return this.title;
+	}
+
+}

Property changes on: tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/app/project/documents/AbstractDocumentAction.java
___________________________________________________________________
Added: svn:mime-type
   + text/plain

Index: tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/app/project/documents/actions/CopyDocumentAction.java
===================================================================
--- tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/app/project/documents/actions/CopyDocumentAction.java	(revision 0)
+++ tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/app/project/documents/actions/CopyDocumentAction.java	(revision 38653)
@@ -0,0 +1,41 @@
+package org.gvsig.app.project.documents.actions;
+
+import java.util.ArrayList;
+import java.util.List;
+
+import org.gvsig.andami.PluginServices;
+import org.gvsig.app.project.Project;
+import org.gvsig.app.project.ProjectManager;
+import org.gvsig.app.project.documents.AbstractDocumentAction;
+import org.gvsig.app.project.documents.Document;
+
+
+public class CopyDocumentAction extends AbstractDocumentAction {
+
+	public CopyDocumentAction() {
+		super("copy");
+		this.order = 0;
+		this.title =PluginServices.getText(this, "copiar");
+		this.group = ProjectManager.getInstance().addDocumentActionGroup("ClipboardActions", "Clipboard actions", null, 0);
+	}
+	
+	public void execute(Document document, List<Document> documents) {
+		Project project = ProjectManager.getInstance().getCurrentProject();
+		
+		List<Document> docs = new ArrayList<Document>(documents);
+		if( !docs.contains(documents)) {
+			docs.add(document);
+		}
+		String data = project.exportDocumentsAsText(docs);
+		PluginServices.putInClipboard(data);
+	}
+	
+	public boolean isAvailable(Document document, List<Document> documents) {
+		return true;
+	}
+
+	public boolean isVisible(Document document, List<Document> documents) {
+		return true;
+	}
+
+}

Property changes on: tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/app/project/documents/actions/CopyDocumentAction.java
___________________________________________________________________
Added: svn:mime-type
   + text/plain

Index: tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/app/project/documents/actions/CutDocumentAction.java
===================================================================
--- tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/app/project/documents/actions/CutDocumentAction.java	(revision 0)
+++ tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/app/project/documents/actions/CutDocumentAction.java	(revision 38653)
@@ -0,0 +1,88 @@
+package org.gvsig.app.project.documents.actions;
+
+import java.awt.Component;
+import java.util.ArrayList;
+import java.util.List;
+
+import javax.swing.JOptionPane;
+
+import org.gvsig.andami.PluginServices;
+import org.gvsig.app.project.Project;
+import org.gvsig.app.project.ProjectManager;
+import org.gvsig.app.project.documents.AbstractDocumentAction;
+import org.gvsig.app.project.documents.Document;
+
+
+public class CutDocumentAction extends AbstractDocumentAction {
+	
+	public CutDocumentAction() {
+		super("cut");
+		this.order = 0;
+		this.title =PluginServices.getText(this, "cortar");
+		this.group = ProjectManager.getInstance().addDocumentActionGroup("ClipboardActions", "Clipboard actions", null, 0);
+	}
+	
+
+	public int getOrder() {
+		return 1;
+	}
+
+	public boolean isVisible(Document item, List<Document> selectedItems) {
+		return true;
+	}
+
+	public boolean isAvailable(Document item, List<Document> selectedItems) {
+		return selectedItems.size() > 0;
+	}
+
+	public void execute(Document document, List<Document> documents) {
+		
+		Project project = ProjectManager.getInstance().getCurrentProject();
+		
+		List<Document> docs = new ArrayList<Document>(documents);
+		if( !docs.contains(documents)) {
+			docs.add(document);
+		}
+		String data = project.exportDocumentsAsText(docs);
+		PluginServices.putInClipboard(data);
+
+
+		for (Document doc : documents) {
+			if (doc.isLocked()) {
+				JOptionPane.showMessageDialog(
+						(Component)PluginServices.getMainFrame(),
+						PluginServices.getText(this, "locked_element_it_cannot_be_deleted") + ": " +doc.getName()
+				);
+				return;
+			}
+		}
+
+    	int option=JOptionPane.showConfirmDialog(
+    			(Component)PluginServices.getMainFrame(),
+    			PluginServices.getText(this,"desea_borrar_el_documento")
+    	);
+    	if (option!=JOptionPane.OK_OPTION) {
+    		return;
+    	}
+
+		this.removeDocuments(documents,project);
+
+	}
+
+	private boolean removeDocuments(List<Document> selectedItems,Project project) {
+		for (Document document : selectedItems) {
+			if (document.isLocked()) {
+				JOptionPane.showMessageDialog(
+						(Component)PluginServices.getMainFrame(),
+						PluginServices.getText(this, "locked_element_it_cannot_be_deleted") + ": " +document.getName()
+				);
+			} else {
+				PluginServices.getMDIManager().closeSingletonWindow(document);
+				project.remove(document);
+			}
+		}
+		return true;
+	}
+
+
+}

Property changes on: tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/app/project/documents/actions/CutDocumentAction.java
___________________________________________________________________
Added: svn:mime-type
   + text/plain

Index: tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/app/project/documents/actions/PasteDocumentAction.java
===================================================================
--- tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/app/project/documents/actions/PasteDocumentAction.java	(revision 0)
+++ tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/app/project/documents/actions/PasteDocumentAction.java	(revision 38653)
@@ -0,0 +1,54 @@
+package org.gvsig.app.project.documents.actions;
+
+import java.util.List;
+
+import org.gvsig.andami.PluginServices;
+import org.gvsig.app.project.Project;
+import org.gvsig.app.project.ProjectManager;
+import org.gvsig.app.project.documents.AbstractDocumentAction;
+import org.gvsig.app.project.documents.Document;
+import org.gvsig.app.project.documents.gui.ProjectWindow;
+
+
+public class PasteDocumentAction extends AbstractDocumentAction {
+
+
+	public PasteDocumentAction() {
+		super("paste");
+		this.order = 0;
+		this.title =PluginServices.getText(this, "pegar");
+		this.group = ProjectManager.getInstance().addDocumentActionGroup("ClipboardActions", "Clipboard actions", null, 0);
+	}
+	
+	public void execute(Document document, List<Document> documents) {
+		String data = PluginServices.getFromClipboard();
+		if (data == null) {
+			return;
+		}
+		ProjectWindow window = ProjectManager.getInstance().getCurrentProjectWindow();
+		Project project = window.getProject();
+		project.importDocuments(
+				data,
+				window.getDocumentSelected()
+		);
+	}
+	
+	public boolean isAvailable(Document document, List<Document> documents) {
+		String data = PluginServices.getFromClipboard();
+		if (data == null) {
+			return false;
+		}
+		ProjectWindow window = ProjectManager.getInstance().getCurrentProjectWindow();
+		Project project = window.getProject();
+		return project.canImportDocuments(
+				data,
+				window.getDocumentSelected()
+		);
+	}
+
+	public boolean isVisible(Document document, List<Document> documents) {
+		return true;
+	}
+
+	
+}

Property changes on: tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/app/project/documents/actions/PasteDocumentAction.java
___________________________________________________________________
Added: svn:mime-type
   + text/plain

Index: tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/app/project/documents/exceptions/SaveException.java
===================================================================
--- tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/app/project/documents/exceptions/SaveException.java	(revision 0)
+++ tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/app/project/documents/exceptions/SaveException.java	(revision 38653)
@@ -0,0 +1,72 @@
+/* gvSIG. Sistema de Informaci�n Geogr�fica de la Generalitat Valenciana
+ *
+ * Copyright (C) 2004 IVER T.I. and Generalitat Valenciana.
+ *
+ * This program is free software; you can redistribute it and/or
+ * modify it under the terms of the GNU General Public License
+ * as published by the Free Software Foundation; either version 2
+ * of the License, or (at your option) any later version.
+ *
+ * This program is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
+ * GNU General Public License for more details.
+ *
+ * You should have received a copy of the GNU General Public License
+ * along with this program; if not, write to the Free Software
+ * Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA  02111-1307,USA.
+ *
+ * For more information, contact:
+ *
+ *  Generalitat Valenciana
+ *   Conselleria d'Infraestructures i Transport
+ *   Av. Blasco Ib��ez, 50
+ *   46010 VALENCIA
+ *   SPAIN
+ *
+ *      +34 963862235
+ *   gvsig@gva.es
+ *      www.gvsig.gva.es
+ *
+ *    or
+ *
+ *   IVER T.I. S.A
+ *   Salamanca 50
+ *   46005 Valencia
+ *   Spain
+ *
+ *   +34 963163400
+ *   dac@iver.es
+ */
+package org.gvsig.app.project.documents.exceptions;
+
+import java.util.Map;
+
+import org.gvsig.andami.messages.NotificationManager;
+import org.gvsig.utils.XMLException;
+
+
+public class SaveException extends XMLException {
+	private Exception e;
+	private String c;
+	public SaveException(Exception e, String c) {
+		this.e=e;
+		this.c=c;
+	}
+	public SaveException() {
+		// TODO Auto-generated constructor stub
+	}
+	public void showError(){
+		NotificationManager.addError("Fallo guardando el Proyecto en : "+c,e);
+	}
+	public void showInfo(){
+		NotificationManager.addInfo("Guardando el Proyecto en : "+c,e);
+	}
+	public void showWarning(){
+		NotificationManager.addWarning("Guardando el Proyecto en : "+c,e);
+	}
+	protected Map values() {
+		// TODO Auto-generated method stub
+		return null;
+	}
+}

Property changes on: tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/app/project/documents/exceptions/SaveException.java
___________________________________________________________________
Added: svn:keywords
   + Author Date Id Revision
Added: svn:eol-style
   + native

Index: tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/app/project/documents/exceptions/NameException.java
===================================================================
--- tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/app/project/documents/exceptions/NameException.java	(revision 0)
+++ tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/app/project/documents/exceptions/NameException.java	(revision 38653)
@@ -0,0 +1,52 @@
+package org.gvsig.app.project.documents.exceptions;
+
+/**
+ * Excepci�n que indica un conflicto de nombres en los elementos del 
+ * proyecto
+ *
+ * @author Fernando Gonz�lez Cort�s
+ */
+public class NameException extends RuntimeException {
+	/**
+	 *
+	 */
+	public NameException() {
+		super();
+
+		// TODO Auto-generated constructor stub
+	}
+
+	/**
+	 * DOCUMENT ME!
+	 *
+	 * @param message
+	 */
+	public NameException(String message) {
+		super(message);
+
+		// TODO Auto-generated constructor stub
+	}
+
+	/**
+	 * DOCUMENT ME!
+	 *
+	 * @param message
+	 * @param cause
+	 */
+	public NameException(String message, Throwable cause) {
+		super(message, cause);
+
+		// TODO Auto-generated constructor stub
+	}
+
+	/**
+	 * DOCUMENT ME!
+	 *
+	 * @param cause
+	 */
+	public NameException(Throwable cause) {
+		super(cause);
+
+		// TODO Auto-generated constructor stub
+	}
+}

Property changes on: tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/app/project/documents/exceptions/NameException.java
___________________________________________________________________
Added: svn:keywords
   + Author Date Id Revision
Added: svn:eol-style
   + native

Index: tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/app/project/documents/exceptions/OpenException.java
===================================================================
--- tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/app/project/documents/exceptions/OpenException.java	(revision 0)
+++ tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/app/project/documents/exceptions/OpenException.java	(revision 38653)
@@ -0,0 +1,75 @@
+/* gvSIG. Sistema de Informaci�n Geogr�fica de la Generalitat Valenciana
+ *
+ * Copyright (C) 2004 IVER T.I. and Generalitat Valenciana.
+ *
+ * This program is free software; you can redistribute it and/or
+ * modify it under the terms of the GNU General Public License
+ * as published by the Free Software Foundation; either version 2
+ * of the License, or (at your option) any later version.
+ *
+ * This program is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
+ * GNU General Public License for more details.
+ *
+ * You should have received a copy of the GNU General Public License
+ * along with this program; if not, write to the Free Software
+ * Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA  02111-1307,USA.
+ *
+ * For more information, contact:
+ *
+ *  Generalitat Valenciana
+ *   Conselleria d'Infraestructures i Transport
+ *   Av. Blasco Ib��ez, 50
+ *   46010 VALENCIA
+ *   SPAIN
+ *
+ *      +34 963862235
+ *   gvsig@gva.es
+ *      www.gvsig.gva.es
+ *
+ *    or
+ *
+ *   IVER T.I. S.A
+ *   Salamanca 50
+ *   46005 Valencia
+ *   Spain
+ *
+ *   +34 963163400
+ *   dac@iver.es
+ */
+package org.gvsig.app.project.documents.exceptions;
+
+import java.util.Map;
+
+import org.gvsig.andami.PluginServices;
+import org.gvsig.andami.messages.NotificationManager;
+import org.gvsig.utils.XMLException;
+
+
+public class OpenException extends XMLException {
+	private Exception e;
+	private String c;
+	public OpenException(Exception e,String c) {
+		this.e=e;
+		this.c=c;
+	}
+	public void showError(){
+		NotificationManager.addError(PluginServices.getText(this,"abrir_proyecto"),e);
+	}
+	public void showInfo(){
+		NotificationManager.addInfo(PluginServices.getText(this,"abrir_proyecto"),e);
+	}
+	public void showWarning(){
+		NotificationManager.addWarning(PluginServices.getText(this,"abrir_proyecto"),e);
+	}
+	protected Map values() {
+		// TODO Auto-generated method stub
+		return null;
+	}
+	public void showMessageError(String name) {
+		String message=PluginServices.getText(this,"error_opening_the_document")+": "+name;
+		NotificationManager.showMessageError(message,e);
+
+	}
+}

Property changes on: tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/app/project/documents/exceptions/OpenException.java
___________________________________________________________________
Added: svn:keywords
   + Author Date Id Revision
Added: svn:eol-style
   + native

Index: tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/app/project/documents/AbstractDocument.java
===================================================================
--- tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/app/project/documents/AbstractDocument.java	(revision 0)
+++ tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/app/project/documents/AbstractDocument.java	(revision 38653)
@@ -0,0 +1,364 @@
+/* gvSIG. Geographic Information System of the Valencian Government
+*
+* Copyright (C) 2007-2009 Infrastructures and Transports Department
+* of the Valencian Government (CIT)
+* 
+* This program is free software; you can redistribute it and/or
+* modify it under the terms of the GNU General Public License
+* as published by the Free Software Foundation; either version 2
+* of the License, or (at your option) any later version.
+* 
+* This program is distributed in the hope that it will be useful,
+* but WITHOUT ANY WARRANTY; without even the implied warranty of
+* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
+* GNU General Public License for more details.
+* 
+* You should have received a copy of the GNU General Public License
+* along with this program; if not, write to the Free Software
+* Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, 
+* MA  02110-1301, USA.
+* 
+*/
+
+/*
+* AUTHORS (In addition to CIT):
+* 2004-2009 IVER TI
+*   
+*/
+package org.gvsig.app.project.documents;
+
+import java.beans.PropertyChangeListener;
+import java.beans.PropertyChangeSupport;
+import java.io.Serializable;
+import java.text.DateFormat;
+import java.util.ArrayList;
+import java.util.Date;
+import java.util.List;
+
+import org.gvsig.andami.PluginServices;
+import org.gvsig.andami.ui.mdiManager.IWindow;
+import org.gvsig.app.project.Project;
+import org.gvsig.app.project.documents.gui.WindowLayout;
+import org.gvsig.tools.ToolsLocator;
+import org.gvsig.tools.dynobject.DynStruct;
+import org.gvsig.tools.persistence.PersistenceManager;
+import org.gvsig.tools.persistence.Persistent;
+import org.gvsig.tools.persistence.PersistentState;
+import org.gvsig.tools.persistence.exception.PersistenceException;
+
+
+
+/**
+ * Clase base de los elementos del proyecto (mapas, tablas y vistas)
+ *
+ * @author 2006-2009 Jose Manuel Vivo
+ * @author 2005-         Vicente Caballero
+ * @author 2009-         Joaquin del Cerro
+ * 
+ */
+public abstract class AbstractDocument implements Serializable, Persistent, Document {
+
+	/**
+	 * 
+	 */
+	private static final long serialVersionUID = 3335040973071555406L;
+
+	public static final String PERSISTENCE_DEFINITION_NAME = "AbstractDocument";
+	
+	protected PropertyChangeSupport change;
+	
+	private Project project;
+	
+	private String name;
+	private String creationDate;
+	private String owner;
+	private String comment;
+	private boolean locked = false;
+	private boolean isModified=false;
+
+	private DocumentManager factory;
+
+	private WindowLayout windowLayout = null;
+	
+	private List<ProjectDocumentListener> projectDocListener = new ArrayList<ProjectDocumentListener>();
+
+	/**
+	 * Creates a new ProjectElement object.
+	 */
+	public AbstractDocument() {
+		creationDate = DateFormat.getDateInstance().format(new Date());
+		change = new PropertyChangeSupport(this);
+		this.factory = null;
+		this.project = null;
+		this.name = PluginServices.getText(this, "untitled");
+	}
+
+	public AbstractDocument(DocumentManager factory) {
+		this();
+		this.factory = factory;
+	}
+	
+	/**
+	 * @see java.lang.Object#toString()
+	 */
+	public String toString() {
+		return name;
+	}
+
+	/**
+	 * return the name of the document
+	 *
+	 * @return name as String
+	 */
+	public String getName() {
+		return name;
+	}
+
+	/**
+	 * Return the name of the type of documents
+	 * 
+	 * @return name as String
+	 */
+	public String getTypeName() {
+		return this.factory.getTypeName();
+	}
+	
+	/**
+	 * Sets the nane of the document
+	 *
+	 * @param name as string
+	 */
+	public void setName(String name) {
+		if (isLocked()) {
+			throw new RuntimeException("this document is locked");
+		}
+		if( name.length()==0) {
+			name = null;
+		} 
+		if( project != null ) {
+			Document doc = project.getDocument(name, this.getTypeName());
+			if( doc != null && !this.equals(doc)  ) {
+				throw new RuntimeException("document name already exists in project");
+			}
+		}
+		String previousName = this.name;
+		this.name = name;
+		change.firePropertyChange("name", previousName, name);
+	}
+
+	/**
+	 * Get the creation date of the document.
+	 *
+	 * @return creation date as String
+	 */
+	public String getCreationDate() {
+		return creationDate;
+	}
+
+	/**
+	 * Get the creator name of the document.
+	 *
+	 * @return creator name as String
+	 */
+	public String getOwner() {
+		return owner;
+	}
+
+	/**
+	 * Set the creation date of the document.
+	 *
+	 * @param string
+	 */
+	public void setCreationDate(String string) {
+		creationDate = string;
+		change.firePropertyChange("creationDate", creationDate, creationDate);
+	}
+
+	/**
+	 * Sets the creator name of the document
+	 *
+	 * @param string
+	 */
+	public void setOwner(String string) {
+		String oldOwner = owner;
+		owner = string;
+		change.firePropertyChange("owner", oldOwner, owner);
+	}
+
+	/**
+	 * Gets the comments asociateds to the document
+	 *
+	 * @return comments as String
+	 */
+	public String getComment() {
+		return comment;
+	}
+
+	/**
+	 * Gets the comments asociateds to the document
+	 *
+	 * @param string
+	 */
+	public void setComment(String string) {
+		String oldComment = comment;
+		comment = string;
+		change.firePropertyChange("comment", oldComment, comment);
+	}
+
+	/**
+	 * Add a listener to monitor the changes in the properties of the document
+	 *
+	 * @param listener
+	 */
+	public synchronized void addPropertyChangeListener(
+		PropertyChangeListener listener) {
+		change.addPropertyChangeListener(listener);
+	}
+
+	/**
+	 * Register a  ProjectDocumentListener.
+	 * @param  listener  ProjectDocumentListener
+	 */
+	public void addListener(ProjectDocumentListener listener) {
+		if(this.projectDocListener.indexOf(listener) == -1)
+			this.projectDocListener.add(listener);
+	}
+
+	
+	public WindowLayout getWindowLayout() {
+		return this.windowLayout;
+	}
+	
+	public void setWindowLayout(WindowLayout layout) {
+		this.windowLayout = layout;
+	}
+	
+	public void loadFromState(PersistentState state)
+			throws PersistenceException {
+		this.setComment( state.getString("comment") );
+		this.setCreationDate( state.getString("creationDate") );
+		this.setName( state.getString("name") );
+		this.setOwner( state.getString("owner") );
+	}
+
+	public void saveToState(PersistentState state) throws PersistenceException {
+		state.set("comment", comment);
+		state.set("creationDate", creationDate);
+		state.set("name", name);
+		state.set("owner", owner);
+		state.set("locked", locked);
+	}
+	
+	public static void registerPersistent() {
+		PersistenceManager manager = ToolsLocator.getPersistenceManager();
+		DynStruct definition = manager.getDefinition(PERSISTENCE_DEFINITION_NAME);
+		if ( definition == null ){
+		    definition = manager.addDefinition(
+		        AbstractDocument.class,
+		        PERSISTENCE_DEFINITION_NAME,
+		        "Document persistence definition",
+		        null, 
+		        null
+		    );  
+		    definition.addDynFieldString("comment").setMandatory(false);
+		    definition.addDynFieldString("creationDate").setMandatory(true);
+		    definition.addDynFieldString("name").setMandatory(true);
+		    definition.addDynFieldString("owner").setMandatory(false);
+		    definition.addDynFieldBoolean("locked").setMandatory(true);
+		}
+	}
+	
+	public Project getProject() {
+		return project;
+	}
+
+	public void setProject(Project project) {
+		this.project = project;
+	}
+	
+
+	/**
+	 * Locks this project element protecting it from deleting from the project.
+	 */
+	public void lock() {		
+		boolean oldLocked = locked;
+		locked = Boolean.TRUE;
+		change.firePropertyChange("locked", oldLocked, locked);
+	}
+
+	/**
+	 * Unlocks this element. So, from now on, it can be removed from the project.
+	 */
+	public void unlock() {
+		boolean oldLocked = locked;
+		locked = Boolean.FALSE;
+		change.firePropertyChange("locked", oldLocked, locked);
+	}
+
+	/**
+	 * Tells whether if this project's element is locked/protected or not. A protected
+	 * element cannot be removed from the current project.
+	 *
+	 * @see <b>lock()</b> and <b>unlock()</b> methods.
+	 *
+	 * @return true if it is locked, false otherwise
+	 */
+	public boolean isLocked() {
+		return locked;
+	}
+
+	public DocumentManager getFactory() {
+		return factory;
+	}
+	
+	public boolean isModified() {
+		return isModified;
+	}
+
+	public void setModified(boolean modified) {
+		isModified=modified;
+	}
+
+	/**
+	 * Throw this event when a new window is created
+	 * @param  window
+	 *         IWindow created
+	 */
+	public void raiseEventCreateWindow(IWindow window) {
+		for (int i = 0; i < projectDocListener.size(); i++)
+			projectDocListener.get(i).windowCreated(window);
+	}
+
+	/**
+	 * @deprecated use {link {@link #raiseEventCreateWindow(IWindow)}
+	 */
+	protected void callCreateWindow(IWindow window) {
+		raiseEventCreateWindow(window);
+	}
+
+	public void afterAdd() {
+		// do nothing by default
+	}
+
+	public void afterRemove() {
+		// do nothing by default
+	}
+
+	public String exportDocumentAsText() {
+		throw new UnsupportedOperationException();
+	}
+
+	public void setStateFromText(String text) {
+		throw new UnsupportedOperationException();
+	}
+
+	public IWindow getPropertiesWindow() {
+		return this.getFactory().getPropertiesWindow(this);
+	}
+	
+	public IWindow getMainWindow() {
+		return this.getFactory().getMainWindow(this);
+	}
+	
+
+}

Property changes on: tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/app/project/documents/AbstractDocument.java
___________________________________________________________________
Added: svn:keywords
   + Author Date Id Revision
Added: svn:eol-style
   + native

Index: tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/app/project/documents/gui/PDFViewerWindow.java
===================================================================
--- tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/app/project/documents/gui/PDFViewerWindow.java	(revision 0)
+++ tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/app/project/documents/gui/PDFViewerWindow.java	(revision 38653)
@@ -0,0 +1,484 @@
+/* gvSIG. Geographic Information System of the Valencian Government
+ *
+ * Copyright (C) 2007-2008 Infrastructures and Transports Department
+ * of the Valencian Government (CIT)
+ * 
+ * This program is free software; you can redistribute it and/or
+ * modify it under the terms of the GNU General Public License
+ * as published by the Free Software Foundation; either version 2
+ * of the License, or (at your option) any later version.
+ * 
+ * This program is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
+ * GNU General Public License for more details.
+ * 
+ * You should have received a copy of the GNU General Public License
+ * along with this program; if not, write to the Free Software
+ * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, 
+ * MA  02110-1301, USA.
+ * 
+ */
+package org.gvsig.app.project.documents.gui;
+
+import java.awt.BorderLayout;
+import java.awt.Component;
+import java.awt.Container;
+import java.awt.Dimension;
+import java.awt.FlowLayout;
+import java.awt.Toolkit;
+import java.awt.event.ActionEvent;
+import java.awt.event.ActionListener;
+import java.awt.print.PageFormat;
+import java.awt.print.Paper;
+import java.awt.print.PrinterException;
+import java.awt.print.PrinterJob;
+import java.beans.PropertyChangeEvent;
+import java.beans.PropertyChangeListener;
+import java.net.URL;
+
+import javax.print.attribute.HashPrintRequestAttributeSet;
+import javax.print.attribute.PrintRequestAttributeSet;
+import javax.print.attribute.standard.PageRanges;
+import javax.swing.ImageIcon;
+import javax.swing.JButton;
+import javax.swing.JLabel;
+import javax.swing.JOptionPane;
+import javax.swing.JPanel;
+import javax.swing.JScrollPane;
+import javax.swing.JTextField;
+
+import org.jpedal.Display;
+import org.jpedal.PdfDecoder;
+import org.jpedal.exception.PdfException;
+import org.jpedal.objects.PrinterOptions;
+
+import org.gvsig.andami.PluginServices;
+import org.gvsig.andami.ui.mdiManager.IWindow;
+import org.gvsig.andami.ui.mdiManager.WindowInfo;
+
+public class PDFViewerWindow extends JPanel implements IWindow,
+    PropertyChangeListener {
+
+    private static final long serialVersionUID = 4022263653761949704L;
+    private WindowInfo m_viewInfo;
+    private PdfDecoder pf;
+
+    // private String viewerTitle="Visor PDF";
+    private String currentFile = null;
+    private int currentPage = 1;
+    private final JLabel pageCounter1 = new JLabel(" "
+        + PluginServices.getText(this, "Pagina") + " ");
+    private JTextField pageCounter2 = new JTextField(4);
+    private JLabel pageCounter3 =
+        new JLabel(PluginServices.getText(this, "de"));
+
+    public PDFViewerWindow(String currentFile) {
+        super();
+        initialize(currentFile);
+    }
+
+    private void initialize(String currentFile) {
+
+        pf = new PdfDecoder();
+        this.currentFile = currentFile;
+        // currentFile = "C:\\Cartografia\\prueba.pdf";
+
+        try {
+            // this opens the PDF and reads its internal details
+            pf.openPdfFile(currentFile);
+
+            // these 2 lines opens page 1 at 100% scaling
+            pf.decodePage(currentPage);
+            float scaling = (float) 1.5;
+            pf.setPageParameters(scaling, 1); // values scaling (1=100%). page
+                                              // number
+            pf.setDisplayView(Display.SINGLE_PAGE, Display.DISPLAY_CENTERED);
+        } catch (Exception e) {
+            e.printStackTrace();
+        }
+
+        // setup our GUI display
+        initializeViewer();
+
+        // set page number display
+        pageCounter2.setText(currentPage + "");
+        pageCounter3.setText(PluginServices.getText(this, "de") + " "
+            + pf.getPageCount() + " ");
+    }
+
+    public void setCurrentFile(String currentFile) {
+        this.currentFile = currentFile;
+    }
+
+    private void initializeViewer() {
+
+        Container cPane = this;
+        cPane.setLayout(new BorderLayout());
+
+        // JButton open = initOpenBut();//setup open button
+        Component[] itemsToAdd = initChangerPanel();// setup page display and
+                                                    // changer
+
+        JPanel topBar = new JPanel();
+        topBar.setLayout(new FlowLayout(FlowLayout.CENTER, 0, 0));
+        // topBar.add(pageChanger);
+        for (int i = 0; i < itemsToAdd.length; i++) {
+            topBar.add(itemsToAdd[i]);
+        }
+
+        cPane.add(topBar, BorderLayout.NORTH);
+
+        JScrollPane display = getJPaneViewer();// setup scrollpane with pdf
+                                               // display inside
+        cPane.add(display, BorderLayout.CENTER);
+
+        // pack();
+
+        Dimension screen = Toolkit.getDefaultToolkit().getScreenSize();
+        setSize(screen.width / 2, screen.height / 2);
+        // <start-13>
+        // setLocationRelativeTo(null);//centre on screen
+        // <end-13>
+        setVisible(true);
+    }
+
+    private Component[] initChangerPanel() {
+
+        Component[] list = new Component[12];
+
+        /** back to page 1 */
+        JButton start = new JButton();
+        start.setBorderPainted(false);
+        URL startImage =
+            getClass().getResource(
+                "/org/jpedal/examples/simpleviewer/res/start.gif");
+        start.setIcon(new ImageIcon(startImage));
+        start.setToolTipText(PluginServices.getText(this, "primera_pagina"));
+        // currentBar1.add(start);
+        list[0] = start;
+        start.addActionListener(new ActionListener() {
+
+            public void actionPerformed(ActionEvent e) {
+                if (currentFile != null && currentPage != 1) {
+                    currentPage = 1;
+                    try {
+                        pf.decodePage(currentPage);
+                        pf.invalidate();
+                        repaint();
+                    } catch (Exception e1) {
+                        System.err.println("back to page 1");
+                        e1.printStackTrace();
+                    }
+
+                    // set page number display
+                    pageCounter2.setText(currentPage + "");
+                }
+            }
+        });
+
+        /** back 10 icon */
+        JButton fback = new JButton();
+        fback.setBorderPainted(false);
+        URL fbackImage =
+            getClass().getResource(
+                "/org/jpedal/examples/simpleviewer/res/fback.gif");
+        fback.setIcon(new ImageIcon(fbackImage));
+        fback
+            .setToolTipText(PluginServices.getText(this, "diez_paginas_atras"));
+        // currentBar1.add(fback);
+        list[1] = fback;
+        fback.addActionListener(new ActionListener() {
+
+            public void actionPerformed(ActionEvent e) {
+                if (currentFile != null && currentPage > 10) {
+                    currentPage -= 10;
+                    try {
+                        pf.decodePage(currentPage);
+                        pf.invalidate();
+                        repaint();
+                    } catch (Exception e1) {
+                        System.err.println("back 10 pages");
+                        e1.printStackTrace();
+                    }
+
+                    // set page number display
+                    pageCounter2.setText(currentPage + "");
+                }
+            }
+        });
+
+        /** back icon */
+        JButton back = new JButton();
+        back.setBorderPainted(false);
+        URL backImage =
+            getClass().getResource(
+                "/org/jpedal/examples/simpleviewer/res/back.gif");
+        back.setIcon(new ImageIcon(backImage));
+        back.setToolTipText(PluginServices.getText(this, "pagina_atras"));
+        // currentBar1.add(back);
+        list[2] = back;
+        back.addActionListener(new ActionListener() {
+
+            public void actionPerformed(ActionEvent e) {
+                if (currentFile != null && currentPage > 1) {
+                    currentPage -= 1;
+                    try {
+                        pf.decodePage(currentPage);
+                        pf.invalidate();
+                        repaint();
+                    } catch (Exception e1) {
+                        System.err.println("back 1 page");
+                        e1.printStackTrace();
+                    }
+
+                    // set page number display
+                    pageCounter2.setText(currentPage + "");
+                }
+            }
+        });
+
+        pageCounter2.setEditable(true);
+        pageCounter2.addActionListener(new ActionListener() {
+
+            public void actionPerformed(ActionEvent a) {
+
+                String value = pageCounter2.getText().trim();
+                int newPage;
+
+                // allow for bum values
+                try {
+                    newPage = Integer.parseInt(value);
+
+                    if ((newPage > pf.getPageCount()) | (newPage < 1)) {
+                        return;
+                    }
+
+                    currentPage = newPage;
+                    try {
+                        pf.decodePage(currentPage);
+                        pf.invalidate();
+                        repaint();
+                    } catch (Exception e) {
+                        System.err.println("page number entered");
+                        e.printStackTrace();
+                    }
+
+                } catch (Exception e) {
+                    JOptionPane.showMessageDialog(
+                        null,
+                        ">" + value + "< "
+                            + PluginServices.getText(this, "valor_incorrecto")
+                            + pf.getPageCount());
+                }
+
+            }
+
+        });
+
+        /** put page count in middle of forward and back */
+        // currentBar1.add(pageCounter1);
+        // currentBar1.add(new JPanel());//add gap
+        // currentBar1.add(pageCounter2);
+        // currentBar1.add(new JPanel());//add gap
+        // currentBar1.add(pageCounter3);
+        list[3] = pageCounter1;
+        list[4] = new JPanel();
+        list[5] = pageCounter2;
+        list[6] = new JPanel();
+        list[7] = pageCounter3;
+
+        /** forward icon */
+        JButton forward = new JButton();
+        forward.setBorderPainted(false);
+        URL fowardImage =
+            getClass().getResource(
+                "/org/jpedal/examples/simpleviewer/res/forward.gif");
+        forward.setIcon(new ImageIcon(fowardImage));
+        forward.setToolTipText(PluginServices.getText(this, "pagina_delante"));
+        // currentBar1.add(forward);
+        list[8] = forward;
+        forward.addActionListener(new ActionListener() {
+
+            public void actionPerformed(ActionEvent e) {
+                if (currentFile != null && currentPage < pf.getPageCount()) {
+                    currentPage += 1;
+                    try {
+                        pf.decodePage(currentPage);
+                        pf.invalidate();
+                        repaint();
+                    } catch (Exception e1) {
+                        System.err.println("forward 1 page");
+                        e1.printStackTrace();
+                    }
+
+                    // set page number display
+                    pageCounter2.setText(currentPage + "");
+                }
+            }
+        });
+
+        /** fast forward icon */
+        JButton fforward = new JButton();
+        fforward.setBorderPainted(false);
+        URL ffowardImage =
+            getClass().getResource(
+                "/org/jpedal/examples/simpleviewer/res/fforward.gif");
+        fforward.setIcon(new ImageIcon(ffowardImage));
+        fforward.setToolTipText(PluginServices.getText(this,
+            "10_paginas_delante"));
+        // currentBar1.add(fforward);
+        list[9] = fforward;
+        fforward.addActionListener(new ActionListener() {
+
+            public void actionPerformed(ActionEvent e) {
+                if (currentFile != null && currentPage < pf.getPageCount() - 9) {
+                    currentPage += 10;
+                    try {
+                        pf.decodePage(currentPage);
+                        pf.invalidate();
+                        repaint();
+                    } catch (Exception e1) {
+                        System.err.println("forward 10 pages");
+                        e1.printStackTrace();
+                    }
+
+                    // set page number display
+                    pageCounter2.setText(currentPage + "");
+                }
+            }
+        });
+
+        /** goto last page */
+        JButton end = new JButton();
+        end.setBorderPainted(false);
+        URL endImage =
+            getClass().getResource(
+                "/org/jpedal/examples/simpleviewer/res/end.gif");
+        end.setIcon(new ImageIcon(endImage));
+        end.setToolTipText(PluginServices.getText(this, "ultima_pagina"));
+        // currentBar1.add(end);
+        list[10] = end;
+        end.addActionListener(new ActionListener() {
+
+            public void actionPerformed(ActionEvent e) {
+                if (currentFile != null && currentPage < pf.getPageCount()) {
+                    currentPage = pf.getPageCount();
+                    try {
+                        pf.decodePage(currentPage);
+                        pf.invalidate();
+                        repaint();
+                    } catch (Exception e1) {
+                        System.err.println("forward to last page");
+                        e1.printStackTrace();
+                    }
+
+                    // set page number display
+                    pageCounter2.setText(currentPage + "");
+                }
+            }
+        });
+
+        /** Print */
+        JButton print = new JButton();
+        print.setBorderPainted(false);
+        URL printImage =
+            getClass().getResource(
+                "/org/jpedal/examples/simpleviewer/res/print.gif");
+        print.setIcon(new ImageIcon(printImage));
+        print.setToolTipText(PluginServices.getText(this, "imprimir"));
+        // currentBar1.add(end);
+        list[11] = print;
+        print.addActionListener(new ActionListener() {
+
+            public void actionPerformed(ActionEvent e) {
+                printPDF();
+            }
+        });
+        return list;
+    }
+
+    public void printPDF() {
+        PrinterJob printJob = PrinterJob.getPrinterJob();
+
+        printJob.setPageable(pf);
+        // decode_pdf.setPageFormat(pf);
+
+        /**
+         * this additional functionality is available under printable interface
+         */
+        // setup default values to add into JPS
+        PrintRequestAttributeSet aset = new HashPrintRequestAttributeSet();
+        aset.add(new PageRanges(1, pf.getPageCount()));
+
+        boolean printFile = printJob.printDialog(aset);
+
+        // set page range
+        PageRanges r = (PageRanges) aset.get(PageRanges.class);
+        if (r != null) {
+            try {
+                PageFormat pformat = printJob.defaultPage();
+
+                Paper paper = new Paper();
+                paper.setSize(595, 842); // default A4
+                paper.setImageableArea(43, 43, 545, 792); // actual print 'zone'
+
+                pformat.setPaper(paper);
+
+                // pageable provides a method getPageFormat(int p) - this method
+                // allows it to be set by JPedal
+                pf.setPageFormat(pformat);
+                pf.setPagePrintRange(r);
+            } catch (PdfException e) {
+                // TODO Auto-generated catch block
+                e.printStackTrace();
+            }
+        }
+
+        /**
+         * generic call to both Pageable and printable
+         */
+        if (printFile) {
+            try {
+                pf.setPrintPageScalingMode(PrinterOptions.PAGE_SCALING_FIT_TO_PRINTER_MARGINS);
+                printJob.print();
+            } catch (PrinterException e) {
+                // TODO Auto-generated catch block
+                e.printStackTrace();
+            }
+        }
+    }
+
+    private JScrollPane getJPaneViewer() {
+        JScrollPane currentScroll = new JScrollPane();
+        currentScroll
+            .setHorizontalScrollBarPolicy(JScrollPane.HORIZONTAL_SCROLLBAR_AS_NEEDED);
+        currentScroll
+            .setVerticalScrollBarPolicy(JScrollPane.VERTICAL_SCROLLBAR_AS_NEEDED);
+
+        currentScroll.setViewportView(pf);
+        return currentScroll;
+    }
+
+    public WindowInfo getWindowInfo() {
+        if (m_viewInfo == null) {
+            m_viewInfo = new WindowInfo(WindowInfo.PALETTE);
+            m_viewInfo.setMaximizable(true);
+            m_viewInfo.setWidth(this.getWidth());
+            m_viewInfo.setHeight(this.getHeight());
+            m_viewInfo.setTitle(PluginServices.getText(this, "pdf_viewer"));
+        }
+        return m_viewInfo;
+    }
+
+    public void propertyChange(PropertyChangeEvent arg0) {
+        // TODO Auto-generated method stub
+
+    }
+
+    public Object getWindowProfile() {
+        // TODO Auto-generated method stub
+        return WindowInfo.TOOL_PROFILE;
+    }
+
+}

Property changes on: tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/app/project/documents/gui/PDFViewerWindow.java
___________________________________________________________________
Added: svn:eol-style
   + native
Added: svn:keywords
   + Author Date Id Revision

Index: tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/app/project/documents/gui/ProjectProperties.java
===================================================================
--- tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/app/project/documents/gui/ProjectProperties.java	(revision 0)
+++ tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/app/project/documents/gui/ProjectProperties.java	(revision 38653)
@@ -0,0 +1,478 @@
+/* gvSIG. Geographic Information System of the Valencian Government
+ *
+ * Copyright (C) 2007-2008 Infrastructures and Transports Department
+ * of the Valencian Government (CIT)
+ * 
+ * This program is free software; you can redistribute it and/or
+ * modify it under the terms of the GNU General Public License
+ * as published by the Free Software Foundation; either version 2
+ * of the License, or (at your option) any later version.
+ * 
+ * This program is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
+ * GNU General Public License for more details.
+ * 
+ * You should have received a copy of the GNU General Public License
+ * along with this program; if not, write to the Free Software
+ * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, 
+ * MA  02110-1301, USA.
+ * 
+ */
+package org.gvsig.app.project.documents.gui;
+
+import java.awt.Color;
+import java.awt.Dimension;
+import java.awt.FlowLayout;
+import java.awt.GridBagConstraints;
+import java.awt.GridBagLayout;
+import java.awt.GridLayout;
+import java.awt.Insets;
+import java.io.File;
+
+import javax.swing.JButton;
+import javax.swing.JColorChooser;
+import javax.swing.JComponent;
+import javax.swing.JLabel;
+import javax.swing.JPanel;
+import javax.swing.JScrollPane;
+import javax.swing.JTextArea;
+import javax.swing.JTextField;
+
+import org.gvsig.andami.PluginServices;
+import org.gvsig.andami.ui.mdiManager.IWindow;
+import org.gvsig.andami.ui.mdiManager.WindowInfo;
+import org.gvsig.app.extension.ProjectExtension;
+import org.gvsig.app.project.Project;
+import org.gvsig.gui.beans.AcceptCancelPanel;
+import org.gvsig.tools.swing.api.ToolsSwingLocator;
+
+/**
+ * Propiedades del proyecto
+ * 
+ * @author Fernando Gonz�lez Cort�s
+ * @author gvSIG team
+ */
+public class ProjectProperties extends JPanel implements IWindow {
+
+    private static final long serialVersionUID = 8952351479171919349L;
+    private Project project = null;
+    private JPanel jPanel = null;
+    private JLabel jLabel = null;
+    private JLabel jLabel1 = null;
+    private JLabel jLabel2 = null;
+    private JLabel jLabel3 = null;
+    private JLabel jLabel4 = null;
+    private JTextField txtName = null;
+    private JTextField txtPath = null;
+    private JTextField txtCreationDate = null;
+    private JTextField txtModificationDate = null;
+    private JTextField txtOwner = null;
+    private JLabel jLabel5 = null;
+    private JTextArea txtComments = null;
+    private JLabel jLabel6 = null;
+    private JLabel lblColor = null;
+    private JButton btnColor = null;
+    private JScrollPane jScrollPane = null;
+
+    /**
+     * This is the default constructor
+     * 
+     * @param owner
+     *            Frame padre del di�logo
+     * @param p
+     *            Proyecto cuyos datos se muestran en el di�logo
+     */
+    public ProjectProperties(Project p) {
+        project = p;
+        initialize();
+    }
+
+    /**
+     * This method initializes this
+     */
+    private void initialize() {
+        setLayout(new GridLayout(1, 1, 0, 0));
+        add(getJPanel());
+
+        getTxtName().setText(project.getName());
+
+        String path = ProjectExtension.getPath();
+
+        if (path != null) {
+            File f = new File(path);
+            getTxtPath().setText(f.toString());
+        } else {
+            getTxtPath().setText("");
+        }
+
+        getTxtOwner().setText(project.getOwner());
+        getTxtComments().setText(project.getComments());
+        getTxtCreationDate().setText(project.getCreationDate());
+        getTxtModificationDate().setText(project.getModificationDate());
+
+        getLblColor().setBackground(project.getSelectionColor());
+    }
+
+    /**
+     * This method initializes jPanel
+     * 
+     * @return JPanel
+     */
+    private JPanel getJPanel() {
+        if (jPanel == null) {
+
+            jPanel = new JPanel(new GridBagLayout());
+            GridBagConstraints c = new GridBagConstraints();
+            c.insets = new Insets(2, 5, 0, 5);
+            c.gridy = -1;
+
+            addRow(c, getJLabel(), getTxtName());
+            addRow(c, getJLabel1(), getTxtPath());
+            addRow(c, getJLabel2(), getTxtCreationDate());
+            addRow(c, getJLabel3(), getTxtModificationDate());
+            addRow(c, getJLabel4(), getTxtOwner());
+
+            c.anchor = GridBagConstraints.WEST;
+            c.weightx = 0.0d;
+            c.gridx = 0;
+            c.gridy++;
+            jPanel.add(getJLabel6(), c);
+
+            JPanel colorPanel = new JPanel(new FlowLayout(FlowLayout.LEFT));
+            colorPanel.add(getLblColor());
+            colorPanel.add(getBtnColor());
+
+            c.fill = GridBagConstraints.HORIZONTAL;
+            c.weightx = 1.0d;
+            c.gridx = 1;
+            jPanel.add(colorPanel, c);
+
+            c.anchor = GridBagConstraints.WEST;
+            c.weightx = 0.0d;
+            c.gridx = 0;
+            c.gridy++;
+            jPanel.add(getJLabel5(), c);
+
+            c.fill = GridBagConstraints.BOTH;
+            c.weightx = 1.0d;
+            c.gridy++;
+            c.gridwidth = 2;
+            jPanel.add(getJScrollPane(), c);
+
+            java.awt.event.ActionListener okAction =
+                new java.awt.event.ActionListener() {
+
+                    public void actionPerformed(java.awt.event.ActionEvent e) {
+                        project.setName(txtName.getText());
+                        project.setOwner(txtOwner.getText());
+                        project.setComments(txtComments.getText());
+                        project.setSelectionColor(lblColor.getBackground());
+                        PluginServices.getMDIManager().closeWindow(
+                            ProjectProperties.this);
+                    }
+                }, cancelAction = new java.awt.event.ActionListener() {
+
+                public void actionPerformed(java.awt.event.ActionEvent e) {
+                    PluginServices.getMDIManager().closeWindow(
+                        ProjectProperties.this);
+                }
+            };
+
+            c.anchor = GridBagConstraints.EAST;
+            c.gridx = 0;
+            c.gridwidth = 2;
+            c.gridy++;
+            c.weightx = 1.0d;
+
+            jPanel.add(new AcceptCancelPanel(okAction, cancelAction), c);
+        }
+
+        return jPanel;
+    }
+
+    private void addRow(GridBagConstraints c, JComponent label, JComponent text) {
+        c.anchor = GridBagConstraints.WEST;
+        c.weightx = 0.0d;
+        c.gridx = 0;
+        c.gridy++;
+        jPanel.add(label, c);
+
+        c.fill = GridBagConstraints.HORIZONTAL;
+        c.weightx = 1.0d;
+        c.gridx = 1;
+        jPanel.add(text, c);
+    }
+
+    /**
+     * This method initializes jLabel
+     * 
+     * @return JLabel
+     */
+    private JLabel getJLabel() {
+        if (jLabel == null) {
+            jLabel = new JLabel();
+            jLabel.setText(PluginServices.getText(this, "nombre_sesion") + ":");
+        }
+
+        return jLabel;
+    }
+
+    /**
+     * This method initializes jLabel1
+     * 
+     * @return JLabel
+     */
+    private JLabel getJLabel1() {
+        if (jLabel1 == null) {
+            jLabel1 = new JLabel();
+            jLabel1.setText(PluginServices.getText(this, "path") + ":");
+        }
+
+        return jLabel1;
+    }
+
+    /**
+     * This method initializes jLabel2
+     * 
+     * @return JLabel
+     */
+    private JLabel getJLabel2() {
+        if (jLabel2 == null) {
+            jLabel2 = new JLabel();
+            jLabel2
+                .setText(PluginServices.getText(this, "creation_date") + ":");
+        }
+
+        return jLabel2;
+    }
+
+    /**
+     * This method initializes jLabel3
+     * 
+     * @return JLabel
+     */
+    private JLabel getJLabel3() {
+        if (jLabel3 == null) {
+            jLabel3 = new JLabel();
+            jLabel3.setText(PluginServices.getText(this, "modification_date")
+                + ":");
+        }
+
+        return jLabel3;
+    }
+
+    /**
+     * This method initializes jLabel4
+     * 
+     * @return JLabel
+     */
+    private JLabel getJLabel4() {
+        if (jLabel4 == null) {
+            jLabel4 = new JLabel();
+            jLabel4.setText(PluginServices.getText(this, "owner") + ":");
+        }
+
+        return jLabel4;
+    }
+
+    /**
+     * This method initializes txtName
+     * 
+     * @return JTextField
+     */
+    private JTextField getTxtName() {
+        if (txtName == null) {
+            txtName = new JTextField(20);
+        }
+
+        return txtName;
+    }
+
+    /**
+     * This method initializes txtPath
+     * 
+     * @return JTextField
+     */
+    private JTextField getTxtPath() {
+        if (txtPath == null) {
+            txtPath = new JTextField(20);
+            txtPath.setEditable(false);
+            txtPath.setBackground(java.awt.Color.white);
+        }
+
+        return txtPath;
+    }
+
+    /**
+     * This method initializes txtCreationDate
+     * 
+     * @return JTextField
+     */
+    private JTextField getTxtCreationDate() {
+        if (txtCreationDate == null) {
+            txtCreationDate = new JTextField(20);
+            txtCreationDate.setEditable(false);
+            txtCreationDate.setBackground(java.awt.Color.white);
+        }
+
+        return txtCreationDate;
+    }
+
+    /**
+     * This method initializes txtModificationDate
+     * 
+     * @return JTextField
+     */
+    private JTextField getTxtModificationDate() {
+        if (txtModificationDate == null) {
+            txtModificationDate = new JTextField(20);
+            txtModificationDate.setEditable(false);
+            txtModificationDate.setBackground(java.awt.Color.white);
+        }
+
+        return txtModificationDate;
+    }
+
+    /**
+     * This method initializes txtOwner
+     * 
+     * @return JTextField
+     */
+    private JTextField getTxtOwner() {
+        if (txtOwner == null) {
+            txtOwner = new JTextField(20);
+        }
+
+        return txtOwner;
+    }
+
+    /**
+     * This method initializes jLabel5
+     * 
+     * @return JLabel
+     */
+    private JLabel getJLabel5() {
+        if (jLabel5 == null) {
+            jLabel5 = new JLabel();
+            jLabel5.setText(PluginServices.getText(this, "comentarios") + ":");
+        }
+
+        return jLabel5;
+    }
+
+    /**
+     * This method initializes txtComments
+     * 
+     * @return JTextArea
+     */
+    private JTextArea getTxtComments() {
+        if (txtComments == null) {
+            txtComments = new JTextArea();
+            txtComments.setRows(4);
+            txtComments.setColumns(20);
+        }
+
+        return txtComments;
+    }
+
+    /**
+     * This method initializes jLabel6
+     * 
+     * @return JLabel
+     */
+    private JLabel getJLabel6() {
+        if (jLabel6 == null) {
+            jLabel6 = new JLabel();
+            jLabel6.setText(PluginServices.getText(this, "selection_color")
+                + ":");
+        }
+
+        return jLabel6;
+    }
+
+    /**
+     * This method initializes lblColor
+     * 
+     * @return JLabel
+     */
+    private JLabel getLblColor() {
+        if (lblColor == null) {
+            lblColor = new JLabel();
+
+            lblColor.setPreferredSize(getBtnColor().getPreferredSize());
+            lblColor.setOpaque(true);
+        }
+
+        return lblColor;
+    }
+
+    /**
+     * This method initializes btnColor
+     * 
+     * @return JButton
+     */
+    private JButton getBtnColor() {
+        if (btnColor == null) {
+            btnColor =
+                ToolsSwingLocator.getUsabilitySwingManager().createJButton(
+                    "...");
+
+            btnColor.addActionListener(new java.awt.event.ActionListener() {
+
+                public void actionPerformed(java.awt.event.ActionEvent e) {
+                    Color ret =
+                        JColorChooser.showDialog(ProjectProperties.this,
+                            PluginServices.getText(this, "selection_color"),
+                            lblColor.getBackground());
+
+                    if (ret != null) {
+                        lblColor.setBackground(ret);
+                    }
+                }
+            });
+        }
+
+        return btnColor;
+    }
+
+    /**
+     * This method initializes jScrollPane
+     * 
+     * @return JScrollPane
+     */
+    private JScrollPane getJScrollPane() {
+        if (jScrollPane == null) {
+            jScrollPane = new JScrollPane(getTxtComments());
+            Dimension dim = getTxtComments().getPreferredSize();
+            jScrollPane
+                .setMinimumSize(new Dimension(dim.width, dim.height + 10));
+        }
+
+        return jScrollPane;
+    }
+
+    /**
+     * @see com.iver.mdiApp.ui.MDIManager.IWindow#getWindowInfo()
+     */
+    public WindowInfo getWindowInfo() {
+        WindowInfo m_viewinfo = new WindowInfo(WindowInfo.MODALDIALOG);
+        this.validate();
+        Dimension dim = getPreferredSize();
+        m_viewinfo.setWidth(dim.width);
+        m_viewinfo.setHeight(dim.height);
+        m_viewinfo.setTitle(PluginServices.getText(this, "propiedades_sesion"));
+        return m_viewinfo;
+    }
+
+    /**
+     * @see com.iver.mdiApp.ui.MDIManager.IWindow#windowActivated()
+     */
+    public void viewActivated() {
+    }
+
+    public Object getWindowProfile() {
+        return WindowInfo.DIALOG_PROFILE;
+    }
+
+}

Property changes on: tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/app/project/documents/gui/ProjectProperties.java
___________________________________________________________________
Added: svn:keywords
   + Author Date Id Revision
Added: svn:eol-style
   + native

Index: tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/app/project/documents/gui/WindowLayout.java
===================================================================
--- tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/app/project/documents/gui/WindowLayout.java	(revision 0)
+++ tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/app/project/documents/gui/WindowLayout.java	(revision 38653)
@@ -0,0 +1,62 @@
+/* gvSIG. Geographic Information System of the Valencian Government
+ *
+ * Copyright (C) 2007-2008 Infrastructures and Transports Department
+ * of the Valencian Government (CIT)
+ * 
+ * This program is free software; you can redistribute it and/or
+ * modify it under the terms of the GNU General Public License
+ * as published by the Free Software Foundation; either version 2
+ * of the License, or (at your option) any later version.
+ * 
+ * This program is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
+ * GNU General Public License for more details.
+ * 
+ * You should have received a copy of the GNU General Public License
+ * along with this program; if not, write to the Free Software
+ * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, 
+ * MA  02110-1301, USA.
+ * 
+ */
+package org.gvsig.app.project.documents.gui;
+
+import java.util.HashMap;
+import java.util.Map;
+
+import org.gvsig.tools.persistence.Persistent;
+import org.gvsig.tools.persistence.PersistentState;
+import org.gvsig.tools.persistence.exception.PersistenceException;
+
+/**
+ * @author cesar
+ * 
+ */
+public class WindowLayout implements Persistent {
+
+    Map<String, String> data = null;
+
+    public WindowLayout() {
+        data = new HashMap<String, String>();
+    }
+
+    public void set(String key, String value) {
+        data.put(key, value);
+    }
+
+    public String get(String key) {
+        return (String) data.get(key);
+    }
+
+    @SuppressWarnings("unchecked")
+    public void loadFromState(PersistentState state)
+        throws PersistenceException {
+        this.data.clear();
+        this.data.putAll((Map<String, String>) state.get("data"));
+    }
+
+    public void saveToState(PersistentState state) throws PersistenceException {
+        state.set("data", data);
+    }
+
+}

Property changes on: tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/app/project/documents/gui/WindowLayout.java
___________________________________________________________________
Added: svn:keywords
   + Author Date Id Revision
Added: svn:eol-style
   + native

Index: tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/app/project/documents/gui/DocumentContextMenu.java
===================================================================
--- tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/app/project/documents/gui/DocumentContextMenu.java	(revision 0)
+++ tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/app/project/documents/gui/DocumentContextMenu.java	(revision 38653)
@@ -0,0 +1,111 @@
+/* gvSIG. Geographic Information System of the Valencian Government
+ *
+ * Copyright (C) 2007-2008 Infrastructures and Transports Department
+ * of the Valencian Government (CIT)
+ * 
+ * This program is free software; you can redistribute it and/or
+ * modify it under the terms of the GNU General Public License
+ * as published by the Free Software Foundation; either version 2
+ * of the License, or (at your option) any later version.
+ * 
+ * This program is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
+ * GNU General Public License for more details.
+ * 
+ * You should have received a copy of the GNU General Public License
+ * along with this program; if not, write to the Free Software
+ * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, 
+ * MA  02110-1301, USA.
+ * 
+ */
+package org.gvsig.app.project.documents.gui;
+
+import java.awt.event.ActionEvent;
+import java.awt.event.ActionListener;
+import java.util.ArrayList;
+import java.util.Arrays;
+import java.util.List;
+
+import javax.swing.JMenuItem;
+import javax.swing.JPopupMenu;
+
+import org.gvsig.app.project.ProjectManager;
+import org.gvsig.app.project.documents.Document;
+import org.gvsig.app.project.documents.DocumentAction;
+import org.gvsig.app.project.documents.DocumentActionGroup;
+
+public class DocumentContextMenu extends JPopupMenu {
+
+    /**
+	 *
+	 */
+    private static final long serialVersionUID = -8153469580038240864L;
+
+    private Document item;
+    private List<Document> seleteds;
+    private List<DocumentAction> actions = null;
+
+    public DocumentContextMenu(String doctype, Document document,
+        Document[] seletedDocuments) {
+        super();
+
+        List<DocumentAction> allActions =
+            ProjectManager.getInstance().getDocumentActions(doctype);
+        List<DocumentAction> actions = new ArrayList<DocumentAction>();
+        DocumentActionGroup group = null;
+
+        this.item = document;
+        this.seleteds = Arrays.asList(seletedDocuments);
+        if (allActions != null) {
+            for (DocumentAction action : allActions) {
+                if (action.isVisible(document, this.seleteds)) {
+                    actions.add(action);
+                    // Create menu item
+                    MenuItem item = new MenuItem(action.getTitle(), action);
+
+                    item.setEnabled(action
+                        .isAvailable(this.item, this.seleteds));
+                    if (!action.getGroup().equals(group)) {
+                        if (group != null) {
+                            this.addSeparator();
+                        }
+                        group = action.getGroup();
+                    }
+                    this.add(item);
+
+                }
+            }
+        }
+        this.actions = actions;
+    }
+
+    public boolean hasActions() {
+        return actions != null || actions.size() > 0;
+    }
+
+    private class MenuItem extends JMenuItem implements ActionListener {
+
+        /**
+		 *
+		 */
+        private static final long serialVersionUID = -752624469241001299L;
+        private DocumentAction action;
+
+        public MenuItem(String text, DocumentAction action) {
+            super(text);
+            this.action = action;
+            String tip = this.action.getDescription();
+            if (tip != null && tip.length() > 0) {
+                this.setToolTipText(tip);
+            }
+            this.addActionListener(this);
+        }
+
+        public void actionPerformed(ActionEvent e) {
+            this.action.execute(DocumentContextMenu.this.item,
+                DocumentContextMenu.this.seleteds);
+        }
+    }
+
+}

Property changes on: tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/app/project/documents/gui/DocumentContextMenu.java
___________________________________________________________________
Added: svn:eol-style
   + native

Index: tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/app/project/documents/gui/ObjectSelectionStep.java
===================================================================
--- tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/app/project/documents/gui/ObjectSelectionStep.java	(revision 0)
+++ tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/app/project/documents/gui/ObjectSelectionStep.java	(revision 38653)
@@ -0,0 +1,62 @@
+/* gvSIG. Geographic Information System of the Valencian Government
+ *
+ * Copyright (C) 2007-2008 Infrastructures and Transports Department
+ * of the Valencian Government (CIT)
+ * 
+ * This program is free software; you can redistribute it and/or
+ * modify it under the terms of the GNU General Public License
+ * as published by the Free Software Foundation; either version 2
+ * of the License, or (at your option) any later version.
+ * 
+ * This program is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
+ * GNU General Public License for more details.
+ * 
+ * You should have received a copy of the GNU General Public License
+ * along with this program; if not, write to the Free Software
+ * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, 
+ * MA  02110-1301, USA.
+ * 
+ */
+package org.gvsig.app.project.documents.gui;
+
+import org.gvsig.utils.swing.objectSelection.ObjectSelection;
+import org.gvsig.utils.swing.wizard.Step;
+import org.gvsig.utils.swing.wizard.WizardControl;
+
+/**
+ * Control ObjectSelection como paso de un asistente
+ * 
+ * @author Fernando Gonz�lez Cort�s
+ */
+public class ObjectSelectionStep extends ObjectSelection implements Step {
+
+    private static final long serialVersionUID = 1721757595450180255L;
+    private WizardControl w;
+
+    /**
+     * @see org.gvsig.utils.swing.wizard.Step#init(org.gvsig.utils.swing.wizard.Wizard)
+     */
+    public void init(WizardControl w) {
+        this.w = w;
+    }
+
+    /**
+     * @see org.gvsig.utils.swing.objectSelection.ObjectSelection#seleccion()
+     */
+    protected void seleccion() {
+        if (w != null) {
+            w.enableNext(getCombo().getSelectedIndex() != -1);
+        }
+    }
+
+    /**
+     * Obtiene el elemento seleccionado
+     * 
+     * @return
+     */
+    public Object getSelectedItem() {
+        return getCombo().getSelectedItem();
+    }
+}

Property changes on: tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/app/project/documents/gui/ObjectSelectionStep.java
___________________________________________________________________
Added: svn:keywords
   + Author Date Id Revision
Added: svn:eol-style
   + native

Index: tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/app/project/documents/gui/AndamiWizard.java
===================================================================
--- tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/app/project/documents/gui/AndamiWizard.java	(revision 0)
+++ tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/app/project/documents/gui/AndamiWizard.java	(revision 38653)
@@ -0,0 +1,60 @@
+/* gvSIG. Geographic Information System of the Valencian Government
+ *
+ * Copyright (C) 2007-2008 Infrastructures and Transports Department
+ * of the Valencian Government (CIT)
+ * 
+ * This program is free software; you can redistribute it and/or
+ * modify it under the terms of the GNU General Public License
+ * as published by the Free Software Foundation; either version 2
+ * of the License, or (at your option) any later version.
+ * 
+ * This program is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
+ * GNU General Public License for more details.
+ * 
+ * You should have received a copy of the GNU General Public License
+ * along with this program; if not, write to the Free Software
+ * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, 
+ * MA  02110-1301, USA.
+ * 
+ */
+package org.gvsig.app.project.documents.gui;
+
+import org.gvsig.andami.ui.mdiManager.IWindow;
+import org.gvsig.andami.ui.mdiManager.WindowInfo;
+import org.gvsig.utils.swing.wizard.Wizard;
+
+/**
+ * Vista de andami que contiene un asistente
+ * 
+ * @author Fernando Gonz�lez Cort�s
+ */
+public class AndamiWizard extends Wizard implements IWindow {
+
+    private static final long serialVersionUID = -4320079648891816068L;
+
+    /**
+     * @param backText
+     * @param nextText
+     * @param finishText
+     * @param cancelText
+     */
+    public AndamiWizard(String backText, String nextText, String finishText,
+        String cancelText) {
+        super(backText, nextText, finishText, cancelText);
+    }
+
+    /**
+     * @see org.gvsig.andami.ui.mdiManager.IWindow#getWindowInfo()
+     */
+    public WindowInfo getWindowInfo() {
+        return new WindowInfo(WindowInfo.ICONIFIABLE | WindowInfo.MAXIMIZABLE
+            | WindowInfo.RESIZABLE);
+    }
+
+    public Object getWindowProfile() {
+        // TODO Auto-generated method stub
+        return WindowInfo.PROPERTIES_PROFILE;
+    }
+}

Property changes on: tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/app/project/documents/gui/AndamiWizard.java
___________________________________________________________________
Added: svn:eol-style
   + native
Added: svn:keywords
   + Author Date Id Revision

Index: tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/app/project/documents/gui/ListManagerSkin.java
===================================================================
--- tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/app/project/documents/gui/ListManagerSkin.java	(revision 0)
+++ tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/app/project/documents/gui/ListManagerSkin.java	(revision 38653)
@@ -0,0 +1,197 @@
+/* gvSIG. Geographic Information System of the Valencian Government
+ *
+ * Copyright (C) 2007-2008 Infrastructures and Transports Department
+ * of the Valencian Government (CIT)
+ * 
+ * This program is free software; you can redistribute it and/or
+ * modify it under the terms of the GNU General Public License
+ * as published by the Free Software Foundation; either version 2
+ * of the License, or (at your option) any later version.
+ * 
+ * This program is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
+ * GNU General Public License for more details.
+ * 
+ * You should have received a copy of the GNU General Public License
+ * along with this program; if not, write to the Free Software
+ * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, 
+ * MA  02110-1301, USA.
+ * 
+ */
+package org.gvsig.app.project.documents.gui;
+
+import java.awt.BorderLayout;
+import java.awt.Dimension;
+import java.awt.FlowLayout;
+import java.awt.GridLayout;
+
+import javax.swing.JList;
+import javax.swing.JPanel;
+import javax.swing.JScrollPane;
+
+import org.gvsig.andami.PluginServices;
+import org.gvsig.gui.beans.swing.JButton;
+import org.gvsig.utils.listManager.ListManager;
+
+public class ListManagerSkin extends JPanel {
+
+    private static final long serialVersionUID = 5194138202300759734L;
+    private JScrollPane jScrollPane = null;
+    private JPanel jPanel = null;
+    private JButton jButtonDown = null;
+    private JButton jButtonUp = null;
+    private JButton jButtonAdd = null;
+    private JButton jButtonDel = null;
+
+    private ListManager listManager;// = new ListManager();
+
+    private JList jList = null;
+    private JPanel jPanel1 = null;
+
+    /**
+     * This method initializes jScrollPane
+     * 
+     * @return javax.swing.JScrollPane
+     */
+    private JScrollPane getJScrollPane() {
+        if (jScrollPane == null) {
+            jScrollPane = new JScrollPane();
+            jScrollPane.setViewportView(getJList());
+        }
+        return jScrollPane;
+    }
+
+    /**
+     * This method initializes jPanel
+     * 
+     * @return javax.swing.JPanel
+     */
+    private JPanel getJPanel() {
+        if (jPanel == null) {
+            jPanel = new JPanel();
+            FlowLayout flowLayout = new FlowLayout();
+            flowLayout.setAlignment(FlowLayout.RIGHT);
+            jPanel.setLayout(flowLayout);
+            jPanel.add(getJPanel1(), null);
+        }
+        return jPanel;
+    }
+
+    /**
+     * This method initializes jButton
+     * 
+     * @return javax.swing.JButton
+     */
+    private JButton getJButtonDown() {
+        if (jButtonDown == null) {
+            jButtonDown = new JButton("abajo");
+            jButtonDown.setText(PluginServices.getText(this, "abajo"));
+        }
+        return jButtonDown;
+    }
+
+    /**
+     * This method initializes jButton1
+     * 
+     * @return javax.swing.JButton
+     */
+    private JButton getJButtonUp() {
+        if (jButtonUp == null) {
+            jButtonUp = new JButton("arriba");
+            jButtonUp.setText(PluginServices.getText(this, "arriba"));
+        }
+        return jButtonUp;
+    }
+
+    /**
+     * This method initializes jButton2
+     * 
+     * @return javax.swing.JButton
+     */
+    private JButton getJButtonAdd() {
+        if (jButtonAdd == null) {
+            jButtonAdd = new JButton("A�adir");
+            jButtonAdd.setText(PluginServices.getText(this, "Anadir"));
+        }
+        return jButtonAdd;
+    }
+
+    /**
+     * This method initializes jButton3
+     * 
+     * @return javax.swing.JButton
+     */
+    private JButton getJButtonDel() {
+        if (jButtonDel == null) {
+            jButtonDel = new JButton("Eliminar");
+            jButtonDel.setText(PluginServices.getText(this, "Eliminar"));
+        }
+        return jButtonDel;
+    }
+
+    /**
+     * This method initializes jList
+     * 
+     * @return javax.swing.JList
+     */
+    private JList getJList() {
+        if (jList == null) {
+            jList = new JList();
+        }
+        return jList;
+    }
+
+    /**
+     * This is the default constructor
+     */
+    public ListManagerSkin(boolean down) {
+        super();
+        listManager = new ListManager(down);
+        initialize();
+    }
+
+    /**
+     * This method initializes this
+     * 
+     * @return void
+     */
+    private void initialize() {
+        this.setLayout(new BorderLayout());
+        this.setSize(421, 349);
+        this.add(getJScrollPane(), BorderLayout.CENTER);
+        this.add(getJPanel(), BorderLayout.EAST);
+        listManager.setBtnDown(getJButtonDown());
+        listManager.setBtnUp(getJButtonUp());
+        listManager.setBtnAdd(getJButtonAdd());
+        listManager.setBtnDel(getJButtonDel());
+        listManager.setList(getJList());
+        listManager.initialize();
+
+    }
+
+    /**
+     * @return Returns the listManager.
+     */
+    public ListManager getListManager() {
+        return listManager;
+    }
+
+    /**
+     * This method initializes jPanel1
+     * 
+     * @return javax.swing.JPanel
+     */
+    private JPanel getJPanel1() {
+        if (jPanel1 == null) {
+            jPanel1 = new JPanel(new GridLayout(6, 1, 5, 5));
+
+            jPanel1.setPreferredSize(new Dimension(100, 180));
+            jPanel1.add(getJButtonAdd(), null);
+            jPanel1.add(getJButtonDel(), null);
+            jPanel1.add(getJButtonUp(), null);
+            jPanel1.add(getJButtonDown(), null);
+        }
+        return jPanel1;
+    }
+} // @jve:decl-index=0:visual-constraint="10,10"

Property changes on: tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/app/project/documents/gui/ListManagerSkin.java
___________________________________________________________________
Added: svn:keywords
   + Author Date Id Revision
Added: svn:eol-style
   + native

Index: tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/app/project/documents/gui/SymbolCellEditor.java
===================================================================
--- tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/app/project/documents/gui/SymbolCellEditor.java	(revision 0)
+++ tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/app/project/documents/gui/SymbolCellEditor.java	(revision 38653)
@@ -0,0 +1,188 @@
+/* gvSIG. Geographic Information System of the Valencian Government
+ *
+ * Copyright (C) 2007-2008 Infrastructures and Transports Department
+ * of the Valencian Government (CIT)
+ * 
+ * This program is free software; you can redistribute it and/or
+ * modify it under the terms of the GNU General Public License
+ * as published by the Free Software Foundation; either version 2
+ * of the License, or (at your option) any later version.
+ * 
+ * This program is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
+ * GNU General Public License for more details.
+ * 
+ * You should have received a copy of the GNU General Public License
+ * along with this program; if not, write to the Free Software
+ * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, 
+ * MA  02110-1301, USA.
+ * 
+ */
+package org.gvsig.app.project.documents.gui;
+
+import java.awt.Component;
+import java.awt.event.KeyAdapter;
+import java.awt.event.KeyEvent;
+import java.awt.event.MouseEvent;
+import java.awt.event.MouseListener;
+import java.util.ArrayList;
+import java.util.EventObject;
+
+import javax.swing.JButton;
+import javax.swing.JTable;
+import javax.swing.event.CellEditorListener;
+import javax.swing.event.ChangeEvent;
+import javax.swing.table.TableCellEditor;
+
+import org.gvsig.andami.PluginServices;
+import org.gvsig.app.project.documents.view.legend.gui.PanelEditSymbol;
+import org.gvsig.fmap.mapcontext.rendering.symbols.ISymbol;
+
+/**
+ * Cell Editor de ISymbols. Controla los eventos de edici�n que se realicen
+ * sobre la columna de s�mbolos.
+ * 
+ * @author Vicente Caballero Navarro
+ */
+public class SymbolCellEditor extends JButton implements TableCellEditor {
+
+    private static final long serialVersionUID = -913612642474934455L;
+    private ArrayList listeners = new ArrayList();
+    private ISymbol symbol;
+    private int shapeType;
+    private PanelEditSymbol symbolPanel;
+
+    public SymbolCellEditor(int shapeType) {
+        this.shapeType = shapeType;
+        addMouseListener(new MouseListener() {
+
+            public void mouseClicked(MouseEvent e) {
+                if (e.getClickCount() == 2) {
+                    symbolPanel.setSymbol(symbol);
+                    // symbolPanel.setShapeType(SymbolCellEditor.this.shapeType);
+                    symbolPanel.setShapeType(symbol.getSymbolType());
+                    PluginServices.getMDIManager().addWindow(symbolPanel);
+                    if (symbolPanel.isOK()) {
+                        symbol = (ISymbol) symbolPanel.getSymbol();
+                        stopCellEditing();
+                    }
+                }
+            }
+
+            public void mouseEntered(MouseEvent e) {
+            }
+
+            public void mouseExited(MouseEvent e) {
+            }
+
+            public void mousePressed(MouseEvent e) {
+            }
+
+            public void mouseReleased(MouseEvent e) {
+            }
+
+        });
+        addKeyListener(new KeyAdapter() {
+
+            public void keyReleased(KeyEvent e) {
+                if (e.getKeyCode() == KeyEvent.VK_ENTER) {
+                    stopCellEditing();
+                } else
+                    if (e.getKeyCode() == KeyEvent.VK_ESCAPE) {
+                        cancelCellEditing();
+                    }
+            }
+        });
+        symbolPanel = new PanelEditSymbol();
+
+    }
+
+    // Implement the one CellEditor method that AbstractCellEditor doesn't.
+    public Object getCellEditorValue() {
+        return symbol;
+    }
+
+    // Implement the one method defined by TableCellEditor.
+    public Component getTableCellEditorComponent(JTable table, Object value,
+        boolean isSelected, int row, int column) {
+        symbol = (ISymbol) value;
+        // setBackground(symbol.getColor());
+
+        return this;
+    }
+
+    /**
+     * DOCUMENT ME!
+     */
+    public void cancelCellEditing() {
+        if (symbol != null) {
+            // setBackground(symbol.getColor());
+        }
+
+        for (int i = 0; i < listeners.size(); i++) {
+            CellEditorListener l = (CellEditorListener) listeners.get(i);
+            ChangeEvent evt = new ChangeEvent(this);
+            l.editingCanceled(evt);
+        }
+    }
+
+    /**
+     * DOCUMENT ME!
+     * 
+     * @return DOCUMENT ME!
+     */
+    public boolean stopCellEditing() {
+        for (int i = 0; i < listeners.size(); i++) {
+            CellEditorListener l = (CellEditorListener) listeners.get(i);
+            ChangeEvent evt = new ChangeEvent(this);
+            l.editingStopped(evt);
+        }
+
+        return true;
+    }
+
+    /**
+     * DOCUMENT ME!
+     * 
+     * @param anEvent
+     *            DOCUMENT ME!
+     * 
+     * @return DOCUMENT ME!
+     */
+    public boolean isCellEditable(EventObject anEvent) {
+        return true;
+    }
+
+    /**
+     * DOCUMENT ME!
+     * 
+     * @param anEvent
+     *            DOCUMENT ME!
+     * 
+     * @return DOCUMENT ME!
+     */
+    public boolean shouldSelectCell(EventObject anEvent) {
+        return true;
+    }
+
+    /**
+     * DOCUMENT ME!
+     * 
+     * @param l
+     *            DOCUMENT ME!
+     */
+    public void addCellEditorListener(CellEditorListener l) {
+        listeners.add(l);
+    }
+
+    /**
+     * DOCUMENT ME!
+     * 
+     * @param l
+     *            DOCUMENT ME!
+     */
+    public void removeCellEditorListener(CellEditorListener l) {
+        listeners.remove(l);
+    }
+}

Property changes on: tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/app/project/documents/gui/SymbolCellEditor.java
___________________________________________________________________
Added: svn:eol-style
   + native
Added: svn:keywords
   + Author Date Id Revision

Index: tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/app/project/documents/gui/ProjectElementListModel.java
===================================================================
--- tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/app/project/documents/gui/ProjectElementListModel.java	(revision 0)
+++ tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/app/project/documents/gui/ProjectElementListModel.java	(revision 38653)
@@ -0,0 +1,72 @@
+/* gvSIG. Geographic Information System of the Valencian Government
+ *
+ * Copyright (C) 2007-2008 Infrastructures and Transports Department
+ * of the Valencian Government (CIT)
+ * 
+ * This program is free software; you can redistribute it and/or
+ * modify it under the terms of the GNU General Public License
+ * as published by the Free Software Foundation; either version 2
+ * of the License, or (at your option) any later version.
+ * 
+ * This program is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
+ * GNU General Public License for more details.
+ * 
+ * You should have received a copy of the GNU General Public License
+ * along with this program; if not, write to the Free Software
+ * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, 
+ * MA  02110-1301, USA.
+ * 
+ */
+package org.gvsig.app.project.documents.gui;
+
+import java.util.ArrayList;
+
+import javax.swing.AbstractListModel;
+
+/**
+ * Modelo para presentar los ProjectElement's (vistas, mapas, tablas) en un
+ * JList
+ * 
+ * @author Fernando Gonz�lez Cort�s
+ */
+public class ProjectElementListModel extends AbstractListModel {
+
+    private static final long serialVersionUID = 5224594892273078623L;
+    private ArrayList els;
+
+    /**
+     * Creates a new MyListModel object.
+     * 
+     * @param els
+     *            Elementos del modelo
+     */
+    public ProjectElementListModel(ArrayList els) {
+        this.els = els;
+    }
+
+    /**
+     * Obtiene el tama�o de la lista
+     * 
+     * @return tama�o de la lista
+     */
+    public int getSize() {
+        if (els == null) {
+            return 0;
+        }
+
+        return els.size();
+    }
+
+    /**
+     * @see javax.swing.ListModel#getElementAt(int)
+     */
+    public Object getElementAt(int index) {
+        if (els == null) {
+            return "";
+        }
+
+        return els.get(index);
+    }
+}

Property changes on: tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/app/project/documents/gui/ProjectElementListModel.java
___________________________________________________________________
Added: svn:keywords
   + Author Date Id Revision
Added: svn:eol-style
   + native

Index: tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/app/project/documents/gui/ProjectWindow.java
===================================================================
--- tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/app/project/documents/gui/ProjectWindow.java	(revision 0)
+++ tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/app/project/documents/gui/ProjectWindow.java	(revision 38653)
@@ -0,0 +1,1125 @@
+/* gvSIG. Geographic Information System of the Valencian Government
+ *
+ * Copyright (C) 2007-2008 Infrastructures and Transports Department
+ * of the Valencian Government (CIT)
+ * 
+ * This program is free software; you can redistribute it and/or
+ * modify it under the terms of the GNU General Public License
+ * as published by the Free Software Foundation; either version 2
+ * of the License, or (at your option) any later version.
+ * 
+ * This program is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
+ * GNU General Public License for more details.
+ * 
+ * You should have received a copy of the GNU General Public License
+ * along with this program; if not, write to the Free Software
+ * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, 
+ * MA  02110-1301, USA.
+ * 
+ */
+package org.gvsig.app.project.documents.gui;
+
+import java.awt.Component;
+import java.awt.Dimension;
+import java.awt.FlowLayout;
+import java.awt.GridBagConstraints;
+import java.awt.GridBagLayout;
+import java.awt.GridLayout;
+import java.awt.Insets;
+import java.beans.PropertyChangeEvent;
+import java.beans.PropertyChangeListener;
+import java.io.File;
+import java.util.ArrayList;
+import java.util.Collections;
+import java.util.Comparator;
+import java.util.Enumeration;
+import java.util.Iterator;
+import java.util.List;
+
+import javax.swing.AbstractButton;
+import javax.swing.BorderFactory;
+import javax.swing.ButtonGroup;
+import javax.swing.JButton;
+import javax.swing.JComponent;
+import javax.swing.JDialog;
+import javax.swing.JLabel;
+import javax.swing.JList;
+import javax.swing.JOptionPane;
+import javax.swing.JPanel;
+import javax.swing.JRadioButton;
+import javax.swing.JScrollPane;
+import javax.swing.ScrollPaneConstants;
+import javax.swing.SwingUtilities;
+import javax.swing.border.TitledBorder;
+
+import org.gvsig.andami.PluginServices;
+import org.gvsig.andami.help.Help;
+import org.gvsig.andami.messages.NotificationManager;
+import org.gvsig.andami.ui.mdiManager.IWindow;
+import org.gvsig.andami.ui.mdiManager.MDIManager;
+import org.gvsig.andami.ui.mdiManager.SingletonWindow;
+import org.gvsig.andami.ui.mdiManager.WindowInfo;
+import org.gvsig.app.extension.ProjectExtension;
+import org.gvsig.app.project.Project;
+import org.gvsig.app.project.ProjectManager;
+import org.gvsig.app.project.documents.AbstractDocument;
+import org.gvsig.app.project.documents.Document;
+import org.gvsig.app.project.documents.DocumentManager;
+import org.gvsig.tools.observer.Observable;
+import org.gvsig.tools.observer.Observer;
+import org.gvsig.tools.swing.api.ToolsSwingLocator;
+import org.gvsig.tools.swing.api.usability.UsabilitySwingManager;
+import org.gvsig.utils.DefaultListModel;
+
+/**
+ * Clase principal del proyecto donde se puede operar para crear cualquier tipo
+ * de documento.
+ * 
+ * @author Vicente Caballero Navarro
+ * @author gvSIG team
+ */
+public class ProjectWindow extends JPanel implements PropertyChangeListener,
+    IWindow, SingletonWindow, Observer {
+
+    private static final long serialVersionUID = 7315293357719796556L;
+
+    public static final String PERSISTENCE_DEFINITION_NAME = "ProjectWindow";
+
+    private JScrollPane documentTypes = null;
+    private JPanel documentTypesList = null;
+    private JRadioButton[] btnsDocuments = null;
+    private ButtonGroup grupo = new ButtonGroup();
+    private JPanel documentsPanel = null;
+    private JList lstDocs = null;
+    private JPanel jPanel2 = null;
+    private JButton btnNuevo = null;
+    private JButton btnPropiedades = null;
+    private JButton btnAbrir = null;
+    private JButton btnBorrar = null;
+    private JButton btnRenombrar = null;
+    private JPanel propertiesPanel = null;
+    private JLabel jLabel = null;
+    private JLabel lblNombreSesion = null;
+    private JLabel jLabel1 = null;
+    private JLabel lblGuardado = null;
+    private JLabel jLabel2 = null;
+    private JLabel lblFecha = null;
+    private JButton btnImportar = null;
+    private JButton btnExportar = null;
+    private JButton btnEditar = null;
+    // The properties of the Project Manager window (size, position, etc):
+    private WindowInfo m_viewInfo = null;
+
+    private Project project;
+    private UsabilitySwingManager manager = ToolsSwingLocator
+        .getUsabilitySwingManager();
+
+    private JScrollPane documentsScrollPane = null;
+    private JPanel projectButtonsPanel = null;
+
+    /**
+     * This is the default constructor
+     * 
+     * @param project
+     *            Extension
+     */
+    public ProjectWindow() {
+        super();
+        initialize();
+        refreshControls();
+        Help.getHelp().enableHelp(this, this.getClass().getName());
+        // Observe document factory registration changes
+        ProjectManager.getInstance().addObserver(this);
+    }
+
+    /**
+     * Asigna el proyecto a la ventana
+     * 
+     * @param project
+     *            Proyecto con el que se operar� a trav�s de este di�logo
+     */
+    public void setProject(Project project) {
+        this.project = project;
+        project.addPropertyChangeListener(this);
+        refreshControls();
+    }
+
+    /**
+     * Activa los botones de la botonera del medio o los desactiva en funci�n de
+     * que est� seleccionado o no un elemento de proyecto en la lista del medio
+     */
+    private void activarBotones() {
+        if (lstDocs.getSelectedIndex() != -1) {
+            btnAbrir.setEnabled(true);
+            btnBorrar.setEnabled(true);
+            if (lstDocs.getSelectedIndices().length == 1) {
+                btnRenombrar.setEnabled(true);
+                btnPropiedades.setEnabled(true);
+            } else {
+                btnRenombrar.setEnabled(false);
+                btnPropiedades.setEnabled(false);
+            }
+        } else {
+            btnAbrir.setEnabled(false);
+            btnBorrar.setEnabled(false);
+            btnRenombrar.setEnabled(false);
+            btnPropiedades.setEnabled(false);
+        }
+    }
+
+    /**
+     * Refresca la lista de elementos de proyecto con vistas, mapas o tablas,
+     * seg�n la opci�n activada
+     */
+    private void refreshList() {
+        if (project != null) {
+            DefaultListModel model = null;
+            String tituloMarco =
+                PluginServices.getText(this, "documentos_existentes");
+
+            String doctype = getDocumentSelected();
+            model = new DefaultListModel(project.getDocuments(doctype));
+            tituloMarco = getDocumentSelectedName();
+
+            lstDocs.setModel(model);
+            ((TitledBorder) getDocumentsPanel().getBorder())
+                .setTitle(tituloMarco);
+            getDocumentsPanel().repaint(1);
+            activarBotones();
+        }
+    }
+
+    /**
+     * Devuelve el nombre del tipo de documento activo (el mismo que
+     * ProjectDocumentFactory.getRegisterName)
+     * 
+     * 
+     * @return
+     */
+
+    public String getDocumentSelected() {
+        JRadioButton btnSelected = null;
+        for (int i = 0; i < btnsDocuments.length; i++) {
+            if (btnsDocuments[i].isSelected()) {
+                btnSelected = btnsDocuments[i];
+                return btnSelected.getName();
+            }
+        }
+
+        return null;
+    }
+
+    private String getDocumentSelectedName() {
+        JRadioButton btnSelected = null;
+        for (int i = 0; i < btnsDocuments.length; i++) {
+            if (btnsDocuments[i].isSelected()) {
+                btnSelected = btnsDocuments[i];
+                return btnSelected.getText();
+            }
+        }
+
+        return null;
+    }
+
+    /**
+     * Refresca las etiquetas con la informaci�n del proyecto
+     */
+    private void refreshProperties() {
+        if (project != null) {
+            lblNombreSesion.setText(project.getName());
+            String path = ProjectExtension.getPath();
+            if (path != null) {
+                File f = new File(path);
+                lblGuardado.setText(f.toString());
+            } else {
+                lblGuardado.setText("");
+            }
+            lblFecha.setText(project.getCreationDate());
+        }
+    }
+
+    /**
+     * Refresca todo el di�logo
+     */
+    public void refreshControls() {
+        refreshList();
+        refreshProperties();
+    }
+
+    /**
+     * This method initializes this
+     */
+    private void initialize() {
+        this.setLayout(new GridBagLayout());
+        GridBagConstraints c = new GridBagConstraints();
+        c.insets = new Insets(2, 5, 2, 5);
+
+        c.fill = GridBagConstraints.HORIZONTAL;
+        c.weightx = 1.0d;
+        c.weighty = 0.0d;
+        c.gridy = 0;
+        add(getDocumentTypesPanel(), c);
+
+        c.fill = GridBagConstraints.BOTH;
+        c.gridy = 1;
+        c.weightx = 1.0d;
+        c.weighty = 1.0d;
+        add(getDocumentsPanel(), c);
+
+        c.fill = GridBagConstraints.HORIZONTAL;
+        c.weightx = 1.0d;
+        c.weighty = 0.0d;
+        c.gridy = 2;
+        add(getPropertiesPanel(), c);
+
+        this.setMinimumSize(this.getPreferredSize());
+        refreshDocuments();
+    }
+
+    private void createDocumentsInProject(String doctype) {
+        Iterator<? extends Document> documents =
+            ProjectManager.getInstance().createDocumentsByUser(doctype);
+        for (; (documents != null) && (documents.hasNext());) {
+            try {
+                Document document = documents.next();
+                project.add(document);
+                int index =
+                    ((DefaultListModel) lstDocs.getModel()).indexOf(document);
+                lstDocs.setSelectedIndex(index);
+                lstDocs.requestFocus();
+                openDocumentWindow(document);
+            } catch (Exception e) {
+                NotificationManager.addError(e);
+            }
+        }
+    }
+
+    /**
+     * Crea un nuevo project element
+     * 
+     * @throws Exception
+     *             DOCUMENT ME!
+     */
+    private void newProjectDocument() throws Exception {
+        String doctype = getDocumentSelected();
+        createDocumentsInProject(doctype);
+    }
+
+    /**
+     * Abre la ventana de un nuevo documento
+     */
+    private void abrir() {
+        int[] indexes = lstDocs.getSelectedIndices();
+        for (int i = indexes.length - 1; i >= 0; i--) {
+            int index = indexes[i];
+            if (index == -1) {
+                return;
+            }
+            String doctype = getDocumentSelected();
+            List<Document> documents = project.getDocuments(doctype);
+            Document doc = documents.get(index);
+            openDocumentWindow(doc);
+        }
+    }
+
+    private void openDocumentWindow(Document doc) {
+        if (doc != null) {
+            IWindow window = doc.getFactory().getMainWindow(doc);
+            if (window == null) {
+                JOptionPane.showMessageDialog(
+                    (Component) PluginServices.getMainFrame(),
+                    PluginServices.getText(this, "error_opening_the_document"));
+                return;
+            }
+            PluginServices.getMDIManager().addWindow(window,
+                MDIManager.ALIGN_FIRST_LINE_END_CASCADE);
+            project.setModified(true);
+        }
+    }
+
+    /**
+     * Cambia el nombre de un project element
+     */
+    private void renombrar() {
+        int index = lstDocs.getSelectedIndex();
+
+        if (index == -1) {
+            return;
+        }
+        String doctype = getDocumentSelected();
+        List<Document> documents = project.getDocuments(doctype);
+        Document doc = documents.get(index);
+
+        if (doc.isLocked()) {
+            JOptionPane.showMessageDialog(this, PluginServices.getText(this,
+                "locked_element_it_cannot_be_renamed"));
+            return;
+        }
+
+        JOptionPane pane = new JOptionPane();
+        pane.setMessage(PluginServices.getText(this, "introduce_nombre"));
+        pane.setMessageType(JOptionPane.QUESTION_MESSAGE);
+        pane.setWantsInput(true);
+        pane.setInitialSelectionValue(doc.getName());
+        pane.setInputValue(doc.getName());
+        JDialog dlg =
+            pane.createDialog((Component) PluginServices.getMainFrame(),
+                PluginServices.getText(this, "renombrar"));
+        dlg.setModal(true);
+        dlg.setVisible(true);
+
+        String nuevoNombre = pane.getInputValue().toString().trim();
+
+        if (nuevoNombre.length() == 0) {
+            return;
+        }
+
+        for (int i = 0; i < lstDocs.getModel().getSize(); i++) {
+            if (i == index) {
+                continue;
+            }
+            if (((AbstractDocument) lstDocs.getModel().getElementAt(i))
+                .getName().equals(nuevoNombre)) {
+                JOptionPane.showMessageDialog(
+                    (Component) PluginServices.getMainFrame(),
+                    PluginServices.getText(this, "elemento_ya_existe"));
+                return;
+            }
+
+        }
+        doc.setName(nuevoNombre);
+
+        refreshList();
+        project.setModified(true);
+    }
+
+    /**
+     * Borra un project element
+     */
+    private void borrar() {
+        int res =
+            JOptionPane.showConfirmDialog(
+                (Component) PluginServices.getMainFrame(),
+                PluginServices.getText(this, "confirmar_borrar"),
+                PluginServices.getText(this, "borrar"),
+                JOptionPane.YES_NO_OPTION, JOptionPane.INFORMATION_MESSAGE);
+
+        int lastremoved = 0;
+        if (res == JOptionPane.YES_OPTION) {
+            int[] indexes = lstDocs.getSelectedIndices();
+            for (int i = indexes.length - 1; i >= 0; i--) {
+                int index = indexes[i];
+                String s = getDocumentSelected();
+                List<Document> documents = project.getDocuments(s);
+                Document doc = documents.get(index);
+                if (doc.isLocked()) {
+                    JOptionPane.showMessageDialog(this, PluginServices.getText(
+                        this, "locked_element_it_cannot_be_deleted"));
+                    return;
+                }
+                PluginServices.getMDIManager().closeSingletonWindow(doc);
+                project.remove(doc);
+                lastremoved = index;
+            }
+            if (lastremoved > lstDocs.getModel().getSize()) {
+                lastremoved = lstDocs.getModel().getSize();
+            }
+            if (lastremoved >= 0) {
+                lstDocs.setSelectedIndex(lastremoved);
+            }
+            // refreshList();
+            project.setModified(true);
+        }
+    }
+
+    /**
+     * Muestra el di�logo de propiedades de un project element
+     */
+    private void propiedades() {
+        int index = lstDocs.getSelectedIndex();
+
+        if (index == -1) {
+            return;
+        }
+
+        IWindow dlg = null;
+        String doctype = getDocumentSelected();
+        List<Document> documents = project.getDocuments(doctype);
+        Document doc = documents.get(index);
+        if (doc.isLocked()) {
+            JOptionPane.showMessageDialog(this,
+                PluginServices.getText(this, "locked_element"));
+            return;
+        }
+        dlg = doc.getFactory().getPropertiesWindow(doc);
+        PluginServices.getMDIManager().addWindow(dlg);
+
+        refreshControls();
+        lstDocs.setSelectedIndex(index);
+        project.setModified(true);
+    }
+
+    /**
+     * This method initializes jPanel
+     * 
+     * @return JPanel
+     */
+    private JComponent getDocumentTypesPanel() {
+        if (documentTypes == null) {
+
+            documentTypesList =
+                new JPanel(new FlowLayout(FlowLayout.CENTER, 5, 5));
+            documentTypesList.setName("tipoDocPanel");
+            fillDocumentTypeButtons();
+
+            documentTypes = new JScrollPane(documentTypesList);
+            Dimension dim = documentTypesList.getPreferredSize();
+            documentTypes.setMinimumSize(new Dimension(dim.width,
+                dim.height + 35));
+            documentTypes.setBorder(BorderFactory.createTitledBorder(null,
+                PluginServices.getText(this, "tipos_de_documentos"),
+                javax.swing.border.TitledBorder.DEFAULT_JUSTIFICATION,
+                javax.swing.border.TitledBorder.DEFAULT_POSITION, null, null));
+        }
+
+        return documentTypes;
+    }
+
+    /**
+     * Adds a button for each document type
+     */
+    private void fillDocumentTypeButtons() {
+        JRadioButton[] btns = getBtnDocumentTypes();
+        for (int i = 0; i < btns.length; i++) {
+            documentTypesList.add(btns[i]);
+        }
+    }
+
+    /**
+     * This method initializes btnVistas
+     * 
+     * @return JRadioButton
+     */
+    private JRadioButton[] getBtnDocumentTypes() {
+        if (btnsDocuments == null) {
+
+            List<JRadioButton> btns = new ArrayList<JRadioButton>();
+            List<DocumentManager> factories =
+                ProjectManager.getInstance().getDocumentManagers();
+            Collections.sort(factories, new Comparator<DocumentManager>() {
+
+                public int compare(DocumentManager arg0, DocumentManager arg1) {
+                    return arg0.getPriority() - arg1.getPriority();
+                }
+
+            });
+            for (DocumentManager documentFactory : factories) {
+                JRadioButton rb = new JRadioButton();
+
+                rb.setIcon(documentFactory.getIcon());
+                rb.setSelectedIcon(documentFactory.getIconSelected());
+                rb.setHorizontalTextPosition(javax.swing.SwingConstants.CENTER);
+                rb.setText(documentFactory.getTitle());
+                rb.setVerticalTextPosition(javax.swing.SwingConstants.BOTTOM);
+                rb.setName(documentFactory.getTypeName());
+                rb.addChangeListener(new javax.swing.event.ChangeListener() {
+
+                    public void stateChanged(javax.swing.event.ChangeEvent e) {
+                        refreshList();
+                    }
+                });
+                btns.add(rb);
+            }
+            btnsDocuments = btns.toArray(new JRadioButton[0]);
+        }
+        return btnsDocuments;
+    }
+
+    /**
+     * This method initializes jPanel1
+     * 
+     * @return JPanel
+     */
+    private JPanel getDocumentsPanel() {
+        if (documentsPanel == null) {
+            documentsPanel = new JPanel();
+
+            GridBagLayout layout2 = new GridBagLayout();
+            GridBagConstraints c = new GridBagConstraints();
+
+            documentsPanel.setLayout(layout2);
+
+            c.insets = new Insets(2, 5, 2, 5);
+            c.anchor = GridBagConstraints.WEST;
+            c.fill = GridBagConstraints.BOTH;
+            c.weightx = 1.0;
+            c.weighty = 1.0;
+            documentsPanel.add(getDocumentsScrollPane(), c);
+
+            c.anchor = GridBagConstraints.EAST;
+            c.fill = GridBagConstraints.NONE;
+            c.weightx = 0;
+            c.weighty = 0;
+            documentsPanel.add(getDocumentButtonsPanel(), c);
+
+            documentsPanel.setBorder(javax.swing.BorderFactory
+                .createTitledBorder(null,
+                    PluginServices.getText(this, "documentos_existentes"),
+                    javax.swing.border.TitledBorder.DEFAULT_JUSTIFICATION,
+                    javax.swing.border.TitledBorder.DEFAULT_POSITION, null,
+                    null));
+        }
+
+        return documentsPanel;
+    }
+
+    /**
+     * This method initializes lstDocs
+     * 
+     * @return JList
+     */
+    private JList getDocumentsList() {
+        if (lstDocs == null) {
+            lstDocs = new JList();
+            lstDocs.addMouseListener(new java.awt.event.MouseAdapter() {
+
+                public AbstractDocument[] getSelecteds() {
+                    if (lstDocs.getSelectedIndex() < 0) {
+                        return new AbstractDocument[0];
+                    }
+                    Object[] seleteds = lstDocs.getSelectedValues();
+                    AbstractDocument[] returnValue =
+                        new AbstractDocument[seleteds.length];
+                    System.arraycopy(seleteds, 0, returnValue, 0,
+                        seleteds.length);
+                    return returnValue;
+                }
+
+                public AbstractDocument getItem(java.awt.event.MouseEvent e) {
+                    if (lstDocs.getSelectedIndex() < 0) {
+                        return null;
+                    }
+
+                    return null;
+                }
+
+                @Override
+                public void mouseClicked(java.awt.event.MouseEvent e) {
+                    if (e.getButton() == java.awt.event.MouseEvent.BUTTON3) {
+                        /*
+                         * getDocumentSelected();//ProjectView
+                         * getDocumentSelectedName();//Vista
+                         */
+                        String docType = getDocumentSelected();
+                        AbstractDocument[] selecteds = this.getSelecteds();
+
+                        if (selecteds == null) {
+                            return;
+                        }
+                        DocumentContextMenu menu =
+                            new DocumentContextMenu(docType, this.getItem(e),
+                                selecteds);
+                        if (!menu.hasActions()) {
+                            return;
+                        }
+                        lstDocs.add(menu);
+                        menu.show(e.getComponent(), e.getX(), e.getY());
+                        return;
+                    }
+
+                    if (e.getClickCount() == 2) {
+                        abrir();
+                    }
+
+                }
+            });
+            lstDocs
+                .addListSelectionListener(new javax.swing.event.ListSelectionListener() {
+
+                    public void valueChanged(
+                        javax.swing.event.ListSelectionEvent e) {
+                        activarBotones();
+                    }
+                });
+        }
+
+        return lstDocs;
+    }
+
+    /**
+     * This method initializes jPanel2
+     * 
+     * @return JPanel
+     */
+    private JPanel getDocumentButtonsPanel() {
+        if (jPanel2 == null) {
+            jPanel2 = new JPanel();
+
+            // FlowLayout layout = new FlowLayout();
+            GridLayout layout = new GridLayout(5, 1);
+            layout.setVgap(7);
+
+            jPanel2.setLayout(layout);
+            jPanel2.add(getBtnNuevo(), null);
+            jPanel2.add(getBtnAbrir(), null);
+            jPanel2.add(getBtnRenombrar(), null);
+            jPanel2.add(getBtnBorrar(), null);
+            jPanel2.add(getBtnPropiedades(), null);
+        }
+
+        return jPanel2;
+    }
+
+    /**
+     * This method initializes btnNuevo
+     * 
+     * @return JButton
+     */
+    private JButton getBtnNuevo() {
+        if (btnNuevo == null) {
+            btnNuevo = manager.createJButton();
+            btnNuevo.setName("btnNuevo");
+            btnNuevo.setText(PluginServices.getText(this, "nuevo"));
+            btnNuevo.setMargin(new java.awt.Insets(2, 2, 2, 2));
+            btnNuevo.addActionListener(new java.awt.event.ActionListener() {
+
+                public void actionPerformed(java.awt.event.ActionEvent e) {
+                    try {
+                        newProjectDocument();
+                    } catch (Exception e1) {
+                        NotificationManager.addError(e1.getLocalizedMessage(),
+                            e1);
+                    }
+                }
+            });
+        }
+
+        return btnNuevo;
+    }
+
+    /**
+     * This method initializes btnPropiedades
+     * 
+     * @return JButton
+     */
+    private JButton getBtnPropiedades() {
+        if (btnPropiedades == null) {
+            btnPropiedades = manager.createJButton();
+            ;
+            btnPropiedades.setText(PluginServices.getText(this, "propiedades"));
+            btnPropiedades.setName("btnPropiedades");
+            btnPropiedades.setEnabled(false);
+            btnPropiedades.setMargin(new java.awt.Insets(2, 2, 2, 2));
+            btnPropiedades
+                .addActionListener(new java.awt.event.ActionListener() {
+
+                    public void actionPerformed(java.awt.event.ActionEvent e) {
+                        propiedades();
+                    }
+                });
+        }
+
+        return btnPropiedades;
+    }
+
+    /**
+     * This method initializes btnAbrir
+     * 
+     * @return JButton
+     */
+    private JButton getBtnAbrir() {
+        if (btnAbrir == null) {
+            btnAbrir = manager.createJButton();
+            btnAbrir.setName("btnAbrir");
+            btnAbrir.setText(PluginServices.getText(this, "abrir"));
+            btnAbrir.setEnabled(false);
+            btnAbrir.setMargin(new java.awt.Insets(2, 2, 2, 2));
+            btnAbrir.addActionListener(new java.awt.event.ActionListener() {
+
+                public void actionPerformed(java.awt.event.ActionEvent e) {
+                    abrir();
+                }
+            });
+        }
+
+        return btnAbrir;
+    }
+
+    /**
+     * This method initializes btnBorrar
+     * 
+     * @return JButton
+     */
+    private JButton getBtnBorrar() {
+        if (btnBorrar == null) {
+            btnBorrar = manager.createJButton();
+            btnBorrar.setText(PluginServices.getText(this, "borrar"));
+            btnBorrar.setName("btnBorrar");
+            btnBorrar.setEnabled(false);
+            btnBorrar.setMargin(new java.awt.Insets(2, 2, 2, 2));
+            btnBorrar.addActionListener(new java.awt.event.ActionListener() {
+
+                public void actionPerformed(java.awt.event.ActionEvent e) {
+                    borrar();
+                }
+            });
+        }
+
+        return btnBorrar;
+    }
+
+    /**
+     * This method initializes btnRenombrar
+     * 
+     * @return JButton
+     */
+    private JButton getBtnRenombrar() {
+        if (btnRenombrar == null) {
+            btnRenombrar = manager.createJButton();
+            btnRenombrar.setName("btnRenombrar");
+            btnRenombrar.setText(PluginServices.getText(this, "renombrar"));
+            btnRenombrar.setEnabled(false);
+            btnRenombrar.setMargin(new java.awt.Insets(2, 2, 2, 2));
+            btnRenombrar.addActionListener(new java.awt.event.ActionListener() {
+
+                public void actionPerformed(java.awt.event.ActionEvent e) {
+                    renombrar();
+                }
+            });
+        }
+
+        return btnRenombrar;
+    }
+
+    /**
+     * This method initializes jPanel3
+     * 
+     * @return JPanel
+     */
+    private JPanel getPropertiesPanel() {
+        if (propertiesPanel == null) {
+            propertiesPanel = new JPanel(new GridBagLayout());
+            GridBagConstraints c = new GridBagConstraints();
+
+            c.insets = new Insets(2, 5, 0, 5);
+            c.anchor = GridBagConstraints.WEST;
+            c.gridx = 0;
+            c.gridy = 0;
+            propertiesPanel.add(getJLabel(), c);
+
+            c.fill = GridBagConstraints.HORIZONTAL;
+            c.weightx = 1.0;
+            c.gridx = 1;
+            propertiesPanel.add(getLblNombreSesion(), c);
+
+            c.gridx = 0;
+            c.gridy = 1;
+            c.fill = GridBagConstraints.NONE;
+            c.weightx = 0.0;
+            propertiesPanel.add(getJLabel1(), c);
+
+            c.fill = GridBagConstraints.HORIZONTAL;
+            c.weightx = 1.0;
+            c.gridx = 1;
+            propertiesPanel.add(getLblGuardado(), c);
+
+            c.gridx = 0;
+            c.gridy = 2;
+            c.fill = GridBagConstraints.NONE;
+            c.weightx = 0.0;
+            propertiesPanel.add(getJLabel2(), c);
+
+            c.fill = GridBagConstraints.HORIZONTAL;
+            c.weightx = 1.0;
+            c.gridx = 1;
+            propertiesPanel.add(getLblFecha(), c);
+
+            c.gridx = 0;
+            c.gridwidth = 2;
+            c.gridy = 4;
+            c.fill = GridBagConstraints.HORIZONTAL;
+            c.anchor = GridBagConstraints.EAST;
+            propertiesPanel.add(getProjectsButtonPanel(), c);
+
+            propertiesPanel.setBorder(javax.swing.BorderFactory
+                .createTitledBorder(null,
+                    PluginServices.getText(this, "propiedades_sesion"),
+                    javax.swing.border.TitledBorder.DEFAULT_JUSTIFICATION,
+                    javax.swing.border.TitledBorder.DEFAULT_POSITION, null,
+                    null));
+        }
+
+        return propertiesPanel;
+    }
+
+    /**
+     * This method initializes jLabel
+     * 
+     * @return JLabel
+     */
+    private JLabel getJLabel() {
+        if (jLabel == null) {
+            jLabel = new JLabel();
+            jLabel.setText(PluginServices.getText(this, "nombre_sesion") + ":");
+        }
+
+        return jLabel;
+    }
+
+    /**
+     * This method initializes lblNombreSesion
+     * 
+     * @return JLabel
+     */
+    private JLabel getLblNombreSesion() {
+        if (lblNombreSesion == null) {
+            lblNombreSesion = new JLabel();
+            lblNombreSesion.setText("");
+            lblNombreSesion.setName("lblNombreSesion");
+            lblNombreSesion.setAutoscrolls(true);
+        }
+
+        return lblNombreSesion;
+    }
+
+    /**
+     * This method initializes jLabel1
+     * 
+     * @return JLabel
+     */
+    private JLabel getJLabel1() {
+        if (jLabel1 == null) {
+            jLabel1 = new JLabel();
+            jLabel1.setText(PluginServices.getText(this, "guardado") + ":");
+        }
+
+        return jLabel1;
+    }
+
+    /**
+     * This method initializes lblGuardado
+     * 
+     * @return JLabel
+     */
+    private JLabel getLblGuardado() {
+        if (lblGuardado == null) {
+            lblGuardado = new JLabel();
+            lblGuardado.setText("");
+            lblGuardado.setAutoscrolls(true);
+        }
+
+        return lblGuardado;
+    }
+
+    /**
+     * This method initializes jLabel2
+     * 
+     * @return JLabel
+     */
+    private JLabel getJLabel2() {
+        if (jLabel2 == null) {
+            jLabel2 = new JLabel();
+            jLabel2
+                .setText(PluginServices.getText(this, "creation_date") + ":");
+        }
+
+        return jLabel2;
+    }
+
+    /**
+     * This method initializes lblFecha
+     * 
+     * @return JLabel
+     */
+    private JLabel getLblFecha() {
+        if (lblFecha == null) {
+            lblFecha = new JLabel();
+            lblFecha.setText("");
+            lblFecha.setAutoscrolls(true);
+        }
+
+        return lblFecha;
+    }
+
+    /**
+     * This method initializes btnImportar
+     * 
+     * @return JButton
+     */
+    private JButton getBtnImportar() {
+        if (btnImportar == null) {
+            btnImportar = manager.createJButton();
+            btnImportar.setPreferredSize(new java.awt.Dimension(80, 23));
+            btnImportar.setText(PluginServices.getText(this, "importar"));
+            btnImportar.setName("btnImportar");
+            btnImportar.setMargin(new java.awt.Insets(2, 2, 2, 2));
+        }
+
+        return btnImportar;
+    }
+
+    /**
+     * This method initializes btnExportar
+     * 
+     * @return JButton
+     */
+    private JButton getBtnExportar() {
+        if (btnExportar == null) {
+            btnExportar = manager.createJButton();
+            btnExportar.setPreferredSize(new java.awt.Dimension(80, 23));
+            btnExportar.setText(PluginServices.getText(this, "exportar"));
+            btnExportar.setName("btnExportar");
+            btnExportar.setMargin(new java.awt.Insets(2, 2, 2, 2));
+        }
+
+        return btnExportar;
+    }
+
+    /**
+     * This method initializes btnEditar
+     * 
+     * @return JButton
+     */
+    private JButton getBtnEditar() {
+        if (btnEditar == null) {
+            btnEditar = manager.createJButton();
+            btnEditar.setPreferredSize(new java.awt.Dimension(80, 23));
+            btnEditar.setText(PluginServices.getText(this, "propiedades"));
+
+            btnEditar.setName("btnEditar");
+            btnEditar.setMargin(new java.awt.Insets(2, 2, 2, 2));
+
+            btnEditar.addActionListener(new java.awt.event.ActionListener() {
+
+                public void actionPerformed(java.awt.event.ActionEvent e) {
+                    ProjectProperties dlg = new ProjectProperties(project);
+                    PluginServices.getMDIManager().addWindow(dlg);
+                    refreshProperties();
+                }
+            });
+        }
+
+        return btnEditar;
+    }
+
+    /**
+     * This method initializes jScrollPane
+     * 
+     * @return JScrollPane
+     */
+    private JScrollPane getDocumentsScrollPane() {
+        if (documentsScrollPane == null) {
+            documentsScrollPane = new JScrollPane();
+            documentsScrollPane.setViewportView(getDocumentsList());
+            documentsScrollPane.setPreferredSize(new java.awt.Dimension(200,
+                100));
+            documentsScrollPane
+                .setVerticalScrollBarPolicy(ScrollPaneConstants.VERTICAL_SCROLLBAR_AS_NEEDED);
+        }
+
+        return documentsScrollPane;
+    }
+
+    /**
+     * @see com.iver.mdiApp.ui.MDIManager.SingletonWindow#getWindowModel()
+     */
+    public Object getWindowModel() {
+        return project;
+    }
+
+    public Project getProject() {
+        return project;
+    }
+
+    /**
+     * This method is used to get <strong>an initial</strong> ViewInfo object
+     * for this Project Manager window. It is not intended to retrieve the
+     * ViewInfo object in a later time. <strong>Use
+     * PluginServices.getMDIManager().getViewInfo(view) to retrieve the ViewInfo
+     * object at any time after the creation of the object.
+     * 
+     * @see com.iver.mdiApp.ui.MDIManager.IWindow#getWindowInfo()
+     */
+    public WindowInfo getWindowInfo() {
+        if (m_viewInfo == null) {
+            m_viewInfo =
+                new WindowInfo(WindowInfo.MAXIMIZABLE | WindowInfo.RESIZABLE);
+            m_viewInfo.setWidth(this.getWidth());
+            m_viewInfo.setHeight(this.getHeight());
+            m_viewInfo.setNormalWidth(this.getPreferredSize().width);
+            m_viewInfo.setNormalHeight(this.getPreferredSize().height);
+            m_viewInfo.setMinimumSize(getPreferredSize());
+
+            m_viewInfo.setTitle(PluginServices.getText(this, "titulo"));
+        }
+        return m_viewInfo;
+    }
+
+    public void propertyChange(final PropertyChangeEvent evt) {
+		if( !SwingUtilities.isEventDispatchThread() ) {
+			SwingUtilities.invokeLater( new Runnable() {
+				public void run() {
+					propertyChange(evt);
+				}
+			});
+			return;
+		}
+        refreshControls();
+    }
+
+    /**
+     * This method initializes jPanel4
+     * 
+     * @return JPanel
+     */
+    private JPanel getProjectsButtonPanel() {
+        if (projectButtonsPanel == null) {
+            projectButtonsPanel = new JPanel();
+
+            projectButtonsPanel.setLayout(new FlowLayout(FlowLayout.RIGHT));
+            projectButtonsPanel
+                .setComponentOrientation(java.awt.ComponentOrientation.LEFT_TO_RIGHT);
+            // TODO: implement export and import functions
+            // projectButtonsPanel.add(getBtnImportar(), null);
+            // projectButtonsPanel.add(getBtnExportar(), null);
+            projectButtonsPanel.add(getBtnEditar(), null);
+        }
+
+        return projectButtonsPanel;
+    }
+
+    public Object getWindowProfile() {
+        return WindowInfo.PROJECT_PROFILE;
+    }
+
+    public void update(Observable observable, Object notification) {
+        if (observable instanceof ProjectManager) {
+            refreshDocuments();
+        }
+    }
+
+    private void refreshDocuments() {
+        // Setting it to null will make it recreate in the next
+        // getBtnDocuments() call
+        this.btnsDocuments = null;
+
+        // Clear previous document type buttons
+        documentTypesList.removeAll();
+        for (Enumeration<AbstractButton> buttons = grupo.getElements(); buttons
+            .hasMoreElements();) {
+            grupo.remove(buttons.nextElement());
+        }
+
+        JRadioButton[] btnDocuments = getBtnDocumentTypes();
+        for (int i = 0; i < btnDocuments.length; i++) {
+            grupo.add(btnDocuments[i]);
+        }
+        if (btnDocuments.length > 0) {
+            btnDocuments[0].setSelected(true);
+        }
+        fillDocumentTypeButtons();
+    }
+
+}

Property changes on: tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/app/project/documents/gui/ProjectWindow.java
___________________________________________________________________
Added: svn:keywords
   + Author Date Id Revision
Added: svn:eol-style
   + native

Index: tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/app/project/documents/gui/IDocumentWindow.java
===================================================================
--- tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/app/project/documents/gui/IDocumentWindow.java	(revision 0)
+++ tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/app/project/documents/gui/IDocumentWindow.java	(revision 38653)
@@ -0,0 +1,66 @@
+/* gvSIG. Geographic Information System of the Valencian Government
+ *
+ * Copyright (C) 2007-2008 Infrastructures and Transports Department
+ * of the Valencian Government (CIT)
+ * 
+ * This program is free software; you can redistribute it and/or
+ * modify it under the terms of the GNU General Public License
+ * as published by the Free Software Foundation; either version 2
+ * of the License, or (at your option) any later version.
+ * 
+ * This program is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
+ * GNU General Public License for more details.
+ * 
+ * You should have received a copy of the GNU General Public License
+ * along with this program; if not, write to the Free Software
+ * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, 
+ * MA  02110-1301, USA.
+ * 
+ */
+package org.gvsig.app.project.documents.gui;
+
+import org.gvsig.andami.ui.mdiManager.IWindow;
+import org.gvsig.andami.ui.mdiManager.IWindowListener;
+import org.gvsig.andami.ui.mdiManager.SingletonWindow;
+import org.gvsig.app.project.documents.Document;
+
+/**
+ * @author Miguel �ngel Querol Carratal� <querol_mig@gva.es>
+ * 
+ *         Interfaz que tienen que implementar las clases de interfaz de
+ *         usuario de los documentos que se quieran insertar en gvSIG. Estas
+ *         clases se usar�n para cargar y guardar las propiedades graficas de la
+ *         ventana
+ *         del documento como tama�os y posiciones.
+ */
+public interface IDocumentWindow extends IWindow, IWindowListener,
+    SingletonWindow {
+
+    /**
+     * M�todo para obtener un windowData con las propiedades de la
+     * ventana del documento como pueden ser tama�os, posiciones y
+     * estados de sliders, divisores etc. Este m�todo ser� llamado
+     * para guardar los datos a disco. Lo llamar� la clase project para
+     * obtener los datos y asi guardarlos.
+     * 
+     * @return un windowData con los datos de la ventana.
+     */
+    public WindowLayout getWindowLayout();
+
+    /**
+     * M�todo para cargar los datos de la ventana de proyecto. El widowData
+     * guardado
+     * se le pasa a la clase de interfaz de usuario correspondiente a la ventana
+     * del documento.
+     * 
+     * @param winData
+     */
+    public void setWindowLayout(WindowLayout layout);
+
+    public void setDocument(Document document);
+
+    public Document getDocument();
+
+}

Property changes on: tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/app/project/documents/gui/IDocumentWindow.java
___________________________________________________________________
Added: svn:keywords
   + Author Date Id Revision
Added: svn:eol-style
   + native

Index: tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/app/project/documents/DocumentActionGroup.java
===================================================================
--- tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/app/project/documents/DocumentActionGroup.java	(revision 0)
+++ tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/app/project/documents/DocumentActionGroup.java	(revision 38653)
@@ -0,0 +1,10 @@
+package org.gvsig.app.project.documents;
+
+public interface DocumentActionGroup {
+
+	public String getTitle();
+	
+	public String getDescription();
+	
+	public int getOrder();
+}

Property changes on: tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/app/project/documents/DocumentActionGroup.java
___________________________________________________________________
Added: svn:mime-type
   + text/plain

Index: tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/app/project/documents/DocumentManager.java
===================================================================
--- tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/app/project/documents/DocumentManager.java	(revision 0)
+++ tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/app/project/documents/DocumentManager.java	(revision 38653)
@@ -0,0 +1,122 @@
+package org.gvsig.app.project.documents;
+
+import java.util.Iterator;
+
+import javax.swing.ImageIcon;
+
+import org.gvsig.andami.ui.mdiManager.IWindow;
+import org.gvsig.app.project.Project;
+import org.gvsig.app.project.documents.gui.IDocumentWindow;
+import org.gvsig.app.project.documents.gui.WindowLayout;
+import org.gvsig.tools.extensionpoint.ExtensionBuilder;
+import org.gvsig.tools.persistence.PersistenceFactory;
+
+public interface DocumentManager extends ExtensionBuilder, PersistenceFactory{
+
+	/**
+	 * Returns the type of document priority.
+	 *
+	 * @return Priority.
+	 */
+	public int getPriority();
+
+	/**
+	 * Returns tdocumenthe icon for the type of document.
+	 *
+	 * @return Image.
+	 */
+	public ImageIcon getIcon();
+
+	/**
+	 * Returns the icon for the type of document when is selected
+	 *
+	 * @return Image.
+	 */
+	public ImageIcon getIconSelected();
+
+	/**
+	 * Create a new ProjectDocument.
+	 *
+	 * @param project Opened project.
+	 *
+	 * @return ProjectDocument.
+	 */
+	public AbstractDocument createDocument();
+
+	        /**
+     * Uses a gui to be able from the characteristics that we want a
+     * ProjectDocument
+     * 
+     * @return a new Document
+     * 
+     * @deprecated user {@link #createDocumentsByUser()} instead
+     */
+	public AbstractDocument createDocumentByUser();
+
+    /**
+     * Uses a gui to be able from the characteristics that we want a
+     * ProjectDocument
+     * 
+     * @return the created documents
+     */
+    public Iterator<? extends Document> createDocumentsByUser();
+
+	/**
+	 * Returns the title of type of document.
+	 *
+	 * @return String title for type of document
+	 */
+	public String getTitle();
+
+	/**
+	 * Returns the type name of the document factory.
+	 *
+	 * @return Name of registration
+	 */
+	public String getTypeName();
+
+	/**
+	 * Return the main window asociated to the passed document. 
+	 * If the window alreade exists return it. If not, a new
+	 * window is created.
+	 * 
+	 * @param doc
+	 * @return Window asociated to document
+	 */
+	public IWindow getMainWindow(Document doc) ;
+	
+	/**
+	 * Return the main window asociated to the document.
+	 * 
+	 * @param doc, layout
+	 * @return Window asociated to document
+	 */
+	public IWindow getMainWindow(Document doc, WindowLayout layout) ;
+	
+	/**
+	 * Return the windows properties asociated to the document.
+	 * @param doc
+	 * @return
+	 */
+	public IWindow getPropertiesWindow(Document doc) ;
+	
+	/**
+	 * Return true if the name exists to another document.
+	 *
+	 * @param project
+	 * @param documentName
+	 *
+	 * @return True if the name exists.
+	 * @deprecated use instead  project.getDocument
+	 */
+	public boolean existName(Project project, String documentName);
+	
+	/**
+	 * Return the class that implement the main window for this type of
+	 * documents.
+	 * 
+	 * @return the class of main window 
+	 */
+    public Class<? extends IDocumentWindow> getMainWindowClass();
+
+}
\ No newline at end of file

Property changes on: tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/app/project/documents/DocumentManager.java
___________________________________________________________________
Added: svn:mime-type
   + text/plain

Index: tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/app/project/documents/view/BaseViewDocument.java
===================================================================
--- tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/app/project/documents/view/BaseViewDocument.java	(revision 0)
+++ tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/app/project/documents/view/BaseViewDocument.java	(revision 38653)
@@ -0,0 +1,272 @@
+/* gvSIG. Geographic Information System of the Valencian Government
+*
+* Copyright (C) 2007-2009 Infrastructures and Transports Department
+* of the Valencian Government (CIT)
+* 
+* This program is free software; you can redistribute it and/or
+* modify it under the terms of the GNU General Public License
+* as published by the Free Software Foundation; either version 2
+* of the License, or (at your option) any later version.
+* 
+* This program is distributed in the hope that it will be useful,
+* but WITHOUT ANY WARRANTY; without even the implied warranty of
+* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
+* GNU General Public License for more details.
+* 
+* You should have received a copy of the GNU General Public License
+* along with this program; if not, write to the Free Software
+* Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, 
+* MA  02110-1301, USA.
+* 
+*/
+
+/*
+* AUTHORS (In addition to CIT):
+* 2004-2009 IVER TI
+*   
+*/
+
+package org.gvsig.app.project.documents.view;
+
+import java.awt.Color;
+import java.awt.Component;
+import java.awt.Dimension;
+import java.util.List;
+
+import javax.swing.JOptionPane;
+import javax.swing.JPanel;
+import javax.swing.JScrollPane;
+
+import org.cresques.cts.IProjection;
+
+import org.gvsig.andami.PluginServices;
+import org.gvsig.andami.ui.mdiManager.IWindow;
+import org.gvsig.andami.ui.mdiManager.WindowInfo;
+import org.gvsig.app.project.documents.AbstractDocument;
+import org.gvsig.app.project.documents.DocumentManager;
+import org.gvsig.app.project.documents.view.info.gui.HTMLInfoToolPanel;
+import org.gvsig.fmap.mapcontext.MapContext;
+import org.gvsig.fmap.mapcontext.events.ErrorEvent;
+import org.gvsig.fmap.mapcontext.events.listeners.ErrorListener;
+import org.gvsig.fmap.mapcontext.layers.CancelationException;
+import org.gvsig.fmap.mapcontext.layers.FLayer;
+import org.gvsig.fmap.mapcontext.layers.FLayers;
+import org.gvsig.tools.exception.BaseException;
+import org.gvsig.tools.persistence.PersistentState;
+import org.gvsig.tools.persistence.exception.PersistenceException;
+
+/**
+ *
+ * @author 2005-         Vicente Caballero
+ * @author 2009-         Joaquin del Cerro
+ * 
+ */
+
+public abstract class BaseViewDocument extends AbstractDocument implements ErrorListener,
+		ViewDocument {
+
+	/**
+	 * 
+	 */
+	private static final long serialVersionUID = -2621709089720665902L;
+	
+	public static final String PERSISTENCE_DEFINITION_NAME = "BaseViewDocument";
+	
+	protected MapContext mapOverViewContext;
+	protected MapContext mapContext;
+	
+	public BaseViewDocument() {
+		super();
+	}
+	
+	public BaseViewDocument(DocumentManager factory) {
+		super(factory);
+	}
+	
+	/**
+	 * Gets the MapContext of the main map in the view.
+	 *
+	 * @return the  main MapContext
+	 */
+	public MapContext getMapContext() {
+		return mapContext;
+	}
+
+	/**
+	 * Gets the MapContext from the locator, which is the
+	 * small map in the left-bottom corner of the View.
+	 *
+	 * @return the locator MapContext
+	 */
+	public MapContext getMapOverViewContext() {
+		return mapOverViewContext;
+	}
+
+	public void setMapContext(MapContext fmap) {
+		mapContext = fmap;
+		fmap.addErrorListener(this);
+	}
+
+	public void setMapOverViewContext(MapContext fmap) {
+		mapOverViewContext = fmap;
+		mapOverViewContext.setProjection(mapContext.getProjection());
+	}
+
+	public void showErrors(){
+		if (mapContext.getLayersError().size()>0){
+			String layersError="";
+			for (int i=0;i<mapContext.getLayersError().size();i++){
+				layersError=layersError+"\n"+(String)mapContext.getLayersError().get(i);
+			}
+			JOptionPane.showMessageDialog((Component)PluginServices.getMainFrame(),
+					PluginServices.getText(this,"fallo_capas")+" : \n"+
+					layersError);
+		}
+	}
+
+	/**
+	 * Reports to the user a bundle of driver exceptions produced in the
+	 * same atomic MapContext transaction
+	 */
+	@SuppressWarnings("rawtypes") 
+	public void reportDriverExceptions(String introductoryText, List driverExceptions) {
+		HtmlWindow htmlPanel = new HtmlWindow(570, 600, PluginServices.getText(this,"driver_error"));
+		String htmlText = "";
+		if(introductoryText == null){
+			htmlText += "<h2 text=\"#000080\">"+PluginServices.getText(this,"se_han_producido_los_siguientes_errores_durante_la_carga_de_las_capas")+"</h2>";
+		}else{
+			htmlText += introductoryText;
+		}
+		int numErrors = driverExceptions.size();
+		for(int i = 0; i < numErrors; i++){
+			//htmlText += "<br>\n";
+			BaseException exception = (BaseException) driverExceptions.get(i);
+			htmlText +="<p text=\"#550080\">_________________________________________________________________________________________</p>";
+			htmlText += "<h3>"+PluginServices.getText(this,exception.getMessageKey())+"</h3>";
+			htmlText += "<p>"+exception.getMessage()+"</p>";
+			htmlText +="<p text=\"#550080\">_________________________________________________________________________________________</p>";
+		}
+
+		System.out.println(htmlText);
+		htmlPanel.show(htmlText);
+
+		PluginServices.getMDIManager().addCentredWindow(htmlPanel);
+
+	}
+
+	/**
+	 * HtmlInfoToolPanel that implements IWindow
+	 * @author azabala
+	 *
+	 */
+	class HtmlWindow extends JPanel implements IWindow {
+		/**
+		 * 
+		 */
+		private static final long serialVersionUID = 1151465547277478664L;
+		
+		private HTMLInfoToolPanel htmlPanel=new HTMLInfoToolPanel();
+		WindowInfo viewInfo = null;
+		public HtmlWindow(int width, int height, String windowTitle){
+			htmlPanel.setBackground(Color.white);
+			JScrollPane scrollPane=new JScrollPane(htmlPanel);
+			scrollPane.setPreferredSize(new Dimension(width-30,height-30));
+			this.add(scrollPane);
+			viewInfo = new WindowInfo(WindowInfo.MODELESSDIALOG);
+			viewInfo.setTitle(windowTitle);
+			viewInfo.setWidth(width);
+			viewInfo.setHeight(height);
+		}
+
+		public void show(String htmlText) {
+			htmlPanel.show(htmlText);
+		}
+
+		public WindowInfo getWindowInfo() {
+			return viewInfo;
+		}
+		public Object getWindowProfile() {
+			return WindowInfo.PROPERTIES_PROFILE;
+		}
+
+	}
+
+	public IProjection getProjection() {
+		return mapContext.getProjection();
+	}
+
+	public void setProjection (IProjection proj) {
+		mapContext.setProjection(proj);
+		mapOverViewContext.setProjection(proj);
+	}
+
+	public IProjection getOverViewProjection() {
+		return mapOverViewContext.getProjection();
+	}
+
+	public void afterRemove() {
+		// FIXME: Parece que no recorre correctamente el arbol de capas
+		
+		FLayers layers=this.getMapContext().getLayers();
+
+		for (int i = layers.getLayersCount()-1; i>=0; i--){
+        	try {
+                layers.getLayer(i).getParentLayer().removeLayer(layers.getLayer(i));
+			} catch (CancelationException e1) {
+    			e1.printStackTrace();
+    		}
+    	}
+		getMapContext().dispose();
+		getMapOverViewContext().dispose();
+	}
+
+	public void afterAdd() {
+		// Do nothing
+	}
+
+
+	public void setBackColor(Color c) {
+		getMapContext().getViewPort().setBackColor(c);
+	}
+
+	public void errorThrown(ErrorEvent e) {
+			JOptionPane.showMessageDialog((Component)PluginServices.getMainFrame(),
+					PluginServices.getText(this,"fallo_capas")+" : \n"+
+					e.getMessage());
+
+	}
+
+	public boolean isLocked() {
+		if(super.isLocked()) return true;
+		FLayers layers = getMapContext().getLayers();
+		for(int i=0; i<layers.getLayersCount(); i++){
+			FLayer layer = layers.getLayer(i);
+			if (layer.isEditing()){
+				return true;
+			}
+		}
+		return false;
+	}
+	
+	public void saveToState(PersistentState state) throws PersistenceException {
+		super.saveToState(state);
+		state.set("mainMapContext", this.getMapContext());
+		if( this.getMapOverViewContext() != null ) {
+			state.set("useMapOverview", true);
+		} else {
+			state.set("useMapOverview", false);
+		}
+		state.set("overviewMapContext", this.getMapOverViewContext());
+	}
+	
+	public void loadFromState(PersistentState state) throws PersistenceException {
+		super.loadFromState(state);
+		this.mapContext = (MapContext) state.get("mainMapContext");
+		if( state.getBoolean("useMapOverview") ) {
+			this.mapOverViewContext = (MapContext) state.get("overviewMapContext");
+		} else {
+			this.mapOverViewContext = null;
+		}
+	}
+	
+}

Property changes on: tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/app/project/documents/view/BaseViewDocument.java
___________________________________________________________________
Added: svn:keywords
   + Author Date Id Revision
Added: svn:eol-style
   + native

Index: tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/app/project/documents/view/MapOverview.java
===================================================================
--- tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/app/project/documents/view/MapOverview.java	(revision 0)
+++ tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/app/project/documents/view/MapOverview.java	(revision 38653)
@@ -0,0 +1,335 @@
+/*
+ * Created on 21-jun-2004
+ *
+ * TODO To change the template for this generated file go to
+ * Window - Preferences - Java - Code Generation - Code and Comments
+ */
+/* gvSIG. Sistema de Informaci�n Geogr�fica de la Generalitat Valenciana
+ *
+ * Copyright (C) 2004 IVER T.I. and Generalitat Valenciana.
+ *
+ * This program is free software; you can redistribute it and/or
+ * modify it under the terms of the GNU General Public License
+ * as published by the Free Software Foundation; either version 2
+ * of the License, or (at your option) any later version.
+ *
+ * This program is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
+ * GNU General Public License for more details.
+ *
+ * You should have received a copy of the GNU General Public License
+ * along with this program; if not, write to the Free Software
+ * Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA  02111-1307,USA.
+ *
+ * For more information, contact:
+ *
+ *  Generalitat Valenciana
+ *   Conselleria d'Infraestructures i Transport
+ *   Av. Blasco Ib��ez, 50
+ *   46010 VALENCIA
+ *   SPAIN
+ *
+ *      +34 963862235
+ *   gvsig@gva.es
+ *      www.gvsig.gva.es
+ *
+ *    or
+ *
+ *   IVER T.I. S.A
+ *   Salamanca 50
+ *   46005 Valencia
+ *   Spain
+ *
+ *   +34 963163400
+ *   dac@iver.es
+ */
+package org.gvsig.app.project.documents.view;
+
+import java.awt.BasicStroke;
+import java.awt.Color;
+import java.awt.Graphics;
+import java.awt.Graphics2D;
+import java.awt.geom.AffineTransform;
+import java.awt.geom.Line2D;
+import java.awt.geom.Point2D;
+import java.awt.geom.Rectangle2D;
+import java.awt.image.BufferedImage;
+
+import org.cresques.cts.IProjection;
+import org.gvsig.app.project.documents.view.toolListeners.MapOverviewChangeZoomListener;
+import org.gvsig.app.project.documents.view.toolListeners.MapOverviewListener;
+import org.gvsig.app.project.documents.view.toolListeners.MapOverviewPanListener;
+import org.gvsig.fmap.dal.exception.ReadException;
+import org.gvsig.fmap.geom.primitive.Envelope;
+import org.gvsig.fmap.mapcontext.MapContext;
+import org.gvsig.fmap.mapcontext.ViewPort;
+import org.gvsig.fmap.mapcontext.events.ColorEvent;
+import org.gvsig.fmap.mapcontext.events.ExtentEvent;
+import org.gvsig.fmap.mapcontext.events.ProjectionEvent;
+import org.gvsig.fmap.mapcontext.events.listeners.ViewPortListener;
+import org.gvsig.fmap.mapcontrol.MapControl;
+import org.gvsig.fmap.mapcontrol.tools.Behavior.Behavior;
+import org.gvsig.fmap.mapcontrol.tools.Behavior.DraggerBehavior;
+import org.gvsig.fmap.mapcontrol.tools.Behavior.PointBehavior;
+import org.gvsig.fmap.mapcontrol.tools.Behavior.RectangleBehavior;
+
+
+
+/**
+ * <p>Lightweight <code>MapControl</code> that uses another <code>MapControl</code>'s <code>MapContext</code>, and updates
+ *  any rectangular extent selected, to the associated <code>MapControl</code>.</p>
+ *
+ * <p>Both <code>MapControl</code> instances work in the same projection. And, always, the not undefined <i>adjusted extent</i>
+ *  of the associated one, will be enhanced as a red-bordered grey-filled rectangle in this one. Furthermore, draws a horizontal and vertical
+ *  this component's width or height, black lines centered in that rectangle.</p>
+ *
+ * @author FJP
+ */
+public class MapOverview extends MapControl implements ViewPortListener {
+	/**
+	 * 
+	 */
+	private static final long serialVersionUID = -2849739771493279542L;
+
+	/**
+	 * <p>Associated <code>MapControl</code> instance that this component represents its overview.</p>
+	 */
+	private MapControl m_MapAssoc;
+
+	/**
+	 * <p>Determines that's the first time this component is going to be painted.</p>
+	 */
+	boolean first = true;
+
+	/**
+	 * <p>Tool listener used to apply a <i>zoom out</i> operation in this component graphical information.</p>
+	 */
+	private MapOverviewListener movl;
+
+	/**
+	 * <p>Tool listener used to allow user work with this component applying <i>pan</i> operations.</p>
+	 */
+	private MapOverviewPanListener movpl;
+
+	/**
+	 * <p>Tool listener used to allow user work with this component applying <i>pan</i> operations.</p>
+	 */
+	private MapOverviewChangeZoomListener movczl;
+
+	/**
+	 * <p>Rectangular area selected in this component, that will be the extent of the associated <code>MapControl</code> instance.</p>
+	 */
+	private Envelope extent;
+
+	/**
+	 * <p>Double buffer used to paint this component graphical information.</p>
+	 */
+	private BufferedImage image;
+
+	/**
+	 * <p>Creates a <code>MapOverview</code> instance associated to <code>mapAssoc</code>.</p>
+	 *
+	 * @param mapAssoc <code>MapControl</code> this component will be the overview
+	 */
+	public MapOverview(MapControl mapAssoc) {
+		super();
+		this.setName("MapOverview");
+		// super.vp.setBackColor(new Color(230,230,230));
+		m_MapAssoc = mapAssoc;
+
+		// setModel((FMap) m_MapAssoc.getMapContext().clone()); // Lo inicializamos con
+		// los mismos temas que tenga el grande.
+		movl = new MapOverviewListener(this);
+		movpl = new MapOverviewPanListener(this);
+		movczl = new MapOverviewChangeZoomListener(this);
+		addBehavior(
+				"zoomtopoint",
+				new Behavior[]{
+						new PointBehavior(movl),
+						new RectangleBehavior(movczl),
+						new DraggerBehavior(movczl),
+						new DraggerBehavior(movpl)
+				}
+		);
+
+//		setCursor(movl.getCursor());
+
+		setTool("zoomtopoint");
+		getGrid().setShowGrid(false);
+		getGrid().setAdjustGrid(false);
+	}
+
+	/**
+	 * @see MapControl#getMapContext()
+	 */
+	public MapContext getAssociatedMapContext() {
+		return m_MapAssoc.getMapContext();
+	}
+
+	/**
+	 * <p>Gets the <code>MapControl</code> instance that wrappers.</p>
+	 *
+	 * @return the <code>MapControl</code> instance that wrappers
+	 */
+	public MapControl getAssociatedMapControl(){
+		return m_MapAssoc;
+	}
+
+	/*
+	 * (non-Javadoc)
+	 * @see com.iver.cit.gvsig.fmap.ViewPortListener#extentChanged(com.iver.cit.gvsig.fmap.ExtentEvent)
+	 */
+	public void extentChanged(ExtentEvent evExtent) {
+		// Nos llega el nuevo extent del FMap asociado, as� que dibujamos nuestro
+		// rect�ngulo para mostrar la zona de dibujo del otro mapa.
+		repaint();
+	}
+
+	/**
+	 * <p>If this had no extent, calls {@link #delModel() #delModel()}, otherwise recalculates this
+	 *  component's view port extent as the union of all extents of all layers of this map.</p>
+	 */
+	public void refreshExtent() {
+		try {
+		if (this.getMapContext().getFullEnvelope()!=null){
+				this.getMapContext().getViewPort().setEnvelope(this.getMapContext().getFullEnvelope());
+		}else{
+			delModel();
+		}
+		} catch (ReadException e1) {
+			e1.printStackTrace();
+		}
+	}
+
+	/**
+	 * <p>Repaints this component updating its <i>extent</i>.</p>
+	 *
+	 * @param r the new extent
+	 */
+	public void refreshOverView(Envelope r){
+		extent=r;
+		repaint();
+	}
+
+	/**
+	 * <p>Paints this component's graphical information using a 8-bit RGBA color double buffer, drawing a red-bordered
+	 *  grey-filled rectangle enhancing the extent selected, and a horizontal and vertical this component's width or
+	 *  height, black lines centered in that rectangle.</p>
+	 */
+	protected void paintComponent(Graphics g) {
+		getGrid().setShowGrid(false);
+		getGrid().setAdjustGrid(false);
+		super.paintComponent(g);
+		
+		if ((m_MapAssoc.getMapContext().getViewPort().getEnvelope() != null) &&
+					(getMapContext().getViewPort().getEnvelope() != null)) {
+				if (first) {
+					first = false;
+					repaint();
+					return;
+				}
+				image = new BufferedImage(this.getWidth(), this.getHeight(),
+		                    BufferedImage.TYPE_INT_ARGB);
+				ViewPort vp = getMapContext().getViewPort();
+				Envelope extentView=vp.getAdjustedEnvelope();
+				ViewPort vpOrig = m_MapAssoc.getMapContext().getViewPort();
+				if (extent==null) {
+					extent=vpOrig.getAdjustedEnvelope();
+				}
+				// Dibujamos el extent del mapa asociado.
+				Graphics2D g2 = (Graphics2D) image.getGraphics();
+				g2.setTransform(vp.getAffineTransform());
+
+				g2.setStroke(new BasicStroke((float) vp.getDist1pixel()));
+
+				g2.setColor(Color.red);
+				Rectangle2D extentToDraw=new Rectangle2D.Double(extent.getMinimum(0),extent.getMinimum(1),extent.getLength(0),extent.getLength(1));
+				g2.draw(extentToDraw);
+				g2.setColor(new Color(100,100,100,100));
+				g2.fill(extentToDraw);
+				// dibujamos las l�neas vertical y horizontal
+				Point2D pRightUp = vp.toMapPoint(getWidth(), 0);
+
+				Line2D.Double linVert = new Line2D.Double(extentToDraw.getCenterX(),
+						extentView.getMinimum(1), extentToDraw.getCenterX(),
+						pRightUp.getY());
+				Line2D.Double linHoriz = new Line2D.Double(extentView.getMinimum(0),
+						extentToDraw.getCenterY(), pRightUp.getX(),
+						extentToDraw.getCenterY());
+
+				g2.setColor(Color.darkGray);
+				g2.draw(linVert);
+				g2.draw(linHoriz);
+				g.drawImage(image,0,0,this);
+				g2.setTransform(new AffineTransform());
+				extent=null;
+			}
+
+	}
+
+	/**
+	 * <p>Sets a <code>MapContext</code> to this component, configuring it to manage view port events produced
+	 *  in the associated <code>MapControl</code> and this one's view port.</p>
+	 *
+	 * <p>This <code>MapContext</code>'s projection will be the same as the associated <code>MapControl</code>'s one.</p>
+	 *
+	 * <p>Setting the model includes the following steps:
+	 *  <ul>
+	 *   <li><b>1.-</b> set <code>model</code> as the <code>MapContext</code> of <code>this</code>.</li>
+	 *   <li><b>2.-</b> set as <code>model</code> projection, the associated <code>MapControl<code>'s projection.</li>
+	 *   <li><b>3.-</b> set <code>this</code> as <i>view port</i> listener of the associated <code>MapControl</code>'s <i>view port</i>.</li>
+	 *   <li><b>4.-</b> set <code>this</code> as <i>view port</i> listener of this <code>MapContext</code>'s <i>view port</i></li>
+	 *  </ul>
+	 * </p>
+	 *
+	 * @param model data to set
+	 */
+	public void setModel(MapContext model) {
+		this.setMapContext(model);
+		model.setProjection(m_MapAssoc.getMapContext().getProjection());
+		m_MapAssoc.getMapContext().getViewPort().addViewPortListener(this);
+		getMapContext().getViewPort().addViewPortListener(this);
+	}
+
+	/**
+	 * <p>Removes this component as listener of the the associated <code>MapControl</code> and this one's view port. Besides,
+     *  removes the extent.</p>
+	 */
+	private void delModel(){
+		this.getMapContext().getViewPort().setEnvelope(null);
+		m_MapAssoc.getMapContext().getViewPort().removeViewPortListener(this);
+		getMapContext().getViewPort().removeViewPortListener(this);
+	}
+
+	/*
+	 * (non-Javadoc)
+	 * @see com.iver.cit.gvsig.fmap.ViewPortListener#backColorChanged(com.iver.cit.gvsig.fmap.ColorEvent)
+	 */
+	public void backColorChanged(ColorEvent e) {
+		// do nothing
+	}
+
+	/**
+	 * @see ViewPortListener#projectionChanged(ProjectionEvent)
+	 *
+	 * @see MapControl#setProjection(IProjection)
+	 */
+	public void projectionChanged(ProjectionEvent e) {
+		super.setProjection(e.getNewProjection());
+
+	}
+
+	/**
+	 * <p>Unimplemented.</p>
+	 *
+	 * <p>Can't change the projection, because must be the same as the one of the
+	 *  associated <code>MapControl</code> instance.</p>
+	 */
+	public void setProjection(IProjection proj) {
+		//No permitimos cambiar la proyeccion
+		//ya que debe ser la misma que la del
+		//MapControl asociado
+		return;
+	}
+}

Property changes on: tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/app/project/documents/view/MapOverview.java
___________________________________________________________________
Added: svn:keywords
   + Author Date Id Revision
Added: svn:eol-style
   + native

Index: tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/app/project/documents/view/gui/IView.java
===================================================================
--- tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/app/project/documents/view/gui/IView.java	(revision 0)
+++ tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/app/project/documents/view/gui/IView.java	(revision 38653)
@@ -0,0 +1,37 @@
+/* gvSIG. Geographic Information System of the Valencian Government
+ *
+ * Copyright (C) 2007-2008 Infrastructures and Transports Department
+ * of the Valencian Government (CIT)
+ * 
+ * This program is free software; you can redistribute it and/or
+ * modify it under the terms of the GNU General Public License
+ * as published by the Free Software Foundation; either version 2
+ * of the License, or (at your option) any later version.
+ * 
+ * This program is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
+ * GNU General Public License for more details.
+ * 
+ * You should have received a copy of the GNU General Public License
+ * along with this program; if not, write to the Free Software
+ * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, 
+ * MA  02110-1301, USA.
+ * 
+ */
+package org.gvsig.app.project.documents.view.gui;
+
+import org.gvsig.app.project.documents.gui.IDocumentWindow;
+import org.gvsig.app.project.documents.view.ViewDocument;
+import org.gvsig.app.project.documents.view.toc.gui.TOC;
+import org.gvsig.fmap.mapcontrol.MapControl;
+
+public interface IView extends IDocumentWindow {
+
+    public MapControl getMapControl();
+
+    public TOC getTOC();
+
+    public ViewDocument getViewDocument();
+
+}

Property changes on: tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/app/project/documents/view/gui/IView.java
___________________________________________________________________
Added: svn:keywords
   + Author Date Id Revision
Added: svn:eol-style
   + native

Index: tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/app/project/documents/view/gui/MapOverViewPalette.java
===================================================================
--- tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/app/project/documents/view/gui/MapOverViewPalette.java	(revision 0)
+++ tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/app/project/documents/view/gui/MapOverViewPalette.java	(revision 38653)
@@ -0,0 +1,88 @@
+/* gvSIG. Geographic Information System of the Valencian Government
+ *
+ * Copyright (C) 2007-2008 Infrastructures and Transports Department
+ * of the Valencian Government (CIT)
+ * 
+ * This program is free software; you can redistribute it and/or
+ * modify it under the terms of the GNU General Public License
+ * as published by the Free Software Foundation; either version 2
+ * of the License, or (at your option) any later version.
+ * 
+ * This program is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
+ * GNU General Public License for more details.
+ * 
+ * You should have received a copy of the GNU General Public License
+ * along with this program; if not, write to the Free Software
+ * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, 
+ * MA  02110-1301, USA.
+ * 
+ */
+package org.gvsig.app.project.documents.view.gui;
+
+import javax.swing.JPanel;
+
+import org.gvsig.andami.PluginServices;
+import org.gvsig.andami.ui.mdiManager.IWindow;
+import org.gvsig.andami.ui.mdiManager.IWindowTransform;
+import org.gvsig.andami.ui.mdiManager.WindowInfo;
+import org.gvsig.app.project.documents.view.MapOverview;
+
+public class MapOverViewPalette extends JPanel implements IWindow,
+    IWindowTransform {
+
+    private static final long serialVersionUID = 3254895082290314502L;
+    private MapOverview mov;
+    private DefaultViewPanel view;
+
+    public MapOverViewPalette(MapOverview mapOverView, IView view) {
+        super();
+        mov = mapOverView;
+        this.view = (DefaultViewPanel) view;
+        initialize();
+        this.add(mov);
+    }
+
+    /**
+     * This method initializes this
+     * 
+     * @return void
+     */
+    private void initialize() {
+        this.setSize(300, 200);
+        this.setBackground(java.awt.SystemColor.control);
+        this.setBorder(javax.swing.BorderFactory.createLineBorder(
+            java.awt.Color.gray, 0));
+    }
+
+    public WindowInfo getWindowInfo() {
+        WindowInfo m_viewinfo =
+            new WindowInfo(WindowInfo.ICONIFIABLE | WindowInfo.MODELESSDIALOG
+                | WindowInfo.PALETTE);
+        m_viewinfo.setTitle(PluginServices.getText(this, "localizador"));
+        m_viewinfo.setWidth(mov.getWidth() + 20);
+        m_viewinfo.setHeight(mov.getHeight());
+
+        return m_viewinfo;
+    }
+
+    public void toPalette() {
+        view.toPalette();
+
+    }
+
+    public void restore() {
+        view.restore();
+
+    }
+
+    public boolean isPalette() {
+        return true;
+    }
+
+    public Object getWindowProfile() {
+        return WindowInfo.TOOL_PROFILE;
+    }
+
+}

Property changes on: tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/app/project/documents/view/gui/MapOverViewPalette.java
___________________________________________________________________
Added: svn:keywords
   + Author Date Id Revision
Added: svn:eol-style
   + native

Index: tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/app/project/documents/view/gui/ExtentListSelectorModel.java
===================================================================
--- tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/app/project/documents/view/gui/ExtentListSelectorModel.java	(revision 0)
+++ tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/app/project/documents/view/gui/ExtentListSelectorModel.java	(revision 38653)
@@ -0,0 +1,80 @@
+/* gvSIG. Geographic Information System of the Valencian Government
+ *
+ * Copyright (C) 2007-2008 Infrastructures and Transports Department
+ * of the Valencian Government (CIT)
+ * 
+ * This program is free software; you can redistribute it and/or
+ * modify it under the terms of the GNU General Public License
+ * as published by the Free Software Foundation; either version 2
+ * of the License, or (at your option) any later version.
+ * 
+ * This program is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
+ * GNU General Public License for more details.
+ * 
+ * You should have received a copy of the GNU General Public License
+ * along with this program; if not, write to the Free Software
+ * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, 
+ * MA  02110-1301, USA.
+ * 
+ */
+package org.gvsig.app.project.documents.view.gui;
+
+import java.beans.PropertyChangeEvent;
+import java.beans.PropertyChangeListener;
+import java.util.ArrayList;
+import java.util.List;
+
+import javax.swing.ListModel;
+import javax.swing.event.ListDataEvent;
+import javax.swing.event.ListDataListener;
+
+import org.gvsig.app.project.Project;
+
+public class ExtentListSelectorModel implements ListModel,
+    PropertyChangeListener {
+
+    private Project project;
+    private List<ListDataListener> listeners =
+        new ArrayList<ListDataListener>();
+
+    public ExtentListSelectorModel(Project p) {
+        project = p;
+    }
+
+    public int getSize() {
+        return project.getExtents().length;
+    }
+
+    public Object getElementAt(int arg0) {
+        return project.getExtents()[arg0];
+    }
+
+    public void addListDataListener(ListDataListener arg0) {
+        listeners.add(arg0);
+    }
+
+    public void removeListDataListener(ListDataListener arg0) {
+        listeners.remove(arg0);
+    }
+
+    public void propertyChange(PropertyChangeEvent change) {
+        if (change.getPropertyName().equals("addExtent")) {
+            ListDataEvent event =
+                new ListDataEvent(this, ListDataEvent.INTERVAL_ADDED, 0,
+                    getSize());
+            for (int i = 0; i < listeners.size(); i++) {
+                listeners.get(i).intervalAdded(event);
+            }
+        } else {
+            ListDataEvent event =
+                new ListDataEvent(this, ListDataEvent.INTERVAL_REMOVED, 0,
+                    getSize());
+            for (int i = 0; i < listeners.size(); i++) {
+                listeners.get(i).intervalRemoved(event);
+            }
+        }
+    }
+
+}

Property changes on: tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/app/project/documents/view/gui/ExtentListSelectorModel.java
___________________________________________________________________
Added: svn:keywords
   + Author Date Id Revision
Added: svn:eol-style
   + native

Index: tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/app/project/documents/view/gui/ViewProperties.java
===================================================================
--- tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/app/project/documents/view/gui/ViewProperties.java	(revision 0)
+++ tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/app/project/documents/view/gui/ViewProperties.java	(revision 38653)
@@ -0,0 +1,651 @@
+/* gvSIG. Geographic Information System of the Valencian Government
+ *
+ * Copyright (C) 2007-2008 Infrastructures and Transports Department
+ * of the Valencian Government (CIT)
+ * 
+ * This program is free software; you can redistribute it and/or
+ * modify it under the terms of the GNU General Public License
+ * as published by the Free Software Foundation; either version 2
+ * of the License, or (at your option) any later version.
+ * 
+ * This program is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
+ * GNU General Public License for more details.
+ * 
+ * You should have received a copy of the GNU General Public License
+ * along with this program; if not, write to the Free Software
+ * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, 
+ * MA  02110-1301, USA.
+ * 
+ */
+package org.gvsig.app.project.documents.view.gui;
+
+import java.awt.Color;
+import java.awt.Component;
+import java.awt.Dimension;
+import java.awt.FlowLayout;
+import java.awt.GridBagConstraints;
+import java.awt.GridBagLayout;
+import java.awt.Insets;
+import java.awt.event.ActionListener;
+import java.util.List;
+
+import javax.swing.BorderFactory;
+import javax.swing.JButton;
+import javax.swing.JColorChooser;
+import javax.swing.JComboBox;
+import javax.swing.JComponent;
+import javax.swing.JOptionPane;
+import javax.swing.JPanel;
+
+import org.cresques.cts.IProjection;
+
+import org.gvsig.andami.PluginServices;
+import org.gvsig.andami.ui.mdiManager.SingletonWindow;
+import org.gvsig.andami.ui.mdiManager.WindowInfo;
+import org.gvsig.app.gui.JComboBoxUnits;
+import org.gvsig.app.gui.panels.CRSSelectPanel;
+import org.gvsig.app.project.Project;
+import org.gvsig.app.project.ProjectManager;
+import org.gvsig.app.project.documents.Document;
+import org.gvsig.app.project.documents.view.DefaultViewDocument;
+import org.gvsig.app.project.documents.view.ViewManager;
+import org.gvsig.fmap.mapcontext.MapContext;
+import org.gvsig.gui.beans.AcceptCancelPanel;
+import org.gvsig.i18n.Messages;
+import org.gvsig.tools.swing.api.ToolsSwingLocator;
+
+/**
+ * Dialogo donde se muestran las propiedades de una vista
+ * 
+ * @author Fernando Gonz�lez Cort�s
+ * @author gvSIG Team
+ */
+public class ViewProperties extends JPanel implements SingletonWindow {
+
+    private static final long serialVersionUID = 5328865370833315385L;
+    private javax.swing.JLabel jLabelName = null;
+    private javax.swing.JTextField txtName = null;
+    private javax.swing.JLabel jLabelDate = null;
+    private javax.swing.JTextField txtDate = null;
+    private javax.swing.JLabel jLabelOwner = null;
+    private javax.swing.JTextField txtOwner = null;
+    private javax.swing.JLabel jLabelMapUnits = null;
+    private javax.swing.JComboBox cmbMapUnits = null;
+    private javax.swing.JLabel jLabelDistanceUnits = null;
+    private javax.swing.JComboBox cmbDistanceUnits = null;
+    private javax.swing.JLabel jLabelAreaUnits = null;
+    private javax.swing.JTextArea txtComments = null;
+    private javax.swing.JLabel jLabelColor = null;
+    private javax.swing.JLabel jLabelComments = null;
+    private javax.swing.JLabel lblColor = null;
+
+    private Color backColor = null;
+
+    private JButton btnColor = null;
+    private DefaultViewDocument view = null;
+    private javax.swing.JScrollPane jScrollPane = null;
+    protected CRSSelectPanel jPanelProj = null;
+    private AcceptCancelPanel okCancelPanel = null;
+    private boolean isAcceppted = false;
+    private JComboBox cmbDistanceArea = null;
+
+    /**
+     * This is the default constructor
+     * 
+     * @param f
+     *            Frame padre del dialogo
+     * @param v
+     *            Vista que se representa
+     */
+    public ViewProperties(DefaultViewDocument v) {
+        view = v;
+        initialize();
+    }
+
+    /**
+     * This method initializes this
+     */
+    private void initialize() {
+        setLayout(new GridBagLayout());
+        setBorder(BorderFactory.createEmptyBorder(4, 5, 4, 5));
+
+        GridBagConstraints c = new GridBagConstraints();
+        c.insets = new Insets(2, 5, 2, 5);
+        c.gridy = -1;
+
+        addRow(c, getJLabelName(), getTxtName());
+        addRow(c, getJLabelDate(), getTxtDate());
+        addRow(c, getJLabelOwner(), getTxtOwner());
+        addRow(c, getJLabelMapUnits(), getCmbMapUnits());
+        addRow(c, getJLabelDistanceUnits(), getCmbDistanceUnits());
+        addRow(c, getJLabelAreaUnits(), getCmbDistanceArea());
+        addRow(c, getJLabelColor(), getJPanelColor());
+
+        c.anchor = GridBagConstraints.WEST;
+        c.weightx = 0.0d;
+        c.gridx = 0;
+        c.gridy++;
+        add(getJLabelColor(), c);
+
+        c.fill = GridBagConstraints.HORIZONTAL;
+        c.weightx = 1.0d;
+        c.gridx = 1;
+        add(getJPanelColor(), c);
+
+        c.anchor = GridBagConstraints.WEST;
+        c.weightx = 0.0d;
+        c.gridx = 0;
+        c.gridwidth = GridBagConstraints.REMAINDER;
+        c.gridy++;
+        c.weightx = 1.0d;
+        c.fill = GridBagConstraints.HORIZONTAL;
+        add(getJPanelProj(), c);
+
+        c.anchor = GridBagConstraints.WEST;
+        c.weightx = 0.0d;
+        c.gridx = 0;
+        c.gridy++;
+        add(getJLabelComments(), c);
+
+        c.fill = GridBagConstraints.BOTH;
+        c.weightx = 1.0d;
+        c.gridy++;
+        c.gridwidth = 2;
+        add(getJScrollPaneComments(), c);
+
+        c.anchor = GridBagConstraints.EAST;
+        c.gridx = 0;
+        c.gridwidth = 2;
+        c.gridy++;
+        c.weightx = 1.0d;
+
+        add(getOkCancelPanel(), c);
+    }
+
+    private JComponent getJPanelColor() {
+        JPanel colorPanel = new JPanel(new FlowLayout(FlowLayout.LEFT));
+        colorPanel.add(getLblColor());
+        colorPanel.add(getBtnColor());
+
+        return colorPanel;
+    }
+
+    private void addRow(GridBagConstraints c, JComponent label, JComponent text) {
+        c.anchor = GridBagConstraints.WEST;
+        c.weightx = 0.0d;
+        c.gridx = 0;
+        c.gridy++;
+        add(label, c);
+
+        c.fill = GridBagConstraints.HORIZONTAL;
+        c.weightx = 1.0d;
+        c.gridx = 1;
+        add(text, c);
+    }
+
+    /**
+     * This method initializes jLabel
+     * 
+     * @return javax.swing.JLabel
+     */
+    private javax.swing.JLabel getJLabelName() {
+        if (jLabelName == null) {
+            jLabelName =
+                new javax.swing.JLabel(Messages.getText("nombre") + ":");
+        }
+
+        return jLabelName;
+    }
+
+    /**
+     * This method initializes txtName
+     * 
+     * @return javax.swing.JTextField
+     */
+    private javax.swing.JTextField getTxtName() {
+        if (txtName == null) {
+            txtName = new javax.swing.JTextField(view.getName());
+        }
+
+        return txtName;
+    }
+
+    /**
+     * This method initializes jLabel1
+     * 
+     * @return javax.swing.JLabel
+     */
+    private javax.swing.JLabel getJLabelDate() {
+        if (jLabelDate == null) {
+            jLabelDate =
+                new javax.swing.JLabel(Messages.getText("creation_date") + ":");
+        }
+
+        return jLabelDate;
+    }
+
+    /**
+     * This method initializes txtDate
+     * 
+     * @return javax.swing.JTextField
+     */
+    private javax.swing.JTextField getTxtDate() {
+        if (txtDate == null) {
+            txtDate = new javax.swing.JTextField(view.getCreationDate());
+            txtDate.setEditable(false);
+            txtDate.setBackground(java.awt.Color.white);
+        }
+
+        return txtDate;
+    }
+
+    /**
+     * This method initializes jLabel2
+     * 
+     * @return javax.swing.JLabel
+     */
+    private javax.swing.JLabel getJLabelOwner() {
+        if (jLabelOwner == null) {
+            jLabelOwner =
+                new javax.swing.JLabel(Messages.getText("owner") + ":");
+        }
+
+        return jLabelOwner;
+    }
+
+    /**
+     * This method initializes txtOwner
+     * 
+     * @return javax.swing.JTextField
+     */
+    private javax.swing.JTextField getTxtOwner() {
+        if (txtOwner == null) {
+            txtOwner = new javax.swing.JTextField(view.getOwner());
+        }
+
+        return txtOwner;
+    }
+
+    /**
+     * This method initializes jLabel4
+     * 
+     * @return javax.swing.JLabel
+     */
+    private javax.swing.JLabel getJLabelMapUnits() {
+        if (jLabelMapUnits == null) {
+            jLabelMapUnits =
+                new javax.swing.JLabel(Messages.getText("map_units") + ":");
+        }
+
+        return jLabelMapUnits;
+    }
+
+    /**
+     * This method initializes cmbMapUnits
+     * 
+     * @return javax.swing.JComboBox
+     */
+    private javax.swing.JComboBox getCmbMapUnits() {
+        if (cmbMapUnits == null
+            || MapContext.getDistanceNames().length > cmbMapUnits
+                .getItemCount()) {
+            cmbMapUnits = new JComboBoxUnits(false);
+
+            IProjection proj = view.getProjection();
+            if (!proj.isProjected()) {
+                cmbMapUnits.setSelectedItem(Messages.getText("Grados")); // deegree
+                cmbMapUnits.setEnabled(false);
+            } else {
+                if (!(cmbMapUnits.getItemCount() == MapContext
+                    .getDistanceNames().length)) {
+                    cmbMapUnits.removeItem(Messages.getText("Grados")); // deegree
+                    view.getMapContext().getViewPort().setMapUnits(1);
+                }
+                cmbMapUnits.setSelectedIndex(view.getMapContext().getViewPort()
+                    .getMapUnits());
+                cmbMapUnits.setEnabled(true);
+            }
+            cmbMapUnits.setSelectedIndex(view.getMapContext().getViewPort()
+                .getMapUnits());
+        }
+
+        return cmbMapUnits;
+    }
+
+    /**
+     * This method initializes jLabel5
+     * 
+     * @return javax.swing.JLabel
+     */
+    private javax.swing.JLabel getJLabelDistanceUnits() {
+        if (jLabelDistanceUnits == null) {
+            jLabelDistanceUnits =
+                new javax.swing.JLabel(Messages.getText("distance_units") + ":");
+        }
+
+        return jLabelDistanceUnits;
+    }
+
+    /**
+     * This method initializes jLabel6
+     * 
+     * @return javax.swing.JLabel
+     */
+    private javax.swing.JLabel getJLabelAreaUnits() {
+        if (jLabelAreaUnits == null) {
+            jLabelAreaUnits =
+                new javax.swing.JLabel(Messages.getText("unidades_area") + ":");
+        }
+
+        return jLabelAreaUnits;
+    }
+
+    /**
+     * This method initializes cmbDistanceUnits
+     * 
+     * @return javax.swing.JComboBox
+     */
+    private javax.swing.JComboBox getCmbDistanceUnits() {
+        if (cmbDistanceUnits == null
+            || MapContext.getDistanceNames().length > cmbDistanceUnits
+                .getItemCount()) {
+            cmbDistanceUnits = new JComboBoxUnits(false);
+            cmbDistanceUnits.setSelectedIndex(view.getMapContext()
+                .getViewPort().getDistanceUnits());
+        }
+
+        return cmbDistanceUnits;
+    }
+
+    /**
+     * This method initializes jLabel6
+     * 
+     * @return javax.swing.JLabel
+     */
+    private javax.swing.JLabel getJLabelComments() {
+        if (jLabelComments == null) {
+            jLabelComments =
+                new javax.swing.JLabel(Messages.getText("comentarios") + ":");
+            jLabelComments
+                .setHorizontalAlignment(javax.swing.SwingConstants.LEFT);
+            jLabelComments
+                .setHorizontalTextPosition(javax.swing.SwingConstants.LEFT);
+        }
+
+        return jLabelComments;
+    }
+
+    /**
+     * This method initializes txtComments
+     * 
+     * @return javax.swing.JTextArea
+     */
+    private javax.swing.JTextArea getTxtComments() {
+        if (txtComments == null) {
+            txtComments = new javax.swing.JTextArea(view.getComment());
+            txtComments.setRows(3);
+            txtComments.setColumns(20);
+        }
+
+        return txtComments;
+    }
+
+    /**
+     * This method initializes jLabel7
+     * 
+     * @return javax.swing.JLabel
+     */
+    private javax.swing.JLabel getJLabelColor() {
+        if (jLabelColor == null) {
+            jLabelColor =
+                new javax.swing.JLabel(Messages.getText("background_color")
+                    + ":");
+        }
+
+        return jLabelColor;
+    }
+
+    /**
+     * This method initializes lblColor
+     * 
+     * @return javax.swing.JLabel
+     */
+    private javax.swing.JLabel getLblColor() {
+        if (lblColor == null) {
+            lblColor = new javax.swing.JLabel("");
+            lblColor.setPreferredSize(new java.awt.Dimension(30, 16));
+            Color theColor = view.getMapContext().getViewPort().getBackColor();
+            backColor = theColor;
+            if (theColor == null) {
+                theColor = Color.WHITE;
+            }
+            lblColor.setBackground(theColor);
+            lblColor.setOpaque(true);
+        }
+
+        return lblColor;
+    }
+
+    /**
+     * This method initializes btnColor
+     * 
+     * @return javax.swing.JButton
+     */
+    private JButton getBtnColor() {
+        if (btnColor == null) {
+            btnColor =
+                ToolsSwingLocator.getUsabilitySwingManager().createJButton();
+
+            btnColor.setText("...");
+
+            btnColor.addActionListener(new java.awt.event.ActionListener() {
+
+                public void actionPerformed(java.awt.event.ActionEvent e) {
+                    Color ret =
+                        JColorChooser.showDialog(ViewProperties.this,
+                            Messages.getText("background_color"),
+                            lblColor.getBackground());
+
+                    if (ret != null) {
+                        lblColor.setBackground(ret);
+                        backColor = ret;
+                    } else {
+                        lblColor.setBackground(Color.WHITE);
+                    }
+                }
+            });
+        }
+
+        return btnColor;
+    }
+
+    /**
+     * This method initializes jScrollPane
+     * 
+     * @return javax.swing.JScrollPane
+     */
+    private javax.swing.JScrollPane getJScrollPaneComments() {
+        if (jScrollPane == null) {
+            jScrollPane = new javax.swing.JScrollPane();
+            jScrollPane.setViewportView(getTxtComments());
+            Dimension dim = getTxtComments().getPreferredSize();
+            jScrollPane
+                .setMinimumSize(new Dimension(dim.width, dim.height + 10));
+        }
+
+        return jScrollPane;
+    }
+
+    /**
+     * @see com.iver.mdiApp.ui.MDIManager.IWindow#getWindowInfo()
+     */
+    public WindowInfo getWindowInfo() {
+        WindowInfo m_viewinfo = new WindowInfo();
+        this.validate();
+        m_viewinfo.setTitle(Messages.getText("propiedades_vista"));
+        Dimension dim = getPreferredSize();
+        m_viewinfo.setWidth(dim.width);
+        m_viewinfo.setHeight(dim.height
+            + getOkCancelPanel().getPreferredSize().height);
+        return m_viewinfo;
+    }
+
+    /**
+     * This method initializes jPanel4
+     * 
+     * @return javax.swing.JPanel
+     */
+    private CRSSelectPanel getJPanelProj() {
+        if (jPanelProj == null) {
+            IProjection proj = view.getProjection();
+            jPanelProj = CRSSelectPanel.getPanel(proj);
+            jPanelProj.addActionListener(new java.awt.event.ActionListener() {
+
+                public void actionPerformed(java.awt.event.ActionEvent e) {
+                    if (jPanelProj.isOkPressed()) {
+                        if (!jPanelProj.getCurProj().isProjected()) {
+                            getCmbMapUnits().setSelectedItem(
+                                PluginServices
+                                    .getText(this, "Grados"));
+                            getCmbMapUnits().setEnabled(false);
+                        } else {
+                            if (getCmbMapUnits().getSelectedItem().equals(
+                                PluginServices
+                                    .getText(this, "Grados"))) {
+                                getCmbMapUnits().setSelectedIndex(1);
+                            }
+                            getCmbMapUnits().setEnabled(true);
+                        }
+                        view.setProjection(jPanelProj.getCurProj());
+                    }
+                }
+            });
+        }
+        return jPanelProj;
+    }
+
+    /**
+     * @see org.gvsig.andami.ui.mdiManager.SingletonWindow#getWindowModel()
+     */
+    public Object getWindowModel() {
+        return view;
+    }
+
+    /**
+     * This method initializes okCancelPanel
+     * 
+     * @return javax.swing.JPanel
+     */
+    private AcceptCancelPanel getOkCancelPanel() {
+        if (okCancelPanel == null) {
+            ActionListener okAction, cancelAction;
+            okAction = new java.awt.event.ActionListener() {
+
+                public void actionPerformed(java.awt.event.ActionEvent e) {
+                    String name = txtName.getText();
+                    if (name == null || name.length() == 0) {
+                        return;
+                    }
+                    Project project =
+                        ProjectManager.getInstance().getCurrentProject();
+                    List<Document> views =
+                        project.getDocuments(ViewManager.TYPENAME);
+                    for (Document theView : views) {
+                        if (view.equals(theView)) {
+                            continue;
+                        }
+                        if (theView.getName().equals(name)) {
+                            JOptionPane.showMessageDialog(
+                                (Component) PluginServices.getMainFrame(),
+                                Messages.getText("elemento_ya_existe"));
+                            return;
+                        }
+                    }
+
+                    view.setName(name);
+                    view.setCreationDate(txtDate.getText());
+                    view.setOwner(txtOwner.getText());
+                    view.setComment(txtComments.getText());
+                    view.getMapContext().getViewPort()
+                        .setMapUnits(cmbMapUnits.getSelectedIndex());
+                    view.getMapContext().getViewPort()
+                        .setDistanceUnits(cmbDistanceUnits.getSelectedIndex());
+                    view.getMapContext().getViewPort()
+                        .setDistanceArea(cmbDistanceArea.getSelectedIndex());
+                    view.setBackColor(backColor);
+
+                    // Select the projection
+                    if (jPanelProj.isOkPressed()) {
+                        if (!jPanelProj.getCurProj().isProjected()) {
+                            getCmbMapUnits().setSelectedItem(
+                                Messages.getText("Grados"));
+                            getCmbMapUnits().setEnabled(false);
+                        } else {
+                            if (getCmbMapUnits().getSelectedItem().equals(
+                                Messages.getText("Grados"))) {
+                                getCmbMapUnits().setSelectedIndex(1);
+                            }
+                            getCmbMapUnits().setEnabled(true);
+                        }
+                        view.setProjection(jPanelProj.getCurProj());
+                    }
+
+                    isAcceppted = true;
+                    PluginServices.getMDIManager().closeWindow(
+                        ViewProperties.this);
+                }
+            };
+            cancelAction = new java.awt.event.ActionListener() {
+
+                public void actionPerformed(java.awt.event.ActionEvent e) {
+                    isAcceppted = false;
+                    PluginServices.getMDIManager().closeWindow(
+                        ViewProperties.this);
+                }
+            };
+            okCancelPanel = new AcceptCancelPanel(okAction, cancelAction);
+        }
+        return okCancelPanel;
+    }
+
+    public boolean isAcceppted() {
+        return isAcceppted;
+    }
+
+    /**
+     * This method initializes jComboBox
+     * 
+     * @return javax.swing.JComboBox
+     */
+    private JComboBox getCmbDistanceArea() {
+        String[] names = MapContext.getAreaNames();
+        if (cmbDistanceArea == null
+            || names.length > cmbDistanceArea.getItemCount()) {
+            for (int i = 0; i < names.length; i++) {
+                names[i] =
+                    Messages.getText(names[i]) + MapContext.getOfLinear(i);
+            }
+            cmbDistanceArea = new javax.swing.JComboBox(names);
+            cmbDistanceArea.setEditable(false);
+            cmbDistanceArea.setSelectedIndex(view.getMapContext().getViewPort()
+                .getDistanceArea());
+            cmbDistanceArea
+                .addActionListener(new java.awt.event.ActionListener() {
+
+                    public void actionPerformed(java.awt.event.ActionEvent e) {
+                        // view.getMapContext().getViewPort().setDistanceUnits(cmbDistanceUnits.getSelectedIndex());
+                    }
+                });
+        }
+
+        return cmbDistanceArea;
+
+    }
+
+    public Object getWindowProfile() {
+        return WindowInfo.PROPERTIES_PROFILE;
+    }
+
+}

Property changes on: tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/app/project/documents/view/gui/ViewProperties.java
___________________________________________________________________
Added: svn:keywords
   + Author Date Id Revision
Added: svn:eol-style
   + native

Index: tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/app/project/documents/view/gui/FPanelLocConfig.java
===================================================================
--- tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/app/project/documents/view/gui/FPanelLocConfig.java	(revision 0)
+++ tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/app/project/documents/view/gui/FPanelLocConfig.java	(revision 38653)
@@ -0,0 +1,433 @@
+/* gvSIG. Geographic Information System of the Valencian Government
+ *
+ * Copyright (C) 2007-2008 Infrastructures and Transports Department
+ * of the Valencian Government (CIT)
+ * 
+ * This program is free software; you can redistribute it and/or
+ * modify it under the terms of the GNU General Public License
+ * as published by the Free Software Foundation; either version 2
+ * of the License, or (at your option) any later version.
+ * 
+ * This program is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
+ * GNU General Public License for more details.
+ * 
+ * You should have received a copy of the GNU General Public License
+ * along with this program; if not, write to the Free Software
+ * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, 
+ * MA  02110-1301, USA.
+ * 
+ */
+package org.gvsig.app.project.documents.view.gui;
+
+import java.awt.Color;
+import java.awt.FlowLayout;
+import java.awt.event.ActionEvent;
+import java.awt.event.ActionListener;
+
+import javax.swing.BorderFactory;
+import javax.swing.DefaultListModel;
+import javax.swing.JButton;
+import javax.swing.JDialog;
+import javax.swing.JOptionPane;
+import javax.swing.JPanel;
+import javax.swing.plaf.basic.BasicArrowButton;
+
+import org.gvsig.andami.PluginServices;
+import org.gvsig.andami.ui.mdiManager.IWindow;
+import org.gvsig.andami.ui.mdiManager.WindowInfo;
+import org.gvsig.app.extension.AddLayer;
+import org.gvsig.app.project.documents.view.MapOverview;
+import org.gvsig.app.project.documents.view.legend.gui.ThemeManagerWindow;
+import org.gvsig.fmap.mapcontext.layers.CancelationException;
+import org.gvsig.fmap.mapcontext.layers.FLayer;
+import org.gvsig.fmap.mapcontext.layers.FLayers;
+import org.gvsig.fmap.mapcontext.layers.operations.Classifiable;
+import org.gvsig.fmap.mapcontrol.MapControl;
+import org.gvsig.tools.swing.api.ToolsSwingLocator;
+
+/**
+ * @author FJP
+ * 
+ *         TODO To change the template for this generated type comment go to
+ *         Window - Preferences - Java - Code Generation - Code and Comments
+ */
+public class FPanelLocConfig extends JPanel implements ActionListener, IWindow {
+
+    private static final long serialVersionUID = -3331364698732098356L;
+    private javax.swing.JLabel jLabel = null;
+    private javax.swing.JList jList = null; // @jve:decl-index=0:visual-constraint="390,10"
+    private JButton jBtnAddLayer = null; //
+    private JButton jBtnRemoveLayer = null;
+    private JButton jBtnEditLegend = null;
+    private JButton jBtnCancel = null;
+
+    private MapControl mapCtrl;
+    private WindowInfo m_viewinfo = null;
+    private JPanel pnlButtons = null; // @jve:decl-index=0:visual-constraint="10,159"
+    private BasicArrowButton jBtnUp;
+    private BasicArrowButton jBtnDown;
+
+    /**
+     * This is the default constructor
+     */
+    public FPanelLocConfig(MapControl mc) {
+        super();
+        mapCtrl = mc;
+        initialize();
+        refreshList();
+        updateControls(null);
+    }
+
+    private void refreshList() {
+        DefaultListModel lstModel = (DefaultListModel) getJList().getModel();
+        lstModel.clear();
+        for (int i = mapCtrl.getMapContext().getLayers().getLayersCount() - 1; i >= 0; i--) {
+            FLayer lyr = mapCtrl.getMapContext().getLayers().getLayer(i);
+            lstModel.addElement(lyr.getName());
+        }
+    }
+
+    /**
+     * This method initializes this
+     * 
+     * @return void
+     */
+    private void initialize() {
+        this.setLayout(null);
+        this.setSize(550, 200);
+        this.add(getJLabel(), null);
+        this.add(getJList(), null);
+        this.add(getJBtnUp(), null);
+        this.add(getJBtnDown(), null);
+        this.add(getJPanel(), null);
+    }
+
+    /**
+     * This method initializes jLabel
+     * 
+     * @return javax.swing.JLabel
+     */
+    private javax.swing.JLabel getJLabel() {
+        if (jLabel == null) {
+            jLabel = new javax.swing.JLabel();
+            jLabel.setText(PluginServices
+                .getText(this, "Capas_del_localizador") + ":");
+            jLabel.setBounds(10, 15, 132, 25);
+        }
+        return jLabel;
+    }
+
+    /**
+     * This method initializes jList
+     * 
+     * @return javax.swing.JList
+     */
+    public javax.swing.JList getJList() {
+        if (jList == null) {
+            jList = new javax.swing.JList(new DefaultListModel());
+            jList.setBounds(10, 49, 357, 139);
+            jList
+                .setSelectionMode(javax.swing.ListSelectionModel.SINGLE_SELECTION);
+            jList.setBorder(BorderFactory.createLineBorder(Color.BLACK));
+            jList
+                .addListSelectionListener(new javax.swing.event.ListSelectionListener() {
+
+                    public void valueChanged(
+                        javax.swing.event.ListSelectionEvent e) {
+                        updateControls(e);
+                    }
+                });
+
+        }
+        return jList;
+    }
+
+    private void updateControls(javax.swing.event.ListSelectionEvent e) {
+        System.out.println("valueChanged()"); // TODO Auto-generated Event stub
+                                              // valueChanged()
+        DefaultListModel lstModel = (DefaultListModel) getJList().getModel();
+        int selIndex = jList.getSelectedIndex();
+        jBtnDown.setEnabled(false);
+        jBtnUp.setEnabled(false);
+
+        if (selIndex != -1) {
+            if (lstModel.getSize() > 1) {
+                if (selIndex < (lstModel.getSize() - 1)) {
+                    jBtnDown.setEnabled(true);
+                }
+
+                if (selIndex > 0) {
+                    jBtnUp.setEnabled(true);
+                }
+            }
+
+        }
+
+    }
+
+    /**
+     * This method initializes jBtnUp
+     * 
+     * @return JButton
+     */
+    private BasicArrowButton getJBtnUp() {
+        if (jBtnUp == null) {
+            jBtnUp =
+                new javax.swing.plaf.basic.BasicArrowButton(
+                    javax.swing.SwingConstants.NORTH);
+            jBtnUp.setBounds(374, 49, 25, 23);
+            jBtnUp.setToolTipText(PluginServices.getText(this, "Subir_capa"));
+            jBtnUp.addActionListener(this);
+            jBtnUp.setActionCommand("UP");
+
+        }
+        return jBtnUp;
+    }
+
+    /**
+     * This method initializes jBtnDown
+     * 
+     * @return JButton
+     */
+    private BasicArrowButton getJBtnDown() {
+        if (jBtnDown == null) {
+            jBtnDown =
+                new javax.swing.plaf.basic.BasicArrowButton(
+                    javax.swing.SwingConstants.SOUTH);
+            jBtnDown.setBounds(374, 164, 25, 23);
+            jBtnDown.setToolTipText(PluginServices.getText(this, "Bajar_capa"));
+            jBtnDown.setActionCommand("DOWN");
+            jBtnDown.addActionListener(this);
+        }
+        return jBtnDown;
+    }
+
+    /**
+     * This method initializes jButton2
+     * 
+     * @return JButton
+     */
+    private JButton getJBtnAddLayer() {
+        if (jBtnAddLayer == null) {
+            jBtnAddLayer =
+                ToolsSwingLocator.getUsabilitySwingManager().createJButton();
+            jBtnAddLayer.setText(PluginServices.getText(this, "Anadir_capa")
+                + "...");
+            jBtnAddLayer.addActionListener(this);
+            jBtnAddLayer.setActionCommand("ADD_LAYER");
+        }
+        return jBtnAddLayer;
+    }
+
+    /**
+     * This method initializes jBtnRemoveLayer
+     * 
+     * @return JButton
+     */
+    private JButton getJBtnRemoveLayer() {
+        if (jBtnRemoveLayer == null) {
+            jBtnRemoveLayer =
+                ToolsSwingLocator.getUsabilitySwingManager().createJButton();
+            jBtnRemoveLayer.setText(PluginServices.getText(this, "Quitar_capa")
+                + "...");
+            jBtnRemoveLayer.addActionListener(this);
+            jBtnRemoveLayer.setActionCommand("REMOVE_LAYER");
+
+        }
+        return jBtnRemoveLayer;
+    }
+
+    /**
+     * This method initializes jBtnEditLegend
+     * 
+     * @return JButton
+     */
+    private JButton getJBtnEditLegend() {
+        if (jBtnEditLegend == null) {
+            jBtnEditLegend =
+                ToolsSwingLocator.getUsabilitySwingManager().createJButton();
+            jBtnEditLegend.setText(PluginServices.getText(this,
+                "Editar_leyenda") + "...");
+            jBtnEditLegend.addActionListener(this);
+            jBtnEditLegend.setActionCommand("EDIT_LEGEND");
+        }
+        return jBtnEditLegend;
+    }
+
+    /**
+     * This method initializes jBtnCancel
+     * 
+     * @return JButton
+     */
+    private JButton getJBtnCancel() {
+        if (jBtnCancel == null) {
+            jBtnCancel =
+                ToolsSwingLocator.getUsabilitySwingManager().createJButton();
+            jBtnCancel.setText(PluginServices.getText(this, "Cerrar"));
+            jBtnCancel.setActionCommand("CANCEL");
+            jBtnCancel.addActionListener(this);
+
+        }
+        return jBtnCancel;
+    }
+
+    public void actionPerformed(ActionEvent e) {
+        DefaultListModel lstModel = (DefaultListModel) getJList().getModel();
+        FLayers theLayers = mapCtrl.getMapContext().getLayers();
+
+        int numLayers = theLayers.getLayersCount() - 1;
+
+        if (e.getActionCommand() == "CANCEL") {
+            if (PluginServices.getMainFrame() != null) {
+                PluginServices.getMDIManager()
+                    .closeWindow(FPanelLocConfig.this);
+            } else {
+                ((JDialog) (getParent().getParent().getParent().getParent()))
+                    .dispose();
+            }
+        }
+        if (e.getActionCommand() == "ADD_LAYER") {
+            AddLayer addLayer =
+                (AddLayer) PluginServices.getExtension(AddLayer.class);// new
+                                                                       // AddLayer();
+            // addLayer.initialize();
+            if (addLayer.addLayers(mapCtrl)) {
+                refreshList();
+                updateControls(null);
+            }
+            if (mapCtrl instanceof MapOverview) {
+                ((MapOverview) mapCtrl).refreshExtent();
+            }
+
+        }
+        if (e.getActionCommand() == "REMOVE_LAYER") {
+            if (jList.getSelectedIndex() != -1) {
+                theLayers.removeLayer((String) lstModel.get(jList
+                    .getSelectedIndex()));
+                lstModel.remove(jList.getSelectedIndex());
+                // /mapCtrl.drawMap();
+                updateControls(null);
+                if (mapCtrl instanceof MapOverview) {
+                    ((MapOverview) mapCtrl).refreshExtent();
+                }
+            }
+        }
+        if (e.getActionCommand() == "EDIT_LEGEND") {
+            int idSelec = jList.getSelectedIndex();
+            if (idSelec != -1) {
+                FLayer lyr = theLayers.getLayer((String) lstModel.get(idSelec));
+                if (lyr instanceof Classifiable) {
+                    ThemeManagerWindow m_LegendEditor =
+                        new ThemeManagerWindow(lyr/* , mapCtrl.getMapContext() */);
+                    theLayers.setActive(false);
+                    lyr.setActive(true);
+                    if (PluginServices.getMainFrame() == null) {
+                        JDialog dlg = new JDialog();
+
+                        m_LegendEditor.setPreferredSize(m_LegendEditor
+                            .getSize());
+                        dlg.getContentPane().add(m_LegendEditor);
+                        dlg.setModal(true);
+                        dlg.pack();
+                        dlg.setVisible(true);
+
+                    } else {
+                        PluginServices.getMDIManager()
+                            .addWindow(m_LegendEditor);
+                    }
+                } else {
+                    JOptionPane.showMessageDialog(
+                        null,
+                        PluginServices.getText(this,
+                            "Solo_para_capas_vectoriales") + ".");
+                }
+
+            }
+
+        }
+        if (e.getActionCommand() == "UP") {
+            int idSelec = jList.getSelectedIndex();
+            int fromIndex = idSelec;
+            int toIndex = idSelec - 1;
+            FLayer aux = theLayers.getLayer((String) lstModel.get(fromIndex));
+            try {
+                theLayers.moveTo(numLayers - fromIndex, numLayers - toIndex);
+            } catch (CancelationException e1) {
+                e1.printStackTrace();
+            }
+
+            lstModel.remove(fromIndex);
+            lstModel.add(toIndex, aux.getName());
+
+            jList.setSelectedIndex(toIndex);
+        }
+        if (e.getActionCommand() == "DOWN") {
+            int idSelec = jList.getSelectedIndex();
+            int fromIndex = idSelec;
+            int toIndex = idSelec + 1;
+            FLayer aux = theLayers.getLayer((String) lstModel.get(fromIndex));
+            try {
+                theLayers.moveTo(numLayers - fromIndex, numLayers - toIndex);
+            } catch (CancelationException e1) {
+                e1.printStackTrace();
+            }
+
+            lstModel.remove(fromIndex);
+            lstModel.add(toIndex, aux.getName());
+
+            jList.setSelectedIndex(toIndex);
+        }
+
+    }
+
+    public WindowInfo getWindowInfo() {
+        if (m_viewinfo == null) {
+            m_viewinfo = new WindowInfo(WindowInfo.MODALDIALOG);
+            m_viewinfo.setTitle(PluginServices.getText(this,
+                "Configurar_localizador"));
+            m_viewinfo.setWidth(this.getWidth() + 8);
+            m_viewinfo.setHeight(this.getHeight() + 8);
+        }
+        return m_viewinfo;
+    }
+
+    /**
+     * @see com.iver.mdiApp.ui.MDIManager.IWindow#windowActivated()
+     */
+    public void viewActivated() {
+    }
+
+    /**
+     * This method initializes jPanel
+     * 
+     * @return javax.swing.JPanel
+     */
+    private JPanel getJPanel() {
+        if (pnlButtons == null) {
+            pnlButtons = new JPanel(new FlowLayout(FlowLayout.RIGHT, 5, 5));
+            pnlButtons.setBounds(new java.awt.Rectangle(0, 200,
+                this.getWidth(), 37));
+            pnlButtons.add(getJBtnAddLayer(), null);
+            pnlButtons.add(getJBtnRemoveLayer(), null);
+            pnlButtons.add(getJBtnEditLegend(), null);
+            pnlButtons.add(getJBtnCancel(), null);
+        }
+        return pnlButtons;
+    }
+
+    /**
+     * Obtiene el MapControl asociado al localizador
+     * 
+     * @return MapControl
+     */
+    public MapControl getMapCtrl() {
+        return mapCtrl;
+    }
+
+    public Object getWindowProfile() {
+        return WindowInfo.DIALOG_PROFILE;
+    }
+
+} // @jve:visual-info decl-index=0 visual-constraint="10,10"

Property changes on: tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/app/project/documents/view/gui/FPanelLocConfig.java
___________________________________________________________________
Added: svn:keywords
   + Author Date Id Revision
Added: svn:eol-style
   + native

Index: tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/app/project/documents/view/gui/AbstractViewPanel.java
===================================================================
--- tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/app/project/documents/view/gui/AbstractViewPanel.java	(revision 0)
+++ tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/app/project/documents/view/gui/AbstractViewPanel.java	(revision 38653)
@@ -0,0 +1,331 @@
+/* gvSIG. Geographic Information System of the Valencian Government
+ *
+ * Copyright (C) 2007-2009 Infrastructures and Transports Department
+ * of the Valencian Government (CIT)
+ * 
+ * This program is free software; you can redistribute it and/or
+ * modify it under the terms of the GNU General Public License
+ * as published by the Free Software Foundation; either version 2
+ * of the License, or (at your option) any later version.
+ * 
+ * This program is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
+ * GNU General Public License for more details.
+ * 
+ * You should have received a copy of the GNU General Public License
+ * along with this program; if not, write to the Free Software
+ * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, 
+ * MA  02110-1301, USA.
+ * 
+ */
+
+/*
+ * AUTHORS (In addition to CIT):
+ * 2004-2009 IVER TI
+ *   
+ */
+package org.gvsig.app.project.documents.view.gui;
+
+import java.awt.Graphics;
+import java.awt.image.BufferedImage;
+import java.beans.PropertyChangeEvent;
+import java.beans.PropertyChangeListener;
+
+import javax.swing.JPanel;
+import javax.swing.JSplitPane;
+
+import org.cresques.cts.IProjection;
+
+import org.gvsig.andami.PluginServices;
+import org.gvsig.andami.messages.NotificationManager;
+import org.gvsig.andami.ui.mdiManager.IWindowTransform;
+import org.gvsig.andami.ui.mdiManager.WindowInfo;
+import org.gvsig.app.project.ProjectManager;
+import org.gvsig.app.project.documents.gui.WindowLayout;
+import org.gvsig.app.project.documents.view.MapOverview;
+import org.gvsig.app.project.documents.view.ViewDocument;
+import org.gvsig.app.project.documents.view.toc.gui.TOC;
+import org.gvsig.fmap.mapcontrol.MapControl;
+import org.gvsig.utils.exceptionHandling.ExceptionListener;
+import org.slf4j.Logger;
+import org.slf4j.LoggerFactory;
+
+/**
+ * 
+ * @author 2005- Vicente Caballero
+ * @author 2009- Joaquin del Cerro
+ * 
+ */
+
+public abstract class AbstractViewPanel extends JPanel implements IView,
+    IWindowTransform, PropertyChangeListener {
+
+	private static final Logger logger = LoggerFactory.getLogger(AbstractViewPanel.class);
+	
+    private static final long serialVersionUID = -259620280790490262L;
+
+    private static final int DEFAULT_HEIGHT = 450;
+
+    private static final int DEFAULT_WIDTH = 700;
+
+    protected MapControl m_MapControl;
+    protected MapOverview m_MapLoc;
+
+    // store the properties of the window
+    protected WindowInfo m_viewInfo = null;
+    protected WindowLayout windowLayout = null;
+
+    protected TOC m_TOC;
+    protected ViewDocument modelo;
+    protected ViewExceptionListener mapControlExceptionListener =
+        new ViewExceptionListener();
+
+    protected boolean isPalette = false;
+    protected MapOverViewPalette movp;
+    protected ViewSplitPane tempMainSplit = null;
+    protected JSplitPane tempSplitToc = null;
+
+    public void windowActivated() {
+        // By default do nothing
+    }
+
+    public void toPalette() {
+        // By default do nothing
+    }
+
+    public void restore() {
+        // By default do nothing
+    }
+
+    protected class ViewSplitPane extends JSplitPane {
+
+        private static final long serialVersionUID = -7506953938664812652L;
+        private int lastDivider = 0;
+
+        public ViewSplitPane(int horizontal_split) {
+            super(horizontal_split);
+        }
+
+        protected void paintChildren(Graphics g) {
+            if (lastDivider != lastDividerLocation) {
+            	logger.debug("paintChildren = "+ this.lastDividerLocation);
+                lastDivider = lastDividerLocation;
+            }
+            super.paintChildren(g);
+        }
+
+    }
+
+    /**
+     * Creates a new View object. Before using it, it must be initialized
+     * using the <code>initialize()</code> method.
+     * 
+     * @see initialize()
+     */
+    public AbstractViewPanel() {
+    	ProjectManager.getInstance().getCurrentProject().addPropertyChangeListener(this);
+    }
+
+    /**
+     * Create the internal componentes and populate the window with them.
+     * If the layout properties were set using the
+     * <code>setWindowData(WindowData)</code> method, the window will be
+     * populated according to this
+     * properties.
+     */
+    protected void initialize() {
+        // Do nothing
+    }
+
+    /**
+     * This method is used to get <strong>an initial</strong> ViewInfo object
+     * for this View. It is not intended to retrieve the ViewInfo object in a
+     * later time. <strong>Use PluginServices.getMDIManager().getViewInfo(view)
+     * to retrieve the ViewInfo object at any time after the creation of the
+     * object.
+     * 
+     * @see com.iver.mdiApp.ui.MDIManager.IWindow#getWindowInfo()
+     */
+    public WindowInfo getWindowInfo() {
+        if (m_viewInfo == null) {
+            m_viewInfo =
+                new WindowInfo(WindowInfo.ICONIFIABLE | WindowInfo.RESIZABLE
+                    | WindowInfo.MAXIMIZABLE);
+
+            m_viewInfo.setWidth(DEFAULT_WIDTH);
+            m_viewInfo.setHeight(DEFAULT_HEIGHT);
+            m_viewInfo.setTitle(PluginServices.getText(this, "Vista") + ": "
+                + modelo.getName());
+        }
+        return m_viewInfo;
+    }
+
+    /**
+     * @see org.gvsig.andami.ui.mdiManager.IWindowListener#windowClosed()
+     */
+    public void windowClosed() {
+        if (movp != null) {
+            PluginServices.getMDIManager().closeWindow(movp);
+        }
+        if (modelo != null) {
+            modelo.setWindowLayout(this.getWindowLayout());
+        }
+    }
+
+    /**
+     * @deprecated See {@link #getViewDocument()}
+     */
+    public ViewDocument getModel() {
+        return modelo;
+    }
+
+    public ViewDocument getViewDocument() {
+        return modelo;
+    }
+
+    public MapOverview getMapOverview() {
+        return m_MapLoc;
+    }
+
+    public MapControl getMapControl() {
+        return m_MapControl;
+    }
+
+    public TOC getTOC() {
+        return m_TOC;
+    }
+
+    /*
+     * (non-Javadoc)
+     * 
+     * @see com.iver.mdiApp.ui.MDIManager.SingletonView#getModel()
+     */
+
+    public Object getWindowModel() {
+        return modelo;
+    }
+
+    /**
+     * This method is used to get <strong>an initial</strong> ViewInfo object
+     * for this View. It is not intended to retrieve the ViewInfo object in a
+     * later time. <strong>Use PluginServices.getMDIManager().getViewInfo(view)
+     * to retrieve the ViewInfo object at any time after the creation of the
+     * object.
+     * 
+     * @see com.iver.mdiApp.ui.MDIManager.IWindow#getWindowInfo()
+     */
+
+    public boolean isPalette() {
+        return isPalette;
+    }
+
+    public void repaintMap() {
+        m_MapControl.drawMap(false);
+    }
+
+    public class ViewExceptionListener implements ExceptionListener {
+
+        /**
+         * @see com.iver.cit.gvsig.fmap.ExceptionListener#exceptionThrown(java.lang.Throwable)
+         */
+        public void exceptionThrown(Throwable t) {
+            NotificationManager.addError(t.getMessage(), t);
+        }
+
+    }
+
+    /**
+     * @return
+     */
+    public BufferedImage getImage() {
+        return m_MapControl.getImage();
+    }
+
+    public void setProjection(IProjection proj) {
+        getMapControl().setProjection(proj);
+    }
+
+    public IProjection getProjection() {
+        return getMapControl().getProjection();
+    }
+
+    public WindowLayout getWindowLayout() {
+        if (windowLayout == null) {
+            windowLayout = new WindowLayout();
+        }
+        windowLayout.set("MainWindow.X", Integer.toString(this.getX()));
+        windowLayout.set("MainWindow.Y", Integer.toString(this.getY()));
+        windowLayout.set("MainWindow.Width", Integer.toString(this.getWidth()));
+        windowLayout.set("MainWindow.Height",
+            Integer.toString(this.getHeight()));
+
+        windowLayout.set("MainDivider.Location",
+            Integer.toString(tempMainSplit.getDividerLocation()));
+        windowLayout.set("MainDivider.X",
+            Integer.toString(tempMainSplit.getX()));
+        windowLayout.set("MainDivider.Y",
+            Integer.toString(tempMainSplit.getY()));
+        windowLayout.set("MainDivider.Width",
+            Integer.toString(tempMainSplit.getWidth()));
+        windowLayout.set("MainDivider.Height",
+            Integer.toString(tempMainSplit.getHeight()));
+
+        if (isPalette()) {
+            windowLayout.set("GraphicLocator.isPalette", "true");
+        } else {
+            windowLayout.set("GraphicLocator.isPalette", "false");
+            if (tempSplitToc != null) {
+                windowLayout.set("TOCDivider.Location",
+                    Integer.toString(tempSplitToc.getDividerLocation()));
+                windowLayout.set("TOCDivider.X",
+                    Integer.toString(tempSplitToc.getX()));
+                windowLayout.set("TOCDivider.Y",
+                    Integer.toString(tempSplitToc.getY()));
+                windowLayout.set("TOCDivider.Width",
+                    Integer.toString(tempSplitToc.getWidth()));
+                windowLayout.set("TOCDivider.Height",
+                    Integer.toString(tempSplitToc.getHeight()));
+            }
+        }
+        if (m_TOC != null) {
+            windowLayout.set("TOC.Width", Integer.toString(m_TOC.getWidth()));
+            windowLayout.set("TOC.Height", Integer.toString(m_TOC.getHeight()));
+        }
+        if (m_MapControl != null) {
+            windowLayout.set("MapControl.Width",
+                Integer.toString(m_MapControl.getWidth()));
+            windowLayout.set("MapControl.Height",
+                Integer.toString(m_MapControl.getHeight()));
+        }
+        if (m_MapLoc != null) {
+            windowLayout.set("GraphicLocator.Width",
+                Integer.toString(m_MapLoc.getWidth()));
+            windowLayout.set("GraphicLocator.Height",
+                Integer.toString(m_MapLoc.getHeight()));
+        }
+
+        return windowLayout;
+    }
+
+    public void setWindowLayout(WindowLayout data) {
+        windowLayout = data;
+    }
+    
+	public void propertyChange(PropertyChangeEvent evt) {
+		// Detect when the related document has been removed
+		// and close or dispose whatever is needed
+		if ("delDocument".equals(evt.getPropertyName())) {
+			if (evt.getOldValue() != null
+					&& evt.getOldValue() instanceof ViewDocument) {
+				ViewDocument viewDocument = (ViewDocument) evt.getOldValue();
+				ViewDocument myViewDocument = getViewDocument();
+				if (myViewDocument != null
+						&& myViewDocument.equals(viewDocument)) {
+					m_MapControl.dispose();
+					m_MapLoc.dispose();
+				}
+			}
+		}
+	}
+}

Property changes on: tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/app/project/documents/view/gui/AbstractViewPanel.java
___________________________________________________________________
Added: svn:keywords
   + Author Date Id Revision
Added: svn:eol-style
   + native

Index: tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/app/project/documents/view/gui/FPanelExtentSelector.java
===================================================================
--- tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/app/project/documents/view/gui/FPanelExtentSelector.java	(revision 0)
+++ tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/app/project/documents/view/gui/FPanelExtentSelector.java	(revision 38653)
@@ -0,0 +1,356 @@
+/* gvSIG. Geographic Information System of the Valencian Government
+ *
+ * Copyright (C) 2007-2008 Infrastructures and Transports Department
+ * of the Valencian Government (CIT)
+ * 
+ * This program is free software; you can redistribute it and/or
+ * modify it under the terms of the GNU General Public License
+ * as published by the Free Software Foundation; either version 2
+ * of the License, or (at your option) any later version.
+ * 
+ * This program is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
+ * GNU General Public License for more details.
+ * 
+ * You should have received a copy of the GNU General Public License
+ * along with this program; if not, write to the Free Software
+ * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, 
+ * MA  02110-1301, USA.
+ * 
+ */
+package org.gvsig.app.project.documents.view.gui;
+
+import java.awt.BorderLayout;
+import java.awt.FlowLayout;
+import java.util.ArrayList;
+import java.util.List;
+
+import javax.swing.JButton;
+import javax.swing.JPanel;
+import javax.swing.ListModel;
+
+import org.gvsig.andami.PluginServices;
+import org.gvsig.andami.ui.mdiManager.IWindow;
+import org.gvsig.andami.ui.mdiManager.WindowInfo;
+import org.gvsig.app.project.documents.view.ListSelectorListener;
+import org.gvsig.tools.swing.api.ToolsSwingLocator;
+
+/**
+ * DOCUMENT ME!
+ * 
+ * @author Fernando Gonz�lez Cort�s
+ */
+public class FPanelExtentSelector extends JPanel implements IWindow {
+
+    private static final long serialVersionUID = -8246729582621010542L;
+    private javax.swing.JScrollPane jScrollPane = null;
+    private javax.swing.JList lista = null;
+    private JButton btnAceptar = null;
+    private ListModel modelo = null;
+    private List<ListSelectorListener> selectionListeners =
+        new ArrayList<ListSelectorListener>();
+    private JButton btnEliminar = null;
+    private javax.swing.JPanel jPanel = null;
+    private javax.swing.JPanel jPanel1 = null;
+    private javax.swing.JLabel jLabel = null;
+    private javax.swing.JTextField txtGuardar = null;
+    private JButton btnGuardar = null;
+    private WindowInfo m_viewinfo = null;
+    private JPanel jPanel2 = null;
+    private JPanel jPanel3 = null;
+
+    /**
+     * This is the default constructor
+     */
+    public FPanelExtentSelector() {
+        super();
+        initialize();
+    }
+
+    /**
+     * This method initializes this
+     */
+    private void initialize() {
+        this.setLayout(new BorderLayout());
+        this.setSize(new java.awt.Dimension(530, 320));
+        this.add(getJPanel(), java.awt.BorderLayout.NORTH);
+        this.add(getJPanel1(), java.awt.BorderLayout.SOUTH);
+
+    }
+
+    /**
+     * This method initializes jScrollPane
+     * 
+     * @return javax.swing.JScrollPane
+     */
+    private javax.swing.JScrollPane getJScrollPane() {
+        if (jScrollPane == null) {
+            jScrollPane = new javax.swing.JScrollPane();
+            jScrollPane.setViewportView(getLista());
+            jScrollPane.setBounds(11, 26, 508, 150);
+            jScrollPane.setPreferredSize(new java.awt.Dimension(400, 150));
+        }
+
+        return jScrollPane;
+    }
+
+    /**
+     * This method initializes lista
+     * 
+     * @return javax.swing.JList
+     */
+    private javax.swing.JList getLista() {
+        if (lista == null) {
+            lista = new javax.swing.JList();
+        }
+
+        return lista;
+    }
+
+    /**
+     * Asigna el el array que se va a representar. Se crea una
+     * copia del modelo, de forma que modificaciones en el modelo
+     * fuera de esta clase ya no afectan al modelo copiado
+     * 
+     * @param model
+     *            DOCUMENT ME!
+     */
+    public void setModel(ListModel model) {
+        // modelo de la lista
+        modelo = model;
+        getLista().setModel(modelo);
+    }
+
+    public void addSelectionListener(ListSelectorListener listener) {
+        getSelectionListeners().add(listener);
+    }
+
+    public void removeSelectionListener(ListSelectorListener listener) {
+        getSelectionListeners().remove(listener);
+    }
+
+    private void callIndexesRemoved(int[] indices) {
+        for (int i = 0; i < selectionListeners.size(); i++) {
+            selectionListeners.get(i).indexesRemoved(indices);
+        }
+    }
+
+    private void callIndexesSelected(int[] indices) {
+        for (int i = 0; i < selectionListeners.size(); i++) {
+            selectionListeners.get(i).indexesSelected(indices);
+        }
+    }
+
+    private void callNewElement(String name) {
+        for (int i = 0; i < selectionListeners.size(); i++) {
+            selectionListeners.get(i).newElement(name);
+        }
+    }
+
+    /**
+     * This method initializes btnAceptar
+     * 
+     * @return JButton
+     */
+    private JButton getBtnAceptar() {
+        if (btnAceptar == null) {
+            btnAceptar =
+                ToolsSwingLocator.getUsabilitySwingManager().createJButton();
+            btnAceptar.setText(PluginServices.getText(this, "Seleccionar"));
+            btnAceptar.addActionListener(new java.awt.event.ActionListener() {
+
+                public void actionPerformed(java.awt.event.ActionEvent e) {
+                    int[] indices = lista.getSelectedIndices();
+
+                    if (indices.length != 0) {
+                        callIndexesSelected(indices);
+                    }
+                }
+            });
+        }
+
+        return btnAceptar;
+    }
+
+    /**
+     * @return
+     */
+    private List<ListSelectorListener> getSelectionListeners() {
+        return selectionListeners;
+    }
+
+    /**
+     * This method initializes btnEliminar
+     * 
+     * @return JButton
+     */
+    private JButton getBtnEliminar() {
+        if (btnEliminar == null) {
+            btnEliminar =
+                ToolsSwingLocator.getUsabilitySwingManager().createJButton();
+            btnEliminar.setText(PluginServices.getText(this, "Eliminar"));
+            btnEliminar.addActionListener(new java.awt.event.ActionListener() {
+
+                public void actionPerformed(java.awt.event.ActionEvent e) {
+                    int[] indices = lista.getSelectedIndices();
+
+                    if (indices.length != 0) {
+                        callIndexesRemoved(indices);
+                    }
+                }
+            });
+        }
+        return btnEliminar;
+    }
+
+    /**
+     * This method initializes jPanel
+     * 
+     * @return javax.swing.JPanel
+     */
+    private javax.swing.JPanel getJPanel() {
+        if (jPanel == null) {
+            jPanel = new javax.swing.JPanel();
+            jPanel.setLayout(null);
+
+            jPanel.add(getJLabel(), null);
+            jPanel.add(getTxtGuardar(), null);
+            jPanel.setPreferredSize(new java.awt.Dimension(530, 100));
+            jPanel.setBorder(javax.swing.BorderFactory.createTitledBorder(null,
+                PluginServices.getText(this, "Guardar_el_zoom_actual"),
+                javax.swing.border.TitledBorder.DEFAULT_JUSTIFICATION,
+                javax.swing.border.TitledBorder.DEFAULT_POSITION, null, null));
+            jPanel.add(getJPanel3(), null);
+        }
+        return jPanel;
+    }
+
+    /**
+     * This method initializes jPanel1
+     * 
+     * @return javax.swing.JPanel
+     */
+    private javax.swing.JPanel getJPanel1() {
+        if (jPanel1 == null) {
+            jPanel1 = new javax.swing.JPanel();
+            jPanel1.setLayout(null);
+            jPanel1.add(getJScrollPane(), null);
+            jPanel1.setPreferredSize(new java.awt.Dimension(530, 220));
+            jPanel1
+                .setBorder(javax.swing.BorderFactory.createTitledBorder(null,
+                    PluginServices.getText(this,
+                        "Recuperar_y_eliminar_otros_zoom"),
+                    javax.swing.border.TitledBorder.DEFAULT_JUSTIFICATION,
+                    javax.swing.border.TitledBorder.DEFAULT_POSITION, null,
+                    null));
+            jPanel1.add(getJPanel2(), null);
+        }
+        return jPanel1;
+    }
+
+    /**
+     * This method initializes jLabel
+     * 
+     * @return javax.swing.JLabel
+     */
+    private javax.swing.JLabel getJLabel() {
+        if (jLabel == null) {
+            jLabel = new javax.swing.JLabel();
+            jLabel.setBounds(7, 35, 248, 16);
+            jLabel.setText(PluginServices.getText(this,
+                "Nombre_que_se_le_dara_al_zoom") + ":");
+        }
+        return jLabel;
+    }
+
+    /**
+     * This method initializes txtGuardar
+     * 
+     * @return javax.swing.JTextField
+     */
+    private javax.swing.JTextField getTxtGuardar() {
+        if (txtGuardar == null) {
+            txtGuardar = new javax.swing.JTextField();
+            txtGuardar.setBounds(250, 34, 269, 20);
+            txtGuardar.setPreferredSize(new java.awt.Dimension(330, 20));
+        }
+        return txtGuardar;
+    }
+
+    /**
+     * This method initializes btnGuardar
+     * 
+     * @return JButton
+     */
+    private JButton getBtnGuardar() {
+        if (btnGuardar == null) {
+            btnGuardar =
+                ToolsSwingLocator.getUsabilitySwingManager().createJButton();
+            btnGuardar.setText(PluginServices.getText(this, "Guardar"));
+            btnGuardar.addActionListener(new java.awt.event.ActionListener() {
+
+                public void actionPerformed(java.awt.event.ActionEvent e) {
+                    String text = txtGuardar.getText().trim();
+                    if (text.length() > 0) {
+                        callNewElement(text);
+                    }
+                }
+            });
+        }
+        return btnGuardar;
+    }
+
+    /**
+     * @see com.iver.mdiApp.ui.MDIManager.IWindow#getWindowInfo()
+     */
+    public WindowInfo getWindowInfo() {
+        if (m_viewinfo == null) {
+            m_viewinfo = new WindowInfo(WindowInfo.MODELESSDIALOG);
+            m_viewinfo.setWidth(this.getWidth() + 8);
+            m_viewinfo.setHeight(this.getHeight());
+            m_viewinfo.setTitle(PluginServices.getText(this, "Encuadre"));
+        }
+        return m_viewinfo;
+    }
+
+    /**
+     * @see com.iver.mdiApp.ui.MDIManager.IWindow#windowActivated()
+     */
+    public void viewActivated() {
+    }
+
+    /**
+     * This method initializes jPanel2
+     * 
+     * @return javax.swing.JPanel
+     */
+    private JPanel getJPanel2() {
+        if (jPanel2 == null) {
+            jPanel2 = new JPanel(new FlowLayout(FlowLayout.RIGHT, 0, 5));
+            jPanel2.setBounds(new java.awt.Rectangle(11, 180, 508, 33));
+            jPanel2.add(getBtnAceptar(), null);
+            jPanel2.add(getBtnEliminar(), null);
+        }
+        return jPanel2;
+    }
+
+    /**
+     * This method initializes jPanel3
+     * 
+     * @return javax.swing.JPanel
+     */
+    private JPanel getJPanel3() {
+        if (jPanel3 == null) {
+            jPanel3 = new JPanel(new FlowLayout(FlowLayout.RIGHT, 0, 5));
+            jPanel3.setBounds(new java.awt.Rectangle(8, 59, 511, 33));
+            jPanel3.add(getBtnGuardar(), null);
+        }
+        return jPanel3;
+    }
+
+    public Object getWindowProfile() {
+        return WindowInfo.TOOL_PROFILE;
+    }
+
+} // @jve:decl-index=0:visual-constraint="10,10"

Property changes on: tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/app/project/documents/view/gui/FPanelExtentSelector.java
___________________________________________________________________
Added: svn:keywords
   + Author Date Id Revision
Added: svn:eol-style
   + native

Index: tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/app/project/documents/view/gui/DefaultViewPanel.java
===================================================================
--- tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/app/project/documents/view/gui/DefaultViewPanel.java	(revision 0)
+++ tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/app/project/documents/view/gui/DefaultViewPanel.java	(revision 38653)
@@ -0,0 +1,579 @@
+/* gvSIG. Geographic Information System of the Valencian Government
+ *
+ * Copyright (C) 2007-2008 Infrastructures and Transports Department
+ * of the Valencian Government (CIT)
+ * 
+ * This program is free software; you can redistribute it and/or
+ * modify it under the terms of the GNU General Public License
+ * as published by the Free Software Foundation; either version 2
+ * of the License, or (at your option) any later version.
+ * 
+ * This program is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
+ * GNU General Public License for more details.
+ * 
+ * You should have received a copy of the GNU General Public License
+ * along with this program; if not, write to the Free Software
+ * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, 
+ * MA  02110-1301, USA.
+ * 
+ */
+
+/*
+ * AUTHORS (In addition to CIT):
+ * 2004-2009 IVER TI
+ *   
+ */
+package org.gvsig.app.project.documents.view.gui;
+
+import java.awt.BorderLayout;
+import java.awt.Color;
+import java.awt.Dimension;
+import java.beans.PropertyChangeEvent;
+import java.beans.PropertyChangeListener;
+import java.util.HashMap;
+import java.util.Iterator;
+
+import javax.swing.JSplitPane;
+
+import org.cresques.cts.IProjection;
+
+import org.gvsig.andami.PluginServices;
+import org.gvsig.andami.messages.NotificationManager;
+import org.gvsig.andami.ui.mdiFrame.NewStatusBar;
+import org.gvsig.andami.ui.mdiManager.WindowInfo;
+import org.gvsig.app.project.DefaultProject;
+import org.gvsig.app.project.documents.Document;
+import org.gvsig.app.project.documents.view.MapOverview;
+import org.gvsig.app.project.documents.view.ViewDocument;
+import org.gvsig.app.project.documents.view.toc.gui.TOC;
+import org.gvsig.app.project.documents.view.toolListeners.AreaListener;
+import org.gvsig.app.project.documents.view.toolListeners.InfoListener;
+import org.gvsig.app.project.documents.view.toolListeners.MeasureListener;
+import org.gvsig.app.project.documents.view.toolListeners.PanListener;
+import org.gvsig.app.project.documents.view.toolListeners.PointSelectListener;
+import org.gvsig.app.project.documents.view.toolListeners.PolygonSelectListener;
+import org.gvsig.app.project.documents.view.toolListeners.RectangleSelectListener;
+import org.gvsig.app.project.documents.view.toolListeners.StatusBarListener;
+import org.gvsig.app.project.documents.view.toolListeners.ZoomInListener;
+import org.gvsig.app.project.documents.view.toolListeners.ZoomOutListener;
+import org.gvsig.fmap.mapcontext.MapContext;
+import org.gvsig.fmap.mapcontext.events.ColorEvent;
+import org.gvsig.fmap.mapcontext.events.ExtentEvent;
+import org.gvsig.fmap.mapcontext.events.ProjectionEvent;
+import org.gvsig.fmap.mapcontext.events.listeners.ViewPortListener;
+import org.gvsig.fmap.mapcontext.layers.FLayer;
+import org.gvsig.fmap.mapcontext.layers.FLayers;
+import org.gvsig.fmap.mapcontext.layers.vectorial.FLyrVect;
+import org.gvsig.fmap.mapcontrol.MapControl;
+import org.gvsig.fmap.mapcontrol.MapControlCreationException;
+import org.gvsig.fmap.mapcontrol.MapControlLocator;
+import org.gvsig.fmap.mapcontrol.MapControlManager;
+import org.gvsig.fmap.mapcontrol.tools.ZoomOutRightButtonListener;
+import org.gvsig.fmap.mapcontrol.tools.Behavior.Behavior;
+import org.gvsig.fmap.mapcontrol.tools.Behavior.MouseMovementBehavior;
+import org.gvsig.fmap.mapcontrol.tools.Behavior.MouseWheelBehavior;
+import org.gvsig.fmap.mapcontrol.tools.Behavior.MoveBehavior;
+import org.gvsig.fmap.mapcontrol.tools.Behavior.PointBehavior;
+import org.gvsig.fmap.mapcontrol.tools.Behavior.PolygonBehavior;
+import org.gvsig.fmap.mapcontrol.tools.Behavior.PolylineBehavior;
+import org.gvsig.fmap.mapcontrol.tools.Behavior.RectangleBehavior;
+import org.gvsig.utils.console.JConsole;
+import org.gvsig.utils.console.JDockPanel;
+import org.gvsig.utils.console.ResponseListener;
+import org.gvsig.utils.console.jedit.JEditTextArea;
+
+/**
+ * <p>
+ * <b>Class View</b>. This class represents the gvSIG specific internal window
+ * where the maps are displayed and where the events coming from the user are
+ * captured.
+ * </p>
+ * <p>
+ * It is composed by three main visual areas:
+ * </p>
+ * <ol>
+ * <li>
+ * <b>Map control</b>: the map area located in the right area of the window. It
+ * takes up the biggest part of the window.</li>
+ * <li>
+ * <b>Table of contents (TOC)</b>: is a list of layers displayed in the view.
+ * The TOC is located on the left-top corner of the View and is the place where
+ * the user can modify the order, the legends, the visibility and other
+ * properties of the layers.</li>
+ * <li>
+ * <b>Map overview</b>: is a small MapControl located in the left-bottom corner
+ * of the View where the user can put some layers which summarizes the view. It
+ * is used to make the navigation easier and faster.</li>
+ * </ol>
+ * 
+ * @author 2005- Vicente Caballero
+ * @author 2009- Joaquin del Cerro
+ * 
+ */
+public class DefaultViewPanel extends AbstractViewPanel {
+	/**
+	 * 
+	 */
+	private static final long serialVersionUID = -4044661458841786519L;
+
+	private JConsole console;
+	private JDockPanel dockConsole = null;
+	protected ResponseAdapter consoleResponseAdapter = new ResponseAdapter();
+	protected boolean isShowConsole = false;
+	private ViewPortListener viewPortListener;
+	private static MapControlManager mapControlManager = MapControlLocator
+			.getMapControlManager();
+
+	/**
+	 * Creates a new View object. Before being used, the object must be
+	 * initialized.
+	 * 
+	 * @see initialize()
+	 */
+	public DefaultViewPanel() {
+		super();
+		this.setName("View");
+		// TODO Remove this when the system lo load libraries is finished
+		if (mapControlManager == null) {
+			mapControlManager = MapControlLocator.getMapControlManager();
+		}
+	}
+
+	public DefaultViewPanel(Document document) {
+		this();
+		this.initialize();
+		this.setDocument(document);
+	}
+
+	/**
+     * Create the internal componentes and populate the window with them.
+     * If the layout properties were set using the
+	 * <code>setWindowData(WindowData)</code> method, the window will be
+	 * populated according to this properties.
+	 */
+	protected void initialize() {
+		super.initialize();
+		initComponents();
+		hideConsole();
+		getConsolePanel().addResponseListener(consoleResponseAdapter);
+	}
+
+	public void setDocument(Document document) {
+		setModel((ViewDocument) document);
+	}
+
+	public Document getDocument() {
+		return this.modelo;
+	}
+
+	public void setModel(ViewDocument model) {
+		this.modelo = model;
+		// Se registra como listener de cambios en FMap
+		MapContext fmap = modelo.getMapContext();
+
+		FLayers layers = fmap.getLayers();
+		for (int i = 0; i < layers.getLayersCount(); i++) {
+			if (layers.getLayer(i).isEditing()
+					&& layers.getLayer(i) instanceof FLyrVect) {
+				this.showConsole();
+			}
+		}
+
+		// Se configura el mapControl
+		m_MapControl.setMapContext(fmap);
+		m_TOC.setMapContext(fmap);
+		m_MapControl.getMapContext().getLayers().addLegendListener(m_TOC);
+
+		m_MapControl.setBackground(new Color(255, 255, 255));
+		if (modelo.getMapOverViewContext() != null) {
+			m_MapLoc.setModel(modelo.getMapOverViewContext());
+		}
+		model.addPropertyChangeListener(new PropertyChangeListener() {
+			public void propertyChange(PropertyChangeEvent evt) {
+				if (evt.getPropertyName().equals("name")) {
+					PluginServices.getMDIManager()
+							.getWindowInfo(DefaultViewPanel.this)
+                        .setTitle(
+                            PluginServices.getText(this, "Vista") + ": "
+                                + (String) evt.getNewValue());
+				}
+			}
+		});
+		if (m_MapControl.getViewPort() != null) {
+			viewPortListener = new ViewPortListener() {
+				public void extentChanged(ExtentEvent e) {
+					if (PluginServices.getMainFrame() != null) {
+						PluginServices
+								.getMainFrame()
+								.getStatusBar()
+								.setControlValue(
+										"view-change-scale",
+										String.valueOf(m_MapControl
+												.getMapContext().getScaleView()));
+						PluginServices
+								.getMainFrame()
+								.getStatusBar()
+								.setMessage(
+										"projection",
+										getMapControl().getViewPort()
+												.getProjection().getAbrev());
+					}
+				}
+
+				public void backColorChanged(ColorEvent e) {
+					// Do nothing
+				}
+
+				public void projectionChanged(ProjectionEvent e) {
+					m_MapLoc.setProjection(e.getNewProjection());
+				}
+			};
+			m_MapControl.getViewPort().addViewPortListener(viewPortListener);
+		}
+	}
+
+	public JConsole getConsolePanel() {
+		if (console == null) {
+			console = new JConsole();
+			// Para distinguir cuando se est� escribiendo sobre la consola y
+			// cuando no.
+			console.setJTextName("CADConsole");
+		}
+		return console;
+	}
+
+	private JDockPanel getDockConsole() {
+		if (dockConsole == null) {
+			dockConsole = new JDockPanel(getConsolePanel());
+		}
+		return dockConsole;
+	}
+
+	public void addConsoleListener(String prefix, ResponseListener listener) {
+		consoleResponseAdapter.putSpaceListener(prefix, listener);
+
+	}
+
+	public void removeConsoleListener(ResponseListener listener) {
+		consoleResponseAdapter.deleteListener(listener);
+
+	}
+
+	public void focusConsole(String text) {
+		getConsolePanel().addResponseText(text);
+
+		JEditTextArea jeta = getConsolePanel().getTxt();
+		jeta.requestFocusInWindow();
+		jeta.setCaretPosition(jeta.getText().length());
+
+	}
+
+	public void hideConsole() {
+		isShowConsole = false;
+		getDockConsole().setVisible(false);
+
+	}
+
+	public void showConsole() {
+		if (isShowConsole) {
+			return;
+		}
+		isShowConsole = true;
+		getMapControl().remove(getDockConsole());
+		getMapControl().setLayout(new BorderLayout());
+		getMapControl().add(getDockConsole(), BorderLayout.SOUTH);
+		getDockConsole().setVisible(true);
+
+	}
+
+	static class ResponseAdapter implements ResponseListener {
+
+        private HashMap<String, ResponseListener> spaceListener =
+            new HashMap<String, ResponseListener>();
+
+		public void putSpaceListener(String namespace, ResponseListener listener) {
+			spaceListener.put(namespace, listener);
+		}
+
+		public void acceptResponse(String response) {
+			boolean nameSpace = false;
+			int n = -1;
+			if (response != null) {
+				if ((n = response.indexOf(':')) != -1) {
+					nameSpace = true;
+				}
+			}
+
+			if (nameSpace) {
+                ResponseListener listener =
+                    spaceListener.get(response.substring(0, n));
+				if (listener != null) {
+					listener.acceptResponse(response.substring(n + 1));
+				}
+			} else {
+                Iterator<ResponseListener> i =
+                    spaceListener.values().iterator();
+				while (i.hasNext()) {
+					ResponseListener listener = i.next();
+					listener.acceptResponse(response);
+				}
+			}
+		}
+
+		/**
+		 * @param listener
+		 */
+		public void deleteListener(ResponseListener listener) {
+			Iterator<String> i = spaceListener.keySet().iterator();
+			while (i.hasNext()) {
+				String namespace = i.next();
+				ResponseListener l = spaceListener.get(namespace);
+				if (l == listener) {
+					spaceListener.remove(namespace);
+				}
+			}
+		}
+
+	}
+
+	protected void initComponents() { // GEN-BEGIN:initComponents
+		m_MapControl = new MapControl(); // Default is paintEnabled = false.
+											// Remember to activate it
+		try {
+			m_MapControl.setMapControlDrawer(mapControlManager
+					.createDefaultMapControlDrawer());
+		} catch (MapControlCreationException e) {
+			NotificationManager.addError(e);
+		}
+
+		m_MapControl.addExceptionListener(mapControlExceptionListener);
+		m_TOC = new TOC();
+
+		// Ponemos el localizador
+		m_MapLoc = new MapOverview(m_MapControl);
+		try {
+			m_MapLoc.setMapControlDrawer(mapControlManager
+					.createDefaultMapControlDrawer());
+		} catch (MapControlCreationException e) {
+			NotificationManager.addError(e);
+		}
+		removeAll();
+		tempMainSplit = new ViewSplitPane(JSplitPane.HORIZONTAL_SPLIT);
+
+		if (windowLayout == null) {
+			m_MapLoc.setPreferredSize(new Dimension(150, 200));
+			tempMainSplit.setPreferredSize(new Dimension(500, 300));
+		}
+
+		if (!isPalette()) {
+			tempSplitToc = new JSplitPane(JSplitPane.VERTICAL_SPLIT);
+			tempSplitToc.setTopComponent(m_TOC);
+			tempSplitToc.setBottomComponent(m_MapLoc);
+			tempSplitToc.setResizeWeight(0.7);
+			tempMainSplit.setLeftComponent(tempSplitToc);
+		} else {
+			tempMainSplit.setLeftComponent(m_TOC);
+		}
+		m_TOC.setVisible(true);
+		tempMainSplit.setRightComponent(m_MapControl);
+		this.setLayout(new BorderLayout());
+		this.add(tempMainSplit, BorderLayout.CENTER);
+
+		if (windowLayout != null) {
+			try {
+				tempMainSplit.setDividerLocation(Integer.valueOf(
+						windowLayout.get("MainDivider.Location")).intValue());
+				if (windowLayout.get("TOCDivider.Location") != null) {
+                    tempSplitToc.setDividerLocation(Integer.valueOf(
+                        windowLayout.get("TOCDivider.Location")).intValue());
+				}
+			} catch (NumberFormatException ex) {
+				PluginServices.getLogger().error(
+						"Error restoring View properties");
+			}
+		}
+
+		// Listener de eventos de movimiento que pone las coordenadas del rat�n
+		// en la barra de estado
+		StatusBarListener sbl = new StatusBarListener(m_MapControl);
+
+		// Zoom out (pinchas y el mapa se centra y te muestra m�s).
+		// No es dibujando un rect�ngulo, es solo pinchando.
+
+		ZoomOutListener zol = new ZoomOutListener(m_MapControl);
+
+		m_MapControl.addBehavior("zoomOut", new Behavior[] {
+            new PointBehavior(zol), new MouseMovementBehavior(sbl) });
+
+		// pan
+
+		PanListener pl = new PanListener(m_MapControl);
+		m_MapControl.addBehavior("pan", new Behavior[] { new MoveBehavior(pl),
+            new MouseMovementBehavior(sbl) });
+
+		// Medir
+
+		MeasureListener mli = new MeasureListener(m_MapControl);
+		m_MapControl.addBehavior("medicion", new Behavior[] {
+            new PolylineBehavior(mli), new MouseMovementBehavior(sbl) });
+
+		// Area
+
+		AreaListener ali = new AreaListener(m_MapControl);
+		m_MapControl.addBehavior("area", new Behavior[] {
+            new PolygonBehavior(ali), new MouseMovementBehavior(sbl) });
+
+		// Seleccion por punto
+		PointSelectListener psl = new PointSelectListener(m_MapControl);
+		m_MapControl.addBehavior("pointSelection", new Behavior[] {
+            new PointBehavior(psl), new MouseMovementBehavior(sbl) });
+
+		// Info por punto
+		InfoListener il = new InfoListener(m_MapControl);
+		m_MapControl.addBehavior("info", new Behavior[] {
+            new PointBehavior(il), new MouseMovementBehavior(sbl) });
+
+		// Selecci�n por rect�ngulo
+		RectangleSelectListener rsl = new RectangleSelectListener(m_MapControl);
+		m_MapControl.addBehavior("rectSelection", new Behavior[] {
+            new RectangleBehavior(rsl), new MouseMovementBehavior(sbl) });
+
+		// Selecci�n por pol�gono
+        PolygonSelectListener poligSel =
+            new PolygonSelectListener(m_MapControl);
+        m_MapControl.addBehavior("polSelection", new Behavior[] {
+            new PolygonBehavior(poligSel), new MouseMovementBehavior(sbl) });
+
+		// Zoom por rect�ngulo
+		ZoomOutRightButtonListener zoil =
+            new ZoomOutRightButtonListener(m_MapControl);
+		ZoomInListener zil = new ZoomInListener(m_MapControl);
+		m_MapControl.addBehavior("zoomIn", new Behavior[] {
+				new RectangleBehavior(zil), new PointBehavior(zoil),
+            new MouseMovementBehavior(sbl) });
+
+		/*
+		SelectImageListener sil = new SelectImageListener(m_MapControl);
+		m_MapControl.addBehavior("selectImage", new Behavior[] {
+            new PointBehavior(sil), new MouseMovementBehavior(sbl) });
+        */
+
+		m_MapControl.setTool("zoomIn"); // Por defecto
+        m_MapControl.addCombinedBehavior(new MouseWheelBehavior());
+	}
+
+	public void windowActivated() {
+		NewStatusBar statusbar = PluginServices.getMainFrame().getStatusBar();
+		MapContext mapContext = this.getMapControl().getMapContext();
+
+		statusbar.setMessage("units",
+				PluginServices.getText(this, mapContext.getDistanceName()));
+		statusbar.setControlValue("view-change-scale",
+				String.valueOf(mapContext.getScaleView()));
+		IProjection proj = getMapControl().getViewPort().getProjection();
+		if (proj != null) {
+			statusbar.setMessage("projection", proj.getAbrev());
+		} else {
+			statusbar.setMessage("projection", "");
+		}
+	}
+
+	public void windowClosed() {
+		super.windowClosed();
+		if (viewPortListener != null) {
+			getMapControl().getViewPort().removeViewPortListener(
+					viewPortListener);
+		}
+		if (getMapOverview() != null) {
+			getMapOverview().getViewPort().removeViewPortListener(
+					getMapOverview());
+		}
+
+	}
+
+	public void toPalette() {
+		isPalette = true;
+		m_MapLoc.setPreferredSize(new Dimension(200, 150));
+		m_MapLoc.setSize(new Dimension(200, 150));
+		movp = new MapOverViewPalette(m_MapLoc, this);
+		PluginServices.getMDIManager().addWindow(movp);
+        FLayer[] layers =
+            getViewDocument().getMapContext().getLayers().getActives();
+		if (layers.length > 0 && layers[0] instanceof FLyrVect) {
+			if (((FLyrVect) layers[0]).isEditing()) {
+				showConsole();
+				return;
+			}
+		}
+		hideConsole();
+
+	}
+
+	public void restore() {
+		isPalette = false;
+		PluginServices.getMDIManager().closeWindow(movp);
+        FLayer[] layers =
+            getViewDocument().getMapContext().getLayers().getActives();
+		if (layers.length > 0 && layers[0] instanceof FLyrVect) {
+			if (((FLyrVect) layers[0]).isEditing()) {
+				showConsole();
+				return;
+			}
+		}
+		hideConsole();
+		JSplitPane tempSplitToc = new JSplitPane(JSplitPane.VERTICAL_SPLIT);
+		tempSplitToc.setTopComponent(m_TOC);
+		tempSplitToc.setBottomComponent(m_MapLoc);
+		tempSplitToc.setResizeWeight(0.7);
+		tempMainSplit.setLeftComponent(tempSplitToc);
+	}
+
+	/**
+	 * Sets the default map overview background color that will be used in
+	 * subsequent projects.
+	 * 
+	 * @param color
+	 * @deprecated use instead
+	 *             Project.getPreferences().setDefaultMapoverViewBackColor
+	 */
+	public static void setDefaultMapOverViewBackColor(Color color) {
+		DefaultProject.getPreferences().setDefaultOverviewBackColor(color);
+	}
+
+	/**
+	 * Returns the current default map overview background color defined which
+	 * is the color defined when the user does not define any other one
+	 * 
+	 * @return java.awt.Color
+	 * @deprecated use instead
+	 *             Project.getPreferences().setDefaultMapoverViewBackColor
+	 */
+	public static Color getDefaultMapOverViewBackColor() {
+		return DefaultProject.getPreferences().getDefaultOverviewBackColor();
+	}
+
+	/**
+	 * Returns the current default view background color defined which is the
+	 * color defined when the user does not define any other one
+	 * 
+	 * @return java.awt.Color
+	 * @deprecated use instead Project.getPreferences().getDefaultViewBackColor
+	 */
+	public static Color getDefaultBackColor() {
+		return DefaultProject.getPreferences().getDefaultViewBackColor();
+	}
+
+	/**
+	 * @deprecated use instead Project.getPreferences().setDefaultViewBackColor
+	 */
+	public static void setDefaultBackColor(Color color) {
+		DefaultProject.getPreferences().setDefaultViewBackColor(color);
+	}
+
+	public Object getWindowProfile() {
+		return WindowInfo.EDITOR_PROFILE;
+	}
+
+}

Property changes on: tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/app/project/documents/view/gui/DefaultViewPanel.java
___________________________________________________________________
Added: svn:keywords
   + Author Date Id Revision
Added: svn:eol-style
   + native

Index: tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/app/project/documents/view/ViewManager.java
===================================================================
--- tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/app/project/documents/view/ViewManager.java	(revision 0)
+++ tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/app/project/documents/view/ViewManager.java	(revision 38653)
@@ -0,0 +1,186 @@
+package org.gvsig.app.project.documents.view;
+
+import javax.swing.ImageIcon;
+
+import org.gvsig.andami.IconThemeHelper;
+import org.gvsig.andami.PluginServices;
+import org.gvsig.andami.ui.mdiManager.IWindow;
+import org.gvsig.app.project.ProjectManager;
+import org.gvsig.app.project.documents.AbstractDocument;
+import org.gvsig.app.project.documents.AbstractDocumentManager;
+import org.gvsig.app.project.documents.Document;
+import org.gvsig.app.project.documents.actions.CopyDocumentAction;
+import org.gvsig.app.project.documents.actions.CutDocumentAction;
+import org.gvsig.app.project.documents.actions.PasteDocumentAction;
+import org.gvsig.app.project.documents.gui.IDocumentWindow;
+import org.gvsig.app.project.documents.gui.WindowLayout;
+import org.gvsig.app.project.documents.view.gui.DefaultViewPanel;
+import org.gvsig.app.project.documents.view.gui.ViewProperties;
+import org.gvsig.fmap.mapcontext.MapContext;
+import org.gvsig.fmap.mapcontext.MapContextLocator;
+import org.gvsig.fmap.mapcontext.MapContextManager;
+import org.gvsig.tools.ToolsLocator;
+import org.gvsig.tools.dynobject.DynStruct;
+import org.gvsig.tools.persistence.PersistenceManager;
+import org.slf4j.Logger;
+import org.slf4j.LoggerFactory;
+
+/**
+ * Factory of View.
+ *
+ * @author 2005-         Vicente Caballero
+ * @author 2009-         Joaquin del Cerro
+ * 
+ */
+public class ViewManager extends AbstractDocumentManager {
+    private static final Logger logger = LoggerFactory.getLogger(ViewManager.class);
+    
+    private static final String PERSISTENCE_VIEW_DOCUMENT_DEFINITION_NAME =
+        "DefaultViewDocument";
+    public static String TYPENAME = "project.document.view2d";
+    private DynStruct persistenceDefinition;
+    
+    public ViewManager() {
+    	// Do nothing
+    }
+    
+    public int getPriority() {
+        return 0;
+    }
+
+    public ImageIcon getIcon() {
+		return PluginServices.getIconTheme().get("document-view-icon");
+    }
+
+    public ImageIcon getIconSelected() {
+		return PluginServices.getIconTheme().get("document-view-icon-sel");
+    }
+
+    public String getTitle() {
+        return PluginServices.getText(this, "Vista");
+    }
+
+    public String getTypeName() {
+        return TYPENAME;
+    }
+    
+    public Class getMainWindowClass() {
+        return DefaultViewPanel.class;
+    }
+    
+    public AbstractDocument createDocument() {
+    	return new DefaultViewDocument(this);
+    }
+
+	public IWindow getMainWindow(Document doc, WindowLayout layout) {
+	    IDocumentWindow view;
+	    
+	    view = (IDocumentWindow) PluginServices.getMDIManager().getSingletonWindow(getMainWindowClass(), doc);
+	    if( view != null ) {
+	        // The view window document is already created, return it.
+	        return view;
+	    }
+	    view = this.createDocumentWindow(doc);
+		if ( layout != null && view != null ) {
+			view.setWindowLayout(layout);
+		}
+		((AbstractDocument) doc).raiseEventCreateWindow(view);
+		return view;
+	}
+
+	public IWindow getPropertiesWindow(Document doc) {
+		return new ViewProperties((DefaultViewDocument) doc);
+	}
+
+    /**
+     * Registers in the points of extension the Factory with alias.
+     *
+     */
+    public static void register() {
+        ViewManager factory = new ViewManager();
+    	ProjectManager.getInstance().registerDocumentFactory(factory);
+    	
+        PersistenceManager manager = ToolsLocator.getPersistenceManager();
+        manager.registerFactory(factory);
+
+
+        ProjectManager.getInstance().registerDocumentAction(TYPENAME,new CopyDocumentAction());
+        ProjectManager.getInstance().registerDocumentAction(TYPENAME,new CutDocumentAction());
+        ProjectManager.getInstance().registerDocumentAction(TYPENAME,new PasteDocumentAction());
+
+	   	IconThemeHelper.registerIcon("document", "document-view-icon", ViewManager.class);
+	   	IconThemeHelper.registerIcon("document", "document-view-icon-sel", ViewManager.class);
+	   	
+	   	IconThemeHelper.registerIcon("cursor", "cursor-crux", ViewManager.class);
+	   	IconThemeHelper.registerIcon("cursor", "cursor-info-by-point", ViewManager.class);
+	   	IconThemeHelper.registerIcon("cursor", "cursor-pan", ViewManager.class);
+	   	IconThemeHelper.registerIcon("cursor", "cursor-query-area", ViewManager.class);
+	   	IconThemeHelper.registerIcon("cursor", "cursor-select-by-point", ViewManager.class);
+	   	IconThemeHelper.registerIcon("cursor", "cursor-select-by-polygon", ViewManager.class);
+	   	IconThemeHelper.registerIcon("cursor", "cursor-zoom-in", ViewManager.class);
+	   	IconThemeHelper.registerIcon("cursor", "cursor-zoom-out", ViewManager.class);
+
+	   	IconThemeHelper.registerIcon("layer", "layer-icon", ViewManager.class);
+	   	IconThemeHelper.registerIcon("layer", "layer-icon-group", ViewManager.class);
+	   	IconThemeHelper.registerIcon("layer", "layer-icon-vectorial", ViewManager.class);
+	   	IconThemeHelper.registerIcon("layer", "layer-icon-dgn", ViewManager.class);
+	   	IconThemeHelper.registerIcon("layer", "layer-icon-dxf", ViewManager.class);
+	   	IconThemeHelper.registerIcon("layer", "layer-icon-postgresql", ViewManager.class);
+	   	IconThemeHelper.registerIcon("layer", "layer-icon-mysql", ViewManager.class);
+	   	IconThemeHelper.registerIcon("layer", "layer-icon-jdbc", ViewManager.class);
+
+	   	IconThemeHelper.registerIcon("legend", "legend-overview-single-symbol", ViewManager.class);
+	   	IconThemeHelper.registerIcon("legend", "legend-overview-vectorial-interval", ViewManager.class);
+	   	IconThemeHelper.registerIcon("legend", "legend-overview-vectorial-unique-value", ViewManager.class);
+
+	   	MapContextManager mapContextMgr = MapContextLocator.getMapContextManager();
+	   	mapContextMgr.registerIconLayer("DGN", "layer-icon-dgn");
+	   	mapContextMgr.registerIconLayer("DXF", "layer-icon-dfx");
+	   	mapContextMgr.registerIconLayer("jdbc", "layer-icon-jdbc");
+	   	mapContextMgr.registerIconLayer("PostgreSQL", "layer-icon-postgresql");
+	   	mapContextMgr.registerIconLayer("MySQL", "layer-icon-mysql");
+	   	
+        if (factory.persistenceDefinition == null){
+            factory.persistenceDefinition = manager.addDefinition(
+                ViewDocument.class,
+                PERSISTENCE_VIEW_DOCUMENT_DEFINITION_NAME,
+                "Default view document persistence definition",
+                null, 
+                null
+            );
+            factory.persistenceDefinition.extend(manager.getDefinition(AbstractDocument.PERSISTENCE_DEFINITION_NAME));
+
+            factory.persistenceDefinition.addDynFieldBoolean("useMapOverview").setMandatory(true);
+            factory.persistenceDefinition.addDynFieldObject("mainMapContext").setClassOfValue(MapContext.class).setMandatory(true);
+            factory.persistenceDefinition.addDynFieldObject("overviewMapContext").setClassOfValue(MapContext.class).setMandatory(false);
+
+        }
+
+
+    }
+
+    @SuppressWarnings("rawtypes")
+    public DynStruct getDefinition(String className) {
+
+        if( this.persistenceDefinition.getName().equalsIgnoreCase(className)) {
+            return this.persistenceDefinition;
+        }
+        if( this.persistenceDefinition.getFullName().equalsIgnoreCase(className)) {
+            return this.persistenceDefinition;
+        }
+        if( this.getDocumentClass().getName().equals(className) ) {
+            return this.persistenceDefinition;
+        }
+
+        return null;
+    }
+
+    @SuppressWarnings("rawtypes")
+    protected Class getDocumentClass() {
+        return DefaultViewDocument.class;
+    }
+
+    public boolean manages(Object object) {
+        return object instanceof ViewDocument;
+    }
+}

Property changes on: tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/app/project/documents/view/ViewManager.java
___________________________________________________________________
Added: svn:keywords
   + Author Date Id Revision
Added: svn:eol-style
   + native

Index: tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/app/project/documents/view/toc/ITocOrderListener.java
===================================================================
--- tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/app/project/documents/view/toc/ITocOrderListener.java	(revision 0)
+++ tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/app/project/documents/view/toc/ITocOrderListener.java	(revision 38653)
@@ -0,0 +1,62 @@
+/*
+ * Created on 03-jun-2004
+ *
+ * TODO To change the template for this generated file go to
+ * Window - Preferences - Java - Code Generation - Code and Comments
+ */
+/* gvSIG. Sistema de Informaci�n Geogr�fica de la Generalitat Valenciana
+ *
+ * Copyright (C) 2004 IVER T.I. and Generalitat Valenciana.
+ *
+ * This program is free software; you can redistribute it and/or
+ * modify it under the terms of the GNU General Public License
+ * as published by the Free Software Foundation; either version 2
+ * of the License, or (at your option) any later version.
+ *
+ * This program is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
+ * GNU General Public License for more details.
+ *
+ * You should have received a copy of the GNU General Public License
+ * along with this program; if not, write to the Free Software
+ * Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA  02111-1307,USA.
+ *
+ * For more information, contact:
+ *
+ *  Generalitat Valenciana
+ *   Conselleria d'Infraestructures i Transport
+ *   Av. Blasco Ib��ez, 50
+ *   46010 VALENCIA
+ *   SPAIN
+ *
+ *      +34 963862235
+ *   gvsig@gva.es
+ *      www.gvsig.gva.es
+ *
+ *    or
+ *
+ *   IVER T.I. S.A
+ *   Salamanca 50
+ *   46005 Valencia
+ *   Spain
+ *
+ *   +34 963163400
+ *   dac@iver.es
+ */
+package org.gvsig.app.project.documents.view.toc;
+
+import org.gvsig.fmap.mapcontext.layers.FLayer;
+import org.gvsig.fmap.mapcontext.layers.FLayers;
+
+
+/**
+ * @author fjp
+ *
+ * TODO To change the template for this generated type comment go to
+ * Window - Preferences - Java - Code Generation - Code and Comments
+ */
+public interface ITocOrderListener {
+	void orderChanged(int oldPos, int newPos,FLayers lpd);
+	void parentChanged(FLayers lpo,FLayers lpd,FLayer ls);
+}

Property changes on: tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/app/project/documents/view/toc/ITocOrderListener.java
___________________________________________________________________
Added: svn:keywords
   + Author Date Id Revision
Added: svn:eol-style
   + native

Index: tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/app/project/documents/view/toc/actions/CopyPasteLayersUtiles.java
===================================================================
--- tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/app/project/documents/view/toc/actions/CopyPasteLayersUtiles.java	(revision 0)
+++ tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/app/project/documents/view/toc/actions/CopyPasteLayersUtiles.java	(revision 38653)
@@ -0,0 +1,416 @@
+package org.gvsig.app.project.documents.view.toc.actions;
+
+import javax.help.UnsupportedOperationException;
+
+import org.gvsig.fmap.mapcontext.layers.FLayer;
+import org.gvsig.fmap.mapcontext.layers.FLayers;
+import org.gvsig.utils.XMLEntity;
+
+
+public class CopyPasteLayersUtiles {
+	private static CopyPasteLayersUtiles theInstance = null;
+
+	public static CopyPasteLayersUtiles getInstance() {
+		if (theInstance == null) {
+			theInstance = new CopyPasteLayersUtiles();
+		}
+		return theInstance;
+	}
+
+	public XMLEntity generateXMLCopyLayers(FLayer[] actives) {
+		// FIXME: jjdc esta pendiente la implementacion del copy/paste
+		throw new UnsupportedOperationException();
+//
+//		XMLEntity xml = this.newRootNode();
+//		XMLEntity xmlLayers = this.newLayersNode();
+//		XMLEntity xmlTables = this.newTablesNode();
+//		XMLEntity xmlDataSources = this.newDataSourcesNode();
+//
+//		for (int i=0;i < actives.length; i++) {
+//			if (!this.addToXMLLayer(actives[i],xmlLayers ,xmlTables,xmlDataSources)) {
+//				return null;
+//			}
+//
+//		}
+//
+//		if (xmlDataSources.getChildrenCount() > 0) {
+//			xml.addChild(xmlDataSources);
+//		}
+//		if (xmlLayers.getChildrenCount() > 0) {
+//			xml.addChild(xmlLayers);
+//		}
+//		if (xmlTables.getChildrenCount() > 0) {
+//			xml.addChild(xmlTables);
+//		}
+//
+//		return xml;
+//
+	}
+
+
+
+	/*
+	 *
+	 *
+	 *
+	 * Funciones Publicas de carga de un XML (pegar)
+	 *
+	 *
+	 *
+	*/
+
+	public boolean loadLayersFromXML(XMLEntity xml, FLayers root) {
+		// FIXME: jjdc esta pendiente la implementacion del copy/paste
+		throw new UnsupportedOperationException();
+//		XMLEntity xmlLayers = xml.firstChild("type","layers");
+//		XMLEntity xmlTables = xml.firstChild("type","tables");
+//		XMLEntity xmlDataSources = xml.firstChild("type","dataSources");
+//
+//		if (xmlLayers == null ) {
+//			return false;
+//		}
+//
+//		// Se pegan las tablas igualmente
+//		/*
+//		Project project = this.getProject();
+//
+//		Hashtable tablesConfits = this.getConflicts(xmlTables,project.getTables());
+//		*/
+//
+//
+//		if (xmlDataSources != null)  {
+//			if (!this.registerDataSources(xmlDataSources)) {
+//				return false;
+//			}
+//		}
+//
+//		if (!this.addLayers(xmlLayers,root)) {
+//			return false;
+//		}
+//
+//		if (xmlTables != null)  {
+//			if (!this.addTables(xmlTables)) {
+//				return false;
+//			}
+//		}
+//
+//		return true;
+//
+	}
+
+	public boolean loadTablesFromXML(XMLEntity xml) {
+		// FIXME: jjdc esta pendiente la implementacion del copy/paste
+		throw new UnsupportedOperationException();
+//		XMLEntity xmlTables = xml.firstChild("type","tables");
+//		XMLEntity xmlDataSources = xml.firstChild("type","dataSources");
+//
+//
+//		if (xmlTables == null ) {
+//			return false;
+//		}
+//
+//		/*
+//		Project project = this.getProject();
+//
+//		Hashtable tablesConfits = this.getConflicts(xmlTables,project.getTables());
+//		*/
+//
+//		if (xmlDataSources != null)  {
+//			if (!this.registerDataSources(xmlDataSources)) {
+//				return false;
+//			}
+//		}
+//
+//
+//
+//		return this.addTables(xmlTables);
+	}
+
+
+	public boolean checkXMLRootNode(XMLEntity xml) {
+		// FIXME: jjdc esta pendiente la implementacion del copy/paste
+		throw new UnsupportedOperationException();
+//		if (!xml.contains("applicationName")) {
+//			return false;
+//		}
+//		if (!xml.getStringProperty("applicationName").equalsIgnoreCase("gvSIG")) {
+//			return false;
+//		}
+//
+//		if (!xml.contains("version")) {
+//			return false;
+//		}
+//		if (!xml.getStringProperty("version").equalsIgnoreCase(Version.format())) {
+//			return false;
+//		}
+//
+//		return true;
+	}
+
+//	private void fillXMLRootNode(XMLEntity xml) {
+//		xml.putProperty("applicationName","gvSIG");
+//		xml.putProperty("version",Version.format());
+//	}
+//
+//	private boolean registerDataSources(XMLEntity xmlDataSources) {
+//		try {
+//			int numDataSources = xmlDataSources.getChildrenCount();
+//
+//			if (numDataSources == 0) return true;
+//			DataSourceFactory dsFactory = LayerFactory.getDataSourceFactory();
+//
+//			for (int i = 0; i < numDataSources; i++) {
+//				XMLEntity child = xmlDataSources.getChild(i);
+//				String name = child.getStringProperty("gdbmsname");
+//
+//				if (dsFactory.getDriverInfo(name) == null) {
+//					if (child.getStringProperty("type").equals("otherDriverFile")) {
+//						LayerFactory.getDataSourceFactory().addFileDataSource(
+//								child.getStringProperty("driverName"),
+//								name,
+//								child.getStringProperty("file")
+//						);
+//
+//
+//					} else if (child.getStringProperty("type").equals("sameDriverFile")) {
+//						/*                                String layerName = child.getStringProperty("layerName");
+//						 ProjectView vista = project.getViewByName(child.getStringProperty(
+//						 "viewName"));
+//						 FLayer layer = vista.getMapContext().getLayers().getLayer(layerName);
+//
+//						 modelo = ((AlphanumericData) layer).getRecordset();
+//						 associatedTable = (AlphanumericData) layer;
+//						 */
+//					} else if (child.getStringProperty("type").equals("db")) {
+//						LayerFactory.getDataSourceFactory().addDBDataSourceByTable(
+//								name,
+//								child.getStringProperty("host"),
+//								child.getIntProperty("port"),
+//								child.getStringProperty("user"),
+//								child.getStringProperty("password"),
+//								child.getStringProperty("dbName"),
+//								child.getStringProperty("tableName"),
+//								child.getStringProperty("driverInfo")
+//						);
+//					}
+//				}
+//			}
+//
+//			return true;
+//		} catch (Exception e) {
+//			e.printStackTrace();
+//			return false;
+//		}
+//		return false;
+//	}
+//
+//	private boolean addTables(XMLEntity xmlTables) {
+//		try {
+//			int numTables = xmlTables.getChildrenCount();
+//			if (numTables == 0) {
+//				return true;
+//			}
+//
+//			Project project = this.getProject();
+//
+//			for (int i = 0; i < numTables; i++) {
+//				try{
+//					FeatureTableDocument ptable = (FeatureTableDocument) FeatureTableDocument.createFromXML(xmlTables.getChild(i), project);
+//					project.addDocument(ptable);
+//					/*
+//					if (ptable.getSeedViewInfo()!=null && ptable.getAndamiView()!=null) { // open the view, if it was open, and restore its dimensions
+//						PluginServices.getMDIManager().addView(ptable.getAndamiView());
+//						PluginServices.getMDIManager().changeViewInfo(ptable.getAndamiView(), ptable.getSeedViewInfo());
+//					}
+//					*/
+//				}catch(OpenException e){
+//					e.printStackTrace();
+//					return false;
+//				}
+//			}
+//
+//			project.setLinkTable();
+//
+//			return true;
+//		} catch (Exception e) {
+//			e.printStackTrace();
+//			return false;
+//		}
+//	}
+//
+//	private boolean addLayers(XMLEntity xmlLayers,FLayers root) {
+//		try {
+//			XMLEntity child;
+//			int numLayers = xmlLayers.getChildrenCount();
+//			for (int i = 0; i < numLayers; i++) {
+//				child = xmlLayers.getChild(i);
+//				if (!root.addLayerFromXMLEntity(child,null)) return false;
+//			}
+//			return true;
+//		} catch (Exception e) {
+//			e.printStackTrace();
+//			return false;
+//		}
+//
+//	}
+//
+//
+//
+//	private Project getProject() {
+//		 return ((ProjectExtension)PluginServices.getExtension(ProjectExtension.class)).getProject();
+//	}
+//
+//	private boolean addToXMLDataSource(SourceInfo source,XMLEntity xmlDataSources, Project project) {
+//		if (project== null) {
+//			project = this.getProject();
+//		}
+//  	  	xmlDataSources.addChild(project.getSourceInfoXMLEntity(source));
+//
+//  	  	return true;
+//	}
+//
+//	private boolean addToXMLTable(FeatureTableDocument pt,XMLEntity xmlTables,XMLEntity xmlDataSources,Project project) {
+//		if (project== null) {
+//			project = this.getProject();
+//		}
+//		if (xmlTables.findChildren("name",pt.getName()) != null) return true;
+//		XMLEntity xmlTable = null;
+//		try {
+//			xmlTable = pt.getXMLEntity();
+//
+//			xmlTables.addChild(xmlTable);
+//
+//			if (pt.getAssociatedTable() != null) {
+//				this.addToXMLDataSource(pt.getAssociatedTable().getRecordset().getSourceInfo(),xmlDataSources,project);
+//			}
+//
+//			if (pt.getLinkTable() != null) {
+//				if (xmlTables.findChildren("name",pt.getLinkTable()) == null)  {
+//					ProjectTable ptLink = (ProjectTable)project.getProjectDocumentByName(pt.getLinkTable(),ProjectTableFactory.registerName);
+//					if (!this.addToXMLTable(ptLink,xmlTables,xmlDataSources,project)) return false;
+//				}
+//			}
+//		} catch (SaveException e) {
+//			e.printStackTrace();
+//			return false;
+//		} catch (ReadException e) {
+//			e.printStackTrace();
+//			return false;
+//		}
+//
+//  	  	return true;
+//	}
+//
+//	private boolean addToXMLLayerDependencies(FLayer lyr,XMLEntity xmlTables,XMLEntity xmlDataSources) {
+//		try {
+//			Project project = this.getProject();
+//
+//			if (lyr instanceof FLayers) {
+//				FLayers lyrs = (FLayers)lyr;
+//				int count = lyrs.getLayersCount();
+//				for (int i=0;i < count;i++) {
+//					FLayer subLyr = lyrs.getLayer(i);
+//					this.addToXMLLayerDependencies(subLyr,xmlTables,xmlDataSources);
+//				}
+//
+//		    } else if (lyr instanceof FLyrVect){
+//            	if (!this.addToXMLDataSource(
+//        			((FLyrVect)lyr).getRecordset().getSourceInfo(),
+//        			xmlDataSources,
+//        			project
+//
+//            	)) return false;
+//
+//                ProjectTable pt = project.getTable((FLyrVect) lyr);
+//                if (pt != null) {
+//                	if (!this.addToXMLTable(pt,xmlTables,xmlDataSources,project)) return false;
+//                }
+//
+//            }
+//
+//		} catch (ReadException e) {
+//			// TODO Auto-generated catch block
+//			e.printStackTrace();
+//			return false;
+//		} catch (Exception e) {
+//			e.printStackTrace();
+//			return false;
+//
+//		}
+//		return true;
+//	}
+//
+//	private boolean addToXMLLayer(FLayer lyr,XMLEntity xmlLayers,XMLEntity xmlTables,XMLEntity xmlDataSources) {
+//		try {
+//			xmlLayers.addChild(lyr.getXMLEntity());
+//
+//			return this.addToXMLLayerDependencies(lyr,xmlTables,xmlDataSources);
+//
+//		} catch (XMLException e) {
+//			e.printStackTrace();
+//			return false;
+//		} catch (Exception e) {
+//			e.printStackTrace();
+//			return false;
+//		}
+//	}
+//
+//	private XMLEntity newRootNode() {
+//		XMLEntity xml = new XMLEntity();
+//		fillXMLRootNode(xml);
+//		return xml;
+//	}
+//
+//	private XMLEntity newLayersNode() {
+//		XMLEntity xmlLayers = new XMLEntity();
+//		xmlLayers.putProperty("type","layers");
+//		return xmlLayers;
+//	}
+//
+//	private XMLEntity newDataSourcesNode() {
+//		XMLEntity xmlDataSources = new XMLEntity();
+//		xmlDataSources.putProperty("type","dataSources");
+//		return xmlDataSources;
+//	}
+//
+//	private XMLEntity newTablesNode() {
+//		XMLEntity xmlTables = new XMLEntity();
+//		xmlTables.putProperty("type","tables");
+//		return xmlTables;
+//	}
+//
+	public boolean removeLayers(FLayer[] actives) {
+		// FIXME: jjdc esta pendiente la implementacion del copy/paste
+		throw new UnsupportedOperationException();
+//   	for (int i = actives.length-1; i>=0; i--){
+//        	try {
+//				//actives[i].getParentLayer().removeLayer(actives[i]);
+//				//FLayers lyrs=getMapContext().getLayers();
+//				//lyrs.addLayer(actives[i]);
+//				actives[i].getParentLayer().removeLayer(actives[i]);
+//
+//                if (actives[i] instanceof FLyrVect){
+//                    Project project = ((ProjectExtension)PluginServices.getExtension(ProjectExtension.class)).getProject();
+//                    FeatureTableDocument pt = project.getTable((FLyrVect) actives[i]);
+//
+//                    List<IProjectDocument> tables = project.getDocuments(FeatureTableDocumentFactory.TYPENAME);
+//                    for (int j = 0; j < tables.size(); j++) {
+//                        if (tables.get(j) == pt){
+//                            project.delDocument(tables.get(j));
+//                            break;
+//                        }
+//                    }
+//
+//                    PluginServices.getMDIManager().closeSingletonWindow(pt);
+//                }
+//
+//
+//    		} catch (CancelationException e1) {
+//    			e1.printStackTrace();
+//    			return false;
+//    		}
+//    	}
+//		return true;
+	}
+
+}

Property changes on: tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/app/project/documents/view/toc/actions/CopyPasteLayersUtiles.java
___________________________________________________________________
Added: svn:eol-style
   + native

Index: tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/app/project/documents/view/toc/actions/ReloadLayerTocMenuEntry.java
===================================================================
--- tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/app/project/documents/view/toc/actions/ReloadLayerTocMenuEntry.java	(revision 0)
+++ tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/app/project/documents/view/toc/actions/ReloadLayerTocMenuEntry.java	(revision 38653)
@@ -0,0 +1,108 @@
+package org.gvsig.app.project.documents.view.toc.actions;
+
+import org.gvsig.andami.PluginServices;
+import org.gvsig.app.project.documents.view.toc.AbstractTocContextMenuAction;
+import org.gvsig.app.project.documents.view.toc.ITocItem;
+import org.gvsig.fmap.mapcontext.layers.FLayer;
+
+
+/* gvSIG. Sistema de Informaci�n Geogr�fica de la Generalitat Valenciana
+ *
+ * Copyright (C) 2004 IVER T.I. and Generalitat Valenciana.
+ *
+ * This program is free software; you can redistribute it and/or
+ * modify it under the terms of the GNU General Public License
+ * as published by the Free Software Foundation; either version 2
+ * of the License, or (at your option) any later version.
+ *
+ * This program is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
+ * GNU General Public License for more details.
+ *
+ * You should have received a copy of the GNU General Public License
+ * along with this program; if not, write to the Free Software
+ * Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA  02111-1307,USA.
+ *
+ * For more information, contact:
+ *
+ *  Generalitat Valenciana
+ *   Conselleria d'Infraestructures i Transport
+ *   Av. Blasco Ib��ez, 50
+ *   46010 VALENCIA
+ *   SPAIN
+ *
+ *      +34 963862235
+ *   gvsig@gva.es
+ *      www.gvsig.gva.es
+ *
+ *    or
+ *
+ *   IVER T.I. S.A
+ *   Salamanca 50
+ *   46005 Valencia
+ *   Spain
+ *
+ *   +34 963163400
+ *   dac@iver.es
+ */
+/* CVS MESSAGES:
+ *
+ * $Id$
+ * $Log$
+ * Revision 1.2  2006-10-02 13:52:34  jaume
+ * organize impots
+ *
+ * Revision 1.1  2006/09/15 10:41:30  caballero
+ * extensibilidad de documentos
+ *
+ * Revision 1.1  2006/09/12 15:58:14  jorpiell
+ * "Sacadas" las opcines del men� de FPopupMenu
+ *
+ *
+ */
+/**
+*
+* @author Jose Manuel Viv� (Chema)
+*
+* Entrada de men� para recargar una capa.
+*/
+public class ReloadLayerTocMenuEntry extends AbstractTocContextMenuAction{
+	public String getGroup() {
+		return "group3"; //FIXME
+	}
+
+	public int getGroupOrder() {
+		return 30;
+	}
+
+	public int getOrder() {
+		return 1;
+	}
+
+	public String getText() {
+		return PluginServices.getText(this, "recargar");
+	}
+
+	public boolean isEnabled(ITocItem item, FLayer[] selectedItems) {
+		return !getNodeLayer(item).isAvailable();
+	}
+
+	public boolean isVisible(ITocItem item, FLayer[] selectedItems) {
+		if (isTocItemBranch(item)) {
+			return true;
+		}
+		return false;
+
+	}
+
+
+	public void execute(ITocItem item, FLayer[] selectedItems) {
+		try {
+			getNodeLayer(item).reload();
+		} catch (Exception ex) {
+			ex.printStackTrace();
+		}
+	}
+}
+

Property changes on: tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/app/project/documents/view/toc/actions/ReloadLayerTocMenuEntry.java
___________________________________________________________________
Added: svn:keywords
   + Author Date Id Revision
Added: svn:eol-style
   + native

Index: tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/app/project/documents/view/toc/actions/ZoomAlTemaTocMenuEntry.java
===================================================================
--- tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/app/project/documents/view/toc/actions/ZoomAlTemaTocMenuEntry.java	(revision 0)
+++ tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/app/project/documents/view/toc/actions/ZoomAlTemaTocMenuEntry.java	(revision 38653)
@@ -0,0 +1,182 @@
+package org.gvsig.app.project.documents.view.toc.actions;
+
+import org.gvsig.andami.PluginServices;
+import org.gvsig.app.extension.ProjectExtension;
+import org.gvsig.app.project.Project;
+import org.gvsig.app.project.documents.view.toc.AbstractTocContextMenuAction;
+import org.gvsig.app.project.documents.view.toc.ITocItem;
+import org.gvsig.fmap.dal.exception.ReadException;
+import org.gvsig.fmap.geom.GeometryLocator;
+import org.gvsig.fmap.geom.GeometryManager;
+import org.gvsig.fmap.geom.Geometry.SUBTYPES;
+import org.gvsig.fmap.geom.exception.CreateEnvelopeException;
+import org.gvsig.fmap.geom.primitive.Envelope;
+import org.gvsig.fmap.mapcontext.layers.FLayer;
+import org.slf4j.Logger;
+import org.slf4j.LoggerFactory;
+
+
+/* gvSIG. Sistema de Informaci�n Geogr�fica de la Generalitat Valenciana
+ *
+ * Copyright (C) 2004 IVER T.I. and Generalitat Valenciana.
+ *
+ * This program is free software; you can redistribute it and/or
+ * modify it under the terms of the GNU General Public License
+ * as published by the Free Software Foundation; either version 2
+ * of the License, or (at your option) any later version.
+ *
+ * This program is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
+ * GNU General Public License for more details.
+ *
+ * You should have received a copy of the GNU General Public License
+ * along with this program; if not, write to the Free Software
+ * Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA  02111-1307,USA.
+ *
+ * For more information, contact:
+ *
+ *  Generalitat Valenciana
+ *   Conselleria d'Infraestructures i Transport
+ *   Av. Blasco Ib��ez, 50
+ *   46010 VALENCIA
+ *   SPAIN
+ *
+ *      +34 963862235
+ *   gvsig@gva.es
+ *      www.gvsig.gva.es
+ *
+ *    or
+ *
+ *   IVER T.I. S.A
+ *   Salamanca 50
+ *   46005 Valencia
+ *   Spain
+ *
+ *   +34 963163400
+ *   dac@iver.es
+ */
+/* CVS MESSAGES:
+ *
+ * $Id$
+ * $Log$
+ * Revision 1.6  2007-09-19 15:52:16  jaume
+ * ReadExpansionFileException removed from this context
+ *
+ * Revision 1.5  2007/03/06 16:37:08  caballero
+ * Exceptions
+ *
+ * Revision 1.4  2007/01/04 07:24:31  caballero
+ * isModified
+ *
+ * Revision 1.3  2006/10/18 16:01:13  sbayarri
+ * Added zoomToExtent method to MapContext.
+ *
+ * Revision 1.2  2006/10/02 13:52:34  jaume
+ * organize impots
+ *
+ * Revision 1.1  2006/09/15 10:41:30  caballero
+ * extensibilidad de documentos
+ *
+ * Revision 1.1  2006/09/12 15:58:14  jorpiell
+ * "Sacadas" las opcines del men� de FPopupMenu
+ *
+ *
+ */
+public class ZoomAlTemaTocMenuEntry extends AbstractTocContextMenuAction {
+	private static final GeometryManager geomManager = GeometryLocator.getGeometryManager();
+	private static final Logger logger = LoggerFactory.getLogger(ZoomAlTemaTocMenuEntry.class);
+	
+	public String getGroup() {
+		return "group2"; //FIXME
+	}
+
+	public int getGroupOrder() {
+		return 20;
+	}
+
+	public int getOrder() {
+		return 1;
+	}
+
+	public String getText() {
+		return PluginServices.getText(this, "Zoom_a_la_capa");
+	}
+
+	public boolean isEnabled(ITocItem item, FLayer[] selectedItems) {
+		return true;
+	}
+
+	public boolean isVisible(ITocItem item, FLayer[] selectedItems) {
+		if (isTocItemBranch(item) && ! (selectedItems == null || selectedItems.length <= 0)) {
+			return true;
+		}
+		return false;
+
+	}
+
+
+	public void execute(ITocItem item, FLayer[] selectedItems) {
+
+
+		// 050209, jmorell: Para que haga un zoom a un grupo de capas seleccionadas.
+
+		if (selectedItems.length==1) {
+	        try {
+	        	if (!selectedItems[0].isAvailable()) {
+					return;
+				}
+	        	getMapContext().zoomToEnvelope(selectedItems[0].getFullEnvelope());
+			} catch (ReadException e1) {
+				e1.printStackTrace();
+			}
+		} else {
+			try {
+				Envelope maxExtent = setMaxExtent(selectedItems);
+				getMapContext().zoomToEnvelope(maxExtent);
+			} catch (ReadException e1) {
+				e1.printStackTrace();
+			}
+		}
+		Project project=((ProjectExtension)PluginServices.getExtension(ProjectExtension.class)).getProject();
+		project.setModified(true);
+	}
+
+	private Envelope setMaxExtent(FLayer[] actives)
+			throws ReadException {
+		Envelope extRef = null;
+			extRef = actives[0].getFullEnvelope();
+
+			double minXRef = extRef.getMinimum(0);
+			double maxYRef = extRef.getMaximum(1);
+			double maxXRef = extRef.getMaximum(0);
+			double minYRef = extRef.getMinimum(1);
+			for (int i = 0; i < actives.length; i++) {
+				if (actives[i].isAvailable()) {
+					Envelope extVar = actives[i].getFullEnvelope();
+					double minXVar = extVar.getMinimum(0);
+					double maxYVar = extVar.getMaximum(1);
+					double maxXVar = extVar.getMaximum(0);
+					double minYVar = extVar.getMinimum(1);
+					if (minXVar <= minXRef) {
+						minXRef = minXVar;
+					}
+					if (maxYVar >= maxYRef) {
+						maxYRef = maxYVar;
+					}
+					if (maxXVar >= maxXRef) {
+						maxXRef = maxXVar;
+					}
+					if (minYVar <= minYRef) {
+						minYRef = minYVar;
+					}
+					try {
+						extRef = geomManager.createEnvelope(minXRef, minYRef, maxXRef, maxYRef, SUBTYPES.GEOM2D);
+					} catch (CreateEnvelopeException e) {
+						logger.error("Error creating the envelope", e);
+					}
+				}
+			}
+		return extRef;
+	}
+}

Property changes on: tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/app/project/documents/view/toc/actions/ZoomAlTemaTocMenuEntry.java
___________________________________________________________________
Added: svn:eol-style
   + native
Added: svn:keywords
   + Author Date Id Revision

Index: tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/app/project/documents/view/toc/actions/ShowLayerErrorsTocMenuEntry.java
===================================================================
--- tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/app/project/documents/view/toc/actions/ShowLayerErrorsTocMenuEntry.java	(revision 0)
+++ tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/app/project/documents/view/toc/actions/ShowLayerErrorsTocMenuEntry.java	(revision 38653)
@@ -0,0 +1,115 @@
+/*
+ * Created on 20-sep-2006
+ *
+ * gvSIG. Sistema de Informaci�n Geogr�fica de la Generalitat Valenciana
+ *
+ * Copyright (C) 2004 IVER T.I. and Generalitat Valenciana.
+ *
+ * This program is free software; you can redistribute it and/or
+ * modify it under the terms of the GNU General Public License
+ * as published by the Free Software Foundation; either version 2
+ * of the License, or (at your option) any later version.
+ *
+ * This program is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
+ * GNU General Public License for more details.
+ *
+ * You should have received a copy of the GNU General Public License
+ * along with this program; if not, write to the Free Software
+ * Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA  02111-1307,USA.
+ *
+ * For more information, contact:
+ *
+ *  Generalitat Valenciana
+ *   Conselleria d'Infraestructures i Transport
+ *   Av. Blasco Ib��ez, 50
+ *   46010 VALENCIA
+ *   SPAIN
+ *
+ *      +34 963862235
+ *   gvsig@gva.es
+ *      www.gvsig.gva.es
+ *
+ *    or
+ *
+ *   IVER T.I. S.A
+ *   Salamanca 50
+ *   46005 Valencia
+ *   Spain
+ *
+ *   +34 963163400
+ *   dac@iver.es
+ */
+/* CVS MESSAGES:
+*
+* $Id$
+* $Log$
+* Revision 1.4  2007-03-06 16:37:08  caballero
+* Exceptions
+*
+* Revision 1.3  2007/02/20 15:52:17  caballero
+* no modified
+*
+* Revision 1.2  2007/01/04 07:24:31  caballero
+* isModified
+*
+* Revision 1.1  2006/09/21 18:26:13  azabala
+* first version in cvs
+*
+*
+*/
+package org.gvsig.app.project.documents.view.toc.actions;
+
+import org.gvsig.andami.PluginServices;
+import org.gvsig.app.project.documents.view.gui.DefaultViewPanel;
+import org.gvsig.app.project.documents.view.toc.AbstractTocContextMenuAction;
+import org.gvsig.app.project.documents.view.toc.ITocItem;
+import org.gvsig.fmap.mapcontext.layers.FLayer;
+
+
+public class ShowLayerErrorsTocMenuEntry extends AbstractTocContextMenuAction{
+
+	public void execute(ITocItem item, FLayer[] selectedItems) {
+		FLayer layer = getNodeLayer(item);
+		String introductoryText = "<h2 text=\"#000080\">La capa "+
+								layer.getName()+
+								" presenta los siguientes errores</h2>";
+		((DefaultViewPanel)PluginServices.getMDIManager().getActiveWindow()).
+			getMapControl().
+			getMapContext().
+			reportDriverExceptions(introductoryText, layer.getErrors());
+//		Project project=((ProjectExtension)PluginServices.getExtension(ProjectExtension.class)).getProject();
+//		project.setModified(true);
+	}
+
+	public String getText() {
+		return PluginServices.getText(this, "ver_error_capa");
+	}
+
+	public String getGroup() {
+		return "group3"; //FIXME
+	}
+
+	public int getGroupOrder() {
+		return 30;
+	}
+
+	public int getOrder() {
+		return 2;
+	}
+
+	public boolean isEnabled(ITocItem item, FLayer[] selectedItems) {
+		return !getNodeLayer(item).isOk();
+	}
+
+	public boolean isVisible(ITocItem item, FLayer[] selectedItems) {
+		if (isTocItemBranch(item)) {
+			return true;
+		}
+		return false;
+
+	}
+
+}
+

Property changes on: tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/app/project/documents/view/toc/actions/ShowLayerErrorsTocMenuEntry.java
___________________________________________________________________
Added: svn:keywords
   + Author Date Id Revision
Added: svn:eol-style
   + native

Index: tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/app/project/documents/view/toc/actions/ChangeSymbolTocMenuEntry.java
===================================================================
--- tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/app/project/documents/view/toc/actions/ChangeSymbolTocMenuEntry.java	(revision 0)
+++ tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/app/project/documents/view/toc/actions/ChangeSymbolTocMenuEntry.java	(revision 38653)
@@ -0,0 +1,219 @@
+package org.gvsig.app.project.documents.view.toc.actions;
+
+import org.gvsig.andami.PluginServices;
+import org.gvsig.andami.messages.NotificationManager;
+import org.gvsig.app.extension.ProjectExtension;
+import org.gvsig.app.gui.styling.SymbolSelector;
+import org.gvsig.app.project.Project;
+import org.gvsig.app.project.documents.view.legend.gui.ISymbolSelector;
+import org.gvsig.app.project.documents.view.toc.AbstractTocContextMenuAction;
+import org.gvsig.app.project.documents.view.toc.ITocItem;
+import org.gvsig.app.project.documents.view.toc.TocItemLeaf;
+import org.gvsig.fmap.dal.exception.ReadException;
+import org.gvsig.fmap.mapcontext.MapContext;
+import org.gvsig.fmap.mapcontext.layers.FLayer;
+import org.gvsig.fmap.mapcontext.layers.vectorial.FLyrVect;
+import org.gvsig.fmap.mapcontext.rendering.legend.IClassifiedVectorLegend;
+import org.gvsig.fmap.mapcontext.rendering.legend.ILegend;
+import org.gvsig.fmap.mapcontext.rendering.legend.ISingleSymbolLegend;
+import org.gvsig.fmap.mapcontext.rendering.legend.IVectorLegend;
+import org.gvsig.fmap.mapcontext.rendering.symbols.ISymbol;
+import org.gvsig.symbology.fmap.mapcontext.rendering.symbol.fill.impl.MultiLayerFillSymbol;
+import org.slf4j.Logger;
+import org.slf4j.LoggerFactory;
+
+/* gvSIG. Sistema de Informaci�n Geogr�fica de la Generalitat Valenciana
+ *
+ * Copyright (C) 2004 IVER T.I. and Generalitat Valenciana.
+ *
+ * This program is free software; you can redistribute it and/or
+ * modify it under the terms of the GNU General Public License
+ * as published by the Free Software Foundation; either version 2
+ * of the License, or (at your option) any later version.
+ *
+ * This program is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
+ * GNU General Public License for more details.
+ *
+ * You should have received a copy of the GNU General Public License
+ * along with this program; if not, write to the Free Software
+ * Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA  02111-1307,USA.
+ *
+ * For more information, contact:
+ *
+ *  Generalitat Valenciana
+ *   Conselleria d'Infraestructures i Transport
+ *   Av. Blasco Ib��ez, 50
+ *   46010 VALENCIA
+ *   SPAIN
+ *
+ *      +34 963862235
+ *   gvsig@gva.es
+ *      www.gvsig.gva.es
+ *
+ *    or
+ *
+ *   IVER T.I. S.A
+ *   Salamanca 50
+ *   46005 Valencia
+ *   Spain
+ *
+ *   +34 963163400
+ *   dac@iver.es
+ */
+/* CVS MESSAGES:
+ *
+ * $Id$
+ * $Log$
+ * Revision 1.3  2007-09-19 15:50:42  jaume
+ * refactor name IVectorialLegend -> IVectorLegend
+ *
+ * Revision 1.2  2007/09/17 09:22:21  jaume
+ * view draw frame rate now customizable
+ *
+ * Revision 1.1  2007/09/10 15:34:39  jaume
+ * improvements on usability (double-clicks on TOC and some minor shorcuts)
+ *
+ * Revision 1.5  2007/01/04 07:24:31  caballero
+ * isModified
+ *
+ * Revision 1.4  2006/10/02 13:52:34  jaume
+ * organize impots
+ *
+ * Revision 1.3  2006/09/29 07:07:41  caballero
+ * llamada a listener
+ *
+ * Revision 1.2  2006/09/28 15:00:45  fjp
+ * Usar siempre que se pueda ISymbol en lugar de FSymbol
+ *
+ * Revision 1.1  2006/09/15 10:41:30  caballero
+ * extensibilidad de documentos
+ *
+ * Revision 1.1  2006/09/12 15:58:14  jorpiell
+ * "Sacadas" las opcines del men� de FPopupMenu
+ *
+ *
+ */
+/**
+ * Directly opens the Symbol Selector if it is invoked from the TOC avoiding
+ * by-passing the Layer Properties window
+ */
+public class ChangeSymbolTocMenuEntry extends AbstractTocContextMenuAction {
+    private static final Logger logger = LoggerFactory
+            .getLogger(ChangeSymbolTocMenuEntry.class);
+
+	public String getGroup() {
+		return "group1"; //FIXME
+	}
+
+	public int getGroupOrder() {
+		return 10;
+	}
+
+	public int getOrder() {
+		return 0;
+	}
+
+	public String getText() {
+		return PluginServices.getText(this, "change_symbol");
+	}
+
+	public boolean isEnabled(ITocItem item, FLayer[] selectedItems) {
+		return true;
+	}
+
+	public boolean isVisible(ITocItem item, FLayer[] selectedItems) {
+		return isTocItemLeaf(item);
+	}
+
+	public void execute(ITocItem item, FLayer[] selectedItems) {
+
+		boolean showDialog = isTocItemLeaf(item);
+
+		if (!showDialog) {
+			return;
+		}
+
+		try {
+			if(!(selectedItems[0] instanceof FLyrVect))
+				return;
+			FLyrVect layer = (FLyrVect) selectedItems[0];
+			ISymbol oldSymbol = ((TocItemLeaf) item).getSymbol();
+			// patch, figure out an ellegant way to solve this
+			if (oldSymbol instanceof MultiLayerFillSymbol) {
+				MultiLayerFillSymbol ms = (MultiLayerFillSymbol) oldSymbol;
+				for (int i = 0; i < ms.getLayerCount(); i++) {
+					if (ms.getLayer(i).getClass().getName().equals("org.gvsig.symbology.symbols.DotDensityFillSymbol")) {
+						/*
+						 * since dot density symbol works together with the
+						 * legend, there is no way to edit it from the symbol selector and editor
+						 * we have to break now!
+						 */
+						return;
+					}
+				}
+			}
+			// end patch
+
+
+			int shapeType = ((IVectorLegend) layer.getLegend()).getShapeType();
+			if (shapeType == 0) {
+				logger.debug("Error legend " + layer.getLegend()
+                        + " does not have shapetype initialized");
+				shapeType = layer.getShapeType();
+			}
+
+			ISymbolSelector symSel = null;
+
+			try {
+				symSel = SymbolSelector.createSymbolSelector(oldSymbol, shapeType);
+			} catch (IllegalArgumentException iaEx) {
+				/*
+				 * this usually happens when the Legend has a composed
+				 * symbol that collides with the normal operation and
+				 * it only can be changed from the panel of the legend
+				 */
+				// TODO throw a signal and show a warning message box telling
+				// that the operation cannot be performed
+				return;
+			}
+			PluginServices.getMDIManager().addWindow(symSel);
+			ISymbol newSymbol = (ISymbol) symSel.getSelectedObject();
+
+			if (newSymbol == null) {
+				return;
+			}
+
+			newSymbol.setDescription(oldSymbol.getDescription());
+
+			for (int i = 0; i < selectedItems.length; i++) {
+				FLyrVect theLayer = ((FLyrVect) selectedItems[i]);
+
+				try {
+					ILegend legend = theLayer.getLegend();
+					if (legend instanceof IClassifiedVectorLegend) {
+						IClassifiedVectorLegend cv = (IClassifiedVectorLegend) legend;
+						cv.replace(oldSymbol, newSymbol);
+					} else if (legend instanceof ISingleSymbolLegend) {
+						ISingleSymbolLegend ss = (ISingleSymbolLegend) legend;
+						ss.setDefaultSymbol(newSymbol);
+					}
+				} catch (Exception e) {
+					NotificationManager.addWarning(PluginServices.getText(this, "skipped_symbol_changed_for_layer")+": "+theLayer.getName(), e);
+				}
+
+			}
+		     // refresh view treak
+			MapContext mc = layer.getMapContext();
+			mc.invalidate();
+			Project project=((ProjectExtension)PluginServices.getExtension(ProjectExtension.class)).getProject();
+			project.setModified(true);
+			mc.callLegendChanged();
+
+		} catch (ReadException e) {
+			NotificationManager.addError(PluginServices.getText(this, "getting_shape_type"), e);
+		}
+	}
+}
+

Property changes on: tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/app/project/documents/view/toc/actions/ChangeSymbolTocMenuEntry.java
___________________________________________________________________
Added: svn:keywords
   + Author Date Id Revision
Added: svn:eol-style
   + native
Added: svn:executable
   + *

Index: tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/app/project/documents/view/toc/actions/CutLayersTocMenuEntry.java
===================================================================
--- tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/app/project/documents/view/toc/actions/CutLayersTocMenuEntry.java	(revision 0)
+++ tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/app/project/documents/view/toc/actions/CutLayersTocMenuEntry.java	(revision 38653)
@@ -0,0 +1,96 @@
+package org.gvsig.app.project.documents.view.toc.actions;
+
+import java.awt.Component;
+
+import javax.swing.JOptionPane;
+
+import org.gvsig.andami.PluginServices;
+import org.gvsig.app.extension.ProjectExtension;
+import org.gvsig.app.project.Project;
+import org.gvsig.app.project.documents.view.toc.AbstractTocContextMenuAction;
+import org.gvsig.app.project.documents.view.toc.ITocItem;
+import org.gvsig.fmap.mapcontext.layers.FLayer;
+import org.gvsig.utils.XMLEntity;
+
+
+public class CutLayersTocMenuEntry extends AbstractTocContextMenuAction {
+	private CopyPasteLayersUtiles utiles = CopyPasteLayersUtiles.getInstance();
+
+	public String getGroup() {
+		return "copyPasteLayer";
+	}
+
+	public int getGroupOrder() {
+		return 60;
+	}
+	public int getOrder() {
+		return 1;
+	}
+
+	public String getText() {
+		return PluginServices.getText(this, "cortar");
+	}
+
+	public boolean isEnabled(ITocItem item, FLayer[] selectedItems) {
+		if ( selectedItems.length >= 1 && isTocItemBranch(item)){
+			for (int i=0;i< selectedItems.length;i++) {
+				if (selectedItems[i].isEditing()){
+					return false;
+				}
+			}
+			return true;
+		}
+		return false;
+	}
+
+
+	public void execute(ITocItem item, FLayer[] selectedItems) {
+		XMLEntity xml = this.utiles.generateXMLCopyLayers(selectedItems);
+		if (xml == null) {
+			JOptionPane.showMessageDialog(
+					(Component)PluginServices.getMainFrame(),
+					"<html>"+PluginServices.getText(this,"No_ha_sido_posible_realizar_la_operacion")+"</html>",//Mensaje
+					PluginServices.getText(this,"cortar"),//titulo
+					JOptionPane.ERROR_MESSAGE
+					);
+			return;
+		}
+
+		String data = xml.toString();
+		if (data == null) {
+			JOptionPane.showMessageDialog(
+					(Component)PluginServices.getMainFrame(),
+					"<html>"+PluginServices.getText(this,"No_ha_sido_posible_realizar_la_operacion")+"</html>",//Mensaje
+					PluginServices.getText(this,"cortar"),//titulo
+					JOptionPane.ERROR_MESSAGE
+					);
+			return;
+		}
+
+
+		PluginServices.putInClipboard(data);
+
+
+    	int option=JOptionPane.showConfirmDialog((Component)PluginServices.getMainFrame(),PluginServices.getText(this,"desea_borrar_la_capa"));
+    	if (option!=JOptionPane.OK_OPTION) {
+    		return;
+    	}
+		getMapContext().beginAtomicEvent();
+
+
+		boolean isOK =this.utiles.removeLayers(selectedItems);
+
+		getMapContext().endAtomicEvent();
+
+		if (isOK) {
+			getMapContext().invalidate();
+			Project project=((ProjectExtension)PluginServices.getExtension(ProjectExtension.class)).getProject();
+			project.setModified(true);
+			if (getMapContext().getLayers().getLayersCount()==0) {
+				PluginServices.getMainFrame().enableControls();
+			}
+		}
+
+	}
+
+}

Property changes on: tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/app/project/documents/view/toc/actions/CutLayersTocMenuEntry.java
___________________________________________________________________
Added: svn:eol-style
   + native

Index: tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/app/project/documents/view/toc/actions/LayersGroupTocMenuEntry.java
===================================================================
--- tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/app/project/documents/view/toc/actions/LayersGroupTocMenuEntry.java	(revision 0)
+++ tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/app/project/documents/view/toc/actions/LayersGroupTocMenuEntry.java	(revision 38653)
@@ -0,0 +1,167 @@
+package org.gvsig.app.project.documents.view.toc.actions;
+
+import org.gvsig.andami.PluginServices;
+import org.gvsig.app.extension.ProjectExtension;
+import org.gvsig.app.project.Project;
+import org.gvsig.app.project.documents.view.toc.AbstractTocContextMenuAction;
+import org.gvsig.app.project.documents.view.toc.ITocItem;
+import org.gvsig.app.project.documents.view.toc.gui.ChangeName;
+import org.gvsig.fmap.mapcontext.layers.FLayer;
+import org.gvsig.fmap.mapcontext.layers.FLayers;
+import org.gvsig.fmap.mapcontext.layers.operations.LayerNotFoundInCollectionException;
+import org.slf4j.Logger;
+import org.slf4j.LoggerFactory;
+
+
+/* gvSIG. Sistema de Informaci�n Geogr�fica de la Generalitat Valenciana
+ *
+ * Copyright (C) 2004 IVER T.I. and Generalitat Valenciana.
+ *
+ * This program is free software; you can redistribute it and/or
+ * modify it under the terms of the GNU General Public License
+ * as published by the Free Software Foundation; either version 2
+ * of the License, or (at your option) any later version.
+ *
+ * This program is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
+ * GNU General Public License for more details.
+ *
+ * You should have received a copy of the GNU General Public License
+ * along with this program; if not, write to the Free Software
+ * Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA  02111-1307,USA.
+ *
+ * For more information, contact:
+ *
+ *  Generalitat Valenciana
+ *   Conselleria d'Infraestructures i Transport
+ *   Av. Blasco Ib��ez, 50
+ *   46010 VALENCIA
+ *   SPAIN
+ *
+ *      +34 963862235
+ *   gvsig@gva.es
+ *      www.gvsig.gva.es
+ *
+ *    or
+ *
+ *   IVER T.I. S.A
+ *   Salamanca 50
+ *   46005 Valencia
+ *   Spain
+ *
+ *   +34 963163400
+ *   dac@iver.es
+ */
+/* CVS MESSAGES:
+ *
+ * $Id$
+ * $Log$
+ * Revision 1.7  2007-06-19 08:42:17  jcampos
+ * New method to get new group layers
+ *
+ * Revision 1.6  2007/02/15 11:04:54  caballero
+ * cancelar agrupaci�n
+ *
+ * Revision 1.5  2007/02/14 17:09:43  caballero
+ * posici�n layerGroup
+ *
+ * Revision 1.4  2007/01/04 07:24:31  caballero
+ * isModified
+ *
+ * Revision 1.3  2006/10/02 13:52:34  jaume
+ * organize impots
+ *
+ * Revision 1.2  2006/09/25 15:21:47  jmvivo
+ * * Modificada la condicion de visibilidad, no permitir si no tienen el mismo padre.
+ * * Modificada la implementacion.
+ *
+ * Revision 1.1  2006/09/15 10:41:30  caballero
+ * extensibilidad de documentos
+ *
+ * Revision 1.1  2006/09/12 15:58:14  jorpiell
+ * "Sacadas" las opcines del men� de FPopupMenu
+ *
+ *
+ */
+/**
+ * Realiza una agrupaci�n de capas, a partir de las capas que se encuentren activas.
+ *
+ * @author Vicente Caballero Navarro
+ */
+public class LayersGroupTocMenuEntry extends AbstractTocContextMenuAction {
+	/**
+	 * Useful for debug the problems during the implementation.
+	 */
+	private static Logger logger = LoggerFactory.getLogger(LayersGroupTocMenuEntry.class);
+
+	public String getGroup() {
+		return "group4"; //FIXME
+	}
+
+	public int getGroupOrder() {
+		return 40;
+	}
+
+	public int getOrder() {
+		return 0;
+	}
+
+	public String getText() {
+		return PluginServices.getText(this, "agrupar_capas");
+	}
+
+	public boolean isEnabled(ITocItem item, FLayer[] selectedItems) {
+		return selectedItems.length > 1;
+	}
+
+	public boolean isVisible(ITocItem item, FLayer[] selectedItems) {
+		if (selectedItems.length < 2) {
+			return false;
+		}
+		FLayers parent = selectedItems[0].getParentLayer();
+		for (int i = 1; i < selectedItems.length;i++){
+			if (parent != selectedItems[i].getParentLayer()){
+				return false;
+			}
+		}
+		return true;
+
+	}
+
+
+	public void execute(ITocItem item, FLayer[] selectedItems) {
+		//ITocItem tocItem = (ITocItem) getNodeUserObject();
+		ChangeName changename=new ChangeName(null);
+		PluginServices.getMDIManager().addWindow(changename);
+		if (!changename.isAccepted())
+			return;
+		String nombre=changename.getName();
+
+		if (nombre != null){
+
+			getMapContext().beginAtomicEvent();
+			FLayers parent = selectedItems[0].getParentLayer();
+			FLayers newGroup = getMapContext().getNewGroupLayer(parent);
+			newGroup.setName(nombre);
+			int pos=0;
+			for (int i=0;i<parent.getLayersCount();i++){
+				if (parent.getLayer(i).equals(selectedItems[0])){
+					pos=i;
+					continue;
+				}
+			}
+			for (int j=0;j < selectedItems.length;j++){
+				FLayer layer = selectedItems[j];
+				parent.move(layer, newGroup);
+			}
+			parent.addLayer(pos,newGroup);
+			newGroup.dispose();
+			getMapContext().endAtomicEvent();
+			// TRUCO PARA REFRESCAR.
+			getMapContext().invalidate();
+			Project project=((ProjectExtension)PluginServices.getExtension(ProjectExtension.class)).getProject();
+			project.setModified(true);
+		}
+	}
+}

Property changes on: tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/app/project/documents/view/toc/actions/LayersGroupTocMenuEntry.java
___________________________________________________________________
Added: svn:eol-style
   + native
Added: svn:keywords
   + Author Date Id Revision

Index: tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/app/project/documents/view/toc/actions/LayersUngroupTocMenuEntry.java
===================================================================
--- tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/app/project/documents/view/toc/actions/LayersUngroupTocMenuEntry.java	(revision 0)
+++ tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/app/project/documents/view/toc/actions/LayersUngroupTocMenuEntry.java	(revision 38653)
@@ -0,0 +1,152 @@
+/* gvSIG. Sistema de Informaci�n Geogr�fica de la Generalitat Valenciana
+ *
+ * Copyright (C) 2004 IVER T.I. and Generalitat Valenciana.
+ *
+ * This program is free software; you can redistribute it and/or
+ * modify it under the terms of the GNU General Public License
+ * as published by the Free Software Foundation; either version 2
+ * of the License, or (at your option) any later version.
+ *
+ * This program is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
+ * GNU General Public License for more details.
+ *
+ * You should have received a copy of the GNU General Public License
+ * along with this program; if not, write to the Free Software
+ * Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA  02111-1307,USA.
+ *
+ * For more information, contact:
+ *
+ *  Generalitat Valenciana
+ *   Conselleria d'Infraestructures i Transport
+ *   Av. Blasco Ib��ez, 50
+ *   46010 VALENCIA
+ *   SPAIN
+ *
+ *      +34 963862235
+ *   gvsig@gva.es
+ *      www.gvsig.gva.es
+ *
+ *    or
+ *
+ *   IVER T.I. S.A
+ *   Salamanca 50
+ *   46005 Valencia
+ *   Spain
+ *
+ *   +34 963163400
+ *   dac@iver.es
+ */
+package org.gvsig.app.project.documents.view.toc.actions;
+
+import org.gvsig.andami.PluginServices;
+import org.gvsig.andami.messages.NotificationManager;
+import org.gvsig.app.extension.ProjectExtension;
+import org.gvsig.app.project.Project;
+import org.gvsig.app.project.documents.view.toc.AbstractTocContextMenuAction;
+import org.gvsig.app.project.documents.view.toc.ITocItem;
+import org.gvsig.fmap.mapcontext.layers.FLayer;
+import org.gvsig.fmap.mapcontext.layers.FLayers;
+import org.gvsig.fmap.mapcontext.layers.operations.LayerCollection;
+import org.gvsig.fmap.mapcontext.layers.operations.LayerNotFoundInCollectionException;
+import org.slf4j.Logger;
+import org.slf4j.LoggerFactory;
+
+
+
+/* CVS MESSAGES:
+ *
+ * $Id$
+ * $Log$
+ * Revision 1.6  2007-01-04 07:24:31  caballero
+ * isModified
+ *
+ * Revision 1.5  2006/10/02 13:52:34  jaume
+ * organize impots
+ *
+ * Revision 1.4  2006/09/25 15:24:26  jmvivo
+ * * Modificada la implementacion.
+ *
+ * Revision 1.3  2006/09/20 12:01:24  jaume
+ * *** empty log message ***
+ *
+ * Revision 1.2  2006/09/20 11:41:20  jaume
+ * *** empty log message ***
+ *
+ * Revision 1.1  2006/09/15 10:41:30  caballero
+ * extensibilidad de documentos
+ *
+ * Revision 1.1  2006/09/12 15:58:14  jorpiell
+ * "Sacadas" las opcines del men� de FPopupMenu
+ *
+ *
+ */
+/**
+ * Realiza una desagrupaci�n de capas, a partir de las capas que se encuentren activas.
+ *
+ * @author Vicente Caballero Navarro
+ */
+public class LayersUngroupTocMenuEntry extends AbstractTocContextMenuAction {
+	/**
+	 * Useful for debug the problems during the implementation.
+	 */
+	private static Logger logger = LoggerFactory.getLogger(LayersUngroupTocMenuEntry.class);
+
+	public String getGroup() {
+		return "group4"; //FIXME
+	}
+
+	public int getGroupOrder() {
+		return 40;
+	}
+
+	public int getOrder() {
+		return 1;
+	}
+
+	public String getText() {
+		return PluginServices.getText(this, "desagrupar_capas");
+	}
+
+	public boolean isEnabled(ITocItem item, FLayer[] selectedItems) {
+		return true;
+	}
+
+	public boolean isVisible(ITocItem item, FLayer[] selectedItems) {
+		FLayer lyr = getNodeLayer(item);
+		if (!(lyr instanceof FLayers) || (lyr instanceof FLayers && lyr.getParentLayer() == null)){
+			return false;
+		}
+		return true;
+
+	}
+
+
+	public void execute(ITocItem item, FLayer[] selectedItems) {
+		if (isTocItemBranch(item)){
+			FLayers agrupa = (FLayers)getNodeLayer(item);
+			FLayers parent=agrupa.getParentLayer();
+
+			if (parent!=null){
+				getMapContext().beginAtomicEvent();
+				try{
+					while (agrupa.getLayersCount() > 0){
+						FLayer layer = agrupa.getLayer(0);
+						agrupa.move(layer, parent, LayerCollection.BEFORE, agrupa);
+					}
+					parent.removeLayer(agrupa);
+				} catch (LayerNotFoundInCollectionException e) {
+					NotificationManager.addError(e);
+				}
+				getMapContext().endAtomicEvent();
+
+				// TRUCO PARA REFRESCAR.
+				getMapContext().invalidate();
+				Project project=((ProjectExtension)PluginServices.getExtension(ProjectExtension.class)).getProject();
+				project.setModified(true);
+
+			}
+		}
+	}
+}

Property changes on: tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/app/project/documents/view/toc/actions/LayersUngroupTocMenuEntry.java
___________________________________________________________________
Added: svn:eol-style
   + native
Added: svn:keywords
   + Author Date Id Revision

Index: tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/app/project/documents/view/toc/actions/FLyrVectEditPropertiesTocMenuEntry.java
===================================================================
--- tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/app/project/documents/view/toc/actions/FLyrVectEditPropertiesTocMenuEntry.java	(revision 0)
+++ tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/app/project/documents/view/toc/actions/FLyrVectEditPropertiesTocMenuEntry.java	(revision 38653)
@@ -0,0 +1,167 @@
+package org.gvsig.app.project.documents.view.toc.actions;
+
+import javax.swing.JDialog;
+
+import org.gvsig.andami.PluginServices;
+import org.gvsig.app.extension.ProjectExtension;
+import org.gvsig.app.project.Project;
+import org.gvsig.app.project.documents.view.legend.gui.ThemeManagerWindow;
+import org.gvsig.app.project.documents.view.toc.AbstractTocContextMenuAction;
+import org.gvsig.app.project.documents.view.toc.ITocItem;
+import org.gvsig.fmap.mapcontext.layers.FLayer;
+import org.gvsig.fmap.mapcontext.layers.operations.ClassifiableVectorial;
+import org.gvsig.fmap.mapcontext.layers.vectorial.FLyrVect;
+
+/* gvSIG. Sistema de Informaci�n Geogr�fica de la Generalitat Valenciana
+ *
+ * Copyright (C) 2004 IVER T.I. and Generalitat Valenciana.
+ *
+ * This program is free software; you can redistribute it and/or
+ * modify it under the terms of the GNU General Public License
+ * as published by the Free Software Foundation; either version 2
+ * of the License, or (at your option) any later version.
+ *
+ * This program is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
+ * GNU General Public License for more details.
+ *
+ * You should have received a copy of the GNU General Public License
+ * along with this program; if not, write to the Free Software
+ * Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA  02111-1307,USA.
+ *
+ * For more information, contact:
+ *
+ *  Generalitat Valenciana
+ *   Conselleria d'Infraestructures i Transport
+ *   Av. Blasco Ib��ez, 50
+ *   46010 VALENCIA
+ *   SPAIN
+ *
+ *      +34 963862235
+ *   gvsig@gva.es
+ *      www.gvsig.gva.es
+ *
+ *    or
+ *
+ *   IVER T.I. S.A
+ *   Salamanca 50
+ *   46005 Valencia
+ *   Spain
+ *
+ *   +34 963163400
+ *   dac@iver.es
+ */
+/* CVS MESSAGES:
+ *
+ * $Id$
+ * $Log$
+ * Revision 1.8  2007-09-19 15:51:33  jaume
+ * fixed bug when opening the layer properties dialog for more than one layer (two or more active layers selected)
+ *
+ * Revision 1.7  2007/07/30 12:56:04  jaume
+ * organize imports, java 5 code downgraded to 1.4 and added PictureFillSymbol
+ *
+ * Revision 1.6  2007/03/09 11:25:00  jaume
+ * Advanced symbology (start committing)
+ *
+ * Revision 1.4.2.3  2007/02/01 12:12:41  jaume
+ * theme manager window and all its components are now dynamic
+ *
+ * Revision 1.4.2.2  2007/01/30 18:10:10  jaume
+ * start commiting labeling stuff
+ *
+ * Revision 1.4.2.1  2007/01/26 13:49:03  jaume
+ * *** empty log message ***
+ *
+ * Revision 1.4  2007/01/23 13:10:45  caballero
+ * no mostrar propiedades de una capa de anotaciones
+ *
+ * Revision 1.3  2007/01/04 07:24:31  caballero
+ * isModified
+ *
+ * Revision 1.2  2006/10/02 13:52:34  jaume
+ * organize impots
+ *
+ * Revision 1.1  2006/09/15 10:41:30  caballero
+ * extensibilidad de documentos
+ *
+ * Revision 1.1  2006/09/12 15:58:14  jorpiell
+ * "Sacadas" las opcines del men� de FPopupMenu
+ *
+ *
+ */
+/**
+ * Muestra el men� de propiedades del tema.
+ *
+ * @author jmorell
+ */
+
+
+public class FLyrVectEditPropertiesTocMenuEntry extends AbstractTocContextMenuAction {
+	public String getGroup() {
+		return "group2"; //FIXME
+	}
+
+	public int getGroupOrder() {
+		return 20;
+	}
+
+	public int getOrder() {
+		return 0;
+	}
+
+	public String getText() {
+		return PluginServices.getText(this, "propiedades");
+	}
+
+	public boolean isEnabled(ITocItem item, FLayer[] selectedItems) {
+		return selectedItems.length == 1;
+	}
+
+	public boolean isVisible(ITocItem item, FLayer[] selectedItems) {
+		if (isTocItemBranch(item)) {
+			FLayer lyr = getNodeLayer(item);
+            if ((lyr instanceof ClassifiableVectorial)) {
+            	if (!((lyr instanceof FLyrVect) &&
+            			!((FLyrVect)lyr).isPropertiesMenuVisible())){
+            		return true;
+//            		if (!(lyr instanceof FLyrAnnotation))
+//            			return true;
+            	}
+
+            }
+		}
+		return false;
+
+	}
+
+
+	public void execute(ITocItem item, FLayer[] selectedItems) {
+//		long t1 = System.currentTimeMillis();
+
+		FLayer lyr = getNodeLayer(item);
+		ThemeManagerWindow fThemeManagerWindow = null;
+
+		if (lyr.isAvailable()) {
+			fThemeManagerWindow = new ThemeManagerWindow(lyr);
+		}
+
+		if (PluginServices.getMainFrame() == null) {
+			JDialog dlg = new JDialog();
+			fThemeManagerWindow.setPreferredSize(fThemeManagerWindow.getSize());
+			dlg.getContentPane().add(fThemeManagerWindow);
+			dlg.setModal(false);
+			dlg.pack();
+			dlg.setVisible(true);
+//			System.err.println("open properties dialog time: "+(System.currentTimeMillis()-t1));
+		} else {
+//			System.err.println("open properties dialog time: "+(System.currentTimeMillis()-t1));
+			PluginServices.getMDIManager().addWindow(fThemeManagerWindow);
+		}
+
+		Project project=((ProjectExtension)PluginServices.getExtension(ProjectExtension.class)).getProject();
+		project.setModified(true);
+	}
+
+}

Property changes on: tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/app/project/documents/view/toc/actions/FLyrVectEditPropertiesTocMenuEntry.java
___________________________________________________________________
Added: svn:keywords
   + Author Date Id Revision
Added: svn:eol-style
   + native

Index: tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/app/project/documents/view/toc/actions/FirstLayerTocMenuEntry.java
===================================================================
--- tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/app/project/documents/view/toc/actions/FirstLayerTocMenuEntry.java	(revision 0)
+++ tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/app/project/documents/view/toc/actions/FirstLayerTocMenuEntry.java	(revision 38653)
@@ -0,0 +1,134 @@
+package org.gvsig.app.project.documents.view.toc.actions;
+
+import org.gvsig.andami.PluginServices;
+import org.gvsig.app.extension.ProjectExtension;
+import org.gvsig.app.project.Project;
+import org.gvsig.app.project.documents.view.toc.AbstractTocContextMenuAction;
+import org.gvsig.app.project.documents.view.toc.ITocItem;
+import org.gvsig.app.project.documents.view.toc.TocItemBranch;
+import org.gvsig.fmap.mapcontext.layers.FLayer;
+import org.gvsig.fmap.mapcontext.layers.FLayers;
+
+
+/* gvSIG. Sistema de Informaci�n Geogr�fica de la Generalitat Valenciana
+ *
+ * Copyright (C) 2004 IVER T.I. and Generalitat Valenciana.
+ *
+ * This program is free software; you can redistribute it and/or
+ * modify it under the terms of the GNU General Public License
+ * as published by the Free Software Foundation; either version 2
+ * of the License, or (at your option) any later version.
+ *
+ * This program is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
+ * GNU General Public License for more details.
+ *
+ * You should have received a copy of the GNU General Public License
+ * along with this program; if not, write to the Free Software
+ * Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA  02111-1307,USA.
+ *
+ * For more information, contact:
+ *
+ *  Generalitat Valenciana
+ *   Conselleria d'Infraestructures i Transport
+ *   Av. Blasco Ib��ez, 50
+ *   46010 VALENCIA
+ *   SPAIN
+ *
+ *      +34 963862235
+ *   gvsig@gva.es
+ *      www.gvsig.gva.es
+ *
+ *    or
+ *
+ *   IVER T.I. S.A
+ *   Salamanca 50
+ *   46005 Valencia
+ *   Spain
+ *
+ *   +34 963163400
+ *   dac@iver.es
+ */
+/* CVS MESSAGES:
+ *
+ * $Id$
+ * $Log$
+ * Revision 1.3  2007-01-04 07:24:31  caballero
+ * isModified
+ *
+ * Revision 1.2  2006/10/02 13:52:34  jaume
+ * organize impots
+ *
+ * Revision 1.1  2006/09/15 10:41:30  caballero
+ * extensibilidad de documentos
+ *
+ * Revision 1.1  2006/09/12 15:58:14  jorpiell
+ * "Sacadas" las opcines del men� de FPopupMenu
+ *
+ *
+ */
+/**
+ * Cambia la posici�n actual del layer a la primera posici�n.
+ *
+ * @author Vicente Caballero Navarro
+ */
+public class FirstLayerTocMenuEntry extends AbstractTocContextMenuAction {
+	public String getGroup() {
+		return "group4"; //FIXME
+	}
+
+	public int getGroupOrder() {
+		return 40;
+	}
+
+	public int getOrder() {
+		return 2;
+	}
+
+	public String getText() {
+		return PluginServices.getText(this, "colocar_delante");
+	}
+
+	public boolean isEnabled(ITocItem item, FLayer[] selectedItems) {
+		return true;
+	}
+
+	public boolean isVisible(ITocItem item, FLayer[] selectedItems) {
+		if (isTocItemBranch(item)){
+			return true;
+		}
+		return false;
+
+	}
+
+
+	public void execute(ITocItem item, FLayer[] selectedItems) {
+      	if (isTocItemBranch(item)){
+            if (getMapContext().getLayers().getActives().length == 1) {
+                FLayer layer=((TocItemBranch)item).getLayer();
+                FLayers layers=layer.getParentLayer();
+                for (int i=0;i<layers.getLayersCount();i++){
+                    if(layers.getLayer(i).equals(layer)){
+                    	layers.moveTo(layers.getLayersCount()-1-i, 0);
+                    }
+                }
+            } else if (selectedItems.length > 1) {
+                FLayer[] actives =selectedItems;
+                FLayers layers=actives[0].getParentLayer();
+                for (int i=0;i<actives.length;i++){
+                    for (int j=0;j<layers.getLayersCount();j++){
+                        if(layers.getLayer(j).equals(actives[i])){
+                        	layers.moveTo(layers.getLayersCount()-1-j, 0);
+                        }
+                    }
+                }
+            }
+		}
+		// TRUCO PARA REFRESCAR.
+        getMapContext().invalidate();
+        Project project=((ProjectExtension)PluginServices.getExtension(ProjectExtension.class)).getProject();
+		project.setModified(true);
+		PluginServices.getMainFrame().enableControls();
+	}
+}

Property changes on: tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/app/project/documents/view/toc/actions/FirstLayerTocMenuEntry.java
___________________________________________________________________
Added: svn:keywords
   + Author Date Id Revision
Added: svn:eol-style
   + native

Index: tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/app/project/documents/view/toc/actions/EliminarCapaTocMenuEntry.java
===================================================================
--- tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/app/project/documents/view/toc/actions/EliminarCapaTocMenuEntry.java	(revision 0)
+++ tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/app/project/documents/view/toc/actions/EliminarCapaTocMenuEntry.java	(revision 38653)
@@ -0,0 +1,180 @@
+package org.gvsig.app.project.documents.view.toc.actions;
+
+import java.awt.Component;
+
+import javax.swing.JOptionPane;
+
+import org.gvsig.andami.PluginServices;
+import org.gvsig.andami.ui.mdiManager.IWindow;
+import org.gvsig.app.extension.ProjectExtension;
+import org.gvsig.app.project.Project;
+import org.gvsig.app.project.documents.view.toc.AbstractTocContextMenuAction;
+import org.gvsig.app.project.documents.view.toc.ITocItem;
+import org.gvsig.fmap.mapcontext.layers.CancelationException;
+import org.gvsig.fmap.mapcontext.layers.FLayer;
+
+
+
+/* gvSIG. Sistema de Informaci�n Geogr�fica de la Generalitat Valenciana
+ *
+ * Copyright (C) 2004 IVER T.I. and Generalitat Valenciana.
+ *
+ * This program is free software; you can redistribute it and/or
+ * modify it under the terms of the GNU General Public License
+ * as published by the Free Software Foundation; either version 2
+ * of the License, or (at your option) any later version.
+ *
+ * This program is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
+ * GNU General Public License for more details.
+ *
+ * You should have received a copy of the GNU General Public License
+ * along with this program; if not, write to the Free Software
+ * Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA  02111-1307,USA.
+ *
+ * For more information, contact:
+ *
+ *  Generalitat Valenciana
+ *   Conselleria d'Infraestructures i Transport
+ *   Av. Blasco Ib��ez, 50
+ *   46010 VALENCIA
+ *   SPAIN
+ *
+ *      +34 963862235
+ *   gvsig@gva.es
+ *      www.gvsig.gva.es
+ *
+ *    or
+ *
+ *   IVER T.I. S.A
+ *   Salamanca 50
+ *   46005 Valencia
+ *   Spain
+ *
+ *   +34 963163400
+ *   dac@iver.es
+ */
+/* CVS MESSAGES:
+ *
+ * $Id$
+ * $Log$
+ * Revision 1.8  2007-08-29 10:52:01  nacho
+ * Bug en eliminar capa
+ *
+ * Revision 1.7  2007/08/29 10:44:00  nacho
+ * Comprobaci�n de null para que no salte la consola en caso de que la capa no est� seleccionada
+ *
+ * Revision 1.6  2007/08/21 11:47:26  nacho
+ * Cerrar cuadros asociados a la capa al eliminar esta
+ *
+ * Revision 1.5  2007/06/06 15:53:09  jmvivo
+ * Added check for edition layers: It cannot be removed
+ *
+ * Revision 1.4  2007/03/06 16:37:08  caballero
+ * Exceptions
+ *
+ * Revision 1.3  2007/01/04 07:24:31  caballero
+ * isModified
+ *
+ * Revision 1.2  2006/12/19 09:09:07  jmvivo
+ * Faltaba un beginAtomicEvent para que no refrescase cada vez
+ *
+ * Revision 1.1  2006/09/15 10:41:30  caballero
+ * extensibilidad de documentos
+ *
+ * Revision 1.1  2006/09/12 15:58:14  jorpiell
+ * "Sacadas" las opcines del men� de FPopupMenu
+ *
+ *
+ */
+public class EliminarCapaTocMenuEntry extends AbstractTocContextMenuAction {
+	public String getGroup() {
+		return "group3"; //FIXME
+	}
+
+	public int getGroupOrder() {
+		return 30;
+	}
+
+	public int getOrder() {
+		return 0;
+	}
+
+	public String getText() {
+		return PluginServices.getText(this, "eliminar_capa");
+	}
+
+	public boolean isEnabled(ITocItem item, FLayer[] selectedItems) {
+		return true;
+	}
+
+	public boolean isVisible(ITocItem item, FLayer[] selectedItems) {
+		if (isTocItemBranch(item)) {
+			return true;
+		}
+		return false;
+
+	}
+
+
+	public void execute(ITocItem item, FLayer[] selectedItems) {
+    	// 050209, jmorell: Para poder borrar todas las capas seleccionadas desde el FPopUpMenu.
+		//					Es necesario pulsar May�sculas a la vez que el bot�n derecho.
+
+    	FLayer[] actives = selectedItems;
+
+    	int i;
+    	for (i= 0; i < actives.length;i++){
+    		if (actives[i].isEditing() && actives[i].isAvailable()){
+    			JOptionPane.showMessageDialog((Component)PluginServices.getMainFrame(), PluginServices.getText(this,"no_se_puede_borrar_una_capa_en_edicion"), PluginServices.getText(this, "eliminar_capa"), JOptionPane.WARNING_MESSAGE);
+    			return;
+    		}
+    	}
+
+    	int option=-1;
+    	if (actives.length>0) {
+    		option=JOptionPane.showConfirmDialog((Component)PluginServices.getMainFrame(),PluginServices.getText(this,"desea_borrar_la_capa"));
+    	} else {
+    		return;
+    	}
+    	if (option!=JOptionPane.OK_OPTION)
+    		return;
+    	getMapContext().beginAtomicEvent();
+    	for (i = actives.length-1; i>=0; i--){
+        	try {
+				//actives[i].getParentLayer().removeLayer(actives[i]);
+				//FLayers lyrs=getMapContext().getLayers();
+				//lyrs.addLayer(actives[i]);
+				actives[i].getParentLayer().removeLayer(actives[i]);
+
+                //Cierra todas las ventanas asociadas a la capa
+        		IWindow[] wList = PluginServices.getMDIManager().getAllWindows();
+        		for (int j = 0; j < wList.length; j++) {
+        			String name = wList[j].getWindowInfo().getAdditionalInfo();
+        			for (int k = 0; k < actives.length; k++) {
+        				if( name != null && actives != null && actives[k] != null &&
+                			actives[k].getName() != null &&
+                			name.compareTo(actives[k].getName()) == 0)
+                			PluginServices.getMDIManager().closeWindow(wList[j]);
+					}
+        		}
+
+    		} catch (CancelationException e1) {
+    			e1.printStackTrace();
+    		}
+    	}
+    	getMapContext().endAtomicEvent();
+    	Project project=((ProjectExtension)PluginServices.getExtension(ProjectExtension.class)).getProject();
+		project.setModified(true);
+    	PluginServices.getMainFrame().enableControls();
+		// 050209, jmorell: As� solo borra una capa (sobre la que pulsas).
+    	/*FLayer lyr = getNodeLayer();
+        try {
+        	getMapContext().getLayers().removeLayer(lyr);
+        	if (getMapContext().getLayers().getLayersCount()==0)PluginServices.getMainFrame().enableControls();
+		} catch (CancelationException e1) {
+			e1.printStackTrace();
+		}*/
+    }
+}
\ No newline at end of file

Property changes on: tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/app/project/documents/view/toc/actions/EliminarCapaTocMenuEntry.java
___________________________________________________________________
Added: svn:keywords
   + Author Date Id Revision
Added: svn:eol-style
   + native

Index: tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/app/project/documents/view/toc/actions/ChangeNameTocMenuEntry.java
===================================================================
--- tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/app/project/documents/view/toc/actions/ChangeNameTocMenuEntry.java	(revision 0)
+++ tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/app/project/documents/view/toc/actions/ChangeNameTocMenuEntry.java	(revision 38653)
@@ -0,0 +1,108 @@
+package org.gvsig.app.project.documents.view.toc.actions;
+
+import org.gvsig.andami.PluginServices;
+import org.gvsig.app.extension.ProjectExtension;
+import org.gvsig.app.project.Project;
+import org.gvsig.app.project.documents.view.toc.AbstractTocContextMenuAction;
+import org.gvsig.app.project.documents.view.toc.ITocItem;
+import org.gvsig.app.project.documents.view.toc.gui.ChangeName;
+import org.gvsig.fmap.mapcontext.layers.FLayer;
+
+
+
+/* gvSIG. Sistema de Informaci�n Geogr�fica de la Generalitat Valenciana
+ *
+ * Copyright (C) 2004 IVER T.I. and Generalitat Valenciana.
+ *
+ * This program is free software; you can redistribute it and/or
+ * modify it under the terms of the GNU General Public License
+ * as published by the Free Software Foundation; either version 2
+ * of the License, or (at your option) any later version.
+ *
+ * This program is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
+ * GNU General Public License for more details.
+ *
+ * You should have received a copy of the GNU General Public License
+ * along with this program; if not, write to the Free Software
+ * Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA  02111-1307,USA.
+ *
+ * For more information, contact:
+ *
+ *  Generalitat Valenciana
+ *   Conselleria d'Infraestructures i Transport
+ *   Av. Blasco Ib��ez, 50
+ *   46010 VALENCIA
+ *   SPAIN
+ *
+ *      +34 963862235
+ *   gvsig@gva.es
+ *      www.gvsig.gva.es
+ *
+ *    or
+ *
+ *   IVER T.I. S.A
+ *   Salamanca 50
+ *   46005 Valencia
+ *   Spain
+ *
+ *   +34 963163400
+ *   dac@iver.es
+ */
+/* CVS MESSAGES:
+ *
+ * $Id$
+ * $Log$
+ * Revision 1.2  2007-01-04 07:24:31  caballero
+ * isModified
+ *
+ * Revision 1.1  2006/09/15 10:41:30  caballero
+ * extensibilidad de documentos
+ *
+ * Revision 1.1  2006/09/12 15:58:14  jorpiell
+ * "Sacadas" las opcines del men� de FPopupMenu
+ *
+ *
+ */
+/**
+ * Realiza un cambio de nombre en la capa seleccionada
+ *
+ * @author Vicente Caballero Navarro
+ */
+public class ChangeNameTocMenuEntry extends AbstractTocContextMenuAction {
+	public String getGroup() {
+		return "group1"; //FIXME
+	}
+
+	public int getGroupOrder() {
+		return 10;
+	}
+
+	public int getOrder() {
+		return 1;
+	}
+
+	public String getText() {
+		return PluginServices.getText(this, "cambio_nombre");
+	}
+
+	public boolean isEnabled(ITocItem item, FLayer[] selectedItems) {
+		return selectedItems.length == 1;
+	}
+
+	public boolean isVisible(ITocItem item, FLayer[] selectedItems) {
+		return isTocItemBranch(item);
+	}
+
+
+	public void execute(ITocItem item, FLayer[] selectedItems) {
+		FLayer lyr = getNodeLayer(item);
+		if (!lyr.isAvailable()) return;
+		ChangeName chn=new ChangeName(lyr.getName());
+		PluginServices.getMDIManager().addWindow(chn);
+		lyr.setName(chn.getName());
+		Project project=((ProjectExtension)PluginServices.getExtension(ProjectExtension.class)).getProject();
+		project.setModified(true);
+	}
+}

Property changes on: tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/app/project/documents/view/toc/actions/ChangeNameTocMenuEntry.java
___________________________________________________________________
Added: svn:keywords
   + Author Date Id Revision
Added: svn:eol-style
   + native

Index: tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/app/project/documents/view/toc/actions/CopyLayersTocMenuEntry.java
===================================================================
--- tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/app/project/documents/view/toc/actions/CopyLayersTocMenuEntry.java	(revision 0)
+++ tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/app/project/documents/view/toc/actions/CopyLayersTocMenuEntry.java	(revision 38653)
@@ -0,0 +1,78 @@
+package org.gvsig.app.project.documents.view.toc.actions;
+
+import java.awt.Component;
+
+import javax.swing.JOptionPane;
+
+import org.gvsig.andami.PluginServices;
+import org.gvsig.app.extension.ProjectExtension;
+import org.gvsig.app.project.Project;
+import org.gvsig.app.project.documents.view.toc.AbstractTocContextMenuAction;
+import org.gvsig.app.project.documents.view.toc.ITocItem;
+import org.gvsig.fmap.mapcontext.layers.FLayer;
+import org.gvsig.utils.XMLEntity;
+
+
+public class CopyLayersTocMenuEntry extends AbstractTocContextMenuAction {
+	private CopyPasteLayersUtiles utiles = CopyPasteLayersUtiles.getInstance();
+
+	public String getGroup() {
+		return "copyPasteLayer";
+	}
+
+	public int getGroupOrder() {
+		return 60;
+	}
+
+	public int getOrder() {
+		return 0;
+	}
+
+	public String getText() {
+		return PluginServices.getText(this, "copiar");
+	}
+
+	public boolean isEnabled(ITocItem item, FLayer[] selectedItems) {
+		if ( selectedItems.length >= 1 && isTocItemBranch(item)){
+			for (int i=0;i< selectedItems.length;i++) {
+				if (selectedItems[i].isEditing()){
+					return false;
+				}
+			}
+			return true;
+		}
+		return false;
+
+	}
+
+
+	public void execute(ITocItem item, FLayer[] selectedItems) {
+		XMLEntity xml = this.utiles.generateXMLCopyLayers(selectedItems);
+		if (xml == null) {
+			JOptionPane.showMessageDialog(
+					(Component)PluginServices.getMainFrame(),
+					"<html>"+PluginServices.getText(this,"No_ha_sido_posible_realizar_la_operacion")+"</html>",//Mensaje
+					PluginServices.getText(this,"copiar"),//titulo
+					JOptionPane.ERROR_MESSAGE
+					);
+			return;
+		}
+
+		String data = xml.toString();
+		if (data == null) {
+			JOptionPane.showMessageDialog(
+					(Component)PluginServices.getMainFrame(),
+					"<html>"+PluginServices.getText(this,"No_ha_sido_posible_realizar_la_operacion")+"</html>",//Mensaje
+					PluginServices.getText(this,"copiar"),//titulo
+					JOptionPane.ERROR_MESSAGE
+					);
+			return;
+		}
+
+		PluginServices.putInClipboard(data);
+		Project project=((ProjectExtension)PluginServices.getExtension(ProjectExtension.class)).getProject();
+		project.setModified(true);
+	}
+
+
+}

Property changes on: tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/app/project/documents/view/toc/actions/CopyLayersTocMenuEntry.java
___________________________________________________________________
Added: svn:eol-style
   + native

Index: tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/app/project/documents/view/toc/actions/PasteLayersTocMenuEntry.java
===================================================================
--- tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/app/project/documents/view/toc/actions/PasteLayersTocMenuEntry.java	(revision 0)
+++ tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/app/project/documents/view/toc/actions/PasteLayersTocMenuEntry.java	(revision 38653)
@@ -0,0 +1,100 @@
+package org.gvsig.app.project.documents.view.toc.actions;
+
+import org.exolab.castor.xml.MarshalException;
+import org.exolab.castor.xml.ValidationException;
+import org.gvsig.andami.PluginServices;
+import org.gvsig.app.extension.ProjectExtension;
+import org.gvsig.app.project.Project;
+import org.gvsig.app.project.documents.view.toc.AbstractTocContextMenuAction;
+import org.gvsig.app.project.documents.view.toc.ITocItem;
+import org.gvsig.fmap.mapcontext.layers.FLayer;
+import org.gvsig.fmap.mapcontext.layers.FLayers;
+import org.gvsig.utils.XMLEntity;
+
+
+public class PasteLayersTocMenuEntry extends AbstractTocContextMenuAction {
+	private XMLEntity xml=null;
+	private CopyPasteLayersUtiles utiles = CopyPasteLayersUtiles.getInstance();
+
+
+	public String getGroup() {
+		return "copyPasteLayer";
+	}
+
+	public int getGroupOrder() {
+		return 60;
+	}
+
+	public int getOrder() {
+		return 2;
+	}
+
+	public String getText() {
+		return PluginServices.getText(this, "pegar");
+	}
+
+	public boolean isEnabled(ITocItem item, FLayer[] selectedItems) {
+		if (isTocItemBranch(item)) {
+			FLayer lyr = getNodeLayer(item);
+			if (lyr instanceof FLayers) {
+				this.xml = this.getCheckedXMLFromClipboard();
+				return true;
+			}
+
+		} else if (!isTocItemLeaf(item)) {
+			if (getNodeLayer(item) == null) {
+				this.xml = this.getCheckedXMLFromClipboard();
+				return this.xml != null;
+			}
+		}
+		return false;
+	}
+
+	private XMLEntity getCheckedXMLFromClipboard() {
+		String sourceString = PluginServices.getFromClipboard();
+		if (sourceString == null) return null;
+
+		XMLEntity xml;
+		try {
+			xml = XMLEntity.parse(sourceString);
+		} catch (MarshalException e) {
+			return null;
+		} catch (ValidationException e) {
+			return null;
+		}
+
+
+		if (!this.utiles.checkXMLRootNode(xml)) return null;
+
+		if (xml.findChildren("type","layers") == null) return null;
+
+		return  xml;
+	}
+
+	public void execute(ITocItem item, FLayer[] selectedItems) {
+		FLayers root;
+
+		if (this.xml == null) return;
+
+		if (isTocItemBranch(item)) {
+			root = (FLayers)getNodeLayer(item);
+		} else if (getNodeLayer(item) == null){
+			root = getMapContext().getLayers();
+		} else {
+			return;
+		}
+		getMapContext().beginAtomicEvent();
+
+		boolean isOK = this.utiles.loadLayersFromXML(this.xml,root);
+
+		getMapContext().endAtomicEvent();
+
+		if (isOK) {
+			getMapContext().invalidate();
+			Project project=((ProjectExtension)PluginServices.getExtension(ProjectExtension.class)).getProject();
+			project.setModified(true);
+		}
+	}
+
+
+}

Property changes on: tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/app/project/documents/view/toc/actions/PasteLayersTocMenuEntry.java
___________________________________________________________________
Added: svn:eol-style
   + native

Index: tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/app/project/documents/view/toc/actions/DelegatedTocContextMenuAction.java
===================================================================
--- tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/app/project/documents/view/toc/actions/DelegatedTocContextMenuAction.java	(revision 0)
+++ tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/app/project/documents/view/toc/actions/DelegatedTocContextMenuAction.java	(revision 38653)
@@ -0,0 +1,58 @@
+package org.gvsig.app.project.documents.view.toc.actions;
+
+import org.gvsig.app.project.documents.view.toc.AbstractTocContextMenuAction;
+import org.gvsig.app.project.documents.view.toc.ITocItem;
+import org.gvsig.fmap.mapcontext.MapContext;
+import org.gvsig.fmap.mapcontext.layers.FLayer;
+
+
+/**
+ * Clase abstract para facilitar sobreescribir una accion sobre el TOC.
+ *
+ * @author Joaquin del Cerro
+ */
+public abstract class DelegatedTocContextMenuAction extends AbstractTocContextMenuAction {
+
+	private AbstractTocContextMenuAction delegated = null; 
+	
+	public DelegatedTocContextMenuAction(AbstractTocContextMenuAction delegated) {
+		this.delegated = delegated;
+	}
+	
+	public void execute(ITocItem item, FLayer[] selectedItems) {
+		delegated.execute(item,selectedItems);
+	}
+
+	public String getText() {
+		return delegated.getText();
+	}
+	public String getGroup() {
+		return delegated.getGroup();
+	}
+
+	public int getGroupOrder() {
+		return delegated.getGroupOrder();
+	}
+
+	public int getOrder() {
+		return delegated.getOrder();
+	}
+
+	public boolean isEnabled(ITocItem item, FLayer[] selectedItems) {
+		return delegated.isEnabled(item, selectedItems);
+	}
+
+	public boolean isVisible(ITocItem item, FLayer[] selectedItems) {
+		return delegated.isVisible(item, selectedItems);
+		
+	}
+	
+	public MapContext getMapContext() {
+		return delegated.getMapContext();
+	}
+	
+	public void setMapContext(MapContext mapContext) {
+		delegated.setMapContext(mapContext);
+	}
+
+}

Property changes on: tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/app/project/documents/view/toc/actions/DelegatedTocContextMenuAction.java
___________________________________________________________________
Added: svn:keywords
   + Author Date Id Revision
Added: svn:eol-style
   + native

Index: tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/app/project/documents/view/toc/actions/OldTocContextMenuAction.java
===================================================================
--- tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/app/project/documents/view/toc/actions/OldTocContextMenuAction.java	(revision 0)
+++ tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/app/project/documents/view/toc/actions/OldTocContextMenuAction.java	(revision 38653)
@@ -0,0 +1,92 @@
+package org.gvsig.app.project.documents.view.toc.actions;
+
+import org.gvsig.app.project.documents.view.toc.AbstractTocContextMenuAction;
+import org.gvsig.app.project.documents.view.toc.ITocItem;
+import org.gvsig.app.project.documents.view.toc.TocMenuEntry;
+import org.gvsig.app.project.documents.view.toc.gui.FPopupMenu;
+import org.gvsig.fmap.mapcontext.layers.FLayer;
+
+
+/* gvSIG. Sistema de Informaci�n Geogr�fica de la Generalitat Valenciana
+ *
+ * Copyright (C) 2004 IVER T.I. and Generalitat Valenciana.
+ *
+ * This program is free software; you can redistribute it and/or
+ * modify it under the terms of the GNU General Public License
+ * as published by the Free Software Foundation; either version 2
+ * of the License, or (at your option) any later version.
+ *
+ * This program is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
+ * GNU General Public License for more details.
+ *
+ * You should have received a copy of the GNU General Public License
+ * along with this program; if not, write to the Free Software
+ * Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA  02111-1307,USA.
+ *
+ * For more information, contact:
+ *
+ *  Generalitat Valenciana
+ *   Conselleria d'Infraestructures i Transport
+ *   Av. Blasco Ib��ez, 50
+ *   46010 VALENCIA
+ *   SPAIN
+ *
+ *      +34 963862235
+ *   gvsig@gva.es
+ *      www.gvsig.gva.es
+ *
+ *    or
+ *
+ *   IVER T.I. S.A
+ *   Salamanca 50
+ *   46005 Valencia
+ *   Spain
+ *
+ *   +34 963163400
+ *   dac@iver.es
+ */
+/* CVS MESSAGES:
+ *
+ * $Id$
+ * $Log$
+ * Revision 1.1  2006-09-15 10:41:30  caballero
+ * extensibilidad de documentos
+ *
+ * Revision 1.1  2006/09/12 15:58:14  jorpiell
+ * "Sacadas" las opcines del men� de FPopupMenu
+ *
+ *
+ */
+public class OldTocContextMenuAction extends AbstractTocContextMenuAction {
+	private TocMenuEntry entry;
+
+	public int getGroupOrder() {
+		return 999;
+	}
+
+	public String getGroup() {
+		return "zzzOldMenus";
+	}
+
+	public void execute(ITocItem item, FLayer[] selectedItems) {
+		return; //No se llega a ejecutar nunca
+	}
+
+	public String getText() {
+		return null; //No se llega a ejecutar nunca
+	}
+
+	public void initializeElement(FPopupMenu menu) {
+		this.entry.initialize(menu);
+	}
+
+	public void setEntry(TocMenuEntry entry) {
+		this.entry = entry;
+	}
+
+	public TocMenuEntry getEntry() {
+		return this.entry;
+	}
+}

Property changes on: tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/app/project/documents/view/toc/actions/OldTocContextMenuAction.java
___________________________________________________________________
Added: svn:keywords
   + Author Date Id Revision
Added: svn:eol-style
   + native

Index: tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/app/project/documents/view/toc/AbstractTocContextMenuAction.java
===================================================================
--- tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/app/project/documents/view/toc/AbstractTocContextMenuAction.java	(revision 0)
+++ tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/app/project/documents/view/toc/AbstractTocContextMenuAction.java	(revision 38653)
@@ -0,0 +1,81 @@
+package org.gvsig.app.project.documents.view.toc;
+
+import java.util.Map;
+
+import org.gvsig.app.project.documents.view.AbstractContextMenuAction;
+import org.gvsig.fmap.mapcontext.MapContext;
+import org.gvsig.fmap.mapcontext.layers.FLayer;
+import org.gvsig.tools.extensionpoint.ExtensionBuilder;
+
+
+public abstract class AbstractTocContextMenuAction extends AbstractContextMenuAction implements ExtensionBuilder{
+	private MapContext mapContext;
+
+	public MapContext getMapContext() {
+		return this.mapContext;
+	}
+
+	public void setMapContext(MapContext mapContext) {
+		this.mapContext = mapContext;
+	}
+
+	/**
+	 * @deprecated use public boolean isEnabled(ITocItem item, FLayer[] selectedItems)
+	 */
+	public boolean isEnabled(Object item, Object[] selectedItems) {
+		return this.isEnabled((ITocItem)item, (FLayer[])selectedItems);
+	}
+
+	/**
+	 * @deprecated use public boolean isVisible(ITocItem item, FLayer[] selectedItems)
+	 */
+	public boolean isVisible(Object item, Object[] selectedItems) {
+		return this.isVisible((ITocItem)item, (FLayer[])selectedItems);
+	}
+
+	/**
+	 * @deprecated use public void execute(ITocItem item, FLayer[] selectedItems)
+	 */
+	public void execute(Object item, Object[] selectedItems) {
+		this.execute((ITocItem)item, (FLayer[])selectedItems);
+	}
+
+	public FLayer getNodeLayer(ITocItem node) {
+		if (isTocItemBranch(node))
+			return ((TocItemBranch) node).getLayer();
+		return null;
+	}
+	public boolean isTocItemLeaf(ITocItem node) {
+		return node instanceof TocItemLeaf;
+	}
+
+	public boolean isTocItemBranch(ITocItem node) {
+		return node instanceof TocItemBranch;
+	}
+
+
+	public boolean isEnabled(ITocItem item, FLayer[] selectedItems) {
+		return true;
+	}
+
+	public boolean isVisible(ITocItem item, FLayer[] selectedItems) {
+		return true;
+	}
+
+	public abstract void execute(ITocItem item, FLayer[] selectedItems);
+
+	public Object create() {
+		return this;
+	}
+
+	public Object create(Map args) {
+		// TODO Auto-generated method stub
+		return this;
+	}
+
+	public Object create(Object[] args) {
+		// TODO Auto-generated method stub
+		return this;
+	}
+
+}

Property changes on: tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/app/project/documents/view/toc/AbstractTocContextMenuAction.java
___________________________________________________________________
Added: svn:keywords
   + Author Date Id Revision
Added: svn:eol-style
   + native

Index: tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/app/project/documents/view/toc/TocItemBranch.java
===================================================================
--- tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/app/project/documents/view/toc/TocItemBranch.java	(revision 0)
+++ tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/app/project/documents/view/toc/TocItemBranch.java	(revision 38653)
@@ -0,0 +1,257 @@
+/*
+ * Created on 03-dic-2004
+ *
+ * TODO To change the template for this generated file go to
+ * Window - Preferences - Java - Code Generation - Code and Comments
+ */
+/* gvSIG. Sistema de Informaci�n Geogr�fica de la Generalitat Valenciana
+ *
+ * Copyright (C) 2004 IVER T.I. and Generalitat Valenciana.
+ *
+ * This program is free software; you can redistribute it and/or
+ * modify it under the terms of the GNU General Public License
+ * as published by the Free Software Foundation; either version 2
+ * of the License, or (at your option) any later version.
+ *
+ * This program is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
+ * GNU General Public License for more details.
+ *
+ * You should have received a copy of the GNU General Public License
+ * along with this program; if not, write to the Free Software
+ * Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA  02111-1307,USA.
+ *
+ * For more information, contact:
+ *
+ *  Generalitat Valenciana
+ *   Conselleria d'Infraestructures i Transport
+ *   Av. Blasco Ib��ez, 50
+ *   46010 VALENCIA
+ *   SPAIN
+ *
+ *      +34 963862235
+ *   gvsig@gva.es
+ *      www.gvsig.gva.es
+ *
+ *    or
+ *
+ *   IVER T.I. S.A
+ *   Salamanca 50
+ *   46005 Valencia
+ *   Spain
+ *
+ *   +34 963163400
+ *   dac@iver.es
+ */
+package org.gvsig.app.project.documents.view.toc;
+
+import java.awt.Dimension;
+import java.awt.Graphics2D;
+import java.awt.Image;
+import java.awt.datatransfer.DataFlavor;
+import java.awt.datatransfer.UnsupportedFlavorException;
+import java.awt.image.BufferedImage;
+import java.io.File;
+import java.io.IOException;
+import java.net.URL;
+
+import javax.swing.Icon;
+import javax.swing.ImageIcon;
+
+import org.gvsig.andami.PluginServices;
+import org.gvsig.app.project.documents.view.IContextMenuAction;
+import org.gvsig.app.project.documents.view.toc.actions.FLyrVectEditPropertiesTocMenuEntry;
+import org.gvsig.fmap.mapcontext.MapContext;
+import org.gvsig.fmap.mapcontext.layers.FLayer;
+import org.gvsig.fmap.mapcontext.layers.vectorial.FLyrVect;
+
+
+/**
+ * @author FJP
+ *
+ * TODO To change the template for this generated type comment go to
+ * Window - Preferences - Java - Code Generation - Code and Comments
+ */
+public class TocItemBranch implements ITocItem {
+
+	private ImageIcon icolayer = null;
+
+	private ImageIcon finalIcon = null;
+
+	private BufferedImage unavailableImg = null;
+
+	private final String defaultIcon = "images/icolayer.PNG";
+
+	private final String unavailableImgPath = "images/unavailable.png";
+
+	private boolean isAvailable = true;
+
+	private FLayer lyr;
+
+	private Dimension sz;
+
+    final public static DataFlavor INFO_FLAVOR =
+	    new DataFlavor(TocItemBranch.class, "ItemBranch");
+    static DataFlavor flavors[] = {INFO_FLAVOR };
+
+	public TocItemBranch(FLayer lyr)
+	{
+		this.lyr = lyr;
+	}
+	/* (non-Javadoc)
+	 * @see com.iver.cit.gvsig.gui.toc.ITocItem#getLabel()
+	 */
+	public String getLabel() {
+		/*if (lyr instanceof FLyrVect && ((FLyrVect)lyr).isBroken())
+		{
+			return lyr.getName() + "(broken)";
+		}
+		else*/
+			return lyr.getName();
+	}
+
+	/* (non-Javadoc)
+	 * @see com.iver.cit.gvsig.gui.toc.ITocItem#getIcon()
+	 */
+	public Icon getIcon() {
+		// TODO Pedirle el icono a la capa. Por defecto habr� un icono
+		// para vectoriales y otro para raster, pero se podr�n cambiar.
+
+		if (finalIcon == null) {
+			ImageIcon icon = (ImageIcon) PluginServices.getIconTheme().get(lyr.getTocImageIcon());
+			this.setIcon(icon);
+		}
+		updateStateIcon();
+
+		return finalIcon;
+	}
+
+	private void setIcon(String path) {
+		File f = new File(path);
+		if (f.exists()) {
+			icolayer = new ImageIcon(f.getAbsolutePath());
+		} else {
+			URL url =PluginServices.getPluginServices("org.gvsig.app").getClassLoader().getResource(path);
+			if (url!=null) {
+				icolayer = new ImageIcon(url);
+				return;
+			}
+		}
+		updateStateIcon();
+
+	}
+	private void updateStateIcon() {
+		if (icolayer == null) return;
+		if (lyr.getTocStatusImage() != null)
+		{
+			BufferedImage newImage = new BufferedImage(icolayer.getIconWidth(),icolayer.getIconHeight(),BufferedImage.TYPE_INT_ARGB);
+			Graphics2D grp = newImage.createGraphics();
+			grp.drawImage(icolayer.getImage(),0,0,null);
+			Image img = lyr.getTocStatusImage();
+			grp.drawImage(
+					img,
+					0,
+					icolayer.getIconHeight() -img.getHeight(null),
+					null
+			);
+			this.finalIcon = new ImageIcon(newImage);
+		}
+		if (this.lyr.isAvailable() != this.isAvailable || finalIcon==null) {
+			if (!this.lyr.isAvailable()) {
+				BufferedImage newImage = new BufferedImage(icolayer.getIconWidth(),icolayer.getIconHeight(),BufferedImage.TYPE_INT_ARGB);
+				Graphics2D grp = newImage.createGraphics();
+				grp.drawImage(icolayer.getImage(),0,0,null);
+				/*grp.setComposite(AlphaComposite.getInstance(
+				 AlphaComposite.SRC_OVER, (float) 1));*/
+				BufferedImage img = this.getUnavailableImage();
+				grp.drawImage(
+						img,
+						0,
+						icolayer.getIconHeight() -img.getHeight(),
+						null
+				);
+				this.finalIcon = new ImageIcon(newImage);
+
+			} else {
+				this.finalIcon = new ImageIcon(icolayer.getImage());
+			}
+			this.isAvailable =(this.lyr.isAvailable());
+		}
+
+	}
+
+	private void setIcon(ImageIcon icon) {
+		if (icon!=null) {
+			icolayer = icon;
+		} else {
+			this.setIcon(defaultIcon);
+
+		}
+		updateStateIcon();
+
+	}
+
+	public FLayer getLayer() {
+		return lyr;
+	}
+
+	/* (non-Javadoc)
+	 * @see java.awt.datatransfer.Transferable#getTransferDataFlavors()
+	 */
+	public DataFlavor[] getTransferDataFlavors() {
+		return flavors;
+	}
+
+	/* (non-Javadoc)
+	 * @see java.awt.datatransfer.Transferable#isDataFlavorSupported(java.awt.datatransfer.DataFlavor)
+	 */
+	public boolean isDataFlavorSupported(DataFlavor dF) {
+		return dF.equals(INFO_FLAVOR);
+	}
+
+	/* (non-Javadoc)
+	 * @see java.awt.datatransfer.Transferable#getTransferData(java.awt.datatransfer.DataFlavor)
+	 */
+	public Object getTransferData(DataFlavor dF) throws UnsupportedFlavorException, IOException {
+	    if (dF.equals(INFO_FLAVOR)) {
+	        return this;
+	      }
+	      else throw new UnsupportedFlavorException(dF);
+	}
+	/* (non-Javadoc)
+	 * @see com.iver.cit.gvsig.gui.toc.ITocItem#getSize()
+	 */
+	public Dimension getSize() {
+		return sz;
+	}
+	/* (non-Javadoc)
+	 * @see com.iver.cit.gvsig.gui.toc.ITocItem#setSize(java.awt.Dimension)
+	 */
+	public void setSize(Dimension sz) {
+		this.sz = sz;
+	}
+
+	private BufferedImage getUnavailableImage() {
+		if (this.unavailableImg == null) {
+			URL url =PluginServices.getPluginServices("org.gvsig.app").getClassLoader().getResource(this.unavailableImgPath);
+			if (url!=null) {
+				ImageIcon uIcon = new ImageIcon(url);
+				this.unavailableImg = new BufferedImage(uIcon.getIconWidth(),uIcon.getIconHeight(),BufferedImage.TYPE_INT_RGB);
+				this.unavailableImg.getGraphics().drawImage(uIcon.getImage(),0,0,null);
+			}
+
+		}
+		return this.unavailableImg;
+	}
+
+	public IContextMenuAction getDoubleClickAction() {
+		// TODO
+		// THIS IS A PATCH; IT WILL BE REMOVED WHEN ALL THE PROPERTIES
+		// FOR ALL LAYERS WILL BE MERGED IN THE SAME DIALOG
+		if (!(getLayer() instanceof FLyrVect)) {
+			return null;
+		}
+		return new FLyrVectEditPropertiesTocMenuEntry();
+	}
+}

Property changes on: tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/app/project/documents/view/toc/TocItemBranch.java
___________________________________________________________________
Added: svn:keywords
   + Author Date Id Revision
Added: svn:eol-style
   + native

Index: tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/app/project/documents/view/toc/gui/TOCRenderer.java
===================================================================
--- tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/app/project/documents/view/toc/gui/TOCRenderer.java	(revision 0)
+++ tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/app/project/documents/view/toc/gui/TOCRenderer.java	(revision 38653)
@@ -0,0 +1,173 @@
+/* gvSIG. Desktop Geographic Information System.
+ *
+ * Copyright � 2007-2012 gvSIG Association
+ *
+ * This program is free software; you can redistribute it and/or
+ * modify it under the terms of the GNU General Public License
+ * as published by the Free Software Foundation; either version 2
+ * of the License, or (at your option) any later version.
+ *
+ * This program is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
+ * GNU General Public License for more details.
+ *
+ * You should have received a copy of the GNU General Public License
+ * along with this program; if not, write to the Free Software
+ * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston,
+ * MA  02110-1301, USA.
+ *
+ * For any additional information, do not hesitate to contact us
+ * at info AT gvsig.com, or visit our website www.gvsig.com.
+ */
+package org.gvsig.app.project.documents.view.toc.gui;
+
+import java.awt.Color;
+import java.awt.Component;
+import java.awt.Dimension;
+import java.awt.Font;
+import java.awt.Rectangle;
+
+import javax.swing.Icon;
+import javax.swing.JCheckBox;
+import javax.swing.JLabel;
+import javax.swing.JPanel;
+import javax.swing.JTree;
+import javax.swing.SpringLayout;
+import javax.swing.tree.DefaultMutableTreeNode;
+import javax.swing.tree.TreeCellRenderer;
+
+import org.gvsig.app.project.documents.view.toc.ITocItem;
+import org.gvsig.app.project.documents.view.toc.TocItemBranch;
+import org.gvsig.fmap.mapcontext.layers.FLyrDefault;
+
+/**
+ * Renderer que actua sobre el TOC.
+ * 
+ * @author vcn
+ */
+public class TOCRenderer extends JPanel implements TreeCellRenderer {
+
+    private static final long serialVersionUID = -6733445768959238193L;
+    private JCheckBox check;
+    private JLabel label;
+
+    private final Color editingColor;
+    
+    /**
+     * toc background color
+     */
+    private final Color tocBgColor;
+
+    /**
+     * Creates a new TOCRenderer object.
+     */
+    public TOCRenderer(Color tocBackground) {
+        this(Color.RED, tocBackground);
+    }
+
+    /**
+     * Creates a new TOCRenderer object.
+     */
+    public TOCRenderer(Color editingColor, Color tocBackground) {
+        
+        this.editingColor = editingColor;
+        this.tocBgColor = tocBackground;
+
+        check = new JCheckBox();
+        label = new JLabel();
+
+        SpringLayout theLayout = new SpringLayout();
+        this.setLayout(theLayout);
+
+        // Adjust constraints for the text field so it's at
+        // (<label's right edge> + 5, 5).
+        this.add(check);
+        this.add(label);
+
+        theLayout.putConstraint(SpringLayout.WEST, label, 5, SpringLayout.EAST,
+            check);
+    }
+
+    /**
+     * M�todo llamado una vez por cada nodo, y todas las veces que se redibuja
+     * en pantalla el TOC.
+     * 
+     * @param tree
+     * @param value
+     * @param isSelected
+     * @param expanded
+     * @param leaf
+     * @param row
+     * @param hasFocus
+     * 
+     * @return
+     */
+    public Component getTreeCellRendererComponent(JTree tree, Object value,
+        boolean isSelected, boolean expanded, boolean leaf, int row,
+        boolean hasFocus) {
+
+        DefaultMutableTreeNode n = (DefaultMutableTreeNode) value;
+        Color foreground = tree.getForeground();
+        this.label.setFont(tree.getFont());
+        
+        this.label.setBackground(this.tocBgColor);
+        this.setBackground(this.tocBgColor);
+
+        if (n.getUserObject() instanceof ITocItem) {
+
+            ITocItem item = (ITocItem) n.getUserObject();
+            label.setText(item.getLabel());
+            Icon icono = item.getIcon();
+            if (icono != null) {
+                label.setIcon(icono);
+            }
+
+            this.validate();
+            Dimension sizeNode = item.getSize(); // Se fija en el resize del TOC
+            this.setPreferredSize(sizeNode);
+
+            if (item instanceof TocItemBranch) {
+                TocItemBranch branch = (TocItemBranch) item;
+                FLyrDefault lyr = (FLyrDefault) branch.getLayer();
+                check.setVisible(true);
+                check.setSelected(lyr.visibleRequired());
+                check.setBackground(this.tocBgColor);
+                if (!lyr.isAvailable()) {
+                    check.setEnabled(false);
+                } else {
+                    check.setEnabled(true);
+                    if (!lyr.isWithinScale(lyr.getMapContext().getScaleView())) {
+                        check.setEnabled(false);
+                    }
+
+                    if (lyr.isEditing()) {
+                        this.label.setForeground(editingColor);
+                    } else {
+                        this.label.setForeground(foreground);
+                    }
+                }
+                if (lyr.isActive()) {
+                    this.label.setFont(label.getFont().deriveFont(Font.BOLD));
+                }
+            } else {
+                check.setVisible(false);
+            }
+        }
+
+        if (leaf) {
+            // label.setIcon(UIManager.getIcon("Tree.leafIcon"));
+        } else if (expanded) {
+            // label.setIcon(UIManager.getIcon("Tree.openIcon"));
+        } else {
+            // label.setIcon(UIManager.getIcon("Tree.closedIcon"));
+        }
+
+        return this;
+    }
+
+    public Rectangle getCheckBoxBounds() {
+        return check.getBounds();
+    }
+
+}

Property changes on: tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/app/project/documents/view/toc/gui/TOCRenderer.java
___________________________________________________________________
Added: svn:keywords
   + Author Date Id Revision
Added: svn:eol-style
   + native

Index: tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/app/project/documents/view/toc/gui/FPopupMenu.java
===================================================================
--- tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/app/project/documents/view/toc/gui/FPopupMenu.java	(revision 0)
+++ tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/app/project/documents/view/toc/gui/FPopupMenu.java	(revision 38653)
@@ -0,0 +1,252 @@
+/* gvSIG. Desktop Geographic Information System.
+ *
+ * Copyright � 2007-2012 gvSIG Association
+ *
+ * This program is free software; you can redistribute it and/or
+ * modify it under the terms of the GNU General Public License
+ * as published by the Free Software Foundation; either version 2
+ * of the License, or (at your option) any later version.
+ *
+ * This program is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
+ * GNU General Public License for more details.
+ *
+ * You should have received a copy of the GNU General Public License
+ * along with this program; if not, write to the Free Software
+ * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston,
+ * MA  02110-1301, USA.
+ *
+ * For any additional information, do not hesitate to contact us
+ * at info AT gvsig.com, or visit our website www.gvsig.com.
+ */
+package org.gvsig.app.project.documents.view.toc.gui;
+
+import java.awt.event.ActionEvent;
+import java.awt.event.ActionListener;
+import java.lang.reflect.Array;
+import java.text.NumberFormat;
+import java.util.ArrayList;
+import java.util.Arrays;
+import java.util.Comparator;
+import java.util.Iterator;
+
+import javax.swing.JMenuItem;
+import javax.swing.JPopupMenu;
+import javax.swing.tree.DefaultMutableTreeNode;
+
+import org.gvsig.andami.messages.NotificationManager;
+import org.gvsig.app.project.documents.view.IContextMenuAction;
+import org.gvsig.app.project.documents.view.toc.AbstractTocContextMenuAction;
+import org.gvsig.app.project.documents.view.toc.ITocItem;
+import org.gvsig.app.project.documents.view.toc.TocItemBranch;
+import org.gvsig.app.project.documents.view.toc.actions.ChangeNameTocMenuEntry;
+import org.gvsig.app.project.documents.view.toc.actions.ChangeSymbolTocMenuEntry;
+import org.gvsig.app.project.documents.view.toc.actions.CopyLayersTocMenuEntry;
+import org.gvsig.app.project.documents.view.toc.actions.CutLayersTocMenuEntry;
+import org.gvsig.app.project.documents.view.toc.actions.EliminarCapaTocMenuEntry;
+import org.gvsig.app.project.documents.view.toc.actions.FLyrVectEditPropertiesTocMenuEntry;
+import org.gvsig.app.project.documents.view.toc.actions.FirstLayerTocMenuEntry;
+import org.gvsig.app.project.documents.view.toc.actions.LayersGroupTocMenuEntry;
+import org.gvsig.app.project.documents.view.toc.actions.LayersUngroupTocMenuEntry;
+import org.gvsig.app.project.documents.view.toc.actions.OldTocContextMenuAction;
+import org.gvsig.app.project.documents.view.toc.actions.PasteLayersTocMenuEntry;
+import org.gvsig.app.project.documents.view.toc.actions.ReloadLayerTocMenuEntry;
+import org.gvsig.app.project.documents.view.toc.actions.ShowLayerErrorsTocMenuEntry;
+import org.gvsig.app.project.documents.view.toc.actions.ZoomAlTemaTocMenuEntry;
+import org.gvsig.fmap.mapcontext.MapContext;
+import org.gvsig.fmap.mapcontext.layers.FLayer;
+import org.gvsig.tools.ToolsLocator;
+import org.gvsig.tools.extensionpoint.ExtensionPoint;
+import org.gvsig.tools.extensionpoint.ExtensionPoint.Extension;
+
+/**
+ * Menu de bot�n derecho para el TOC.
+ * Se pueden a�adir entradas facilmente desde una extensi�n,
+ * creando una clase derivando de TocMenuEntry, y a�adiendola en
+ * est�tico (o en tiempo de carga de la extensi�n) a FPopupMenu.
+ * (Las entradas actuales est�n hechas de esa manera).
+ * 
+ * @author vcn To change the template for this generated type comment go to
+ *         Window&gt;Preferences&gt;Java&gt;Code Generation&gt;Code and
+ *         Comments
+ */
+
+public class FPopupMenu extends JPopupMenu {
+
+    private static final long serialVersionUID = -7420923229618207434L;
+    private DefaultMutableTreeNode nodo;
+    protected MapContext mapContext;
+    private ExtensionPoint extensionPoint;
+    private FLayer[] selecteds;
+
+    public static void registerExtensionPoint() {
+        ExtensionPoint exPoint =
+            ToolsLocator.getExtensionPointManager().add("View_TocActions", "");
+        exPoint
+            .append("FSymbolChangeColor", "", new ChangeSymbolTocMenuEntry());
+        exPoint.append("ChangeName", "", new ChangeNameTocMenuEntry());
+        exPoint.append("FLyrVectEditProperties", "",
+            new FLyrVectEditPropertiesTocMenuEntry());
+        exPoint.append("ZoomAlTema", "", new ZoomAlTemaTocMenuEntry());
+        exPoint.append("EliminarCapa", "", new EliminarCapaTocMenuEntry());
+        exPoint.append("VerErroresCapa", "", new ShowLayerErrorsTocMenuEntry());
+        exPoint.append("ReloadLayer", "", new ReloadLayerTocMenuEntry());
+        exPoint.append("LayersGroup", "", new LayersGroupTocMenuEntry());
+        exPoint.append("LayersUngroup", "", new LayersUngroupTocMenuEntry());
+        exPoint.append("FirstLayer", "", new FirstLayerTocMenuEntry());
+
+        exPoint.append("Copy", "", new CopyLayersTocMenuEntry());
+        exPoint.append("Cut", "", new CutLayersTocMenuEntry());
+        exPoint.append("Paste", "", new PasteLayersTocMenuEntry());
+    }
+
+    /**
+     * Creates a new FPopupMenu object.
+     * 
+     * @param nodo
+     *            DOCUMENT ME!
+     * @param vista
+     *            DOCUMENT ME!
+     */
+    public FPopupMenu(MapContext mc, DefaultMutableTreeNode node) {
+        super();
+        this.initialize(mc, node);
+    }
+
+    private void initialize(MapContext mc, DefaultMutableTreeNode node) {
+        this.mapContext = mc;
+        this.nodo = node;
+
+        this.extensionPoint =
+            ToolsLocator.getExtensionPointManager().get("View_TocActions");
+        this.selecteds = this.mapContext.getLayers().getActives();
+
+        IContextMenuAction[] actions = this.getActionList();
+        if (actions == null) {
+            return;
+        }
+        this.createMenuElements(actions);
+    }
+
+    public MapContext getMapContext() {
+        return mapContext;
+    }
+
+    public ITocItem getNodeUserObject() {
+        if (nodo == null) {
+            return null;
+        }
+        return (ITocItem) nodo.getUserObject();
+    }
+
+    public DefaultMutableTreeNode getNode() {
+        return this.nodo;
+    }
+
+    private IContextMenuAction[] getActionList() {
+        ArrayList<IContextMenuAction> actionArrayList =
+            new ArrayList<IContextMenuAction>();
+        @SuppressWarnings("unchecked")
+        Iterator<Extension> iter = this.extensionPoint.iterator();
+        AbstractTocContextMenuAction action;
+        boolean contains = false;
+        ITocItem tocItem = this.getNodeUserObject();
+        if (tocItem instanceof TocItemBranch) {
+            for (int i = 0; i < this.selecteds.length; i++) {
+                if (this.selecteds[i].equals(((TocItemBranch) tocItem)
+                    .getLayer())) {
+                    contains = true;
+                    break;
+                }
+            }
+        } else {
+            contains = true;
+        }
+        if (contains) {
+            while (iter.hasNext()) {
+                action = null;
+                try {
+                    action =
+                        (AbstractTocContextMenuAction) iter.next().create();
+                } catch (Exception e) {
+                    NotificationManager.addError(e);
+                }
+                if (action != null
+                    && !(action instanceof OldTocContextMenuAction)) {
+                    action.setMapContext(this.mapContext);
+                    if (action.isVisible(this.getNodeUserObject(),
+                        this.selecteds)) {
+                        actionArrayList.add(action);
+                    }
+                }
+
+            }
+            IContextMenuAction[] result =
+                (IContextMenuAction[]) Array.newInstance(
+                    IContextMenuAction.class, actionArrayList.size());
+            System.arraycopy(actionArrayList.toArray(), 0, result, 0,
+                actionArrayList.size());
+            Arrays.sort(result, new CompareAction());
+
+            return result;
+        }
+        return null;
+    }
+
+    public class CompareAction implements Comparator<IContextMenuAction> {
+
+        public int compare(IContextMenuAction o1, IContextMenuAction o2) {
+            // FIXME: flata formatear los enteros!!!!
+            NumberFormat formater = NumberFormat.getInstance();
+            formater.setMinimumIntegerDigits(3);
+            String key1 =
+                "" + formater.format(o1.getGroupOrder()) + o1.getGroup()
+                    + formater.format(o1.getOrder());
+            String key2 =
+                "" + formater.format(o2.getGroupOrder()) + o2.getGroup()
+                    + formater.format(o2.getOrder());
+            return key1.compareTo(key2);
+        }
+    }
+
+    private void createMenuElements(IContextMenuAction[] actions) {
+        String group = null;
+        for (int i = 0; i < actions.length; i++) {
+            IContextMenuAction action = actions[i];
+            MenuItem item = new MenuItem(action.getText(), action);
+            item.setEnabled(action.isEnabled(this.getNodeUserObject(),
+                this.selecteds));
+            if (!action.getGroup().equals(group)) {
+                if (group != null) {
+                    this.addSeparator();
+                }
+                group = action.getGroup();
+            }
+            this.add(item);
+        }
+
+    }
+
+    public class MenuItem extends JMenuItem implements ActionListener {
+
+        private static final long serialVersionUID = 6858724610206253411L;
+        private IContextMenuAction action;
+
+        public MenuItem(String text, IContextMenuAction documentAction) {
+            super(text);
+            this.action = documentAction;
+            String tip = this.action.getDescription();
+            if (tip != null && tip.length() > 0) {
+                this.setToolTipText(tip);
+            }
+            this.addActionListener(this);
+        }
+
+        public void actionPerformed(ActionEvent e) {
+            this.action.execute(FPopupMenu.this.getNodeUserObject(),
+                FPopupMenu.this.selecteds);
+        }
+    }
+
+}

Property changes on: tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/app/project/documents/view/toc/gui/FPopupMenu.java
___________________________________________________________________
Added: svn:eol-style
   + native
Added: svn:keywords
   + Author Date Id Revision

Index: tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/app/project/documents/view/toc/gui/PanelColor.java
===================================================================
--- tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/app/project/documents/view/toc/gui/PanelColor.java	(revision 0)
+++ tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/app/project/documents/view/toc/gui/PanelColor.java	(revision 38653)
@@ -0,0 +1,123 @@
+/*
+ * Created on 27-feb-2004
+ *
+ * To change the template for this generated file go to
+ * Window&gt;Preferences&gt;Java&gt;Code Generation&gt;Code and Comments
+ */
+/* gvSIG. Sistema de Informaci�n Geogr�fica de la Generalitat Valenciana
+ *
+ * Copyright (C) 2004 IVER T.I. and Generalitat Valenciana.
+ *
+ * This program is free software; you can redistribute it and/or
+ * modify it under the terms of the GNU General Public License
+ * as published by the Free Software Foundation; either version 2
+ * of the License, or (at your option) any later version.
+ *
+ * This program is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
+ * GNU General Public License for more details.
+ *
+ * You should have received a copy of the GNU General Public License
+ * along with this program; if not, write to the Free Software
+ * Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA  02111-1307,USA.
+ *
+ * For more information, contact:
+ *
+ *  Generalitat Valenciana
+ *   Conselleria d'Infraestructures i Transport
+ *   Av. Blasco Ib��ez, 50
+ *   46010 VALENCIA
+ *   SPAIN
+ *
+ *      +34 963862235
+ *   gvsig@gva.es
+ *      www.gvsig.gva.es
+ *
+ *    or
+ *
+ *   IVER T.I. S.A
+ *   Salamanca 50
+ *   46005 Valencia
+ *   Spain
+ *
+ *   +34 963163400
+ *   dac@iver.es
+ */
+package org.gvsig.app.project.documents.view.toc.gui;
+
+import java.awt.BorderLayout;
+import java.awt.Color;
+import java.awt.Dimension;
+
+import javax.swing.JPanel;
+
+
+/**
+ * DOCUMENT ME!
+ *
+ * @author vcn To change the template for this generated type comment go to
+ *         Window&gt;Preferences&gt;Java&gt;Code Generation&gt;Code and
+ *         Comments
+ */
+public class PanelColor extends JPanel {
+    public Color[] m_colores = new Color[100];
+    public Color m_color;
+    private Integer numReg;
+    private int numreg;
+    public int a = 155;
+    public int b = 205;
+    public int c = 255;
+
+    /**
+     * Creates a new PanelColor object.
+     *
+     * @param numReg DOCUMENT ME!
+     */
+    public PanelColor(int numReg) {
+        //numReg=numReg+1;
+        //m_color = new Color((numReg*numReg+100)%255,(numReg+(3*numReg+100))%255,numReg%255);
+        //this.setBackground(m_color);
+        setLayout(new BorderLayout());
+		
+        //add(oneColorPanel);
+        setMaximumSize(new Dimension(12, 12));
+        setMinimumSize(new Dimension(12, 12));
+        setPreferredSize(new Dimension(12, 12));
+    }
+
+    //private ColorPanel oneColorPanel = new ColorPanel();
+    //private FourColorPanel fourColorPanel = new LayerColorPanel.FourColorPanel();
+    public void setColor(Color color) {
+        m_color = color;
+        a=color.getRed();
+        System.out.println("a=color.getRed();"+a);
+		b=color.getGreen();
+		System.out.println("b=color.getGreen();"+b);
+        c=color.getBlue();
+		System.out.println("c=color.getBlue();"+c);
+        this.setBackground(color);
+    }
+
+    /**
+     * DOCUMENT ME!
+     */
+    public void setColorinicial() {
+        a=155;
+		b=205;
+		c=255;
+        m_color = new Color(a, b, c);
+        this.setBackground(m_color);
+    }
+
+    /**
+     * DOCUMENT ME!
+     */
+    public void setColorfin() {
+        this.m_color = new Color(45, 95, 145);
+        a=45;
+        b=95;
+        c=145;
+        this.setBackground(m_color);
+    }
+}

Property changes on: tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/app/project/documents/view/toc/gui/PanelColor.java
___________________________________________________________________
Added: svn:keywords
   + Author Date Id Revision
Added: svn:eol-style
   + native

Index: tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/app/project/documents/view/toc/gui/HTMLInfoPanel.java
===================================================================
--- tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/app/project/documents/view/toc/gui/HTMLInfoPanel.java	(revision 0)
+++ tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/app/project/documents/view/toc/gui/HTMLInfoPanel.java	(revision 38653)
@@ -0,0 +1,201 @@
+/* gvSIG. Geographic Information System of the Valencian Government
+*
+* Copyright (C) 2007-2008 Infrastructures and Transports Department
+* of the Valencian Government (CIT)
+* 
+* This program is free software; you can redistribute it and/or
+* modify it under the terms of the GNU General Public License
+* as published by the Free Software Foundation; either version 2
+* of the License, or (at your option) any later version.
+* 
+* This program is distributed in the hope that it will be useful,
+* but WITHOUT ANY WARRANTY; without even the implied warranty of
+* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
+* GNU General Public License for more details.
+* 
+* You should have received a copy of the GNU General Public License
+* along with this program; if not, write to the Free Software
+* Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, 
+* MA  02110-1301, USA.
+* 
+*/
+
+/*
+* AUTHORS (In addition to CIT):
+* 2009 {Iver T.I.}   {Task}
+*/
+ 
+package org.gvsig.app.project.documents.view.toc.gui;
+
+import java.awt.BorderLayout;
+import java.awt.Dimension;
+import java.awt.event.ItemEvent;
+import java.awt.event.ItemListener;
+
+import javax.swing.JEditorPane;
+import javax.swing.JScrollPane;
+
+import org.gvsig.andami.PluginServices;
+import org.gvsig.gui.beans.panelGroup.panels.AbstractPanel;
+import org.gvsig.utils.swing.JComboBox;
+
+
+/**
+ * @author <a href="mailto:jpiera@gvsig.org">Jorge Piera</a>
+ */
+public abstract class HTMLInfoPanel extends AbstractPanel{
+	private final String      bgColor0        = "\"#FEEDD6\""; // light salmon
+	private final String      bgColor1        = "\"#EAEAEA\""; // light grey
+	private final String      bgColor3        = "\"#FBFFE1\""; // light yellow
+	private final String      bgColor4        = "\"#D6D6D6\""; // Gris
+	private final String      bgColorBody     = "\"#FFFFFF\""; // white
+	
+	private JScrollPane       jScrollPane     = null;
+	public JEditorPane        jEditorPane     = null;
+	private JComboBox         jComboBox       = null;
+		
+	/**
+	 * 
+	 */
+	public HTMLInfoPanel() {
+		super();
+		setLabel(PluginServices.getText(this, "info"));
+		initialize();
+	}
+
+	/**
+	 * This method initializes this
+	 *
+	 * @return void
+	 */
+	protected void initialize() {
+		this.setLayout(new BorderLayout(5, 5));
+		this.setBorder(javax.swing.BorderFactory.createEmptyBorder(5, 5, 5, 5));
+		this.add(getJScrollPane(), BorderLayout.CENTER);		
+		this.getJEditorPane().repaint();		
+	}	
+	
+	/**
+	 * This method initializes jScrollPane
+	 *
+	 * @return javax.swing.JScrollPane
+	 */
+	private JScrollPane getJScrollPane() {
+		if (jScrollPane == null) {
+			jScrollPane = new JScrollPane();
+			jScrollPane.setViewportView(getJEditorPane());
+		}
+		return jScrollPane;
+	}
+
+	/**
+	 * This method initializes jEditorPane
+	 *
+	 * @return javax.swing.JEditorPane
+	 */
+	private JEditorPane getJEditorPane() {
+		if (jEditorPane == null) {
+			jEditorPane = new JEditorPane();
+			jEditorPane.setEditable(false);
+			jEditorPane.setContentType("text/html");
+		}
+		return jEditorPane;
+	}
+	
+	/**
+	 * Booleano que est� a true cuando la fila a dibujar es par y a false cuando
+	 * es impar.
+	 */
+	private boolean           rowColor        = true;
+	
+	/**
+	 * Controla la alternatividad de colores en la tabla.
+	 *
+	 * @return Cadena con el color de la fila siguiente.
+	 */
+	private String getColor() {
+		String color = (rowColor ? bgColor0 : bgColor1);
+		rowColor = !rowColor;
+		return color;
+	}
+
+	/**
+	 * Obtiene una entrada de la tabla en formato HTML a partir de una propiedad,
+	 * un valor y un color.
+	 *
+	 * @param prop
+	 *          Nombre de la propiedad
+	 * @param value
+	 *          Valor
+	 * @param color
+	 *          Color
+	 *
+	 * @return Entrada HTML de la tabla
+	 */
+	protected String setHTMLBasicProperty(String prop, String value) {
+		String content = "<tr valign=\"top\">";
+		if (prop != null)
+			content += "<td bgcolor=" + bgColor4 + "align=\"right\" width=\"33%\"><font face=\"Arial\" size=\"3\">" + prop + ":&nbsp;</font></td>";
+		content += "<td bgcolor=" + getColor() + "align=\"left\" width=\"67%\"><font face=\"Arial\" size=\"3\">" + value + "</font></td>";
+		content += "</tr>";
+
+		return content;
+	}
+
+	/**
+	 * Obtiene una cabecera de tabla en formato HTML a partir de un titulo.
+	 *
+	 * @param title
+	 *          Nombre del titulo
+	 * @param colspan
+	 *          Numero de celdas que ocupara el titulo
+	 *
+	 * @return Entrada HTML del titulo
+	 */
+	protected String setHTMLTitleTable(String title, int colspan) {
+		return
+			"<tr valign=\"middle\" >" +
+			"<td bgcolor=" + bgColor3 + " align=\"center\" colspan=\"" + colspan + "\"><font face=\"Arial\" size=\"3\"><b> " + title + "</b></font></td>" +
+			"</tr>";
+	}
+
+	/**
+	 * Obtiene una cabecera de tabla en formato HTML a partir de un titulo.
+	 *
+	 * @param content
+	 *          Codigo HTML de las filas que componen la tabla.
+	 *
+	 * @return Entrada HTML de la tabla completa
+	 */
+	protected String setHTMLTable(String content) {
+		return "<table cellpadding=\"0\" cellspacing=\"0\" align=\"center\" width=\"100%\">" + content + "</table>";
+	}
+
+	/**
+	 * Genera el HTML para todo el contenido.
+	 *
+	 * @param content
+	 *          Codigo HTML que ira en el <body>...</body>.
+	 *
+	 * @return HTML completo
+	 */
+	protected String setHTMLBody(String content) {
+		String html = "<html>";
+		html += "<body bgcolor=" + bgColorBody + " topmargin=\"0\" marginheight=\"0\">";
+		html += content;
+		html += "</body>";
+		html += "</html>";
+		return html;
+	}
+	
+	/**
+	 * Add the HTML code t the form
+	 * @param content
+	 */
+	protected void addHTMLToPanel(String content){
+		this.getJEditorPane().setContentType("text/html");
+		this.getJEditorPane().setText(content);
+		this.getJEditorPane().setCaretPosition(0);
+	}
+}
+

Property changes on: tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/app/project/documents/view/toc/gui/HTMLInfoPanel.java
___________________________________________________________________
Added: svn:mime-type
   + text/plain

Index: tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/app/project/documents/view/toc/gui/TOC.java
===================================================================
--- tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/app/project/documents/view/toc/gui/TOC.java	(revision 0)
+++ tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/app/project/documents/view/toc/gui/TOC.java	(revision 38653)
@@ -0,0 +1,1133 @@
+/* gvSIG. Desktop Geographic Information System.
+ *
+ * Copyright � 2007-2012 gvSIG Association
+ *
+ * This program is free software; you can redistribute it and/or
+ * modify it under the terms of the GNU General Public License
+ * as published by the Free Software Foundation; either version 2
+ * of the License, or (at your option) any later version.
+ *
+ * This program is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
+ * GNU General Public License for more details.
+ *
+ * You should have received a copy of the GNU General Public License
+ * along with this program; if not, write to the Free Software
+ * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston,
+ * MA  02110-1301, USA.
+ *
+ * For any additional information, do not hesitate to contact us
+ * at info AT gvsig.com, or visit our website www.gvsig.com.
+ */
+package org.gvsig.app.project.documents.view.toc.gui;
+
+import java.awt.BorderLayout;
+import java.awt.Dimension;
+import java.awt.Font;
+import java.awt.FontMetrics;
+import java.awt.Image;
+import java.awt.Point;
+import java.awt.Rectangle;
+import java.awt.event.ActionEvent;
+import java.awt.event.ActionListener;
+import java.awt.event.ComponentEvent;
+import java.awt.event.ComponentListener;
+import java.awt.event.InputEvent;
+import java.awt.event.MouseAdapter;
+import java.awt.event.MouseEvent;
+import java.text.MessageFormat;
+import java.util.ArrayList;
+import java.util.Enumeration;
+import java.util.HashMap;
+import java.util.Map;
+
+import javax.swing.BorderFactory;
+import javax.swing.JColorChooser;
+import javax.swing.JComponent;
+import javax.swing.JDialog;
+import javax.swing.JScrollPane;
+import javax.swing.JTree;
+import javax.swing.SwingUtilities;
+import javax.swing.event.TreeExpansionEvent;
+import javax.swing.event.TreeExpansionListener;
+import javax.swing.tree.DefaultMutableTreeNode;
+import javax.swing.tree.DefaultTreeModel;
+import javax.swing.tree.TreePath;
+import javax.swing.tree.TreeSelectionModel;
+
+import org.slf4j.Logger;
+import org.slf4j.LoggerFactory;
+
+import org.gvsig.andami.PluginServices;
+import org.gvsig.andami.messages.NotificationManager;
+import org.gvsig.app.gui.preferencespage.ViewPage;
+import org.gvsig.app.project.documents.view.IContextMenuAction;
+import org.gvsig.app.project.documents.view.toc.DnDJTree;
+import org.gvsig.app.project.documents.view.toc.ITocItem;
+import org.gvsig.app.project.documents.view.toc.ITocOrderListener;
+import org.gvsig.app.project.documents.view.toc.TocItemBranch;
+import org.gvsig.app.project.documents.view.toc.TocItemLeaf;
+import org.gvsig.fmap.dal.exception.ReadException;
+import org.gvsig.fmap.mapcontext.MapContext;
+import org.gvsig.fmap.mapcontext.events.AtomicEvent;
+import org.gvsig.fmap.mapcontext.events.listeners.AtomicEventListener;
+import org.gvsig.fmap.mapcontext.layers.CancelationException;
+import org.gvsig.fmap.mapcontext.layers.FLayer;
+import org.gvsig.fmap.mapcontext.layers.FLayers;
+import org.gvsig.fmap.mapcontext.layers.LayerCollectionEvent;
+import org.gvsig.fmap.mapcontext.layers.LayerCollectionListener;
+import org.gvsig.fmap.mapcontext.layers.LayerPositionEvent;
+import org.gvsig.fmap.mapcontext.layers.operations.Classifiable;
+import org.gvsig.fmap.mapcontext.layers.operations.IHasImageLegend;
+import org.gvsig.fmap.mapcontext.layers.operations.LayerCollection;
+import org.gvsig.fmap.mapcontext.layers.vectorial.FLyrVect;
+import org.gvsig.fmap.mapcontext.rendering.legend.IClassifiedLegend;
+import org.gvsig.fmap.mapcontext.rendering.legend.ILegend;
+import org.gvsig.fmap.mapcontext.rendering.legend.ISingleSymbolLegend;
+import org.gvsig.fmap.mapcontext.rendering.legend.IVectorLegend;
+import org.gvsig.fmap.mapcontext.rendering.legend.events.LegendChangedEvent;
+import org.gvsig.fmap.mapcontext.rendering.legend.events.listeners.LegendListener;
+import org.gvsig.fmap.mapcontext.rendering.symbols.ISymbol;
+import org.gvsig.utils.XMLEntity;
+
+/**
+ * 
+ * @author fjp
+ */
+public class TOC extends JComponent implements ITocOrderListener,
+    LegendListener, LayerCollectionListener, TreeExpansionListener,
+    ComponentListener {
+
+    /**
+     * 
+     */
+    private static final long serialVersionUID = 5689047685537359038L;
+
+    /**
+     * Useful for debug the problems during the implementation.
+     */
+    private static Logger logger = LoggerFactory.getLogger(TOC.class);
+
+    private MapContext mapContext;
+
+    private DnDJTree m_Tree;
+
+    private DefaultTreeModel m_TreeModel;
+
+    private DefaultMutableTreeNode m_Root;
+
+    private TOCRenderer m_TocRenderer;
+
+    private JScrollPane m_Scroller;
+
+    // private ArrayList m_Listeners;
+    private Map<String, Boolean> m_ItemsExpanded =
+        new HashMap<String, Boolean>();
+
+    private NodeSelectionListener nodeSelectionListener = null;
+
+    /**
+     * Crea un nuevo TOC.
+     */
+    public TOC() {
+        this.setName("TOC");
+        this.setLayout(new BorderLayout());
+        this.setMinimumSize(new Dimension(100, 80));
+        this.setPreferredSize(new Dimension(100, 80));
+
+        // Construct the tree.
+        m_Root = new DefaultMutableTreeNode(java.lang.Object.class);
+        m_TreeModel = new DefaultTreeModel(m_Root);
+        m_Tree = new DnDJTree(m_TreeModel);
+
+        m_TocRenderer = new TOCRenderer(m_Tree.getBackground());
+        m_Tree.setCellRenderer(m_TocRenderer);
+
+        m_Tree.setRootVisible(false);
+
+        // m_Tree.setExpandsSelectedPaths(true);
+        // m_Tree.setAutoscrolls(true);
+        m_Tree.setShowsRootHandles(true);
+
+        // Posibilidad de seleccionar de forma aleatoria nodos de la leyenda.
+        m_Tree.getSelectionModel().setSelectionMode(
+            TreeSelectionModel.DISCONTIGUOUS_TREE_SELECTION);
+        nodeSelectionListener = new NodeSelectionListener(m_Tree);
+        m_Tree.addMouseListener(nodeSelectionListener);
+        // m_Tree.setBackground(UIManager.getColor("Button.background"));
+        // m_Tree.setBorder(BorderFactory.createEtchedBorder());
+
+        this.addComponentListener(this);
+
+        m_Tree.addTreeExpansionListener(this);
+
+        m_Tree.addOrderListener(this);
+
+        m_Tree.setRowHeight(0); // Para que lo determine el renderer
+
+        m_Scroller = new JScrollPane(m_Tree);
+        m_Scroller.setBorder(BorderFactory.createEmptyBorder());
+
+        // scrollPane.setPreferredSize(new Dimension(80,80));
+        // Add everything to this panel.
+        /*
+         * GridBagLayout gridbag = new GridBagLayout(); GridBagConstraints c =
+         * new GridBagConstraints(); setLayout(gridbag); c.fill =
+         * GridBagConstraints.BOTH; c.weightx = 1.0;
+         * gridbag.setConstraints(check,c);
+         */
+        add(m_Scroller); // , BorderLayout.WEST);
+
+        // refresh();
+    }
+
+    /**
+     * Elimina los listeners que actuan sobre el TOC, lo �nico que deja hacer es
+     * desplegar la leyenda de las capas.
+     */
+    public void removeListeners() {
+        m_Tree.removeMouseListener(nodeSelectionListener);
+        m_Tree.invalidateListeners();
+    }
+
+    /**
+     * Inserta el FMap.
+     * 
+     * @param mc
+     *            FMap.
+     */
+    public void setMapContext(MapContext mc) {
+        mapContext = mc;
+        mapContext.addAtomicEventListener(new AtomicEventListener() {
+
+            /**
+             * @see org.gvsig.fmap.mapcontext.events.listeners.AtomicEventListener#atomicEvent(org.gvsig.fmap.mapcontext.events.AtomicEvent)
+             */
+            public void atomicEvent(final AtomicEvent e) {
+                if (!SwingUtilities.isEventDispatchThread()) {
+                    SwingUtilities.invokeLater(new Runnable() {
+
+                        public void run() {
+                            atomicEvent(e);
+                        }
+                    });
+                    return;
+                }
+
+                if ((e.getLayerCollectionEvents().length > 0)
+                    || (e.getLegendEvents().length > 0)) {
+                    refresh();
+                }
+
+                if (e.getLayerEvents().length > 0) {
+                    repaint();
+                }
+
+                if (e.getExtentEvents().length > 0) {
+                    repaint();
+                }
+                LayerCollectionEvent[] events = e.getLayerCollectionEvents();
+                for( int i=0; i<events.length ; i++ ) {
+                   if( events[i].getEventType() == LayerCollectionEvent.LAYER_ADDED ) { 
+                       if (PluginServices.getMainFrame() != null) {
+                           PluginServices.getMainFrame().enableControls();
+                       }
+                   }
+                   // ===================================================
+                   // Change visibility of layer before adding, according to app preferences
+                   if( events[i].getEventType() == LayerCollectionEvent.LAYER_ADDING ) {
+
+                       if (invisibilityIsForced()) {
+                           events[i].getAffectedLayer().setVisible(false);
+                       }
+                   }
+                   // ===================================================
+                }
+            }
+        });
+
+        refresh();
+    }
+
+    /**
+     * DOCUMENT ME!
+     */
+    private void setExpandedNodes(DefaultMutableTreeNode node) {
+        // int i = 0;
+        // Las claves sobrantes de m_ItemsExpanded (provocadas
+        // por layerRemove, se quitan en el evento layerRemoved
+        // de este TOC
+        DefaultMutableTreeNode n;
+        @SuppressWarnings("rawtypes")
+        Enumeration enumeration = node.children();
+
+        while (enumeration.hasMoreElements()) {
+            n = (DefaultMutableTreeNode) enumeration.nextElement();
+            if (n.getChildCount() > 0) {
+                setExpandedNodes(n);
+            }
+            TreePath path = new TreePath(m_TreeModel.getPathToRoot(n));
+            ITocItem item = (ITocItem) n.getUserObject();
+            Boolean b = (Boolean) m_ItemsExpanded.get(item.getLabel());
+
+            if (b == null) // No estaba en el hash todav�a: valor por defecto
+            {
+                m_Tree.expandPath(path);
+
+                return;
+            }
+
+            if (b.booleanValue()) {
+                m_Tree.expandPath(path);
+            } else {
+                m_Tree.collapsePath(path);
+            }
+        }
+    }
+
+    /*
+     * (non-Javadoc)
+     * 
+     * @see com.iver.cit.opensig.gui.IToc#refresh()
+     */
+    public void refresh() {
+        if (!SwingUtilities.isEventDispatchThread()) {
+            SwingUtilities.invokeLater(new Runnable() {
+
+                public void run() {
+                    refresh();
+                }
+            });
+            return;
+        }
+        LayerCollection theLayers = mapContext.getLayers();
+        m_Root.removeAllChildren();
+        m_Root.setAllowsChildren(true);
+        doRefresh(theLayers, m_Root);
+
+        m_TreeModel.reload();
+
+        setExpandedNodes(m_Root);
+    }
+
+    private void doRefresh(LayerCollection theLayers,
+        DefaultMutableTreeNode parentNode) {
+        int width = m_Tree.getWidth();
+        if (width == 0) {
+            width = 300;
+        }
+        Dimension sizeLeaf = new Dimension(width, 15);
+        // Get the tree font height
+        Font font = m_Tree.getFont();
+        FontMetrics metrics = this.getFontMetrics(font);
+        Dimension sizeBranch = new Dimension(width, metrics.getHeight() + 4);
+
+        for (int i = theLayers.getLayersCount() - 1; i >= 0; i--) {
+            FLayer lyr = theLayers.getLayer(i);
+            if (!lyr.isInTOC()) {
+                continue;
+            }
+            TocItemBranch elTema = new TocItemBranch(lyr);
+            elTema.setSize(sizeBranch);
+
+            DefaultMutableTreeNode nodeLayer =
+                new DefaultMutableTreeNode(elTema);
+
+            m_TreeModel.insertNodeInto(nodeLayer, parentNode,
+                parentNode.getChildCount());
+
+            if (lyr instanceof LayerCollection) {
+                LayerCollection group = (LayerCollection) lyr;
+                doRefresh(group, nodeLayer);
+            } else {
+                if (lyr instanceof Classifiable) {// && !(lyr instanceof
+                                                  // FLyrAnnotation)) {
+
+                    Classifiable classifiable = (Classifiable) lyr;
+                    ILegend legendInfo = classifiable.getLegend();
+
+                    try {
+                        if (legendInfo instanceof IClassifiedLegend) {
+                            IClassifiedLegend cl =
+                                (IClassifiedLegend) legendInfo;
+                            String[] descriptions = cl.getDescriptions();
+                            ISymbol[] symbols = cl.getSymbols();
+
+                            for (int j = 0; j < descriptions.length; j++) {
+                                TocItemLeaf itemLeaf;
+                                itemLeaf =
+                                    new TocItemLeaf(symbols[j],
+                                        descriptions[j], classifiable.getShapeType());
+                                itemLeaf.setSize(sizeLeaf);
+
+                                DefaultMutableTreeNode nodeValue =
+                                    new DefaultMutableTreeNode(itemLeaf);
+                                m_TreeModel.insertNodeInto(nodeValue,
+                                    nodeLayer, nodeLayer.getChildCount());
+
+                            }
+                        }
+
+                        if (legendInfo instanceof ISingleSymbolLegend
+                            && (legendInfo.getDefaultSymbol() != null)) {
+                            TocItemLeaf itemLeaf;
+                            itemLeaf =
+                                new TocItemLeaf(legendInfo.getDefaultSymbol(),
+                                    legendInfo.getDefaultSymbol()
+                                        .getDescription(), classifiable.getShapeType());
+                            itemLeaf.setSize(sizeLeaf);
+
+                            DefaultMutableTreeNode nodeValue =
+                                new DefaultMutableTreeNode(itemLeaf);
+                            m_TreeModel.insertNodeInto(nodeValue, nodeLayer,
+                                nodeLayer.getChildCount());
+                        }
+                        
+                        if (legendInfo instanceof IHasImageLegend) {
+                            TocItemLeaf itemLeaf;
+                            IHasImageLegend imageLegend = (IHasImageLegend) legendInfo;
+                            Image image = imageLegend.getImageLegend();
+
+                            if (image != null) {
+                                itemLeaf = new TocItemLeaf();
+                                itemLeaf.setImageLegend(image, "", new Dimension(
+                                    image.getWidth(null), image.getHeight(null)));// new
+                                                                                  // Dimension(150,200));
+
+                                DefaultMutableTreeNode nodeValue =
+                                    new DefaultMutableTreeNode(itemLeaf);
+                                m_TreeModel.insertNodeInto(nodeValue, nodeLayer,
+                                    nodeLayer.getChildCount());
+                            }
+                        }
+                    } catch (ReadException e) {
+                        logger.error(MessageFormat.format(
+                            "Can't add leyend of layer {0} to the TOC.", lyr),
+                            e);
+                    }
+                } 
+            } // if instanceof layers
+        }
+    }
+
+    /**
+     * @see com.iver.cit.opensig.gui.toc.ITocOrderListener#orderChanged(int,
+     *      int)
+     */
+    public void orderChanged(int oldPos, int newPos, FLayers lpd) {
+        try {
+            lpd.moveTo(oldPos, newPos);
+        } catch (CancelationException e) {
+            logger.error("Can't change order of layers in TOC", e);
+        }
+        mapContext.invalidate();
+    }
+
+    public void parentChanged(FLayers lpo, FLayers lpd, FLayer ls) {
+        lpo.move(ls, lpd);
+        mapContext.invalidate();
+    }
+
+    /*
+     * (non-Javadoc)
+     * 
+     * @see java.awt.event.ComponentListener#componentHidden(java.awt.event.
+     * ComponentEvent)
+     */
+    public void componentHidden(ComponentEvent e) {
+    }
+
+    /*
+     * (non-Javadoc)
+     * 
+     * @see
+     * java.awt.event.ComponentListener#componentMoved(java.awt.event.ComponentEvent
+     * )
+     */
+    public void componentMoved(ComponentEvent e) {
+    }
+
+    /*
+     * (non-Javadoc)
+     * 
+     * @see java.awt.event.ComponentListener#componentResized(java.awt.event.
+     * ComponentEvent)
+     */
+    public void componentResized(ComponentEvent e) {
+        DefaultMutableTreeNode n;
+        @SuppressWarnings("rawtypes")
+        Enumeration enumeration = m_Root.children();
+
+        while (enumeration.hasMoreElements()) {
+            n = (DefaultMutableTreeNode) enumeration.nextElement();
+
+            if (n.getUserObject() instanceof TocItemBranch) {
+                ITocItem item = (ITocItem) n.getUserObject();
+                Dimension szAnt = item.getSize();
+                item.setSize(new Dimension(this.getWidth() - 40, szAnt.height));
+            }
+
+        }
+    }
+
+    /*
+     * (non-Javadoc)
+     * 
+     * @see
+     * java.awt.event.ComponentListener#componentShown(java.awt.event.ComponentEvent
+     * )
+     */
+    public void componentShown(ComponentEvent e) {
+    }
+
+    /*
+     * (non-Javadoc)
+     * 
+     * @see
+     * com.iver.cit.gvsig.fmap.layers.LayerListener#legendChanged(com.iver.cit
+     * .gvsig.fmap.rendering.LegendChangedEvent)
+     */
+    public void legendChanged(final LegendChangedEvent e) {
+        if (!SwingUtilities.isEventDispatchThread()) {
+            SwingUtilities.invokeLater(new Runnable() {
+
+                public void run() {
+                    legendChanged(e);
+                }
+            });
+            return;
+        }
+        refresh();
+    }
+
+    /*
+     * (non-Javadoc)
+     * 
+     * @see
+     * com.iver.cit.gvsig.fmap.layers.LayerCollectionListener#layerAdded(com
+     * .iver.cit.gvsig.fmap.layers.LayerCollectionEvent)
+     */
+    public void layerAdded(final LayerCollectionEvent e) {
+        if (!SwingUtilities.isEventDispatchThread()) {
+            SwingUtilities.invokeLater(new Runnable() {
+
+                public void run() {
+                    layerAdded(e);
+                }
+            });
+            return;
+        }
+        refresh();
+    }
+
+    /*
+     * (non-Javadoc)
+     * 
+     * @see
+     * com.iver.cit.gvsig.fmap.layers.LayerCollectionListener#layerMoved(com
+     * .iver.cit.gvsig.fmap.layers.LayerPositionEvent)
+     */
+    public void layerMoved(final LayerPositionEvent e) {
+        if (!SwingUtilities.isEventDispatchThread()) {
+            SwingUtilities.invokeLater(new Runnable() {
+
+                public void run() {
+                    layerMoved(e);
+                }
+            });
+            return;
+        }
+        refresh();
+    }
+
+    /*
+     * (non-Javadoc)
+     * 
+     * @see
+     * com.iver.cit.gvsig.fmap.layers.LayerCollectionListener#layerRemoved(com
+     * .iver.cit.gvsig.fmap.layers.LayerCollectionEvent)
+     */
+    public void layerRemoved(final LayerCollectionEvent e) {
+        if (!SwingUtilities.isEventDispatchThread()) {
+            SwingUtilities.invokeLater(new Runnable() {
+
+                public void run() {
+                    layerRemoved(e);
+                }
+            });
+            return;
+        }
+        m_ItemsExpanded.remove(e.getAffectedLayer().getName());
+        refresh();
+    }
+
+    /*
+     * (non-Javadoc)
+     * 
+     * @see
+     * com.iver.cit.gvsig.fmap.layers.LayerCollectionListener#layerAdding(com
+     * .iver.cit.gvsig.fmap.layers.LayerCollectionEvent)
+     */
+    public void layerAdding(LayerCollectionEvent e) throws CancelationException {
+    }
+
+    /*
+     * (non-Javadoc)
+     * 
+     * @see
+     * com.iver.cit.gvsig.fmap.layers.LayerCollectionListener#layerMoving(com
+     * .iver.cit.gvsig.fmap.layers.LayerPositionEvent)
+     */
+    public void layerMoving(LayerPositionEvent e) throws CancelationException {
+    }
+
+    /*
+     * (non-Javadoc)
+     * 
+     * @see
+     * com.iver.cit.gvsig.fmap.layers.LayerCollectionListener#layerRemoving(
+     * com.iver.cit.gvsig.fmap.layers.LayerCollectionEvent)
+     */
+    public void layerRemoving(LayerCollectionEvent e)
+        throws CancelationException {
+    }
+
+    /*
+     * (non-Javadoc)
+     * 
+     * @see
+     * com.iver.cit.gvsig.fmap.layers.LayerCollectionListener#activationChanged
+     * (com.iver.cit.gvsig.fmap.layers.LayerCollectionEvent)
+     */
+    public void activationChanged(LayerCollectionEvent e)
+        throws CancelationException {
+        repaint();
+    }
+
+    /*
+     * (non-Javadoc)
+     * 
+     * @see
+     * com.iver.cit.gvsig.fmap.layers.LayerCollectionListener#visibilityChanged
+     * (com.iver.cit.gvsig.fmap.layers.LayerCollectionEvent)
+     */
+    public void visibilityChanged(final LayerCollectionEvent e)
+        throws CancelationException {
+        if (!SwingUtilities.isEventDispatchThread()) {
+            SwingUtilities.invokeLater(new Runnable() {
+
+                public void run() {
+                    visibilityChanged(e);
+                }
+            });
+            return;
+        }
+        repaint();
+    }
+
+    /*
+     * (non-Javadoc)
+     * 
+     * @see
+     * javax.swing.event.TreeExpansionListener#treeCollapsed(javax.swing.event
+     * .TreeExpansionEvent)
+     */
+    public void treeCollapsed(TreeExpansionEvent event) {
+        TreePath path = event.getPath();
+        DefaultMutableTreeNode n =
+            (DefaultMutableTreeNode) path.getLastPathComponent();
+
+        if (n.getUserObject() instanceof ITocItem) {
+            ITocItem item = (ITocItem) n.getUserObject();
+            Boolean b = Boolean.FALSE;
+
+            m_ItemsExpanded.put(item.getLabel(), b);
+        }
+    }
+
+    /*
+     * (non-Javadoc)
+     * 
+     * @see
+     * javax.swing.event.TreeExpansionListener#treeExpanded(javax.swing.event
+     * .TreeExpansionEvent)
+     */
+    public void treeExpanded(TreeExpansionEvent event) {
+        TreePath path = event.getPath();
+        DefaultMutableTreeNode n =
+            (DefaultMutableTreeNode) path.getLastPathComponent();
+
+        if (n.getUserObject() instanceof ITocItem) {
+            ITocItem item = (ITocItem) n.getUserObject();
+            Boolean b = Boolean.TRUE;
+
+            m_ItemsExpanded.put(item.getLabel(), b);
+        }
+    }
+
+    /**
+     * Obtiene el JScrollPane que contiene el TOC
+     * 
+     * @return JScrollPane que contiene el TOC
+     */
+    public JScrollPane getJScrollPane() {
+        return this.m_Scroller;
+    }
+
+    /**
+     * DOCUMENT ME!
+     * 
+     * @return DOCUMENT ME!
+     */
+    public DnDJTree getTree() {
+        return m_Tree;
+    }
+
+    /**
+     * Clase Listener que reacciona al pulsar sobre el checkbox de un nodo y
+     * crea un popupmenu al pulsar el bot�n derecho.
+     */
+    class NodeSelectionListener extends MouseAdapter implements ActionListener {
+
+        JTree tree;
+
+        JDialog dlg;
+
+        JColorChooser colorChooser;
+
+        FPopupMenu popmenu = null;
+
+        DefaultMutableTreeNode node;
+
+        /**
+         * Crea un nuevo NodeSelectionListener.
+         * 
+         * @param tree
+         *            DOCUMENT ME!
+         */
+        NodeSelectionListener(JTree tree) {
+            this.tree = tree;
+        }
+
+        /**
+         * DOCUMENT ME!
+         * 
+         * @param e
+         *            DOCUMENT ME!
+         */
+        public void mouseClicked(MouseEvent e) {
+            int x = e.getX();
+            int y = e.getY();
+            int row = tree.getRowForLocation(x, y);
+            TreePath path = tree.getPathForRow(row);
+            LayerCollection layers = mapContext.getLayers();
+
+            if (path != null) {
+                if (e.getClickCount() == 1) {
+                    // this fixes a bug when double-clicking. JTree by default
+                    // expands the tree when double-clicking, so we capture a
+                    // different node in the second click than in the first
+                    node = (DefaultMutableTreeNode) path.getLastPathComponent();
+                }
+
+                if (node != null
+                    && node.getUserObject() instanceof TocItemBranch) {
+                    // double click with left button ON A BRANCH/NODE (layer)
+                    if (e.getClickCount() >= 2
+                        && e.getButton() == MouseEvent.BUTTON1) {
+                        e.consume();
+                        PluginServices.getMDIManager().setWaitCursor();
+                        try {
+                            TocItemBranch leaf =
+                                (TocItemBranch) node.getUserObject();
+
+                            IContextMenuAction action =
+                                leaf.getDoubleClickAction();
+                            if (action != null) {
+                                /*
+                                 * if there is an action associated with the
+                                 * double-clicked element it will be fired for
+                                 * it and FOR ALL OTHER COMPATIBLES THAT HAVE
+                                 * BEEN ACTIVATED.
+                                 */
+                                ArrayList<FLayer> targetLayers =
+                                    new ArrayList<FLayer>();
+
+                                TocItemBranch owner =
+                                    (TocItemBranch) node.getUserObject();
+
+                                FLayer masterLayer = owner.getLayer();
+                                targetLayers.add(masterLayer);
+                                FLayer[] actives =
+                                    mapContext.getLayers().getActives();
+                                for (int i = 0; i < actives.length; i++) {
+                                    if (actives[i].getClass().equals(
+                                        masterLayer.getClass())) {
+                                        if (actives[i] instanceof FLyrVect) {
+                                            FLyrVect vectorLayer =
+                                                (FLyrVect) actives[i];
+                                            FLyrVect vectorMaster =
+                                                (FLyrVect) masterLayer;
+                                            if (vectorLayer.getShapeType() == vectorMaster
+                                                .getShapeType()) {
+                                                targetLayers.add(vectorLayer);
+                                            } else {
+                                                vectorLayer.setActive(false);
+                                            }
+                                        }
+                                        // TODO for the rest of layer types
+                                        // (i.e. FLyrRaster)
+                                    } else {
+                                        actives[i].setActive(false);
+                                    }
+                                }
+                                action.execute(leaf,
+                                    targetLayers.toArray(new FLayer[0]));
+                            }
+                        } catch (Exception ex) {
+                            NotificationManager.addError(ex);
+                        } finally {
+                            PluginServices.getMDIManager().restoreCursor();
+                        }
+                        return;
+                    }
+
+                    TocItemBranch elTema = (TocItemBranch) node.getUserObject();
+                    FLayer lyr = elTema.getLayer();
+                    lyr.getMapContext().beginAtomicEvent();
+
+                    if (((e.getModifiers() & InputEvent.SHIFT_MASK) != 0)
+                        && (e.getButton() == MouseEvent.BUTTON1)) {
+                        FLayer[] activeLayers = layers.getActives();
+                        if (activeLayers.length > 0) {
+                            selectInterval(layers, lyr);
+                        } else {
+                            updateActive(lyr, !lyr.isActive());
+                        }
+
+                    } else {
+                        if (!((e.getModifiers() & InputEvent.CTRL_MASK) != 0)
+                            && (e.getButton() == MouseEvent.BUTTON1)) {
+                            layers.setAllActives(false);
+                        }
+                        if (e.getButton() == MouseEvent.BUTTON1) {
+                            // lyr.setActive(true);
+                            updateActive(lyr, !lyr.isActive());
+                        }
+                    }
+                    // Si pertenece a un grupo, lo ponemos activo tambi�n.
+                    // FLayer parentLayer = lyr.getParentLayer();
+
+                    /*
+                     * if (parentLayer != null) { parentLayer.setActive(true); }
+                     */
+                    Point layerNodeLocation =
+                        tree.getUI().getPathBounds(tree, path).getLocation();
+
+                    // Rect�ngulo que representa el checkbox
+                    Rectangle checkBoxBounds =
+                        m_TocRenderer.getCheckBoxBounds();
+                    checkBoxBounds.translate((int) layerNodeLocation.getX(),
+                        (int) layerNodeLocation.getY());
+
+                    if (checkBoxBounds.contains(e.getPoint())) {
+                        updateVisible(lyr);
+                    }
+
+                    // }
+                    if (e.getButton() == MouseEvent.BUTTON3) {
+                        // Boton derecho sobre un nodo del arbol
+                        // if ((e.getModifiers() & InputEvent.META_MASK) != 0) {
+                        popmenu = new FPopupMenu(mapContext, node);
+                        tree.add(popmenu);
+
+                        popmenu.show(e.getComponent(), e.getX(), e.getY());
+
+                        // }
+                    }
+
+                    lyr.getMapContext().endAtomicEvent();
+                }
+
+                if (node != null && node.getUserObject() instanceof TocItemLeaf) {
+                    // double click with left button ON A LEAF (ISymbol)
+                    if (e.getClickCount() >= 2
+                        && e.getButton() == MouseEvent.BUTTON1) {
+                        e.consume();
+
+                        PluginServices.getMDIManager().setWaitCursor();
+                        try {
+                            TocItemLeaf leaf =
+                                (TocItemLeaf) node.getUserObject();
+                            IContextMenuAction action =
+                                leaf.getDoubleClickAction();
+                            if (action != null) {
+                                /*
+                                 * if there is an action associated with the
+                                 * double-clicked element it will be fired for
+                                 * it and FOR ALL OTHER COMPATIBLES THAT HAVE
+                                 * BEEN ACTIVATED.
+                                 */
+                                ArrayList<FLayer> targetLayers =
+                                    new ArrayList<FLayer>();
+
+                                TocItemBranch owner =
+                                    (TocItemBranch) ((DefaultMutableTreeNode) node
+                                        .getParent()).getUserObject();
+
+                                FLayer masterLayer = owner.getLayer();
+                                targetLayers.add(masterLayer);
+                                FLayer[] actives =
+                                    mapContext.getLayers().getActives();
+                                for (int i = 0; i < actives.length; i++) {
+                                    if (actives[i].getClass().equals(
+                                        masterLayer.getClass())) {
+                                        if (actives[i] instanceof FLyrVect) {
+                                            FLyrVect vectorLayer =
+                                                (FLyrVect) actives[i];
+                                            FLyrVect vectorMaster =
+                                                (FLyrVect) masterLayer;
+                                            int masterLayerShapetypeOF_THE_LEGEND =
+                                                ((IVectorLegend) vectorMaster
+                                                    .getLegend())
+                                                    .getShapeType();
+                                            int anotherVectorLayerShapetypeOF_THE_LEGEND =
+                                                ((IVectorLegend) vectorLayer
+                                                    .getLegend())
+                                                    .getShapeType();
+                                            if (masterLayerShapetypeOF_THE_LEGEND == anotherVectorLayerShapetypeOF_THE_LEGEND) {
+                                                targetLayers.add(vectorLayer);
+                                            } else {
+                                                vectorLayer.setActive(false);
+                                            }
+                                        }
+                                        // TODO for the rest of layer types
+                                        // (i.e. FLyrRaster)
+                                    } else {
+                                        actives[i].setActive(false);
+                                    }
+                                }
+                                action.execute(leaf,
+                                    targetLayers.toArray(new FLayer[0]));
+                            }
+                        } catch (Exception ex) {
+                            NotificationManager.addError(ex);
+                        } finally {
+                            PluginServices.getMDIManager().restoreCursor();
+                        }
+                        return;
+                    }
+
+                    // Boton derecho sobre un Simbolo
+                    // TocItemLeaf auxLeaf = (TocItemLeaf) node.getUserObject();
+                    // FSymbol theSym = auxLeaf.getSymbol();
+                    if ((e.getModifiers() & InputEvent.META_MASK) != 0) {
+                        popmenu = new FPopupMenu(mapContext, node);
+                        tree.add(popmenu);
+                        popmenu.show(e.getComponent(), e.getX(), e.getY());
+                    }
+                }
+
+                ((DefaultTreeModel) tree.getModel()).nodeChanged(node);
+
+                if (row == 0) {
+                    tree.revalidate();
+                    tree.repaint();
+                }
+
+                if (PluginServices.getMainFrame() != null) {
+                    PluginServices.getMainFrame().enableControls();
+                }
+            } else {
+                if (e.getButton() == MouseEvent.BUTTON3) {
+                    popmenu = new FPopupMenu(mapContext, null);
+                    tree.add(popmenu);
+                    popmenu.show(e.getComponent(), e.getX(), e.getY());
+                }
+
+            }
+        }
+
+        private void selectInterval(LayerCollection layers, FLayer lyr) {
+            FLayer[] activeLayers = layers.getActives();
+            // if (activeLayers[0].getParentLayer() instanceof FLayers &&
+            // activeLayers[0].getParentLayer().getParentLayer()!=null) {
+            // selectInterval((LayerCollection)activeLayers[0].getParentLayer(),lyr);
+            // }
+            for (int j = 0; j < layers.getLayersCount(); j++) {
+                FLayer layerAux = layers.getLayer(j);
+                // Si se cumple esta condici�n es porque la primera capa que nos
+                // encontramos en el TOC es la que estaba activa
+                if (activeLayers[0].equals(layerAux)) {
+                    boolean isSelected = false;
+                    for (int i = 0; i < layers.getLayersCount(); i++) {
+                        FLayer layer = layers.getLayer(i);
+                        if (!isSelected) {
+                            isSelected = layer.isActive();
+                        } else {
+                            updateActive(layer, true);
+                            if (lyr.equals(layer)) {
+                                isSelected = false;
+                            }
+                        }
+                    }
+                    break;
+                } else
+                    // Si se cumple esta condici�n es porque la primera capa que
+                    // nos
+                    // encontramos en el TOC es la que acabamos de seleccionar
+                    if (lyr.equals(layerAux)) {
+                        boolean isSelected = false;
+                        for (int i = layers.getLayersCount() - 1; i >= 0; i--) {
+                            FLayer layer = layers.getLayer(i);
+                            if (!isSelected) {
+                                isSelected = layer.isActive();
+                            } else {
+                                updateActive(layer, true);
+                                if (lyr.equals(layer)) {
+                                    isSelected = false;
+                                }
+                            }
+                        }
+                        break;
+                    }
+            }
+
+        }
+
+        /**
+         * DOCUMENT ME!
+         * 
+         * @param lyr
+         *            DOCUMENT ME!
+         * @param active
+         *            DOCUMENT ME!
+         */
+        private void updateActive(FLayer lyr, boolean active) {
+            lyr.setActive(active);
+            updateActiveChild(lyr);
+        }
+
+        /**
+         * DOCUMENT ME!
+         * 
+         * @param lyr
+         *            DOCUMENT ME!
+         */
+        private void updateActiveChild(FLayer lyr) {
+            if (lyr instanceof FLayers) { // Es la raiz de una rama o
+                // cualquier nodo intermedio.
+
+                FLayers layergroup = (FLayers) lyr;
+
+                for (int i = 0; i < layergroup.getLayersCount(); i++) {
+                    layergroup.getLayer(i).setActive(lyr.isActive());
+                    updateActiveChild(layergroup.getLayer(i));
+                }
+            }
+        }
+
+        /**
+         * Actualiza la visibilidad de la capas.
+         * 
+         * @param lyr
+         *            Capa sobre la que se est� clickando.
+         */
+        private void updateVisible(FLayer lyr) {
+            if (lyr.isAvailable()) {
+                lyr.setVisible(!lyr.visibleRequired());
+                updateVisibleChild(lyr);
+                updateVisibleParent(lyr);
+            }
+        }
+
+        /**
+         * Actualiza de forma recursiva la visibilidad de los hijos de la capa
+         * que se pasa como par�metro.
+         * 
+         * @param lyr
+         *            Capa a actualizar.
+         */
+        private void updateVisibleChild(FLayer lyr) {
+            if (lyr instanceof FLayers) { // Es la raiz de una rama o
+                                          // cualquier nodo intermedio.
+
+                FLayers layergroup = (FLayers) lyr;
+
+                for (int i = 0; i < layergroup.getLayersCount(); i++) {
+                    layergroup.getLayer(i).setVisible(lyr.visibleRequired());
+                    updateVisibleChild(layergroup.getLayer(i));
+                }
+            }
+        }
+
+        /**
+         * Actualiza de forma recursiva la visibilidad del padre de la capa que
+         * se pasa como par�metro.
+         * 
+         * @param lyr
+         *            Capa a actualizar.
+         */
+        private void updateVisibleParent(FLayer lyr) {
+            FLayers parent = lyr.getParentLayer();
+
+            if (parent != null) {
+                boolean parentVisible = false;
+
+                for (int i = 0; i < parent.getLayersCount(); i++) {
+                    if (parent.getLayer(i).visibleRequired()) {
+                        parentVisible = true;
+                    }
+                }
+
+                parent.setVisible(parentVisible);
+                updateVisibleParent(parent);
+            }
+        }
+
+        /**
+         * DOCUMENT ME!
+         * 
+         * @param arg0
+         *            DOCUMENT ME!
+         */
+        public void actionPerformed(ActionEvent arg0) {
+        }
+
+        /**
+         * DOCUMENT ME!
+         * 
+         * @param arg0
+         *            DOCUMENT ME!
+         */
+        public void mouseReleased(MouseEvent arg0) {
+            super.mouseReleased(arg0);
+        }
+
+        /**
+         * DOCUMENT ME!
+         * 
+         * @param arg0
+         *            DOCUMENT ME!
+         */
+        public void mouseEntered(MouseEvent arg0) {
+            super.mouseEntered(arg0);
+        }
+    }
+    
+    private boolean invisibilityIsForced() {
+        
+        PluginServices ps = PluginServices.getPluginServices(this);
+        XMLEntity xml = ps.getPersistentXML();
+
+        if (xml.contains(ViewPage.ADD_NEW_LAYERS_IN_INVISIBLE_MODE_KEY_NAME)) {
+            // Get invisibility value
+            return xml.getBooleanProperty(ViewPage.ADD_NEW_LAYERS_IN_INVISIBLE_MODE_KEY_NAME);
+        } else {
+            // not found in preferences
+            return false;
+        }
+    }
+
+}

Property changes on: tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/app/project/documents/view/toc/gui/TOC.java
___________________________________________________________________
Added: svn:keywords
   + Author Date Id Revision
Added: svn:eol-style
   + native

Index: tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/app/project/documents/view/toc/gui/ChangeName.java
===================================================================
--- tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/app/project/documents/view/toc/gui/ChangeName.java	(revision 0)
+++ tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/app/project/documents/view/toc/gui/ChangeName.java	(revision 38653)
@@ -0,0 +1,222 @@
+/* gvSIG. Desktop Geographic Information System.
+ *
+ * Copyright � 2007-2012 gvSIG Association
+ *
+ * This program is free software; you can redistribute it and/or
+ * modify it under the terms of the GNU General Public License
+ * as published by the Free Software Foundation; either version 2
+ * of the License, or (at your option) any later version.
+ *
+ * This program is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
+ * GNU General Public License for more details.
+ *
+ * You should have received a copy of the GNU General Public License
+ * along with this program; if not, write to the Free Software
+ * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston,
+ * MA  02110-1301, USA.
+ *
+ * For any additional information, do not hesitate to contact us
+ * at info AT gvsig.com, or visit our website www.gvsig.com.
+ */
+package org.gvsig.app.project.documents.view.toc.gui;
+
+import java.awt.Dimension;
+import java.awt.GridBagConstraints;
+import java.awt.GridBagLayout;
+import java.awt.Insets;
+import java.awt.event.ActionListener;
+import java.awt.event.KeyEvent;
+import java.awt.event.KeyListener;
+
+import javax.swing.BorderFactory;
+import javax.swing.JLabel;
+import javax.swing.JPanel;
+import javax.swing.JTextField;
+
+import org.gvsig.andami.PluginServices;
+import org.gvsig.andami.ui.mdiManager.IWindow;
+import org.gvsig.andami.ui.mdiManager.WindowInfo;
+import org.gvsig.gui.beans.AcceptCancelPanel;
+import org.gvsig.i18n.Messages;
+
+/**
+ * Di�logo para cambiar el nombre de una capa.
+ * 
+ * @author Vicente Caballero Navarro
+ * @author gvSIG Team
+ */
+public class ChangeName extends JPanel implements IWindow {
+
+    private static final long serialVersionUID = -1366865045507066336L;
+    private JLabel lblName = null;
+    private JTextField txtName = null;
+    private String name;
+    private AcceptCancelPanel jPanelAcceptCancel = null;
+    private boolean isAccepted = false;
+
+    /**
+     * This is the default constructor
+     * 
+     * @param layout
+     *            Referencia al Layout.
+     * @param fframe
+     *            Referencia al fframe de imagen.
+     */
+    public ChangeName(String n) {
+        super();
+        if (n == null) {
+            name = PluginServices.getText(this, "agrupacion");
+        } else {
+            name = n;
+        }
+        initialize();
+    }
+
+    /**
+     * This method initializes this
+     */
+    private void initialize() {
+        setLayout(new GridBagLayout());
+        setBorder(BorderFactory.createEmptyBorder(4, 5, 4, 5));
+
+        GridBagConstraints c = new GridBagConstraints();
+        c.insets = new Insets(2, 5, 2, 5);
+        c.gridy = -1;
+
+        c.anchor = GridBagConstraints.WEST;
+        c.weightx = 0.0d;
+        c.gridx = 0;
+        c.gridy++;
+        add(getLblName(), c);
+
+        c.fill = GridBagConstraints.HORIZONTAL;
+        c.weightx = 1.0d;
+        c.gridx = 1;
+        add(getTxtName(), c);
+
+        c.anchor = GridBagConstraints.EAST;
+        c.gridx = 0;
+        c.gridwidth = 2;
+        c.gridy++;
+        c.weightx = 1.0d;
+        add(getJPanelAcceptCancel(), c);
+    }
+
+    /**
+     * This method initializes lFichero
+     * 
+     * @return javax.swing.JLabel
+     */
+    private JLabel getLblName() {
+        if (lblName == null) {
+            lblName = new JLabel(Messages.getText("nombre"));
+        }
+
+        return lblName;
+    }
+
+    /**
+     * This method initializes tFichero
+     * 
+     * @return javax.swing.JTextField
+     */
+    private JTextField getTxtName() {
+        if (txtName == null) {
+            txtName = new JTextField(name, 20);
+            txtName.addKeyListener(new KeyListener() {
+
+                public void keyPressed(KeyEvent e) {
+                    if (e.getKeyCode() == KeyEvent.VK_ENTER) {
+                        acceptAction();
+                    } else
+                        if (e.getKeyCode() == KeyEvent.VK_ESCAPE) {
+                            cancelAction();
+                        }
+                }
+
+                public void keyReleased(KeyEvent e) {
+                    // Nothing to do
+                }
+
+                public void keyTyped(KeyEvent e) {
+                    // Nothing to do
+                }
+
+            });
+        }
+        return txtName;
+    }
+
+    /**
+     * Inserta el path al TFichero.
+     * 
+     * @param val
+     *            path del fichero.
+     */
+    public void setText(String val) {
+        getTxtName().setText(val);
+    }
+
+    public WindowInfo getWindowInfo() {
+        WindowInfo m_viewinfo = new WindowInfo(WindowInfo.MODALDIALOG);
+        m_viewinfo.setTitle(Messages.getText("cambio_nombre"));
+        Dimension dim = getPreferredSize();
+        m_viewinfo.setWidth(dim.width);
+        m_viewinfo.setHeight(dim.height);
+        return m_viewinfo;
+    }
+
+    public String getName() {
+        return name;
+    }
+
+    /**
+     * This method initializes jPanel1
+     * 
+     * @return javax.swing.JPanel
+     */
+    private AcceptCancelPanel getJPanelAcceptCancel() {
+        if (jPanelAcceptCancel == null) {
+            ActionListener okActionListener, cancelActionListener;
+            okActionListener = new java.awt.event.ActionListener() {
+
+                public void actionPerformed(java.awt.event.ActionEvent e) {
+                    acceptAction();
+                }
+            };
+            cancelActionListener = new java.awt.event.ActionListener() {
+
+                public void actionPerformed(java.awt.event.ActionEvent e) {
+                    cancelAction();
+                }
+            };
+            jPanelAcceptCancel =
+                new AcceptCancelPanel(okActionListener, cancelActionListener);
+        }
+        return jPanelAcceptCancel;
+    }
+
+    public boolean isAccepted() {
+        return isAccepted;
+    }
+
+    protected void acceptAction() {
+        name = getTxtName().getText();
+        isAccepted = true;
+        PluginServices.getMDIManager().closeWindow(ChangeName.this);
+
+    }
+
+    protected void cancelAction() {
+        isAccepted = false;
+        PluginServices.getMDIManager().closeWindow(ChangeName.this);
+
+    }
+
+    public Object getWindowProfile() {
+        return WindowInfo.DIALOG_PROFILE;
+    }
+
+}

Property changes on: tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/app/project/documents/view/toc/gui/ChangeName.java
___________________________________________________________________
Added: svn:eol-style
   + native
Added: svn:keywords
   + Author Date Id Revision

Index: tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/app/project/documents/view/toc/TocItemLeaf.java
===================================================================
--- tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/app/project/documents/view/toc/TocItemLeaf.java	(revision 0)
+++ tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/app/project/documents/view/toc/TocItemLeaf.java	(revision 38653)
@@ -0,0 +1,250 @@
+/*
+ * Created on 03-dic-2004
+ *
+ * TODO To change the template for this generated file go to
+ * Window - Preferences - Java - Code Generation - Code and Comments
+ */
+/* gvSIG. Sistema de Informaci�n Geogr�fica de la Generalitat Valenciana
+ *
+ * Copyright (C) 2004 IVER T.I. and Generalitat Valenciana.
+ *
+ * This program is free software; you can redistribute it and/or
+ * modify it under the terms of the GNU General Public License
+ * as published by the Free Software Foundation; either version 2
+ * of the License, or (at your option) any later version.
+ *
+ * This program is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
+ * GNU General Public License for more details.
+ *
+ * You should have received a copy of the GNU General Public License
+ * along with this program; if not, write to the Free Software
+ * Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA  02111-1307,USA.
+ *
+ * For more information, contact:
+ *
+ *  Generalitat Valenciana
+ *   Conselleria d'Infraestructures i Transport
+ *   Av. Blasco Ib��ez, 50
+ *   46010 VALENCIA
+ *   SPAIN
+ *
+ *      +34 963862235
+ *   gvsig@gva.es
+ *      www.gvsig.gva.es
+ *
+ *    or
+ *
+ *   IVER T.I. S.A
+ *   Salamanca 50
+ *   46005 Valencia
+ *   Spain
+ *
+ *   +34 963163400
+ *   dac@iver.es
+ */
+package org.gvsig.app.project.documents.view.toc;
+
+import java.awt.Dimension;
+import java.awt.Graphics2D;
+import java.awt.Image;
+import java.awt.Rectangle;
+import java.awt.datatransfer.DataFlavor;
+import java.awt.datatransfer.UnsupportedFlavorException;
+import java.awt.geom.AffineTransform;
+import java.awt.image.BufferedImage;
+import java.io.IOException;
+
+import javax.swing.Icon;
+import javax.swing.ImageIcon;
+
+import org.gvsig.andami.PluginServices;
+import org.gvsig.app.project.documents.view.IContextMenuAction;
+import org.gvsig.app.project.documents.view.toc.actions.ChangeSymbolTocMenuEntry;
+import org.gvsig.fmap.geom.Geometry;
+import org.gvsig.fmap.mapcontext.MapContextLocator;
+import org.gvsig.fmap.mapcontext.rendering.symbols.ISymbol;
+import org.gvsig.fmap.mapcontext.rendering.symbols.SymbolDrawingException;
+
+
+/**
+ * @author FJP
+ *
+ * TODO To change the template for this generated type comment go to
+ * Window - Preferences - Java - Code Generation - Code and Comments
+ */
+public class TocItemLeaf implements ITocItem {
+
+	private ISymbol symbol;
+	private String description;
+	private int layerType;
+	private static int w_1symbol = 20;
+	private static int h_1symbol = 15;
+
+	private Dimension sz;
+	BufferedImage imgLegend = null;
+
+    final public static DataFlavor INFO_FLAVOR =
+	    new DataFlavor(TocItemLeaf.class, "ItemLeaf");
+
+	static DataFlavor flavors[] = {INFO_FLAVOR };
+
+
+	public TocItemLeaf(ISymbol symbol, String description, int layerType)
+	{
+		this.symbol = symbol;
+		this.description = description;
+		this.layerType = layerType;
+	}
+	public TocItemLeaf()
+	{
+
+	}
+	public void setImageLegend(Image imageLegend, String descrip, Dimension size)
+	{
+		this.description = descrip;
+		this.sz = size;
+		imgLegend = new BufferedImage(sz.width, sz.height, BufferedImage.TYPE_INT_ARGB);
+		Graphics2D g2 = imgLegend.createGraphics();
+		// Rectangle r = new Rectangle(sz.width, sz.height);
+		// TODO: Calcular ratio
+
+		double ratioImage =  (double) imageLegend.getWidth(null) / (double) imageLegend.getHeight(null);
+	    double ratioToc  = (double) sz.width / (double) sz.height;
+
+	    boolean resul = g2.drawImage(imageLegend, 0, 0, sz.width, sz.height, null);
+//		if (ratioImage > ratioToc) {
+//			int newHeight = (int) (sz.width / ratioImage);
+//			boolean resul = g2.drawImage(imageLegend, 0, 0, sz.width, newHeight, null);
+//		} else {
+//			int newWidth = (int) (sz.height * ratioImage);
+//			boolean resul = g2.drawImage(imageLegend, 0, 0, newWidth, sz.height, null);
+//		}
+
+	}
+	/* (non-Javadoc)
+	 * @see com.iver.cit.gvsig.gui.toc.ITocItem#getLabel()
+	 */
+	public String getLabel() {
+		return description;
+	}
+
+	/* (non-Javadoc)
+	 * @see com.iver.cit.gvsig.gui.toc.ITocItem#getIcon()
+	 */
+	public Icon getIcon() {
+		// System.out.println("Dentro de getIcon: layerType=" + layerType);
+		if (imgLegend != null)
+		{
+//			Graphics2D g2 = imgLegend.createGraphics();
+//			g2.drawString("Prueba", 10, 20);
+			return new ImageIcon(imgLegend);
+		}
+
+		BufferedImage img = null;
+		Graphics2D g2 = null;
+		Rectangle r = null;
+
+		switch (layerType)
+		{
+			case Geometry.TYPES.POINT:
+			case Geometry.TYPES.CURVE:
+			case Geometry.TYPES.SURFACE:
+			case Geometry.TYPES.MULTICURVE:
+			case Geometry.TYPES.MULTISURFACE:
+			case Geometry.TYPES.MULTIPOINT:
+				img = new BufferedImage(w_1symbol, h_1symbol, BufferedImage.TYPE_INT_ARGB);
+				g2 = img.createGraphics();
+				r = new Rectangle(w_1symbol, h_1symbol);
+
+//				// TODO: CAMBIAR PARA QUE NO DEPENDA DE FSYMBOL
+//				if (symbol instanceof FSymbol)
+//					FGraphicUtilities.DrawSymbol(g2, AffineTransform.getScaleInstance(0.8,0.8), r, (FSymbol) symbol);
+//				// Por ahora, los que no sean FSymbol no se renderizan en el TOC.
+				break;
+			case Geometry.TYPES.GEOMETRY:
+				img = new BufferedImage(3*w_1symbol, h_1symbol, BufferedImage.TYPE_INT_ARGB);
+				g2 = img.createGraphics();
+				r = new Rectangle(3*w_1symbol, h_1symbol);
+//				if (symbol instanceof FSymbol)
+//					FGraphicUtilities.DrawSymbol(g2, AffineTransform.getScaleInstance(0.8,0.8), r, (FSymbol) symbol);
+				break;
+
+		}
+
+		if (g2 == null) {
+			return null;//TODO tipo de shape no soportado.
+		}
+		try {
+			symbol.drawInsideRectangle(g2, AffineTransform.getScaleInstance(1,1), r,null);
+		} catch (SymbolDrawingException e) {
+			if (e.getType() == SymbolDrawingException.UNSUPPORTED_SET_OF_SETTINGS) {
+				try {
+					MapContextLocator.getSymbolManager()
+							.getWarningSymbol(
+									SymbolDrawingException.STR_UNSUPPORTED_SET_OF_SETTINGS,
+									symbol.getDescription(),
+									SymbolDrawingException.UNSUPPORTED_SET_OF_SETTINGS)
+							.drawInsideRectangle(g2, g2.getTransform(),
+									r.getBounds(), null);
+				} catch (SymbolDrawingException e1) {
+					// IMPOSSIBLE TO REACH THIS
+				}
+			} else {
+				// should be unreachable code
+				throw new Error(PluginServices.getText(this, "symbol_shapetype_mismatch"));
+			}
+		}
+		return new ImageIcon(img);
+	}
+
+	/* (non-Javadoc)
+	 * @see java.awt.datatransfer.Transferable#getTransferDataFlavors()
+	 */
+	public DataFlavor[] getTransferDataFlavors() {
+		return flavors;
+	}
+
+	/* (non-Javadoc)
+	 * @see java.awt.datatransfer.Transferable#isDataFlavorSupported(java.awt.datatransfer.DataFlavor)
+	 */
+	public boolean isDataFlavorSupported(DataFlavor dF) {
+		return dF.equals(INFO_FLAVOR);
+	}
+
+	/* (non-Javadoc)
+	 * @see java.awt.datatransfer.Transferable#getTransferData(java.awt.datatransfer.DataFlavor)
+	 */
+	public Object getTransferData(DataFlavor dF) throws UnsupportedFlavorException, IOException {
+	    if (dF.equals(INFO_FLAVOR)) {
+	        return this;
+	      } else {
+			throw new UnsupportedFlavorException(dF);
+		}
+	}
+	/* (non-Javadoc)
+	 * @see com.iver.cit.gvsig.gui.toc.ITocItem#getSize()
+	 */
+	public Dimension getSize() {
+		return sz;
+	}
+	/* (non-Javadoc)
+	 * @see com.iver.cit.gvsig.gui.toc.ITocItem#setSize(java.awt.Dimension)
+	 */
+	public void setSize(Dimension sz) {
+		this.sz = sz;
+
+	}
+
+
+	/**
+	 * @return Returns the symbol.
+	 */
+	public ISymbol getSymbol() {
+		return symbol;
+	}
+	public IContextMenuAction getDoubleClickAction() {
+		return new ChangeSymbolTocMenuEntry();
+	}
+}

Property changes on: tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/app/project/documents/view/toc/TocItemLeaf.java
___________________________________________________________________
Added: svn:keywords
   + Author Date Id Revision
Added: svn:eol-style
   + native

Index: tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/app/project/documents/view/toc/TocMenuEntry.java
===================================================================
--- tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/app/project/documents/view/toc/TocMenuEntry.java	(revision 0)
+++ tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/app/project/documents/view/toc/TocMenuEntry.java	(revision 38653)
@@ -0,0 +1,108 @@
+/*
+ * Created on 20-dic-2004
+ *
+ * gvSIG. Sistema de Informaci�n Geogr�fica de la Generalitat Valenciana
+ *
+ * Copyright (C) 2004 IVER T.I. and Generalitat Valenciana.
+ *
+ * This program is free software; you can redistribute it and/or
+ * modify it under the terms of the GNU General Public License
+ * as published by the Free Software Foundation; either version 2
+ * of the License, or (at your option) any later version.
+ *
+ * This program is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
+ * GNU General Public License for more details.
+ *
+ * You should have received a copy of the GNU General Public License
+ * along with this program; if not, write to the Free Software
+ * Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA  02111-1307,USA.
+ *
+ * For more information, contact:
+ *
+ *  Generalitat Valenciana
+ *   Conselleria d'Infraestructures i Transport
+ *   Av. Blasco Ib��ez, 50
+ *   46010 VALENCIA
+ *   SPAIN
+ *
+ *      +34 963862235
+ *   gvsig@gva.es
+ *      www.gvsig.gva.es
+ *
+ *    or
+ *
+ *   IVER T.I. S.A
+ *   Salamanca 50
+ *   46005 Valencia
+ *   Spain
+ *
+ *   +34 963163400
+ *   dac@iver.es
+ */
+package org.gvsig.app.project.documents.view.toc;
+
+import java.awt.event.ActionEvent;
+import java.awt.event.ActionListener;
+
+import org.gvsig.app.project.documents.view.toc.gui.FPopupMenu;
+import org.gvsig.fmap.mapcontext.MapContext;
+import org.gvsig.fmap.mapcontext.layers.FLayer;
+
+
+/**
+ * @author Luis W. Sevilla (sevilla_lui@gva.es)�
+ * @deprecated
+ */
+public abstract class TocMenuEntry implements ActionListener {
+	private FPopupMenu menu;
+	//private Class [] layerTypes = null;
+	public TocMenuEntry() {
+	}
+
+	/**
+	 * Se utiliza para inicializar el menu. Dentro comprobar�
+	 * encima de qu� tipo de tocItem hemos pinchado, y se
+	 * mostrar� la opci�n de menu o no en funci�n de si
+	 * es un branch o un leaf, o incluso de alg�n otro
+	 * par�metro interno.
+	 * @param menu
+	 */
+	public void initialize(FPopupMenu m) {
+		menu = m;
+	}
+
+	/**
+	 * C�digo que se ejecuta cuando selecciona una opci�n
+	 * de menu. Recibe el tocItem sobre el que has pinchado.
+	 * @param tocItem
+	 */
+	public abstract void actionPerformed(ActionEvent e);
+
+	public FPopupMenu getMenu() { return menu; }
+
+	public MapContext getMapContext() {
+		return menu.getMapContext();
+	}
+	public Object getNodeUserObject() {
+		if (menu.getNode() == null) {
+			return null;
+		}
+		return menu.getNode().getUserObject();
+	}
+
+	public FLayer getNodeLayer() {
+		if (isTocItemBranch()) {
+			return ((TocItemBranch) getNodeUserObject()).getLayer();
+		}
+		return null;
+	}
+	public boolean isTocItemLeaf() {
+		return getNodeUserObject() instanceof TocItemLeaf;
+	}
+
+	public boolean isTocItemBranch() {
+		return getNodeUserObject() instanceof TocItemBranch;
+	}
+}

Property changes on: tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/app/project/documents/view/toc/TocMenuEntry.java
___________________________________________________________________
Added: svn:keywords
   + Author Date Id Revision
Added: svn:eol-style
   + native

Index: tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/app/project/documents/view/toc/ITocItem.java
===================================================================
--- tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/app/project/documents/view/toc/ITocItem.java	(revision 0)
+++ tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/app/project/documents/view/toc/ITocItem.java	(revision 38653)
@@ -0,0 +1,72 @@
+/*
+ * Created on 03-dic-2004
+ *
+ * TODO To change the template for this generated file go to
+ * Window - Preferences - Java - Code Generation - Code and Comments
+ */
+/* gvSIG. Sistema de Informaci�n Geogr�fica de la Generalitat Valenciana
+ *
+ * Copyright (C) 2004 IVER T.I. and Generalitat Valenciana.
+ *
+ * This program is free software; you can redistribute it and/or
+ * modify it under the terms of the GNU General Public License
+ * as published by the Free Software Foundation; either version 2
+ * of the License, or (at your option) any later version.
+ *
+ * This program is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
+ * GNU General Public License for more details.
+ *
+ * You should have received a copy of the GNU General Public License
+ * along with this program; if not, write to the Free Software
+ * Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA  02111-1307,USA.
+ *
+ * For more information, contact:
+ *
+ *  Generalitat Valenciana
+ *   Conselleria d'Infraestructures i Transport
+ *   Av. Blasco Ib��ez, 50
+ *   46010 VALENCIA
+ *   SPAIN
+ *
+ *      +34 963862235
+ *   gvsig@gva.es
+ *      www.gvsig.gva.es
+ *
+ *    or
+ *
+ *   IVER T.I. S.A
+ *   Salamanca 50
+ *   46005 Valencia
+ *   Spain
+ *
+ *   +34 963163400
+ *   dac@iver.es
+ */
+package org.gvsig.app.project.documents.view.toc;
+
+import java.awt.Dimension;
+import java.awt.datatransfer.Transferable;
+
+import javax.swing.Icon;
+
+import org.gvsig.app.project.documents.view.IContextMenuAction;
+
+
+/**
+ * @author FJP
+ * Siguiendo el Patr�n COMPOSITE: la rama ser� la capa (FLayer) y la
+ * hoja ser� el s�mbolo (FStyle2D)
+ *
+ * TODO To change the template for this generated type comment go to
+ * Window - Preferences - Java - Code Generation - Code and Comments
+ */
+public interface ITocItem extends Transferable {
+	String getLabel();
+	Icon getIcon();
+	Dimension getSize();
+	void setSize(Dimension sz);
+	public IContextMenuAction getDoubleClickAction();
+	
+}

Property changes on: tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/app/project/documents/view/toc/ITocItem.java
___________________________________________________________________
Added: svn:eol-style
   + native
Added: svn:keywords
   + Author Date Id Revision

Index: tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/app/project/documents/view/toc/DnDJTree.java
===================================================================
--- tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/app/project/documents/view/toc/DnDJTree.java	(revision 0)
+++ tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/app/project/documents/view/toc/DnDJTree.java	(revision 38653)
@@ -0,0 +1,607 @@
+/*
+ * Created on 02-jun-2004
+ *
+ */
+/* gvSIG. Sistema de Informaci�n Geogr�fica de la Generalitat Valenciana
+ *
+ * Copyright (C) 2004 IVER T.I. and Generalitat Valenciana.
+ *
+ * This program is free software; you can redistribute it and/or
+ * modify it under the terms of the GNU General Public License
+ * as published by the Free Software Foundation; either version 2
+ * of the License, or (at your option) any later version.
+ *
+ * This program is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
+ * GNU General Public License for more details.
+ *
+ * You should have received a copy of the GNU General Public License
+ * along with this program; if not, write to the Free Software
+ * Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA  02111-1307,USA.
+ *
+ * For more information, contact:
+ *
+ *  Generalitat Valenciana
+ *   Conselleria d'Infraestructures i Transport
+ *   Av. Blasco Ib��ez, 50
+ *   46010 VALENCIA
+ *   SPAIN
+ *
+ *      +34 963862235
+ *   gvsig@gva.es
+ *      www.gvsig.gva.es
+ *
+ *    or
+ *
+ *   IVER T.I. S.A
+ *   Salamanca 50
+ *   46005 Valencia
+ *   Spain
+ *
+ *   +34 963163400
+ *   dac@iver.es
+ */
+package org.gvsig.app.project.documents.view.toc;
+/*
+**  This is version II of DnDJTree. The first version allowed for what I
+**  thought was a JDK oversight. However, we can set the cursor appropriately,
+**  relative to whether the current cursor location is a valid drop target.
+**
+**  If this is your first time reading the source code. Just ignore the above
+**  comment and ignore the "CHANGED" comments below. Otherwise, the
+**  "CHANGED" comments will show where the code has changed.
+**
+**  Credit for finding this shortcoming in my code goes Laurent Hubert.
+**  Thanks Laurent.
+**
+**  Rob. [ rkenworthy@hotmail.com ]
+*/
+
+
+import java.awt.Point;
+import java.awt.datatransfer.Transferable;
+import java.awt.datatransfer.UnsupportedFlavorException;
+import java.awt.dnd.DnDConstants;
+import java.awt.dnd.DragGestureEvent;
+import java.awt.dnd.DragGestureListener;
+import java.awt.dnd.DragGestureRecognizer;
+import java.awt.dnd.DragSource;
+import java.awt.dnd.DragSourceDragEvent;
+import java.awt.dnd.DragSourceDropEvent;
+import java.awt.dnd.DragSourceEvent;
+import java.awt.dnd.DragSourceListener;
+import java.awt.dnd.DropTarget;
+import java.awt.dnd.DropTargetDragEvent;
+import java.awt.dnd.DropTargetDropEvent;
+import java.awt.dnd.DropTargetEvent;
+import java.awt.dnd.DropTargetListener;
+import java.awt.dnd.MouseDragGestureRecognizer;
+import java.awt.event.InputEvent;
+import java.awt.event.MouseEvent;
+import java.io.IOException;
+import java.util.ArrayList;
+
+import javax.swing.JTree;
+import javax.swing.SwingUtilities;
+import javax.swing.event.TreeSelectionEvent;
+import javax.swing.event.TreeSelectionListener;
+import javax.swing.tree.DefaultMutableTreeNode;
+import javax.swing.tree.DefaultTreeModel;
+import javax.swing.tree.MutableTreeNode;
+import javax.swing.tree.TreeModel;
+import javax.swing.tree.TreeNode;
+import javax.swing.tree.TreePath;
+
+import org.gvsig.andami.PluginServices;
+import org.gvsig.app.project.documents.view.gui.DefaultViewPanel;
+import org.gvsig.fmap.mapcontext.layers.FLayer;
+import org.gvsig.fmap.mapcontext.layers.FLayers;
+
+
+public class DnDJTree extends JTree
+                  implements TreeSelectionListener,
+                  DragGestureListener, DropTargetListener,
+                  DragSourceListener {
+
+  protected ArrayList m_Listeners = new ArrayList();
+
+  private static DnDJTree oDnDtocOrigin = null;
+  private static DnDJTree oDnDtocDestination = null;
+  /** Stores the parent Frame of the component */
+  // private Frame Parent = null;
+
+  /** Stores the selected node info */
+  protected TreePath SelectedTreePath = null;
+  protected DefaultMutableTreeNode SelectedNode = null;
+
+  /** Variables needed for DnD */
+  private DragSource dragSource = null;
+  //private DragSourceContext dragSourceContext = null;
+  private DropTarget dropTarget;
+  //private ArrayList treeListeners=new ArrayList();
+  //private ArrayList dropListeners=new ArrayList();
+ // private TreeModel model1;
+  /** Constructor
+  @param root The root node of the tree
+  @param parent Parent JFrame of the JTree */
+  public DnDJTree(TreeModel treeModel) {
+    super(treeModel);
+    // Parent = parent;
+
+    //addTreeSelectionListener(this);
+
+		/* ********************** CHANGED ********************** */
+    dragSource = DragSource.getDefaultDragSource() ;
+		/* ****************** END OF CHANGE ******************** */
+
+    DragGestureRecognizer dgr =
+      dragSource.createDefaultDragGestureRecognizer(
+        this,                             //DragSource
+        DnDConstants.ACTION_COPY_OR_MOVE, //specifies valid actions
+        this                              //DragGestureListener
+      );
+
+
+    /* Eliminates right mouse clicks as valid actions - useful especially
+     * if you implement a JPopupMenu for the JTree
+     */
+    dgr.setSourceActions(dgr.getSourceActions() & ~InputEvent.BUTTON3_MASK);
+
+    /* First argument:  Component to associate the target with
+     * Second argument: DropTargetListener
+    */
+    //DropTarget dropTarget = new DropTarget(this, this);
+    setDropTarget();
+  }
+  public void invalidateListeners(){
+	  removeDropListener();
+	  removeTreeListener();
+  }
+  private void addDropListener(){
+	  dropTarget= new DropTarget(this, this);
+  }
+  private void removeDropListener(){
+	  dropTarget=null;
+  }
+  private void addTreeListener(){
+	  addTreeSelectionListener(this);
+  }
+  private void removeTreeListener(){
+	  removeTreeSelectionListener(this);
+  }
+  public void setDropTarget(){
+      // TODO: COMENTADO POR FJP
+	  /* com.iver.andami.ui.mdiManager.View[] views=PluginServices.getMDIManager().getAllViews();
+	  for(int i=0;i<views.length;i++){
+		  if (views[i] instanceof View){
+			 // model1=((View)views[i]).getTOC().getTree().getModel();
+			  ((View)views[i]).getTOC().getTree().removeTreeListener();
+			  ((View)views[i]).getTOC().getTree().addTreeListener();
+			  ((View)views[i]).getTOC().getTree().removeDropListener();
+			  ((View)views[i]).getTOC().getTree().addDropListener();
+		  } */
+		  addTreeListener();
+		  addDropListener();
+	  // }
+	 ////////// new DropTarget(this, this);
+  }
+  /** Returns The selected node */
+  public DefaultMutableTreeNode getSelectedNode() {
+    return SelectedNode;
+  }
+
+  ///////////////////////// Interface stuff ////////////////////
+
+
+  /** DragGestureListener interface method */
+  public void dragGestureRecognized(DragGestureEvent e) {
+	  if (((MouseEvent)((MouseDragGestureRecognizer)e.getSource()).getTriggerEvent()).getButton()==MouseEvent.BUTTON3){
+		  return;
+	  }
+    //Get the selected node
+    DefaultMutableTreeNode dragNode = getSelectedNode();
+    if (dragNode != null) {
+
+
+      if (!(dragNode.getUserObject() instanceof Transferable)) {
+		return;
+	}
+
+//    Get the Transferable Object
+      Transferable transferable = (Transferable) dragNode.getUserObject();
+
+			/* ********************** CHANGED ********************** */
+
+      //Select the appropriate cursor;
+      // Cursor cursor = DragSource.DefaultCopyNoDrop;
+      int action = e.getDragAction();
+      /* if (action == DnDConstants.ACTION_MOVE)
+        cursor = DragSource.DefaultMoveDrop; */
+
+
+      //In fact the cursor is set to NoDrop because once an action is rejected
+      // by a dropTarget, the dragSourceListener are no more invoked.
+      // Setting the cursor to no drop by default is so more logical, because
+      // when the drop is accepted by a component, then the cursor is changed by the
+      // dropActionChanged of the default DragSource.
+			/* ****************** END OF CHANGE ******************** */
+
+      //begin the drag
+      oDnDtocOrigin = this;
+      dragSource.startDrag(e, null, transferable, this);
+    }
+  }
+
+  /** DragSourceListener interface method */
+  public void dragDropEnd(DragSourceDropEvent dsde) {
+  }
+
+  /** DragSourceListener interface method */
+  public void dragEnter(DragSourceDragEvent dsde) {
+		/* ********************** CHANGED ********************** */
+      // System.err.println("dragOver" + dsde.getDragSourceContext().getComponent());
+
+		/* ****************** END OF CHANGE ******************** */
+  }
+
+  /** DragSourceListener interface method */
+  public void dragOver(DragSourceDragEvent dsde) {
+		/* ********************** CHANGED ********************** */
+      // System.err.println("dragOver" + dsde.getDragSourceContext().getComponent());
+		/* ****************** END OF CHANGE ******************** */
+  }
+
+  /** DragSourceListener interface method */
+  public void dropActionChanged(DragSourceDragEvent dsde) {
+  }
+
+  /** DragSourceListener interface method */
+  public void dragExit(DragSourceEvent dsde) {
+  }
+
+  /** DropTargetListener interface method - What we do when drag is released */
+  public void drop(DropTargetDropEvent e) {
+    try {
+      Transferable tr = e.getTransferable();
+      //flavor not supported, reject drop
+      if (!tr.isDataFlavorSupported( TocItemBranch.INFO_FLAVOR)) {
+		e.rejectDrop();
+	}
+      //cast into appropriate data type
+      TocItemBranch childInfo =
+        (TocItemBranch) tr.getTransferData( TocItemBranch.INFO_FLAVOR );
+      //get new parent node
+      Point loc = e.getLocation();
+      TreePath destinationPath = getPathForLocation(loc.x, loc.y);
+
+      final String msg = testDropTarget(destinationPath, SelectedTreePath);
+      if (msg != null) {
+          /* if (testSameComponent())
+          { */
+              e.rejectDrop();
+              SwingUtilities.invokeLater(new Runnable() {
+                  public void run() {
+                      System.err.println(msg);
+                  }
+              });
+              return;
+          /* }
+          else
+          {
+              // TODO: Por ahora solo dejamos mover, no copiar
+              // TODO: �Y qu� pasa si la vista a la que vamos
+              // no tiene la misma proyecci�n? MEJOR DESHABILITO ESTO POR AHORA
+              if (e.getDropAction() == DnDConstants.ACTION_MOVE)
+                  dropRoot(SelectedNode);
+              else
+                  e.rejectDrop();
+              return;
+          } */
+      }
+      if (!testSameComponent(e))
+      {
+          e.rejectDrop();
+          return;
+      }
+      int oldPos,newPos;
+	  //boolean isContainer=false;
+
+	  DefaultMutableTreeNode nodoTocado =
+        (DefaultMutableTreeNode) destinationPath.getLastPathComponent();
+	  //	get old parent node
+      DefaultMutableTreeNode oldParent = (DefaultMutableTreeNode) getSelectedNode().getParent();
+      if (nodoTocado.getParent().equals(getSelectedNode())){
+    	  return;
+      }
+      //oldParent.setUserObject(new TocItemBranch(((TocItemBranch)getSelectedNode().getUserObject()).getLayer().getParentLayer()));
+	  if (oldParent==null) {
+		return;
+	}
+      oldPos = oldParent.getIndex(getSelectedNode());
+	  // Para no tener en cuenta los nodos de s�mbolos:
+      if (!(nodoTocado.getUserObject() instanceof TocItemBranch)){
+      		nodoTocado = (DefaultMutableTreeNode) nodoTocado.getParent();
+      }
+
+      ///posActual = oldParent.getIndex(getSelectedNode());
+      //Destino
+	  DefaultMutableTreeNode destParent=null;
+
+	  if (((TocItemBranch)nodoTocado.getUserObject()).getLayer() instanceof FLayers){
+		  //isContainer=true;
+		  newPos=0;
+		  destParent=nodoTocado;
+      }else{//Si donde se deja la capa seleccionada no es un contenedor de capas.
+		destParent= (DefaultMutableTreeNode)nodoTocado.getParent();
+        newPos=destParent.getIndex(nodoTocado);
+      }
+
+
+
+
+      int action = e.getDropAction();
+      boolean copyAction = (action == DnDConstants.ACTION_COPY);
+
+      //make new child node
+      DefaultMutableTreeNode newChild = new DefaultMutableTreeNode(childInfo);
+	  if (getSelectedNode().getAllowsChildren()){
+		  int childs=getSelectedNode().getChildCount();
+
+		  for (int i=0;i<childs;i++){
+			  newChild.add((MutableTreeNode)getSelectedNode().getChildAt(0));
+		  }
+	  }
+
+	  try {
+        if (!copyAction){
+        	oldParent.remove(getSelectedNode());
+            destParent.insert(newChild,newPos);
+            // newParent.add(newChild);
+        }
+        if (copyAction) {
+			e.acceptDrop (DnDConstants.ACTION_COPY);
+		} else {
+			e.acceptDrop (DnDConstants.ACTION_MOVE);
+		}
+      }
+      catch (java.lang.IllegalStateException ils) {
+        e.rejectDrop();
+      }
+
+      e.getDropTargetContext().dropComplete(true);
+
+      //expand nodes appropriately - this probably isnt the best way...
+
+      // TODO: COMENTADO POR FJP
+      /* com.iver.andami.ui.mdiManager.View[] views=PluginServices.getMDIManager().getAllViews();
+	  for(int i=0;i<views.length;i++){
+		  if (views[i] instanceof View){
+			  ((DefaultTreeModel)((View)views[i]).getTOC().getTree().getModel()).reload(oldParent);
+		  }
+	  } */
+
+
+
+     // ((DefaultTreeModel)model1).reload(oldParent);
+      DefaultTreeModel model = (DefaultTreeModel) getModel();
+
+	  model.reload(getSelectedNode().getRoot());
+	  FLayers lpo=null;
+	  FLayers lpd=null;
+
+	  if (oldParent.getUserObject() instanceof TocItemBranch){
+	  lpo=(FLayers)((TocItemBranch)oldParent.getUserObject()).getLayer();
+	  //lpd=(FLayers)((TocItemBranch)destParent.getUserObject()).getLayer();
+	  }/*else if (((TocItemBranch)nodoTocado.getUserObject()).getLayer().getParentLayer()!=null){
+		  lpo=((TocItemBranch)nodoTocado.getUserObject()).getLayer().getParentLayer();
+	  }*/else{
+		  lpo=((TocItemBranch)getSelectedNode().getUserObject()).getLayer().getParentLayer();
+	  }
+		  if (destParent.getUserObject() instanceof TocItemBranch){
+		  lpd=(FLayers)((TocItemBranch)destParent.getUserObject()).getLayer();
+		  }else{
+		  lpd=((TocItemBranch)nodoTocado.getUserObject()).getLayer().getParentLayer();
+		  }
+
+
+	  if (destParent.equals(oldParent)){
+		  callListeners(oldPos,newPos,lpd);
+	  }else{
+		  callListeners(lpo,lpd,((TocItemBranch)newChild.getUserObject()).getLayer());
+	  }
+	  }
+
+    catch (IOException io) { e.rejectDrop(); }
+    catch (UnsupportedFlavorException ufe) {e.rejectDrop();}
+  } //end of method
+public void dropRoot(TreeNode tn){
+	int oldPos,newPos;
+	DefaultMutableTreeNode nodoTocado =
+	        (DefaultMutableTreeNode) tn;
+		  //	get old parent node
+	    if (getSelectedNode()==null) {
+			return;
+		}
+		DefaultMutableTreeNode oldParent = (DefaultMutableTreeNode) getSelectedNode().getParent();
+		  if (oldParent!=null){
+	      oldPos = oldParent.getIndex(getSelectedNode());
+	      //Destino
+		  DefaultMutableTreeNode destParent=null;
+		  newPos=0;
+		  destParent=nodoTocado;
+
+	      //make new child node
+	      DefaultMutableTreeNode newChild = (DefaultMutableTreeNode)getSelectedNode().clone();
+	      oldParent.remove(getSelectedNode());
+	      destParent.insert(newChild,newPos);
+
+	      org.gvsig.andami.ui.mdiManager.IWindow[] views=PluginServices.getMDIManager().getAllWindows();
+		  for(int i=0;i<views.length;i++){
+			  if (views[i] instanceof DefaultViewPanel){
+				  ((DefaultTreeModel)((DefaultViewPanel)views[i]).getTOC().getTree().getModel()).reload(oldParent);
+			  }
+		  }
+	     // ((DefaultTreeModel)model1).reload(oldParent);
+	      DefaultTreeModel model = (DefaultTreeModel) getModel();
+		  model.reload(destParent);
+		  FLayers lpo=null;
+		  FLayers lpd=null;
+
+		  lpo=((TocItemBranch)getSelectedNode().getUserObject()).getLayer().getParentLayer();
+		  for(int i=0;i<views.length;i++){
+			  if (views[i] instanceof DefaultViewPanel){
+				  if (((DefaultViewPanel)views[i]).getTOC().getTree().equals(this)){
+					  lpd= ((DefaultViewPanel)views[i]).getMapControl().getMapContext().getLayers();
+				  }
+			  }
+		  }
+		  if (destParent.equals(oldParent)){
+			  callListeners(oldPos,newPos,lpd);
+		  }else{
+			  callListeners(lpo,lpd,((TocItemBranch)newChild.getUserObject()).getLayer());
+		  }
+		  }
+	}
+
+  /** DropTaregetListener interface method */
+  public void dragEnter(DropTargetDragEvent e) {
+  }
+
+  /** DropTaregetListener interface method */
+  public void dragExit(DropTargetEvent e) {
+  }
+
+  /** DropTaregetListener interface method */
+  public void dragOver(DropTargetDragEvent e) {
+		/* ********************** CHANGED ********************** */
+    //set cursor location. Needed in setCursor method
+    Point cursorLocationBis = e.getLocation();
+        TreePath destinationPath =
+      getPathForLocation(cursorLocationBis.x, cursorLocationBis.y);
+
+
+    // if destination path is okay accept drop...
+
+    if (testSameComponent(e))
+    {
+        String msg = testDropTarget(destinationPath, SelectedTreePath);
+        if ( msg == null) {
+            e.acceptDrag(DnDConstants.ACTION_MOVE) ;
+            return;
+        }
+
+    }
+    // ...otherwise reject drop
+    // else {
+        // System.err.println(e.getDropTargetContext().getComponent());
+
+        // if (testSameComponent(e))
+            e.rejectDrag() ;
+        /* else
+            e.acceptDrag(DnDConstants.ACTION_MOVE); */
+    // }
+		/* ****************** END OF CHANGE ******************** */
+  }
+
+  /** DropTaregetListener interface method */
+  public void dropActionChanged(DropTargetDragEvent e) {
+  }
+  private void setSelectedNode(DefaultMutableTreeNode smtn){
+	  if (smtn!=null) {
+		SelectedNode=smtn;
+	}
+  }
+
+  /** TreeSelectionListener - sets selected node */
+  public void valueChanged(TreeSelectionEvent evt) {
+    SelectedTreePath = evt.getNewLeadSelectionPath();
+    /* com.iver.andami.ui.mdiManager.View[] views=PluginServices.getMDIManager().getAllViews();
+	  for(int i=0;i<views.length;i++){
+		  if (views[i] instanceof View){
+			  if (SelectedTreePath == null) {
+				((View)views[i]).getTOC().getTree().setSelectedNode(null);
+			  }else{
+			   	((View)views[i]).getTOC().getTree().setSelectedNode((DefaultMutableTreeNode)SelectedTreePath.getLastPathComponent());
+			  }
+		  }
+	  } */
+	  if (SelectedTreePath == null){
+		  setSelectedNode(null);
+	  }else{
+		  setSelectedNode((DefaultMutableTreeNode)SelectedTreePath.getLastPathComponent());
+	  }
+  }
+
+  /** Convenience method to test whether drop location is valid
+  @param destination The destination path
+  @param dropper The path for the node to be dropped
+  @return null if no problems, otherwise an explanation
+  */
+  private String testDropTarget(TreePath destination, TreePath dropper) {
+    //Typical Tests for dropping
+
+    //Test 1.
+    boolean destinationPathIsNull = destination == null;
+    if (destinationPathIsNull) {
+		return "Invalid drop location.";
+	}
+
+    //Test 2.
+    DefaultMutableTreeNode node = (DefaultMutableTreeNode) destination.getLastPathComponent();
+    if ( !node.getAllowsChildren() ) {
+		return "This node does not allow children";
+	}
+
+    if (destination.equals(dropper)) {
+		return "Destination cannot be same as source";
+	}
+
+    //Test 3.
+    /* if ( dropper.isDescendant(destination))
+       return "Destination node cannot be a descendant.";
+
+    //Test 4.
+    if ( dropper.getParentPath().equals(destination))
+       return "Destination node cannot be a parent."; */
+
+    return null;
+  }
+
+  private boolean testSameComponent(DropTargetEvent e)
+  {
+      oDnDtocDestination = this;
+      return (oDnDtocOrigin == oDnDtocDestination);
+  }
+	/**
+	 * @param arg0
+	 * @return
+	 */
+	public boolean addOrderListener(ITocOrderListener arg0) {
+		return m_Listeners.add(arg0);
+	}
+	/**
+	 * @param arg0
+	 * @return
+	 */
+	public boolean removeOrderListener(ITocOrderListener arg0) {
+		return m_Listeners.remove(arg0);
+	}
+	private void callListeners(int oldPos, int newPos,FLayers lpd)
+	{
+		for (int i=0; i < m_Listeners.size(); i++)
+		{
+			ITocOrderListener listener = (ITocOrderListener) m_Listeners.get(i);
+			listener.orderChanged(oldPos, newPos,lpd);
+		}
+	}
+
+  private void callListeners(FLayers lpo,FLayers lpd,FLayer ls){
+	  for (int i=0; i < m_Listeners.size(); i++)
+		{
+			ITocOrderListener listener = (ITocOrderListener) m_Listeners.get(i);
+			listener.parentChanged(lpo,lpd,ls);
+		}
+  }
+
+} //end of DnDJTree

Property changes on: tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/app/project/documents/view/toc/DnDJTree.java
___________________________________________________________________
Added: svn:keywords
   + Author Date Id Revision
Added: svn:eol-style
   + native

Index: tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/app/project/documents/view/toolListeners/PanListener.java
===================================================================
--- tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/app/project/documents/view/toolListeners/PanListener.java	(revision 0)
+++ tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/app/project/documents/view/toolListeners/PanListener.java	(revision 38653)
@@ -0,0 +1,76 @@
+/* gvSIG. Sistema de Informaci�n Geogr�fica de la Generalitat Valenciana
+ *
+ * Copyright (C) 2004 IVER T.I. and Generalitat Valenciana.
+ *
+ * This program is free software; you can redistribute it and/or
+ * modify it under the terms of the GNU General Public License
+ * as published by the Free Software Foundation; either version 2
+ * of the License, or (at your option) any later version.
+ *
+ * This program is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
+ * GNU General Public License for more details.
+ *
+ * You should have received a copy of the GNU General Public License
+ * along with this program; if not, write to the Free Software
+ * Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA  02111-1307,USA.
+ *
+ * For more information, contact:
+ *
+ *  Generalitat Valenciana
+ *   Conselleria d'Infraestructures i Transport
+ *   Av. Blasco Ib��ez, 50
+ *   46010 VALENCIA
+ *   SPAIN
+ *
+ *      +34 963862235
+ *   gvsig@gva.es
+ *      www.gvsig.gva.es
+ *
+ *    or
+ *
+ *   IVER T.I. S.A
+ *   Salamanca 50
+ *   46005 Valencia
+ *   Spain
+ *
+ *   +34 963163400
+ *   dac@iver.es
+ */
+package org.gvsig.app.project.documents.view.toolListeners;
+
+import org.gvsig.andami.PluginServices;
+import org.gvsig.fmap.mapcontrol.MapControl;
+import org.gvsig.fmap.mapcontrol.tools.PanListenerImpl;
+import org.gvsig.fmap.mapcontrol.tools.Events.MoveEvent;
+
+
+
+/**
+ * <p>Inherits {@link PanListener PanListener} enabling/disabling special
+ *  controls for managing the data.</p>
+ *
+ * @see PanListenerImpl
+ *
+ * @author Vicente Caballero Navarro
+ */
+public class PanListener extends PanListenerImpl {
+	/**
+	 * <p>Creates a new <code>PanListener</code> object.</p>
+	 * 
+	 * @param mapCtrl the <code>MapControl</code> where will be applied the changes
+	 */
+	public PanListener(MapControl mapCtrl) {
+		super(mapCtrl);
+	}
+
+	/*
+	 * (non-Javadoc)
+	 * @see com.iver.cit.gvsig.fmap.tools.PanListenerImpl#move(com.iver.cit.gvsig.fmap.tools.Events.MoveEvent)
+	 */
+	public void move(MoveEvent event) {
+		super.move(event);
+		PluginServices.getMainFrame().enableControls();
+	}
+}

Property changes on: tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/app/project/documents/view/toolListeners/PanListener.java
___________________________________________________________________
Added: svn:keywords
   + Author Date Id Revision
Added: svn:eol-style
   + native

Index: tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/app/project/documents/view/toolListeners/MapOverviewChangeZoomListener.java
===================================================================
--- tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/app/project/documents/view/toolListeners/MapOverviewChangeZoomListener.java	(revision 0)
+++ tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/app/project/documents/view/toolListeners/MapOverviewChangeZoomListener.java	(revision 38653)
@@ -0,0 +1,191 @@
+/**
+ *
+ */
+package org.gvsig.app.project.documents.view.toolListeners;
+
+import java.awt.Image;
+import java.awt.event.InputEvent;
+import java.awt.event.MouseEvent;
+import java.awt.geom.Point2D;
+import java.awt.geom.Rectangle2D;
+
+import org.gvsig.andami.PluginServices;
+import org.gvsig.app.gui.styling.SymbolSelector;
+import org.gvsig.app.project.documents.view.MapOverview;
+import org.gvsig.fmap.geom.GeometryLocator;
+import org.gvsig.fmap.geom.GeometryManager;
+import org.gvsig.fmap.geom.Geometry.SUBTYPES;
+import org.gvsig.fmap.geom.exception.CreateEnvelopeException;
+import org.gvsig.fmap.geom.primitive.Envelope;
+import org.gvsig.fmap.geom.util.UtilFunctions;
+import org.gvsig.fmap.mapcontext.ViewPort;
+import org.gvsig.fmap.mapcontrol.MapControl;
+import org.gvsig.fmap.mapcontrol.tools.BehaviorException;
+import org.gvsig.fmap.mapcontrol.tools.Events.EnvelopeEvent;
+import org.gvsig.fmap.mapcontrol.tools.Events.MoveEvent;
+import org.gvsig.fmap.mapcontrol.tools.Listeners.PanListener;
+import org.gvsig.fmap.mapcontrol.tools.Listeners.RectangleListener;
+import org.slf4j.Logger;
+import org.slf4j.LoggerFactory;
+
+
+/**
+ * <p>Listener for changes of the zoom caused by selecting a rectangular area on the associated
+ *  {@link MapOverview MapOverview} object with the first button of the mouse.</p>
+ *
+ * <p>If the kind of action was a movement on the associated object,
+ *  updates the <i>extent</i> of its rectangular area.</p>
+ *
+ * <p>If the kind of action is the selection of a rectangular area, and is bigger than 3x3 pixels,
+ *  applies a <i>zoom in</i> operation centering its <code>ViewPort</code> according the equivalent <i>extent</i>
+ *  in map coordinates.</p>
+ *
+ * @see ViewPort
+ *
+ * @author jmvivo
+ */
+public class MapOverviewChangeZoomListener implements RectangleListener, PanListener {
+	private static final GeometryManager geomManager = GeometryLocator.getGeometryManager();
+	private static final Logger logger = LoggerFactory.getLogger(MapOverviewChangeZoomListener.class);
+	/**
+	 * The image to display when the cursor is active.
+	 */
+	private final Image izoomin = PluginServices.getIconTheme()
+		.get("cursor-zoom-in").getImage();
+
+	/**
+	 * The cursor used to work with this tool listener.
+	 *
+	 * @see #getCursor()
+	 */
+//	private Cursor cur = Toolkit.getDefaultToolkit().createCustomCursor(izoomin,new Point(16, 16), "");
+
+	/**
+	 * Reference to the <code>MapControl</code> object that uses.
+	 */
+	protected MapControl mapControl;
+
+	/**
+	 * <p>Creates a new listener for changes of zoom at the associated {@link MapOverview MapOverview} object.</p>
+	 *
+	 * @param mapControl the <code>MapControl</code> object which represents the <code>MapOverview</code>
+	 */
+	public MapOverviewChangeZoomListener(MapControl mapControl) {
+		this.mapControl=mapControl;
+	}
+
+	/*
+	 * (non-Javadoc)
+	 * @see com.iver.cit.gvsig.fmap.tools.Listeners.RectangleListener#rectangle(com.iver.cit.gvsig.fmap.tools.Events.RectangleEvent)
+	 */
+	public void rectangle(EnvelopeEvent event) throws BehaviorException {
+
+		if (!checkModifiers(event.getEvent())){
+			return;
+		}
+		MapOverview mov=(MapOverview) this.mapControl;
+		ViewPort vpView=mov.getAssociatedMapContext().getViewPort();
+		ViewPort vp = mov.getViewPort();
+
+		if (vp.getExtent() != null && vpView.getExtent() != null) {
+
+			// Recuperamos las coordenadas del evento en px
+			Rectangle2D pxRectangle = event.getPixelCoordRect();
+			// Recuperamos las coordenadas del evento en coordenadas de la vista de localizador
+			Envelope realRectangle = event.getWorldCoordRect();
+
+			if ((pxRectangle.getWidth() < 3) && (pxRectangle.getHeight() < 3))
+			{
+				// rectangulo < 3 px no hacemos nada
+				return;
+
+			} else {
+				// Cambiamos la extension de la vista asociada al localizador
+				vpView.setEnvelope(realRectangle);
+				mov.getAssociatedMapContext().invalidate();
+				vpView.setEnvelope(realRectangle);
+			}
+		}
+	}
+
+	/*
+	 * (non-Javadoc)
+	 * @see com.iver.cit.gvsig.fmap.tools.Listeners.ToolListener#getCursor()
+	 */
+	public Image getImageCursor() {
+		return izoomin;
+	}
+
+	/* (non-Javadoc)
+	 * @see com.iver.cit.gvsig.fmap.tools.Listeners.ToolListener#cancelDrawing()
+	 */
+	public boolean cancelDrawing() {
+		return true; //???
+	}
+
+	/*
+	 * (non-Javadoc)
+	 * @see com.iver.cit.gvsig.fmap.tools.Listeners.PanListener#move(com.iver.cit.gvsig.fmap.tools.Events.MoveEvent)
+	 */
+	public void move(MoveEvent event) throws BehaviorException {
+
+
+		if (!checkModifiers(event.getEvent())){
+			return;
+		}
+		System.out.println("mapOvervierChangeZoom");
+		MapOverview mov=(MapOverview) this.mapControl;
+		ViewPort vpView=mov.getAssociatedMapContext().getViewPort();
+		ViewPort vp = mov.getViewPort();
+
+		if (vp.getExtent() != null && vpView.getExtent() != null) {
+
+			// Creamos un recuadro con las coordenadas del raton
+			// traducidas a la del mapa
+//			Rectangle2D realRectangle = new Rectangle2D.Double();
+			Point2D p1=vp.toMapPoint(event.getFrom());
+			Point2D p2=vp.toMapPoint(event.getTo());
+			Envelope realRectangle = null;
+			double x=0;
+			double y=0;
+			double xMax=0;
+			double yMax=0;
+			if (p1.getX()<p2.getX()){
+				x=p1.getX();
+				xMax=p2.getX();
+			}else{
+				x=p2.getX();
+				xMax=p1.getX();
+			}
+			if (p1.getY()<p2.getY()){
+				y=p1.getY();
+				yMax=p2.getY();
+			}else{
+				y=p2.getY();
+				yMax=p1.getY();
+			}
+				try {
+					realRectangle = geomManager.createEnvelope(x,y,xMax,yMax, SUBTYPES.GEOM2D);
+				} catch (CreateEnvelopeException e) {
+					logger.error("Error creating the envelope", e);
+				}
+
+			//			realRectangle.setFrameFromDiagonal(vp.toMapPoint(event.getFrom()),vp.toMapPoint(event.getTo()));
+
+			// Establecemos la forma
+			mov.refreshOverView(realRectangle);
+		}
+
+
+
+	}
+
+	/**
+	 * Determines if has pressed the button 1 of the mouse.
+	 */
+	private boolean checkModifiers(MouseEvent event) {
+		int modifiers = event.getModifiers();
+		int keyPressedMask = InputEvent.BUTTON1_MASK;
+		return ((modifiers & keyPressedMask) == keyPressedMask);
+	}
+}

Property changes on: tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/app/project/documents/view/toolListeners/MapOverviewChangeZoomListener.java
___________________________________________________________________
Added: svn:keywords
   + Author Date Id Revision
Added: svn:eol-style
   + native

Index: tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/app/project/documents/view/toolListeners/MeasureListener.java
===================================================================
--- tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/app/project/documents/view/toolListeners/MeasureListener.java	(revision 0)
+++ tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/app/project/documents/view/toolListeners/MeasureListener.java	(revision 38653)
@@ -0,0 +1,111 @@
+/* gvSIG. Sistema de Informaci�n Geogr�fica de la Generalitat Valenciana
+ *
+ * Copyright (C) 2004 IVER T.I. and Generalitat Valenciana.
+ *
+ * This program is free software; you can redistribute it and/or
+ * modify it under the terms of the GNU General Public License
+ * as published by the Free Software Foundation; either version 2
+ * of the License, or (at your option) any later version.
+ *
+ * This program is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
+ * GNU General Public License for more details.
+ *
+ * You should have received a copy of the GNU General Public License
+ * along with this program; if not, write to the Free Software
+ * Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA  02111-1307,USA.
+ *
+ * For more information, contact:
+ *
+ *  Generalitat Valenciana
+ *   Conselleria d'Infraestructures i Transport
+ *   Av. Blasco Ib��ez, 50
+ *   46010 VALENCIA
+ *   SPAIN
+ *
+ *      +34 963862235
+ *   gvsig@gva.es
+ *      www.gvsig.gva.es
+ *
+ *    or
+ *
+ *   IVER T.I. S.A
+ *   Salamanca 50
+ *   46005 Valencia
+ *   Spain
+ *
+ *   +34 963163400
+ *   dac@iver.es
+ */
+package org.gvsig.app.project.documents.view.toolListeners;
+
+import java.awt.geom.Point2D;
+import java.text.NumberFormat;
+
+import org.gvsig.andami.PluginServices;
+import org.gvsig.fmap.mapcontext.MapContext;
+import org.gvsig.fmap.mapcontext.ViewPort;
+import org.gvsig.fmap.mapcontrol.MapControl;
+import org.gvsig.fmap.mapcontrol.tools.MeasureListenerImpl;
+import org.gvsig.fmap.mapcontrol.tools.Events.MeasureEvent;
+
+
+
+/**
+ * <p>Listener for calculating distances using vertexes of a polyline, defined in the associated {@link MapControl MapControl}
+ *  object, and displaying that information at the status bar of the application's main frame.</p>
+ *
+ * <p>Calculates and displays:
+ *  <ul>
+ *   <li>Distance of the last segment of the polyline.</li>
+ *   <li>Accumulated distance of all segments of the polyline.</li>
+ *  </ul>
+ * </p>
+ *
+ * @see MeasureListenerImpl
+ *
+ * @author Vicente Caballero Navarro
+ */
+public class MeasureListener extends MeasureListenerImpl {
+	/**
+	 * <p>Creates a new listener for calculating distances using points of a polyline.</p>
+	 *
+	 * @param mc the <code>MapControl</code> where is calculated the length
+	 */
+	public MeasureListener(MapControl mc) {
+		super(mc);
+	}
+
+	/*
+	 * (non-Javadoc)
+	 * @see com.iver.cit.gvsig.fmap.tools.MeasureListenerImpl#points(com.iver.cit.gvsig.fmap.tools.Events.MeasureEvent)
+	 */
+	public void points(MeasureEvent event) {
+		double dist = 0;
+		double distAll = 0;
+
+		ViewPort vp = mapCtrl.getMapContext().getViewPort();
+
+		Point2D p = new Point2D.Double(event.getXs()[0].doubleValue(),event.getYs()[0].doubleValue());//vp.toMapPoint(new Point(event.getXs()[0].intValue(),event.getYs()[0].intValue()));
+		for (int i = 1; i < (event.getXs().length); i++) {
+			Point2D p2 = new Point2D.Double(event.getXs()[i].doubleValue(),	event.getYs()[i].doubleValue());// vp.toMapPoint(new Point(event.getXs()[i].intValue(),event.getYs()[i].intValue()));
+			dist = vp.distanceWorld(p, p2);
+			distAll += dist;
+			p = p2;
+		}
+
+		//System.out.println("Distancia = " + dist + " Distancia Total = " +
+		//	(distAll));
+		NumberFormat nf = NumberFormat.getInstance();
+        nf.setMaximumFractionDigits(2);
+        if (PluginServices.getMainFrame() != null)
+        {
+        	double[] trans2Meter=MapContext.getDistanceTrans2Meter();
+            PluginServices.getMainFrame().getStatusBar().setMessage("4",
+    			"Dist:" + nf.format(dist/trans2Meter[mapCtrl.getViewPort().getDistanceUnits()]) + "");
+    		PluginServices.getMainFrame().getStatusBar().setMessage("5",
+    			"Total:" + nf.format(distAll/trans2Meter[mapCtrl.getViewPort().getDistanceUnits()]) + "");
+        }
+	}
+}

Property changes on: tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/app/project/documents/view/toolListeners/MeasureListener.java
___________________________________________________________________
Added: svn:keywords
   + Author Date Id Revision
Added: svn:eol-style
   + native

Index: tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/app/project/documents/view/toolListeners/CircleMeasureListener.java
===================================================================
--- tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/app/project/documents/view/toolListeners/CircleMeasureListener.java	(revision 0)
+++ tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/app/project/documents/view/toolListeners/CircleMeasureListener.java	(revision 38653)
@@ -0,0 +1,145 @@
+/* gvSIG. Sistema de Informaci�n Geogr�fica de la Generalitat Valenciana
+ *
+ * Copyright (C) 2004 IVER T.I. and Generalitat Valenciana.
+ *
+ * This program is free software; you can redistribute it and/or
+ * modify it under the terms of the GNU General Public License
+ * as published by the Free Software Foundation; either version 2
+ * of the License, or (at your option) any later version.
+ *
+ * This program is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
+ * GNU General Public License for more details.
+ *
+ * You should have received a copy of the GNU General Public License
+ * along with this program; if not, write to the Free Software
+ * Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA  02111-1307,USA.
+ *
+ * For more information, contact:
+ *
+ *  Generalitat Valenciana
+ *   Conselleria d'Infraestructures i Transport
+ *   Av. Blasco Ib��ez, 50
+ *   46010 VALENCIA
+ *   SPAIN
+ *
+ *      +34 963862235
+ *   gvsig@gva.es
+ *      www.gvsig.gva.es
+ *
+ *    or
+ *
+ *   IVER T.I. S.A
+ *   Salamanca 50
+ *   46005 Valencia
+ *   Spain
+ *
+ *   +34 963163400
+ *   dac@iver.es
+ */
+package org.gvsig.app.project.documents.view.toolListeners;
+
+
+import java.awt.Image;
+import java.awt.geom.Point2D;
+import java.text.NumberFormat;
+
+import org.gvsig.andami.PluginServices;
+import org.gvsig.fmap.mapcontext.MapContext;
+import org.gvsig.fmap.mapcontext.ViewPort;
+import org.gvsig.fmap.mapcontrol.MapControl;
+import org.gvsig.fmap.mapcontrol.tools.BehaviorException;
+import org.gvsig.fmap.mapcontrol.tools.Events.MeasureEvent;
+import org.gvsig.fmap.mapcontrol.tools.Listeners.CircleListener;
+
+
+
+/**
+ * <p>Listener for tools that measure using a circular area, displaying
+ *   its radius at the status bar of the application's main frame.</p>
+ *
+ * @see CircleListener
+ *
+ * @author Laura
+ */
+public class CircleMeasureListener implements CircleListener {
+	/**
+	 * The image to display when the cursor is active.
+	 */
+	private final Image img = PluginServices.getIconTheme().get("cursor-query-distance").getImage();
+
+	/**
+	 * The cursor used to work with this tool listener.
+	 *
+	 * @see #getCursor()
+	 */
+//	private Cursor cur = Toolkit.getDefaultToolkit().createCustomCursor(img,
+//			new Point(16, 16), "");
+
+	/**
+	 * Reference to the <code>MapControl</code> object that uses.
+	 */
+	private MapControl mapCtrl;
+
+	/**
+	 * <p>Creates a new listener for measure circular areas.</p>
+	 *
+	 * @param mc the <code>MapControl</code> object where the measures are made
+	 */
+	public CircleMeasureListener(MapControl mc) {
+		this.mapCtrl = mc;
+	}
+
+	/*
+	 * (non-Javadoc)
+	 * @see com.iver.cit.gvsig.fmap.tools.Listeners.CircleListener#circle(com.iver.cit.gvsig.fmap.tools.Events.MeasureEvent)
+	 */
+	public void circle(MeasureEvent event) throws BehaviorException {
+		double dist = 0;
+		double distAll = 0;
+
+		ViewPort vp = mapCtrl.getMapContext().getViewPort();
+
+		for (int i = 0; i < (event.getXs().length - 1); i++) {
+			dist = 0;
+
+			Point2D p = new Point2D.Double(event.getXs()[i].doubleValue(),
+					event.getYs()[i].doubleValue());
+			Point2D p2 = new Point2D.Double(event.getXs()[i + 1].doubleValue(),
+					event.getYs()[i + 1].doubleValue());
+
+			///dist = vp.toMapDistance((int) p.distance(p2));
+			dist = vp.distanceWorld(p, p2);
+			distAll += dist;
+		}
+		//System.out.println("Distancia = " + dist + " Distancia Total = " +
+		//	(distAll));
+		NumberFormat nf = NumberFormat.getInstance();
+        nf.setMaximumFractionDigits(2);
+        if (PluginServices.getMainFrame() != null)
+        {
+        	double[] trans2Meter=MapContext.getDistanceTrans2Meter();
+            PluginServices.getMainFrame().getStatusBar().setMessage("4",
+    			"Dist:" + nf.format(dist/trans2Meter[mapCtrl.getViewPort().getDistanceUnits()]) + "");
+    		PluginServices.getMainFrame().getStatusBar().setMessage("5",
+    			"Total:" + nf.format(distAll/trans2Meter[mapCtrl.getViewPort().getDistanceUnits()]) + "");
+        }
+	}
+
+	/*
+	 * (non-Javadoc)
+	 * @see com.iver.cit.gvsig.fmap.tools.Listeners.ToolListener#getImageCursor()
+	 */
+	public Image getImageCursor() {
+		return img;
+	}
+
+	/*
+	 * (non-Javadoc)
+	 * @see com.iver.cit.gvsig.fmap.tools.Listeners.ToolListener#cancelDrawing()
+	 */
+	public boolean cancelDrawing() {
+		return false;
+	}
+}

Property changes on: tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/app/project/documents/view/toolListeners/CircleMeasureListener.java
___________________________________________________________________
Added: svn:keywords
   + Author Date Id Revision
Added: svn:eol-style
   + native

Index: tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/app/project/documents/view/toolListeners/MapOverviewPanListener.java
===================================================================
--- tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/app/project/documents/view/toolListeners/MapOverviewPanListener.java	(revision 0)
+++ tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/app/project/documents/view/toolListeners/MapOverviewPanListener.java	(revision 38653)
@@ -0,0 +1,235 @@
+/* gvSIG. Sistema de Informaci�n Geogr�fica de la Generalitat Valenciana
+ *
+ * Copyright (C) 2004 IVER T.I. and Generalitat Valenciana.
+ *
+ * This program is free software; you can redistribute it and/or
+ * modify it under the terms of the GNU General Public License
+ * as published by the Free Software Foundation; either version 2
+ * of the License, or (at your option) any later version.
+ *
+ * This program is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
+ * GNU General Public License for more details.
+ *
+ * You should have received a copy of the GNU General Public License
+ * along with this program; if not, write to the Free Software
+ * Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA  02111-1307,USA.
+ *
+ * For more information, contact:
+ *
+ *  Generalitat Valenciana
+ *   Conselleria d'Infraestructures i Transport
+ *   Av. Blasco Ib��ez, 50
+ *   46010 VALENCIA
+ *   SPAIN
+ *
+ *      +34 963862235
+ *   gvsig@gva.es
+ *      www.gvsig.gva.es
+ *
+ *    or
+ *
+ *   IVER T.I. S.A
+ *   Salamanca 50
+ *   46005 Valencia
+ *   Spain
+ *
+ *   +34 963163400
+ *   dac@iver.es
+ */
+package org.gvsig.app.project.documents.view.toolListeners;
+
+import java.awt.Image;
+import java.awt.event.InputEvent;
+import java.awt.event.MouseEvent;
+import java.awt.geom.Point2D;
+
+import org.gvsig.andami.PluginServices;
+import org.gvsig.app.gui.styling.SymbolSelector;
+import org.gvsig.app.project.documents.view.MapOverview;
+import org.gvsig.fmap.geom.GeometryLocator;
+import org.gvsig.fmap.geom.GeometryManager;
+import org.gvsig.fmap.geom.Geometry.SUBTYPES;
+import org.gvsig.fmap.geom.exception.CreateEnvelopeException;
+import org.gvsig.fmap.geom.primitive.Envelope;
+import org.gvsig.fmap.geom.util.UtilFunctions;
+import org.gvsig.fmap.mapcontext.ViewPort;
+import org.gvsig.fmap.mapcontrol.MapControl;
+import org.gvsig.fmap.mapcontrol.tools.BehaviorException;
+import org.gvsig.fmap.mapcontrol.tools.Events.MoveEvent;
+import org.gvsig.fmap.mapcontrol.tools.Listeners.PanListener;
+import org.slf4j.Logger;
+import org.slf4j.LoggerFactory;
+
+
+
+
+/**
+ * <p>Listener for moving the extent of the associated {@link MapOverview MapOverview} object
+ *  according the movement between the initial and final points of line determined by the movement
+ *  dragging with the third button of the mouse.</p>
+ *
+ * <p>Updates the extent of its <code>ViewPort</code> with the new position.</p>
+ *
+ * @author Vicente Caballero Navarro
+ */
+public class MapOverviewPanListener implements PanListener {
+	private static final GeometryManager geomManager = GeometryLocator.getGeometryManager();
+	private static final Logger logger = LoggerFactory.getLogger(MapOverviewPanListener.class);
+	
+	/**
+	 * The image to display when the cursor is active.
+	 */
+	private final Image icursor = PluginServices.getIconTheme().get("cursor-crux").getImage();
+
+	/**
+	 * The cursor used to work with this tool listener.
+	 *
+	 * @see #getCursor()
+	 */
+//	private Cursor cur = Toolkit.getDefaultToolkit().createCustomCursor(icursor,
+//			new Point(16, 16), "");
+
+	/**
+	 * Reference to the <code>MapControl</code> object that uses.
+	 */
+	protected MapControl mapControl;
+
+	/**
+ 	 * <p>Creates a new listener for changing the position of the extent of the associated {@link MapOverview MapOverview} object.</p>
+	 *
+	 * @param mapControl the <code>MapControl</code> object which represents the <code>MapOverview</code>
+	 */
+	public MapOverviewPanListener(MapControl mapControl) {
+		this.mapControl = mapControl;
+	}
+
+	/*
+	 * (non-Javadoc)
+	 * @see com.iver.cit.gvsig.fmap.tools.Listeners.ToolListener#getImageCursor()
+	 */
+	public Image getImageCursor() {
+		return icursor;
+	}
+
+	/*
+	 * (non-Javadoc)
+	 * @see com.iver.cit.gvsig.fmap.tools.Listeners.ToolListener#cancelDrawing()
+	 */
+	public boolean cancelDrawing() {
+		return true;
+	}
+
+	/*
+	public void move(MoveEvent event) throws BehaviorException {
+		if (!checkModifiers(event.getEvent().getModifiers())){
+			return;
+		}
+
+		ViewPort vp = mapControl.getMapContext().getViewPort();
+		MapOverview mov=(MapOverview) this.mapControl;
+		ViewPort vpView=mov.getAssociatedMapContext().getViewPort();
+		if (vp.getExtent() != null) {
+			Point2D p = vp.toMapPoint(event.getTo());
+			Rectangle2D r = (Rectangle2D) vpView.getExtent().clone();
+			r.setRect(p.getX() - (r.getWidth() / 2),
+				p.getY() - (r.getHeight() / 2), r.getWidth(), r.getHeight());
+			//vpView.setExtent(r);
+			double scale;
+			double escalaX;
+			double escalaY;
+			double newHeight;
+			double newWidth;
+			double xCenter = r.getCenterX();
+			double yCenter = r.getCenterY();
+
+			escalaX = mapControl.getWidth() / r.getWidth();
+			escalaY = mapControl.getHeight() / r.getHeight();
+			Rectangle2D adjustedExtent = new Rectangle2D.Double();
+
+			if (escalaX < escalaY) {
+				scale = escalaX;
+				newHeight = mapControl.getHeight() / scale;
+				adjustedExtent.setRect(xCenter - (r.getWidth() / 2.0),
+					yCenter - (newHeight / 2.0), r.getWidth(), newHeight);
+			} else {
+				scale = escalaY;
+				newWidth = mapControl.getWidth() / scale;
+				adjustedExtent.setRect(xCenter - (newWidth / 2.0),
+					yCenter - (r.getHeight() / 2.0), newWidth,
+					r.getHeight());
+			}
+			mov.refreshOverView(adjustedExtent);
+		}
+
+	}
+	*/
+
+	/*
+	 * @see com.iver.cit.gvsig.fmap.tools.Listeners.PanListener#move(MoveEvent)
+	 */
+	public void move(MoveEvent event) throws BehaviorException {
+
+
+		if (!checkModifiers(event.getEvent())){
+			return;
+		}
+		System.out.println("mapOvervierPan");
+		MapOverview mov=(MapOverview) this.mapControl;
+		ViewPort vp = mov.getViewPort();
+		ViewPort vpView=mov.getAssociatedMapContext().getViewPort();
+
+		if (vp.getExtent() != null && vpView.getExtent() != null) {
+
+			// recogemos la forma de la vista actual
+			Envelope curEnvelope = vpView.getAdjustedExtent();
+			// traducimos las coordenadas en px de la ultima posicion del raton
+			// a coordenadas de la vista
+			Point2D thePoint= vp.toMapPoint( event.getTo());
+
+			double diffx =
+				(curEnvelope.getMaximum(0) - curEnvelope.getMinimum(0)) / 2;
+			double diffy =
+				(curEnvelope.getMaximum(1) - curEnvelope.getMinimum(1)) / 2;
+			// Creamos un envelope del mismo tama�o
+			// con la coordenadas del punto del raton,
+			// teniendo en cuenta que estas sera el
+			// centro del recuadro
+
+			Envelope envelope;
+			try {
+				envelope = geomManager.createEnvelope(
+						thePoint.getX() - diffx,
+						thePoint.getY() - diffy,
+						thePoint.getX() + diffx,
+						thePoint.getY()	+ diffy,
+						SUBTYPES.GEOM2D
+				);
+				// cambiamos la posicion
+				mov.refreshOverView(envelope);
+				vpView.setEnvelope(envelope);
+			} catch (CreateEnvelopeException e) {
+				logger.error("Error creating the envelope", e);
+			}			
+			mov.getAssociatedMapContext().invalidate();
+		}
+	}
+
+	/**
+	 * Determines if has pressed the button 3 of the mouse.
+	 */
+	private boolean checkModifiers(MouseEvent event) {
+
+		int modifiers = event.getModifiers();
+		/*
+		int keyPressedMask = InputEvent.BUTTON2_MASK;
+
+		*** No se porque el boton derecho del raton devuelve
+		*** un modificador 'Meta + BUTTON3'. Pensaba que deberia
+		*** devolver 'BUTTON2' ????
+		*/
+		int keyPressedMask = InputEvent.BUTTON3_MASK;
+		return ((modifiers & keyPressedMask) == keyPressedMask);
+	}
+}

Property changes on: tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/app/project/documents/view/toolListeners/MapOverviewPanListener.java
___________________________________________________________________
Added: svn:keywords
   + Author Date Id Revision
Added: svn:eol-style
   + native

Index: tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/app/project/documents/view/toolListeners/MapOverviewListener.java
===================================================================
--- tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/app/project/documents/view/toolListeners/MapOverviewListener.java	(revision 0)
+++ tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/app/project/documents/view/toolListeners/MapOverviewListener.java	(revision 38653)
@@ -0,0 +1,158 @@
+/* gvSIG. Sistema de Informaci�n Geogr�fica de la Generalitat Valenciana
+ *
+ * Copyright (C) 2004 IVER T.I. and Generalitat Valenciana.
+ *
+ * This program is free software; you can redistribute it and/or
+ * modify it under the terms of the GNU General Public License
+ * as published by the Free Software Foundation; either version 2
+ * of the License, or (at your option) any later version.
+ *
+ * This program is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
+ * GNU General Public License for more details.
+ *
+ * You should have received a copy of the GNU General Public License
+ * along with this program; if not, write to the Free Software
+ * Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA  02111-1307,USA.
+ *
+ * For more information, contact:
+ *
+ *  Generalitat Valenciana
+ *   Conselleria d'Infraestructures i Transport
+ *   Av. Blasco Ib��ez, 50
+ *   46010 VALENCIA
+ *   SPAIN
+ *
+ *      +34 963862235
+ *   gvsig@gva.es
+ *      www.gvsig.gva.es
+ *
+ *    or
+ *
+ *   IVER T.I. S.A
+ *   Salamanca 50
+ *   46005 Valencia
+ *   Spain
+ *
+ *   +34 963163400
+ *   dac@iver.es
+ */
+package org.gvsig.app.project.documents.view.toolListeners;
+
+import java.awt.Image;
+import java.awt.event.MouseEvent;
+import java.awt.geom.Point2D;
+import java.awt.geom.Rectangle2D;
+
+import org.gvsig.andami.PluginServices;
+import org.gvsig.app.gui.styling.SymbolSelector;
+import org.gvsig.app.project.documents.view.MapOverview;
+import org.gvsig.fmap.geom.GeometryLocator;
+import org.gvsig.fmap.geom.GeometryManager;
+import org.gvsig.fmap.geom.Geometry.SUBTYPES;
+import org.gvsig.fmap.geom.exception.CreateEnvelopeException;
+import org.gvsig.fmap.geom.util.UtilFunctions;
+import org.gvsig.fmap.mapcontext.ViewPort;
+import org.gvsig.fmap.mapcontrol.tools.BehaviorException;
+import org.gvsig.fmap.mapcontrol.tools.Events.PointEvent;
+import org.gvsig.fmap.mapcontrol.tools.Listeners.PointListener;
+import org.slf4j.Logger;
+import org.slf4j.LoggerFactory;
+
+
+
+/**
+ * <p>Listener for changes of the zoom caused by selecting a point on the associated {@link MapOverview MapOverview} object
+ *  by a single click of the button 1 of the mouse.</p>
+ *
+ * <p>Updates the extent of its <code>ViewPort</code> with a <i>zoom out</i> operation, and enables/disables controls for
+ *  managing the data.</p>
+ *
+ * @see ViewPort
+ *
+ * @author Vicente Caballero Navarro
+ */
+public class MapOverviewListener implements PointListener {
+	private static final GeometryManager geomManager = GeometryLocator.getGeometryManager();
+	private static final Logger logger = LoggerFactory.getLogger(MapOverviewListener.class);
+	/**
+	 * The image to display when the cursor is active.
+	 */
+	private final Image izoomout = PluginServices.getIconTheme().get("cursor-crux").getImage();
+
+	/**
+	 * The cursor used to work with this tool listener.
+	 *
+	 * @see #getCursor()
+	 */
+//	private Cursor cur = Toolkit.getDefaultToolkit().createCustomCursor(izoomout,
+//			new Point(16, 16), "");
+
+	/**
+	 * Reference to the <code>MapControl</code> object that uses.
+	 */
+	protected MapOverview mapControl;
+
+	/**
+ 	 * <p>Creates a new listener for zooming out the extent of the associated {@link MapOverview MapOverview} object.</p>
+	 *
+	 * @param mapControl the <code>MapControl</code> object which represents the <code>MapOverview</code>
+	 */
+	public MapOverviewListener(MapOverview mapControl) {
+		this.mapControl = mapControl;
+	}
+
+	/*
+	 * (non-Javadoc)
+	 * @see com.iver.cit.gvsig.fmap.tools.Listeners.PointListener#point(com.iver.cit.gvsig.fmap.tools.Events.PointEvent)
+	 */
+	public void point(PointEvent event) {
+		ViewPort vp = mapControl.getMapContext().getViewPort();
+
+		if (vp.getExtent() != null &&
+				mapControl.getAssociatedMapContext().getViewPort().getExtent()!=null) {
+			Point2D p = vp.toMapPoint(event.getPoint());
+			Rectangle2D r = (Rectangle2D) mapControl.getAssociatedMapContext()
+										   .getViewPort().getExtent().clone();
+
+			r.setRect(p.getX() - (r.getWidth() / 2),
+				p.getY() - (r.getHeight() / 2), r.getWidth(), r.getHeight());
+
+			if (event.getEvent().getButton()!=MouseEvent.BUTTON1) {
+				try {
+					(this.mapControl).getAssociatedMapContext()
+						.getViewPort().setEnvelope(geomManager.createEnvelope(r.getX(),r.getY(),r.getMaxX(),r.getMaxY(), SUBTYPES.GEOM2D));
+				} catch (CreateEnvelopeException e) {
+					logger.error("Error creating the envelope", e);
+				}
+				PluginServices.getMainFrame().enableControls();
+			}
+		}
+	}
+
+	/*
+	 * (non-Javadoc)
+	 * @see com.iver.cit.gvsig.fmap.tools.Listeners.ToolListener#getImageCursor()
+	 */
+	public Image getImageCursor() {
+		return izoomout;
+	}
+
+	/*
+	 * (non-Javadoc)
+	 * @see com.iver.cit.gvsig.fmap.tools.Listeners.ToolListener#cancelDrawing()
+	 */
+	public boolean cancelDrawing() {
+		return true;
+	}
+
+	/*
+	 * (non-Javadoc)
+	 * @see com.iver.cit.gvsig.fmap.tools.Listeners.PointListener#pointDoubleClick(com.iver.cit.gvsig.fmap.tools.Events.PointEvent)
+	 */
+	public void pointDoubleClick(PointEvent event) throws BehaviorException {
+		// TODO Auto-generated method stub
+
+	}
+}

Property changes on: tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/app/project/documents/view/toolListeners/MapOverviewListener.java
___________________________________________________________________
Added: svn:keywords
   + Author Date Id Revision
Added: svn:eol-style
   + native

Index: tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/app/project/documents/view/toolListeners/RectangleSelectListener.java
===================================================================
--- tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/app/project/documents/view/toolListeners/RectangleSelectListener.java	(revision 0)
+++ tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/app/project/documents/view/toolListeners/RectangleSelectListener.java	(revision 38653)
@@ -0,0 +1,77 @@
+/* gvSIG. Sistema de Informaci�n Geogr�fica de la Generalitat Valenciana
+ *
+ * Copyright (C) 2004 IVER T.I. and Generalitat Valenciana.
+ *
+ * This program is free software; you can redistribute it and/or
+ * modify it under the terms of the GNU General Public License
+ * as published by the Free Software Foundation; either version 2
+ * of the License, or (at your option) any later version.
+ *
+ * This program is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
+ * GNU General Public License for more details.
+ *
+ * You should have received a copy of the GNU General Public License
+ * along with this program; if not, write to the Free Software
+ * Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA  02111-1307,USA.
+ *
+ * For more information, contact:
+ *
+ *  Generalitat Valenciana
+ *   Conselleria d'Infraestructures i Transport
+ *   Av. Blasco Ib��ez, 50
+ *   46010 VALENCIA
+ *   SPAIN
+ *
+ *      +34 963862235
+ *   gvsig@gva.es
+ *      www.gvsig.gva.es
+ *
+ *    or
+ *
+ *   IVER T.I. S.A
+ *   Salamanca 50
+ *   46005 Valencia
+ *   Spain
+ *
+ *   +34 963163400
+ *   dac@iver.es
+ */
+package org.gvsig.app.project.documents.view.toolListeners;
+
+import org.gvsig.andami.PluginServices;
+import org.gvsig.fmap.mapcontrol.MapControl;
+import org.gvsig.fmap.mapcontrol.tools.BehaviorException;
+import org.gvsig.fmap.mapcontrol.tools.RectangleSelectionListener;
+import org.gvsig.fmap.mapcontrol.tools.Events.EnvelopeEvent;
+
+
+
+/**
+ * <p>Inherits {@link RectangleSelectionListener RectangleSelectionListener} enabling/disabling special
+ *  controls for managing the data selected.</p>
+ *
+ * @see RectangleSelectionListener
+ *
+ * @author Vicente Caballero Navarro
+ */
+public class RectangleSelectListener extends RectangleSelectionListener {
+	/**
+ 	 * <p>Creates a new <code>RectangleSelectListener</code> object.</p>
+ 	 *
+	 * @param mapCtrl the <code>MapControl</code> where is defined the rectangle
+	 */
+	public RectangleSelectListener(MapControl mapCtrl) {
+		super(mapCtrl);
+	}
+
+	/*
+	 * (non-Javadoc)
+	 * @see com.iver.cit.gvsig.fmap.tools.RectangleSelectionListener#rectangle(com.iver.cit.gvsig.fmap.tools.Events.RectangleEvent)
+	 */
+	public void rectangle(EnvelopeEvent event) throws BehaviorException {
+		super.rectangle(event);
+		PluginServices.getMainFrame().enableControls();
+	}
+}

Property changes on: tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/app/project/documents/view/toolListeners/RectangleSelectListener.java
___________________________________________________________________
Added: svn:eol-style
   + native
Added: svn:keywords
   + Author Date Id Revision

Index: tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/app/project/documents/view/toolListeners/PolygonSelectListener.java
===================================================================
--- tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/app/project/documents/view/toolListeners/PolygonSelectListener.java	(revision 0)
+++ tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/app/project/documents/view/toolListeners/PolygonSelectListener.java	(revision 38653)
@@ -0,0 +1,77 @@
+/* gvSIG. Sistema de Informaci�n Geogr�fica de la Generalitat Valenciana
+ *
+ * Copyright (C) 2004 IVER T.I. and Generalitat Valenciana.
+ *
+ * This program is free software; you can redistribute it and/or
+ * modify it under the terms of the GNU General Public License
+ * as published by the Free Software Foundation; either version 2
+ * of the License, or (at your option) any later version.
+ *
+ * This program is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
+ * GNU General Public License for more details.
+ *
+ * You should have received a copy of the GNU General Public License
+ * along with this program; if not, write to the Free Software
+ * Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA  02111-1307,USA.
+ *
+ * For more information, contact:
+ *
+ *  Generalitat Valenciana
+ *   Conselleria d'Infraestructures i Transport
+ *   Av. Blasco Ib��ez, 50
+ *   46010 VALENCIA
+ *   SPAIN
+ *
+ *      +34 963862235
+ *   gvsig@gva.es
+ *      www.gvsig.gva.es
+ *
+ *    or
+ *
+ *   IVER T.I. S.A
+ *   Salamanca 50
+ *   46005 Valencia
+ *   Spain
+ *
+ *   +34 963163400
+ *   dac@iver.es
+ */
+package org.gvsig.app.project.documents.view.toolListeners;
+
+import org.gvsig.andami.PluginServices;
+import org.gvsig.fmap.mapcontrol.MapControl;
+import org.gvsig.fmap.mapcontrol.tools.BehaviorException;
+import org.gvsig.fmap.mapcontrol.tools.PolygonSelectionListener;
+import org.gvsig.fmap.mapcontrol.tools.Events.MeasureEvent;
+
+
+
+/**
+ * <p>Inherits {@link PolygonSelectionListener PolygonSelectionListener} enabling/disabling special
+ *  controls for managing the data selected.</p>
+ *
+ * @see PolygonSelectionListener
+ *
+ * @author Vicente Caballero Navarro
+ */
+public class PolygonSelectListener extends PolygonSelectionListener {
+	/**
+ 	 * <p>Creates a new <code>PolygonSelectListener</code> object.</p>
+	 *
+	 * @param mapCtrl the <code>MapControl</code> where is drawn the polyline
+	 */
+	public PolygonSelectListener(MapControl mapCtrl) {
+		super(mapCtrl);
+	}
+
+	/*
+	 * (non-Javadoc)
+	 * @see com.iver.cit.gvsig.fmap.tools.PolygonSelectionListener#polylineFinished(com.iver.cit.gvsig.fmap.tools.Events.MeasureEvent)
+	 */
+	public void polylineFinished(MeasureEvent event) throws BehaviorException {
+		super.polylineFinished(event);
+		PluginServices.getMainFrame().enableControls();
+	}
+}

Property changes on: tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/app/project/documents/view/toolListeners/PolygonSelectListener.java
___________________________________________________________________
Added: svn:keywords
   + Author Date Id Revision
Added: svn:eol-style
   + native

Index: tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/app/project/documents/view/toolListeners/AreaListener.java
===================================================================
--- tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/app/project/documents/view/toolListeners/AreaListener.java	(revision 0)
+++ tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/app/project/documents/view/toolListeners/AreaListener.java	(revision 38653)
@@ -0,0 +1,128 @@
+/* gvSIG. Sistema de Informaci�n Geogr�fica de la Generalitat Valenciana
+ *
+ * Copyright (C) 2004 IVER T.I. and Generalitat Valenciana.
+ *
+ * This program is free software; you can redistribute it and/or
+ * modify it under the terms of the GNU General Public License
+ * as published by the Free Software Foundation; either version 2
+ * of the License, or (at your option) any later version.
+ *
+ * This program is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
+ * GNU General Public License for more details.
+ *
+ * You should have received a copy of the GNU General Public License
+ * along with this program; if not, write to the Free Software
+ * Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA  02111-1307,USA.
+ *
+ * For more information, contact:
+ *
+ *  Generalitat Valenciana
+ *   Conselleria d'Infraestructures i Transport
+ *   Av. Blasco Ib��ez, 50
+ *   46010 VALENCIA
+ *   SPAIN
+ *
+ *      +34 963862235
+ *   gvsig@gva.es
+ *      www.gvsig.gva.es
+ *
+ *    or
+ *
+ *   IVER T.I. S.A
+ *   Salamanca 50
+ *   46005 Valencia
+ *   Spain
+ *
+ *   +34 963163400
+ *   dac@iver.es
+ */
+package org.gvsig.app.project.documents.view.toolListeners;
+
+import java.awt.geom.Point2D;
+import java.text.NumberFormat;
+
+import org.gvsig.andami.PluginServices;
+import org.gvsig.andami.ui.mdiFrame.MainFrame;
+import org.gvsig.fmap.mapcontext.MapContext;
+import org.gvsig.fmap.mapcontext.ViewPort;
+import org.gvsig.fmap.mapcontrol.MapControl;
+import org.gvsig.fmap.mapcontrol.tools.AreaListenerImpl;
+import org.gvsig.fmap.mapcontrol.tools.Events.MeasureEvent;
+
+
+
+/**
+ * <p>Listener for calculating the area of a polygon, defined in the associated {@link MapControl MapControl}
+ *  object.</p>
+ * <p>Moves the extent of the associated {@link MapControl MapControl} object
+ *  according the movement between the initial and final points of the line determined by the movement
+ *  dragged with the third button of the mouse.</p>
+ *
+ * <p>Updates the status bar of the main frame of the application with the current area.</p>
+ *
+ * @see AreaListenerImpl
+ *
+ * @author Vicente Caballero Navarro
+ */
+public class AreaListener extends AreaListenerImpl {
+	/**
+ 	 * <p>Creates a new listener for calculating the area of a polygon and displaying it at the status bar
+ 	 *  of the main frame of the application.</p>
+	 *
+	 * @param mc the <code>MapControl</code> where is calculated the area
+	 */
+    public AreaListener(MapControl mc) {
+    	super(mc);
+    }
+
+    /*
+     * (non-Javadoc)
+     * @see com.iver.cit.gvsig.fmap.tools.AreaListenerImpl#points(com.iver.cit.gvsig.fmap.tools.Events.MeasureEvent)
+     */
+    public void points(MeasureEvent event) {
+        this.event = event;
+
+        double dist = 0;
+        double distAll = 0;
+
+        ViewPort vp = mapCtrl.getMapContext().getViewPort();
+        for (int i = 0; i < (event.getXs().length - 1); i++) {
+            dist = 0;
+
+            Point2D p = new Point2D.Double(event.getXs()[i].doubleValue(), event.getYs()[i].doubleValue());//vp.toMapPoint(new Point(event.getXs()[i].intValue(), event.getYs()[i].intValue()));
+            Point2D p2 = new Point2D.Double(event.getXs()[i + 1].doubleValue(), event.getYs()[i + 1].doubleValue());//vp.toMapPoint(new Point(event.getXs()[i + 1].intValue(), event.getYs()[i + 1].intValue()));
+            ///dist = vp.toMapDistance((int) p.distance(p2));
+            dist = vp.distanceWorld(p,p2);
+//            System.out.println("distancia parcial = "+dist);
+            distAll += dist;
+        }
+
+       // System.out.println("Per�metro = " + distAll + " �rea = " +
+       //     (returnArea(vp.toMapPoint(
+       //             new Point2D.Double(
+       //                 event.getXs()[event.getXs().length - 2].doubleValue(),
+       //                 event.getYs()[event.getYs().length - 2].doubleValue())))));
+        NumberFormat nf = NumberFormat.getInstance();
+        nf.setMaximumFractionDigits(2);
+        MainFrame mF = PluginServices.getMainFrame();
+        if (mF != null)
+        {
+        	int distanceUnits=mapCtrl.getViewPort().getDistanceUnits();
+        	int distanceArea=mapCtrl.getViewPort().getDistanceArea();
+            mF.getStatusBar().setMessage("4",
+        			"P:" + nf.format(distAll/MapContext.getDistanceTrans2Meter()[distanceUnits]) + "");
+        		mF.getStatusBar().setMessage("5",
+        			///"A:" + nf.format(returnArea(vp.toMapPoint(
+                    ///        new Point2D.Double(
+                    ///                event.getXs()[event.getXs().length - 2].doubleValue(),
+                    ///                event.getYs()[event.getYs().length - 2].doubleValue())))/FMap.CHANGEM[mapCtrl.getViewPort().getDistanceUnits()]) + "");
+        				"A:" + nf.format(returnArea(
+                                new Point2D.Double(
+                                        event.getXs()[event.getXs().length - 2].doubleValue(),
+                                        event.getYs()[event.getYs().length - 2].doubleValue()))/Math.pow(MapContext.getAreaTrans2Meter()[distanceArea],2)) + "");
+        		mF.getStatusBar().setMessage("distancearea",MapContext.getAreaAbbr()[distanceArea]);
+        }
+    }
+}

Property changes on: tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/app/project/documents/view/toolListeners/AreaListener.java
___________________________________________________________________
Added: svn:keywords
   + Author Date Id Revision
Added: svn:eol-style
   + native

Index: tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/app/project/documents/view/toolListeners/StatusBarListener.java
===================================================================
--- tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/app/project/documents/view/toolListeners/StatusBarListener.java	(revision 0)
+++ tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/app/project/documents/view/toolListeners/StatusBarListener.java	(revision 38653)
@@ -0,0 +1,327 @@
+/* gvSIG. Sistema de Informaci�n Geogr�fica de la Generalitat Valenciana
+ *
+ * Copyright (C) 2004 IVER T.I. and Generalitat Valenciana.
+ *
+ * This program is free software; you can redistribute it and/or
+ * modify it under the terms of the GNU General Public License
+ * as published by the Free Software Foundation; either version 2
+ * of the License, or (at your option) any later version.
+ *
+ * This program is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
+ * GNU General Public License for more details.
+ *
+ * You should have received a copy of the GNU General Public License
+ * along with this program; if not, write to the Free Software
+ * Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA  02111-1307,USA.
+ *
+ * For more information, contact:
+ *
+ *  Generalitat Valenciana
+ *   Conselleria d'Infraestructures i Transport
+ *   Av. Blasco Ib��ez, 50
+ *   46010 VALENCIA
+ *   SPAIN
+ *
+ *      +34 963862235
+ *   gvsig@gva.es
+ *      www.gvsig.gva.es
+ *
+ *    or
+ *
+ *   IVER T.I. S.A
+ *   Salamanca 50
+ *   46005 Valencia
+ *   Spain
+ *
+ *   +34 963163400
+ *   dac@iver.es
+ */
+package org.gvsig.app.project.documents.view.toolListeners;
+
+import java.awt.Image;
+import java.awt.geom.Point2D;
+import java.text.NumberFormat;
+
+import org.cresques.cts.IProjection;
+import org.gvsig.andami.PluginServices;
+import org.gvsig.andami.ui.mdiFrame.MainFrame;
+import org.gvsig.fmap.mapcontext.MapContext;
+import org.gvsig.fmap.mapcontrol.MapControl;
+import org.gvsig.fmap.mapcontrol.tools.BehaviorException;
+import org.gvsig.fmap.mapcontrol.tools.Events.PointEvent;
+import org.gvsig.fmap.mapcontrol.tools.Listeners.PointListener;
+
+
+
+/**
+ * <p>Listener that displays at the status bar of the application's main frame, the value of the point coordinates of the mouse's
+ *  cursor on the associated <code>MapControl</code>, just as is received a <code>PointEvent</code> event.</p>
+ *
+ * <p>Calculates the coordinates equivalent to the point according this rules:
+ *  <ul>
+ *   <li>uses <i><code>formatDegrees(p.get{X or Y}()</code></i> if the associated <code>MapControl</code> object isn't projected.</li>
+ *   <li>uses <i><code>formatDegrees({MapControl's projection}.toGeo(p.get{X or Y}())</code></i> if the associated
+ *    <code>MapControl</code> object is projected and its <code>ViewPort</code>'s distance units are in degrees.</li>
+ *   <li>uses <i><code>{NumberFormat according to {@link #setFractionDigits(Point2D) #setFractionDigits(Point2D)}}.format((p.get{X or Y}()/MapContext.CHANGEM[mapControl.getViewPort().getDistanceUnits()])*MapContext.CHANGEM[mapControl.getViewPort().getMapUnits()])</code></i>
+ *    otherwise.</li>
+ *  </ul>
+ * </p>
+ *
+ * <p>The <u>prefix</u> of the coordinate expressions will be:
+ *  <ul>
+ *   <li>Longitude "<i>Long =</i>" and latitude "<i>Lat =</i>", if the associated <i>MapControl</i> object isn't projected, or the current distance unit
+ *    of the <code>MapControl</code>'s view port is in degrees.</li>
+ *   <li>X "<i>X =</i>" and Y "<i>Y =</i>", otherwise.</li>
+ *  </ul>
+ * </p>
+ *
+ * <p>And the <u>sufix</u> value:
+ *  <ul>
+ *   <li>If the associated <i>MapControl</i> object isn't projected, or the current distance unit
+ *    of the <code>MapControl</code>'s view port is in degrees(expected latitude or longitude), according this pattern:<br>
+ *    <code><b><i>S?G� M' S''</i></b></code>, having:<br>
+ *    <ul>
+ *     <li><i>S?</i> : optionally, if the value is negative, sets a "-" symbol.</li>
+ *     <li><i>G</i> : equivalent grades.</li>
+ *     <li><i>M</i> : equivalent minutes.</li>
+ *     <li><i>S</i> : equivalent seconds.</li>
+ *    </ul>
+ *   </li>
+ *   <li>Otherwise a decimal number according this rules:
+ *    <ul>
+ *     <li><i>8 decimals</i>, if is using any of the following geographic coordinate systems:
+ *      <ul>
+ *       <li><i>EPSG:4230 (known as <a href="http://en.wikipedia.org/wiki/ED50">ED50</a>)</i>.</li>
+ *       <li><i>EPSG:4326 (known as <a href="http://en.wikipedia.org/wiki/WGS84">WGS84</a>)</i>.</li>
+ *      </ul>
+ *     <li><i>2 decimals</i>, otherwise.</li>
+ *    </ul>
+ *   </li>
+ *  </ul>
+ * </p>
+ *
+ * @author Vicente Caballero Navarro
+ */
+public class StatusBarListener implements PointListener {
+	/**
+	 * Reference to the <code>MapControl</code> object that uses.
+	 */
+	private MapControl mapControl = null;
+
+	/**
+	 * Format of the coordinates. Is used to set the number of decimals.
+	 */
+	private NumberFormat nf = null;
+
+	/**
+	 * <p>Creates a new <code>StatusBarListener</code> object.</p>
+	 *
+	 * @param mc the <code>MapControl</code> where will be applied the changes
+	 */
+	public StatusBarListener(MapControl mc) {
+		mapControl = mc;
+		nf = NumberFormat.getInstance();
+		nf.setMaximumFractionDigits(2);
+	}
+
+	/*
+	 * (non-Javadoc)
+	 * @see com.iver.cit.gvsig.fmap.tools.Listeners.ToolListener#getImageCursor()
+	 */
+	public Image getImageCursor() {
+		return null;
+	}
+
+	/*
+	 * (non-Javadoc)
+	 * @see com.iver.cit.gvsig.fmap.tools.Listeners.ToolListener#cancelDrawing()
+	 */
+	public boolean cancelDrawing() {
+		return false;
+	}
+
+	/*
+	 * 050211, jmorell: M�todo modificado para mejorar la manera de mostrar las
+	 * coordenadas geod�sicas en la barra de estado. Muestra Lat y Lon y aumenta
+	 * el n�mero de decimales para cuando trabajemos en coordenadas geod�sicas.
+	 *
+	 * (non-Javadoc)
+	 * @see com.iver.cit.gvsig.fmap.tools.Listeners.PointListener#point(com.iver.cit.gvsig.fmap.tools.Events.PointEvent)
+	 */
+	public void point(PointEvent event) throws BehaviorException {
+		String[] axisText = new String[2];
+		axisText[0] = "X = ";
+		axisText[1] = "Y = ";
+		Point2D p = mapControl.getMapContext().getViewPort().toMapPoint(event.getPoint());
+		setFractionDigits(p);
+		axisText = setCoorDisplayText(axisText);
+		MainFrame mF = PluginServices.getMainFrame();
+
+		if (mF != null){
+
+			mF.getStatusBar().setMessage("units",
+            		PluginServices.getText(this, MapContext.getDistanceNames()[mapControl.getMapContext().getViewPort().getDistanceUnits()]));
+
+			// FJP: No se debe llamar a setControlValue desde aqu�, porque
+            // cambia la escala, y con ella el viewPort (adem�s, de
+            // la vista que no es).
+            // mF.getStatusBar().setControlValue("scale",String.valueOf(mapControl.getMapContext().getScaleView()));
+            // Fin
+			mF.getStatusBar().setMessage("projection", mapControl.getViewPort().getProjection().getAbrev());
+
+			String[] coords=getCoords(p);
+			mF.getStatusBar().setMessage("x", axisText[0] + coords[0]);
+			mF.getStatusBar().setMessage("y", axisText[1] + coords[1]);
+		}
+	}
+
+	/**
+	 * <p>Sets the number of decimals of the coordinates that will be displayed, according the current projection
+	 *  of the associated <code>MapControl</code>:
+	 *  <ul>
+	 *   <li><i>8 decimals</i>, if is using geographical coordinates:
+	 *    <ul>
+	 *     <li><i>EPSG:4230 (known as <a href="http://en.wikipedia.org/wiki/ED50">ED50</a>)</i>.</li>
+	 *     <li><i>EPSG:4326 (known as <a href="http://en.wikipedia.org/wiki/WGS84">WGS84</a>)</i>.</li>
+	 *    </ul>
+	 *   <li><i>2 decimals</i>, otherwise.</li>
+	 *  </ul>
+	 * </p>
+	 *
+	 * @param p unused parameter
+	 *
+	 * @version 050211
+	 * @author jmorell.
+	 */
+	public void setFractionDigits(Point2D p) {
+		IProjection iProj = mapControl.getMapContext().getProjection();
+		if (!iProj.isProjected()) {
+			nf.setMaximumFractionDigits(8);
+		} else {
+			nf.setMaximumFractionDigits(2);
+		}
+	}
+
+	/**
+	 * <p>Gets the name of the coordinates:
+	 *  <ul>
+	 *   <li><i>Longitude</i> and <i>Latitude</i>, if the associated <i>MapControl</i> object isn't projected, or the current distance unit
+	 *    of the <code>MapControl</code>'s view port is in degrees.</li>
+	 *   <li><i>X</i> and <i>Y</i>, otherwise.</li>
+	 *  </ul>
+	 * </p>
+	 *
+	 * @param p array of at least two <code>String</code>, where text will be stored and returned
+	 *
+	 * @return text describing the coordinate value:
+	 *  <ul>
+	 *   <li>If isn't projected:
+	 *    <ul>
+	 *     <li><code>String[0]</code> : "Long = "</li>
+	 *     <li><code>String[1]</code> : "Lat = "</li>
+	 *    </ul>
+	 *   </li>
+	 *   <li>Otherwise:
+	 *    <ul>
+	 *     <li><code>String[0]</code> : "X = "</li>
+	 *     <li><code>String[1]</code> : "Y = "</li>
+	 *    </ul>
+	 *   </li>
+	 *  </ul>
+	 *
+	 * @version 050211
+	 * @author jmorell
+	 */
+	public String[] setCoorDisplayText(String[] axisText) {
+		IProjection iProj = mapControl.getMapContext().getProjection();
+		if (!iProj.isProjected() || MapContext.getDistanceNames()[mapControl.getMapContext().getViewPort().getDistanceUnits()].equals("Grados")) {
+			axisText[0] = "Lon = ";
+			axisText[1] = "Lat = ";
+		} else {
+			axisText[0] = "X = ";
+			axisText[1] = "Y = ";
+		}
+		return axisText;
+	}
+
+	/**
+	 * <p>Converts a decimal value (expected latitude or longitude) in degrees, and formats it according this pattern:<br>
+	 *  <code><b><i>S?G� M' S''</i></b></code>, having:<br>
+	 *  <ul>
+	 *   <li><i>S?</i> : optionally, if the value is negative, sets a "-" symbol.</li>
+	 *   <li><i>G</i> : equivalent grades.</li>
+	 *   <li><i>M</i> : equivalent minutes.</li>
+	 *   <li><i>S</i> : equivalent seconds.</li>
+	 *  </ul>
+	 * </p>
+	 *
+	 * @param d the latitude or longitude value to convert
+	 *
+	 * @return value formatted in degrees
+	 */
+	private String formatDegrees(double d) {
+		String signo = d<0 ? "-" : "";
+		d = Math.abs(d);
+		long grado = 0;
+		double minuto = 0;
+		double segundo = 0;
+
+		grado = (long)(d);
+		minuto = (d - grado) * 60;
+		segundo = (minuto - (long) minuto)*60;
+//		System.out.println("Grados: " + grado);
+//		System.out.println("Minutos: " + minuto);
+//		System.out.println("Segundos: " + segundo);
+		return signo+grado+"� "+(long) minuto+"' "+(long)segundo+"''";
+	}
+
+	/**
+	 * <p>Returns the coordinates equivalent to <code>p</code>:
+	 *  <ul>
+	 *   <li>Uses <i><code>formatDegrees(p.get{X or Y}()</code></i> if the associated <code>MapControl</code> object isn't projected.</li>
+	 *   <li>Uses <i><code>formatDegrees({MapControl's projection}.toGeo(p.get{X or Y}())</code></i> if the associated
+	 *    <code>MapControl</code> object is projected and its <code>ViewPort</code>'s distance units are in degrees.</li>
+	 *   <li>Uses <i><code>{NumberFormat according to {@link #setFractionDigits(Point2D) #setFractionDigits(Point2D)}}.format((p.get{X or Y}()/MapContext.CHANGEM[mapControl.getViewPort().getDistanceUnits()])*MapContext.CHANGEM[mapControl.getViewPort().getMapUnits()])</code></i>
+	 *    otherwise.</li>
+	 *  </ul>
+	 * </p>
+	 *
+	 * @param p point 2D to convert in text coordinates according the projection of the associated <code>MapControl</code> and the
+	 *  distance units of its <code>ViewPort</code>.
+	 *
+	 * @return coordinates equivalent to <code>p</code>, according to the algorithm explained up
+	 */
+	public String[] getCoords(Point2D p) {
+		String[] coords=new String[2];
+		IProjection iProj = mapControl.getMapContext().getProjection();
+		if (!iProj.isProjected()) {
+			coords[0]=String.valueOf(formatDegrees(p.getX()));
+			coords[1]=String.valueOf(formatDegrees(p.getY()));
+		} else {
+			double[] trans2Meter=MapContext.getDistanceTrans2Meter();
+			if (PluginServices.getText(this,MapContext.getDistanceNames()[mapControl.getViewPort().getDistanceUnits()]).equals(PluginServices.getText(this,"Grados"))) {
+				Point2D pgeo=iProj.toGeo(p);
+				coords[0]=String.valueOf(formatDegrees(pgeo.getX()));
+				coords[1]=String.valueOf(formatDegrees(pgeo.getY()));
+			}else {
+				if (PluginServices.getText(this,MapContext.getDistanceNames()[mapControl.getViewPort().getMapUnits()]).equals(PluginServices.getText(this,"Grados"))) {
+					mapControl.getViewPort().setMapUnits(1);
+				}
+
+				coords[0]=String.valueOf(nf.format((p.getX()/trans2Meter[mapControl.getViewPort().getDistanceUnits()])*trans2Meter[mapControl.getViewPort().getMapUnits()]));
+				coords[1]=String.valueOf(nf.format((p.getY()/trans2Meter[mapControl.getViewPort().getDistanceUnits()])*trans2Meter[mapControl.getViewPort().getMapUnits()]));
+			}
+		}
+		return coords;
+	}
+
+	/*
+	 * (non-Javadoc)
+	 * @see com.iver.cit.gvsig.fmap.tools.Listeners.PointListener#pointDoubleClick(com.iver.cit.gvsig.fmap.tools.Events.PointEvent)
+	 */
+	public void pointDoubleClick(PointEvent event) throws BehaviorException {
+		// TODO Auto-generated method stub
+	}
+}

Property changes on: tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/app/project/documents/view/toolListeners/StatusBarListener.java
___________________________________________________________________
Added: svn:keywords
   + Author Date Id Revision
Added: svn:eol-style
   + native

Index: tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/app/project/documents/view/toolListeners/PointSelectListener.java
===================================================================
--- tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/app/project/documents/view/toolListeners/PointSelectListener.java	(revision 0)
+++ tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/app/project/documents/view/toolListeners/PointSelectListener.java	(revision 38653)
@@ -0,0 +1,115 @@
+/* gvSIG. Sistema de Informaci�n Geogr�fica de la Generalitat Valenciana
+ *
+ * Copyright (C) 2004 IVER T.I. and Generalitat Valenciana.
+ *
+ * This program is free software; you can redistribute it and/or
+ * modify it under the terms of the GNU General Public License
+ * as published by the Free Software Foundation; either version 2
+ * of the License, or (at your option) any later version.
+ *
+ * This program is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
+ * GNU General Public License for more details.
+ *
+ * You should have received a copy of the GNU General Public License
+ * along with this program; if not, write to the Free Software
+ * Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA  02111-1307,USA.
+ *
+ * For more information, contact:
+ *
+ *  Generalitat Valenciana
+ *   Conselleria d'Infraestructures i Transport
+ *   Av. Blasco Ib��ez, 50
+ *   46010 VALENCIA
+ *   SPAIN
+ *
+ *      +34 963862235
+ *   gvsig@gva.es
+ *      www.gvsig.gva.es
+ *
+ *    or
+ *
+ *   IVER T.I. S.A
+ *   Salamanca 50
+ *   46005 Valencia
+ *   Spain
+ *
+ *   +34 963163400
+ *   dac@iver.es
+ */
+package org.gvsig.app.project.documents.view.toolListeners;
+
+
+import org.gvsig.andami.PluginServices;
+import org.gvsig.fmap.mapcontrol.MapControl;
+import org.gvsig.fmap.mapcontrol.tools.BehaviorException;
+import org.gvsig.fmap.mapcontrol.tools.PointSelectionListener;
+import org.gvsig.fmap.mapcontrol.tools.Events.PointEvent;
+
+
+
+/**
+ * <p>Inherits {@link PointSelectListener PointSelectListener} enabling/disabling special
+ *  controls for managing the data selected.</p>
+ *
+ * @see PointSelectionListener
+ *
+ * @author Vicente Caballero Navarro
+ */
+public class PointSelectListener extends PointSelectionListener {
+	/**
+	 * <p>Creates a new <code>PointSelectListener</code> object.</p>
+	 * 
+	 * @param mapCtrl the <code>MapControl</code> where will be applied the changes
+	 */
+	public PointSelectListener(MapControl mapCtrl) {
+		super(mapCtrl);
+	}
+
+	/*
+	 * (non-Javadoc)
+	 * @see com.iver.cit.gvsig.fmap.tools.PointSelectionListener#point(com.iver.cit.gvsig.fmap.tools.Events.PointEvent)
+	 */
+	public void point(PointEvent event) throws BehaviorException {
+		super.point(event);
+		PluginServices.getMainFrame().enableControls();
+	}
+
+	/*
+	 * (non-Javadoc)
+	 * @see com.iver.cit.gvsig.fmap.tools.PointSelectionListener#pointDoubleClick(com.iver.cit.gvsig.fmap.tools.Events.PointEvent)
+	 */
+	public void pointDoubleClick(PointEvent event) throws BehaviorException {
+	/*	try {
+			FLayer[] actives = mapCtrl.getMapContext()
+            .getLayers().getActives();
+            for (int i=0; i < actives.length; i++){
+                if (actives[i] instanceof FLyrAnnotation && actives[i].isEditing()) {
+                    FLyrAnnotation lyrAnnotation = (FLyrAnnotation) actives[i];
+
+                    	lyrAnnotation.setSelectedEditing();
+                    	lyrAnnotation.setInEdition(lyrAnnotation.getRecordset().getSelection().nextSetBit(0));
+                    	FLabel fl=lyrAnnotation.getLabel(lyrAnnotation.getInEdition());
+        				if (fl!=null){
+
+        					View vista=(View)PluginServices.getMDIManager().getActiveView();
+        					TextFieldEdit tfe=new TextFieldEdit(lyrAnnotation);
+
+        					tfe.show(vista.getMapControl().getViewPort().fromMapPoint(fl.getOrig()),vista.getMapControl());
+        				}
+
+
+                }
+            }
+
+		} catch (DriverLoadException e) {
+			e.printStackTrace();
+			throw new BehaviorException("Fallo con el recordset");
+		} catch (com.iver.cit.gvsig.fmap.DriverException e) {
+			e.printStackTrace();
+			throw new BehaviorException("Fallo con el recordset");
+		}
+*/
+	}
+}

Property changes on: tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/app/project/documents/view/toolListeners/PointSelectListener.java
___________________________________________________________________
Added: svn:eol-style
   + native
Added: svn:keywords
   + Author Date Id Revision

Index: tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/app/project/documents/view/toolListeners/snapping/snappers/CentralPointSnapper.java
===================================================================
--- tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/app/project/documents/view/toolListeners/snapping/snappers/CentralPointSnapper.java	(revision 0)
+++ tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/app/project/documents/view/toolListeners/snapping/snappers/CentralPointSnapper.java	(revision 38653)
@@ -0,0 +1,65 @@
+package org.gvsig.app.project.documents.view.toolListeners.snapping.snappers;
+
+import java.awt.geom.Point2D;
+
+import org.gvsig.fmap.geom.Geometry;
+import org.gvsig.fmap.geom.handler.CenterHandler;
+import org.gvsig.fmap.geom.handler.Handler;
+import org.gvsig.fmap.mapcontrol.PrimitivesDrawer;
+import org.gvsig.fmap.mapcontrol.tools.snapping.snappers.ISnapperVectorial;
+import org.gvsig.fmap.mapcontrol.tools.snapping.snappers.impl.AbstractSnapper;
+import org.gvsig.i18n.Messages;
+
+
+/**
+ * Central point snapper.
+ *
+ * @author Vicente Caballero Navarro
+ */
+public class CentralPointSnapper extends AbstractSnapper
+    implements ISnapperVectorial {
+	/* (non-Javadoc)
+     * @see com.iver.cit.gvsig.gui.cad.snapping.ISnapper#getSnapPoint(Point2D point,
+     * IGeometry geom,double tolerance, Point2D lastPointEntered)
+     */
+	public Point2D getSnapPoint(Point2D point, Geometry geom,
+        double tolerance, Point2D lastPointEntered) {
+        Point2D resul = null;
+
+        Handler[] handlers = geom.getHandlers(Geometry.SELECTHANDLER);
+
+        double minDist = tolerance;
+
+        for (int j = 0; j < handlers.length; j++) {
+            if (handlers[j] instanceof CenterHandler) {
+                Point2D handlerPoint = handlers[j].getPoint();
+                double dist = handlerPoint.distance(point);
+
+                if ((dist < minDist)) {
+                    resul = handlerPoint;
+                    minDist = dist;
+                }
+            }
+        }
+
+        return resul;
+    }
+	/* (non-Javadoc)
+     * @see com.iver.cit.gvsig.gui.cad.snapping.ISnapper#getToolTipText()
+     */
+    public String getToolTipText() {
+        return Messages.getText("Central_point");
+    }
+
+    /*
+     * (non-Javadoc)
+     * @see org.gvsig.fmap.mapcontrol.tools.snapping.snappers.ISnapper#draw(org.gvsig.fmap.mapcontrol.PrimitivesDrawer, java.awt.geom.Point2D)
+     */
+    public void draw(PrimitivesDrawer primitivesDrawer, Point2D pPixels) {
+    	primitivesDrawer.setColor(getColor());
+
+        int half = getSizePixels() / 2;
+        primitivesDrawer.drawOval((int) (pPixels.getX() - half),
+            (int) (pPixels.getY() - half), getSizePixels(), getSizePixels());
+    }
+}
Index: tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/app/project/documents/view/toolListeners/snapping/snappers/FinalPointSnapper.java
===================================================================
--- tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/app/project/documents/view/toolListeners/snapping/snappers/FinalPointSnapper.java	(revision 0)
+++ tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/app/project/documents/view/toolListeners/snapping/snappers/FinalPointSnapper.java	(revision 38653)
@@ -0,0 +1,62 @@
+package org.gvsig.app.project.documents.view.toolListeners.snapping.snappers;
+
+import java.awt.geom.Point2D;
+
+import org.gvsig.fmap.geom.Geometry;
+import org.gvsig.fmap.geom.handler.Handler;
+import org.gvsig.fmap.mapcontrol.PrimitivesDrawer;
+import org.gvsig.fmap.mapcontrol.tools.snapping.snappers.ISnapperVectorial;
+import org.gvsig.fmap.mapcontrol.tools.snapping.snappers.impl.AbstractSnapper;
+import org.gvsig.i18n.Messages;
+
+
+public class FinalPointSnapper extends AbstractSnapper implements ISnapperVectorial {
+	public Point2D getSnapPoint(Point2D point, Geometry geom, double tolerance, Point2D lastPointEntered) {
+		Point2D resul = null;
+		Handler[] handlers = geom.getHandlers(Geometry.SELECTHANDLER);
+		//		Point2D initPoint=handlers[0].getPoint();
+		//		Point2D endPoint=handlers[handlers.length-1].getPoint();
+		//		if (initPoint.equals(endPoint))
+		//			return resul;
+
+		double minDist = tolerance;
+		//		double dist = initPoint.distance(point);
+		//		if (dist < minDist) {
+		//			resul = initPoint;
+		//			minDist = dist;
+		//		}
+		//
+		//		dist = endPoint.distance(point);
+		//		if (dist < minDist) {
+		//			resul = endPoint;
+		//		}
+
+		for (int j = 0; j < handlers.length; j++) {
+			Point2D handlerPoint = handlers[j].getPoint();
+			double dist = handlerPoint.distance(point);
+			if ((dist < minDist)) {
+				resul = handlerPoint;
+				minDist = dist;
+			}
+		}
+
+		return resul;
+	}
+
+	public String getToolTipText() {
+	    return Messages.getText("Final_point");
+	}
+
+	/*
+	 * (non-Javadoc)
+	 * @see org.gvsig.fmap.mapcontrol.tools.snapping.snappers.ISnapper#draw(org.gvsig.fmap.mapcontrol.PrimitivesDrawer, java.awt.geom.Point2D)
+	 */
+	public void draw(PrimitivesDrawer primitivesDrawer, Point2D pPixels) {
+		primitivesDrawer.setColor(getColor());
+
+		int half = getSizePixels() / 2;
+		primitivesDrawer.drawRect((int) (pPixels.getX() - half),
+				(int) (pPixels.getY() - half),
+				getSizePixels(), getSizePixels());
+	}
+}
Index: tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/app/project/documents/view/toolListeners/snapping/snappers/PerpendicularPointSnapper.java
===================================================================
--- tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/app/project/documents/view/toolListeners/snapping/snappers/PerpendicularPointSnapper.java	(revision 0)
+++ tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/app/project/documents/view/toolListeners/snapping/snappers/PerpendicularPointSnapper.java	(revision 38653)
@@ -0,0 +1,130 @@
+package org.gvsig.app.project.documents.view.toolListeners.snapping.snappers;
+
+import java.awt.geom.PathIterator;
+import java.awt.geom.Point2D;
+
+import org.gvsig.fmap.geom.Geometry;
+import org.gvsig.fmap.mapcontrol.PrimitivesDrawer;
+import org.gvsig.fmap.mapcontrol.tools.snapping.snappers.ISnapperVectorial;
+import org.gvsig.fmap.mapcontrol.tools.snapping.snappers.impl.AbstractSnapper;
+import org.gvsig.i18n.Messages;
+
+import com.vividsolutions.jts.geom.Coordinate;
+import com.vividsolutions.jts.geom.LineSegment;
+
+
+/**
+ * Perpendicular point snapper.
+ *
+ * @author Vicente Caballero Navarro
+ */
+public class PerpendicularPointSnapper extends AbstractSnapper
+    implements ISnapperVectorial {
+	/* (non-Javadoc)
+     * @see com.iver.cit.gvsig.gui.cad.snapping.ISnapper#getSnapPoint(Point2D point,
+     * IGeometry geom,double tolerance, Point2D lastPointEntered)
+     */
+    public Point2D getSnapPoint(Point2D point, Geometry geom,
+        double tolerance, Point2D lastPointEntered) {
+        Point2D resul = null;
+        Coordinate c = new Coordinate(point.getX(), point.getY());
+
+        if (lastPointEntered == null) {
+            return null;
+        }
+
+        Coordinate cLastPoint = new Coordinate(lastPointEntered.getX(),
+                lastPointEntered.getY());
+        PathIterator theIterator = geom.getPathIterator(null,
+                geomManager.getFlatness()); //polyLine.getPathIterator(null, flatness);
+        double[] theData = new double[6];
+        double minDist = tolerance;
+        Coordinate from = null;
+        Coordinate first = null;
+
+        while (!theIterator.isDone()) {
+            //while not done
+            int theType = theIterator.currentSegment(theData);
+
+            switch (theType) {
+            case PathIterator.SEG_MOVETO:
+                from = new Coordinate(theData[0], theData[1]);
+                first = from;
+
+                break;
+
+            case PathIterator.SEG_LINETO:
+
+                // System.out.println("SEG_LINETO");
+                Coordinate to = new Coordinate(theData[0], theData[1]);
+                LineSegment line = new LineSegment(from, to);
+                Coordinate closestPoint = line.closestPoint(cLastPoint);
+                double dist = c.distance(closestPoint);
+
+                if (!(line.getCoordinate(0).equals2D(closestPoint) ||
+                        line.getCoordinate(1).equals2D(closestPoint))) {
+                    if ((dist < minDist)) {
+                        resul = new Point2D.Double(closestPoint.x,
+                                closestPoint.y);
+                        minDist = dist;
+                    }
+                }
+
+                from = to;
+
+                break;
+
+            case PathIterator.SEG_CLOSE:
+                line = new LineSegment(from, first);
+                closestPoint = line.closestPoint(cLastPoint);
+                dist = c.distance(closestPoint);
+
+                if (!(line.getCoordinate(0).equals2D(closestPoint) ||
+                        line.getCoordinate(1).equals2D(closestPoint))) {
+                    if ((dist < minDist)) {
+                        resul = new Point2D.Double(closestPoint.x,
+                                closestPoint.y);
+                        minDist = dist;
+                    }
+                }
+
+                from = first;
+
+                break;
+            } //end switch
+
+            theIterator.next();
+        }
+
+        return resul;
+    }
+
+    /* (non-Javadoc)
+     * @see com.iver.cit.gvsig.gui.cad.snapping.ISnapper#getToolTipText()
+     */
+    public String getToolTipText() {
+        return Messages.getText("Perpendicular_point");
+    }
+
+    /*
+     * (non-Javadoc)
+     * @see org.gvsig.fmap.mapcontrol.tools.snapping.snappers.ISnapper#draw(org.gvsig.fmap.mapcontrol.PrimitivesDrawer, java.awt.geom.Point2D)
+     */
+    public void draw(PrimitivesDrawer primitivesDrawer, Point2D pPixels) {
+    	primitivesDrawer.setColor(getColor());
+
+        int half = getSizePixels() / 2;
+        int x1 = (int) (pPixels.getX() - half);
+        int x2 = (int) (pPixels.getX() + half);
+        int x3 = (int) pPixels.getX();
+        int y1 = (int) (pPixels.getY() - half);
+        int y2 = (int) (pPixels.getY() + half);
+        int y3 = (int) pPixels.getY();
+
+        primitivesDrawer.drawLine(x1, y2, x2, y2);
+        primitivesDrawer.drawLine(x1, y2, x1, y1);
+        primitivesDrawer.drawLine(x1, y3, x3, y3);
+        primitivesDrawer.drawLine(x3, y3, x3, y2);
+    }
+
+}
Index: tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/app/project/documents/view/toolListeners/snapping/snappers/QuadrantPointSnapper.java
===================================================================
--- tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/app/project/documents/view/toolListeners/snapping/snappers/QuadrantPointSnapper.java	(revision 0)
+++ tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/app/project/documents/view/toolListeners/snapping/snappers/QuadrantPointSnapper.java	(revision 38653)
@@ -0,0 +1,74 @@
+package org.gvsig.app.project.documents.view.toolListeners.snapping.snappers;
+
+import java.awt.geom.Point2D;
+
+import org.gvsig.fmap.geom.Geometry;
+import org.gvsig.fmap.geom.handler.CuadrantHandler;
+import org.gvsig.fmap.geom.handler.Handler;
+import org.gvsig.fmap.mapcontrol.PrimitivesDrawer;
+import org.gvsig.fmap.mapcontrol.tools.snapping.snappers.ISnapperVectorial;
+import org.gvsig.fmap.mapcontrol.tools.snapping.snappers.impl.AbstractSnapper;
+import org.gvsig.i18n.Messages;
+
+
+/**
+ * Quadrant point snapper.
+ *
+ * @author Vicente Caballero Navarro
+ */
+public class QuadrantPointSnapper extends AbstractSnapper
+    implements ISnapperVectorial {
+	/* (non-Javadoc)
+     * @see com.iver.cit.gvsig.gui.cad.snapping.ISnapper#getSnapPoint(Point2D point,
+     * IGeometry geom,double tolerance, Point2D lastPointEntered)
+     */
+    public Point2D getSnapPoint(Point2D point, Geometry geom,
+        double tolerance, Point2D lastPointEntered) {
+        Point2D resul = null;
+
+        Handler[] handlers = geom.getHandlers(Geometry.SELECTHANDLER);
+
+        double minDist = tolerance;
+
+        for (int j = 0; j < handlers.length; j++) {
+            if (handlers[j] instanceof CuadrantHandler) {
+                Point2D handlerPoint = handlers[j].getPoint();
+                double dist = handlerPoint.distance(point);
+
+                if ((dist < minDist)) {
+                    resul = handlerPoint;
+                    minDist = dist;
+                }
+            }
+        }
+
+        return resul;
+    }
+
+    /* (non-Javadoc)
+     * @see com.iver.cit.gvsig.gui.cad.snapping.ISnapper#getToolTipText()
+     */
+    public String getToolTipText() {
+        return Messages.getText("Quadrant_point");
+    }
+
+    /* (non-Javadoc)
+     * @see com.iver.cit.gvsig.gui.cad.snapping.ISnapper#draw(java.awt.Graphics, java.awt.geom.Point2D)
+     */
+    public void draw(PrimitivesDrawer primitivesDrawer, Point2D pPixels) {
+    	primitivesDrawer.setColor(getColor());
+
+        int half = getSizePixels() / 2;
+        int x1 = (int) (pPixels.getX() - half);
+        int x2 = (int) (pPixels.getX() + half);
+        int x3 = (int) pPixels.getX();
+        int y1 = (int) (pPixels.getY() - half);
+        int y2 = (int) (pPixels.getY() + half);
+        int y3 = (int) pPixels.getY();
+
+        primitivesDrawer.drawLine(x1, y3, x3, y1);
+        primitivesDrawer.drawLine(x1, y3, x3, y2);
+        primitivesDrawer.drawLine(x2, y3, x3, y1);
+        primitivesDrawer.drawLine(x2, y3, x3, y2);
+    }
+}
Index: tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/app/project/documents/view/toolListeners/snapping/snappers/MediumPointSnapper.java
===================================================================
--- tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/app/project/documents/view/toolListeners/snapping/snappers/MediumPointSnapper.java	(revision 0)
+++ tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/app/project/documents/view/toolListeners/snapping/snappers/MediumPointSnapper.java	(revision 38653)
@@ -0,0 +1,123 @@
+package org.gvsig.app.project.documents.view.toolListeners.snapping.snappers;
+
+import java.awt.geom.PathIterator;
+import java.awt.geom.Point2D;
+
+import org.gvsig.fmap.geom.Geometry;
+import org.gvsig.fmap.geom.primitive.Arc;
+import org.gvsig.fmap.geom.primitive.Circle;
+import org.gvsig.fmap.geom.primitive.Ellipse;
+import org.gvsig.fmap.geom.primitive.Spline;
+import org.gvsig.fmap.mapcontrol.PrimitivesDrawer;
+import org.gvsig.fmap.mapcontrol.tools.snapping.snappers.ISnapperVectorial;
+import org.gvsig.fmap.mapcontrol.tools.snapping.snappers.impl.AbstractSnapper;
+import org.gvsig.i18n.Messages;
+
+import com.vividsolutions.jts.geom.Coordinate;
+
+
+/**
+ * Medium point snapper.
+ *
+ * @author Vicente Caballero Navarro
+ */
+public class MediumPointSnapper extends AbstractSnapper
+    implements ISnapperVectorial {
+	/* (non-Javadoc)
+     * @see com.iver.cit.gvsig.gui.cad.snapping.ISnapper#getSnapPoint(Point2D point,
+     * IGeometry geom,double tolerance, Point2D lastPointEntered)
+     */
+    public Point2D getSnapPoint(Point2D point, Geometry geom,
+        double tolerance, Point2D lastPointEntered) {
+        if (geom instanceof Circle ||
+                geom instanceof Arc ||
+                geom instanceof Ellipse ||
+                geom instanceof Spline) {
+            return null;
+        }
+
+        Point2D resul = null;
+        Coordinate c = new Coordinate(point.getX(), point.getY());
+
+        PathIterator theIterator = geom.getPathIterator(null,
+                geomManager.getFlatness()); //polyLine.getPathIterator(null, flatness);
+        double[] theData = new double[6];
+        double minDist = tolerance;
+        Coordinate from = null;
+        Coordinate first = null;
+
+        while (!theIterator.isDone()) {
+            //while not done
+            int theType = theIterator.currentSegment(theData);
+
+            switch (theType) {
+            case PathIterator.SEG_MOVETO:
+                from = new Coordinate(theData[0], theData[1]);
+                first = from;
+
+                break;
+
+            case PathIterator.SEG_LINETO:
+
+                Coordinate to = new Coordinate(theData[0], theData[1]);
+                Coordinate mediumPoint = new Coordinate((to.x + from.x) / 2,
+                        (to.y + from.y) / 2);
+                double dist = c.distance(mediumPoint);
+
+                if ((dist < minDist)) {
+                    resul = new Point2D.Double(mediumPoint.x, mediumPoint.y);
+                    minDist = dist;
+                }
+
+                from = to;
+
+                break;
+
+            case PathIterator.SEG_CLOSE:
+                mediumPoint = new Coordinate((first.x + from.x) / 2,
+                        (first.y + from.y) / 2);
+                dist = c.distance(mediumPoint);
+
+                if ((dist < minDist)) {
+                    resul = new Point2D.Double(mediumPoint.x, mediumPoint.y);
+                    minDist = dist;
+                }
+
+                from = first;
+
+                break;
+            } //end switch
+
+            theIterator.next();
+        }
+
+        return resul;
+    }
+
+    /* (non-Javadoc)
+     * @see com.iver.cit.gvsig.gui.cad.snapping.ISnapper#getToolTipText()
+     */
+    public String getToolTipText() {
+        return Messages.getText("Medium_point");
+    }
+
+    /*
+     * (non-Javadoc)
+     * @see org.gvsig.fmap.mapcontrol.tools.snapping.snappers.ISnapper#draw(org.gvsig.fmap.mapcontrol.PrimitivesDrawer, java.awt.geom.Point2D)
+     */
+    public void draw(PrimitivesDrawer primitivesDrawer, Point2D pPixels) {
+    	primitivesDrawer.setColor(getColor());
+
+        int half = getSizePixels() / 2;
+        int x1 = (int) (pPixels.getX() - half);
+        int x2 = (int) (pPixels.getX() + half);
+        int x3 = (int) pPixels.getX();
+        int y1 = (int) (pPixels.getY() - half);
+        int y2 = (int) (pPixels.getY() + half);
+
+        primitivesDrawer.drawLine(x1, y2, x2, y2);
+        primitivesDrawer.drawLine(x1, y2, x3, y1);
+        primitivesDrawer.drawLine(x2, y2, x3, y1);
+    }
+
+}
Index: tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/app/project/documents/view/toolListeners/snapping/snappers/TangentPointSnapper.java
===================================================================
--- tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/app/project/documents/view/toolListeners/snapping/snappers/TangentPointSnapper.java	(revision 0)
+++ tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/app/project/documents/view/toolListeners/snapping/snappers/TangentPointSnapper.java	(revision 38653)
@@ -0,0 +1,122 @@
+package org.gvsig.app.project.documents.view.toolListeners.snapping.snappers;
+
+import java.awt.geom.PathIterator;
+import java.awt.geom.Point2D;
+
+import org.gvsig.fmap.geom.Geometry;
+import org.gvsig.fmap.geom.primitive.Arc;
+import org.gvsig.fmap.geom.primitive.Circle;
+import org.gvsig.fmap.geom.primitive.Ellipse;
+import org.gvsig.fmap.geom.primitive.Spline;
+import org.gvsig.fmap.mapcontrol.PrimitivesDrawer;
+import org.gvsig.fmap.mapcontrol.tools.snapping.snappers.ISnapperVectorial;
+import org.gvsig.fmap.mapcontrol.tools.snapping.snappers.impl.AbstractSnapper;
+import org.gvsig.i18n.Messages;
+
+import com.vividsolutions.jts.geom.Coordinate;
+import com.vividsolutions.jts.geom.LineSegment;
+
+
+/**
+ * Tangent point snapper.
+ *
+ * @author Vicente Caballero Navarro
+ */
+public class TangentPointSnapper extends AbstractSnapper
+    implements ISnapperVectorial {
+	/* (non-Javadoc)
+     * @see com.iver.cit.gvsig.gui.cad.snapping.ISnapper#getSnapPoint(Point2D point,
+     * IGeometry geom,double tolerance, Point2D lastPointEntered)
+     */
+    public Point2D getSnapPoint(Point2D point, Geometry geom,
+        double tolerance, Point2D lastPointEntered) {
+        if (!(geom instanceof Circle ||
+                geom instanceof Arc ||
+                geom instanceof Ellipse ||
+                geom instanceof Spline)) {
+            return null;
+        }
+
+        Point2D resul = null;
+        Coordinate c = new Coordinate(point.getX(), point.getY());
+
+        PathIterator theIterator = geom.getPathIterator(null,
+                geomManager.getFlatness());
+        double[] theData = new double[6];
+        double minDist = tolerance;
+        Coordinate from = null;
+        Coordinate first = null;
+
+        while (!theIterator.isDone()) {
+            //while not done
+            int theType = theIterator.currentSegment(theData);
+
+            switch (theType) {
+            case PathIterator.SEG_MOVETO:
+                from = new Coordinate(theData[0], theData[1]);
+                first = from;
+
+                break;
+
+            case PathIterator.SEG_LINETO:
+
+                // System.out.println("SEG_LINETO");
+                Coordinate to = new Coordinate(theData[0], theData[1]);
+                LineSegment line = new LineSegment(from, to);
+                Coordinate closestPoint = line.closestPoint(c);
+                double dist = c.distance(closestPoint);
+
+                if ((dist < minDist)) {
+                    resul = new Point2D.Double(closestPoint.x, closestPoint.y);
+                    minDist = dist;
+                }
+
+                from = to;
+
+                break;
+
+            case PathIterator.SEG_CLOSE:
+                line = new LineSegment(from, first);
+                closestPoint = line.closestPoint(c);
+                dist = c.distance(closestPoint);
+
+                if ((dist < minDist)) {
+                    resul = new Point2D.Double(closestPoint.x, closestPoint.y);
+                    minDist = dist;
+                }
+
+                from = first;
+
+                break;
+            } //end switch
+
+            theIterator.next();
+        }
+
+        return resul;
+    }
+
+    /* (non-Javadoc)
+     * @see com.iver.cit.gvsig.gui.cad.snapping.ISnapper#getToolTipText()
+     */
+    public String getToolTipText() {
+        return Messages.getText("Tangent_point");
+    }
+
+    /*
+     * (non-Javadoc)
+     * @see org.gvsig.fmap.mapcontrol.tools.snapping.snappers.ISnapper#draw(org.gvsig.fmap.mapcontrol.PrimitivesDrawer, java.awt.geom.Point2D)
+     */
+    public void draw(PrimitivesDrawer primitivesDrawer, Point2D pPixels) {
+    	primitivesDrawer.setColor(getColor());
+
+        int half = getSizePixels() / 2;
+        primitivesDrawer.drawLine((int) (pPixels.getX() - half),
+            (int) (pPixels.getY() - half), (int) (pPixels.getX() + half),
+            (int) (pPixels.getY() - half));
+        primitivesDrawer.drawOval((int) (pPixels.getX() - half),
+            (int) (pPixels.getY() - half), getSizePixels(), getSizePixels());
+    }
+
+
+}
Index: tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/app/project/documents/view/toolListeners/snapping/snappers/NearestPointSnapper.java
===================================================================
--- tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/app/project/documents/view/toolListeners/snapping/snappers/NearestPointSnapper.java	(revision 0)
+++ tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/app/project/documents/view/toolListeners/snapping/snappers/NearestPointSnapper.java	(revision 38653)
@@ -0,0 +1,90 @@
+package org.gvsig.app.project.documents.view.toolListeners.snapping.snappers;
+
+import java.awt.geom.PathIterator;
+import java.awt.geom.Point2D;
+
+import org.gvsig.fmap.geom.Geometry;
+import org.gvsig.fmap.mapcontrol.PrimitivesDrawer;
+import org.gvsig.fmap.mapcontrol.tools.snapping.snappers.ISnapperVectorial;
+import org.gvsig.fmap.mapcontrol.tools.snapping.snappers.impl.AbstractSnapper;
+import org.gvsig.i18n.Messages;
+
+import com.vividsolutions.jts.geom.Coordinate;
+import com.vividsolutions.jts.geom.LineSegment;
+
+public class NearestPointSnapper extends AbstractSnapper implements ISnapperVectorial {
+	public Point2D getSnapPoint(Point2D point, Geometry geom, double tolerance, Point2D lastPointEntered) {
+		Point2D resul = null;
+		Coordinate c = new Coordinate(point.getX(), point.getY());
+
+		PathIterator theIterator = geom.getPathIterator(null, geomManager.getFlatness()); //polyLine.getPathIterator(null, flatness);
+		double[] theData = new double[6];
+		double minDist = tolerance;
+		Coordinate from = null, first = null;
+		while (!theIterator.isDone()) {
+			//while not done
+			int theType = theIterator.currentSegment(theData);
+
+			switch (theType) {
+				case PathIterator.SEG_MOVETO:
+					from = new Coordinate(theData[0], theData[1]);
+					first = from;
+					break;
+
+				case PathIterator.SEG_LINETO:
+
+					// System.out.println("SEG_LINETO");
+					Coordinate to = new Coordinate(theData[0], theData[1]);
+					LineSegment line = new LineSegment(from, to);
+					Coordinate closestPoint = line.closestPoint(c);
+					double dist = c.distance(closestPoint);
+					if ((dist < minDist)) {
+						resul = new Point2D.Double(closestPoint.x, closestPoint.y);
+						minDist = dist;
+					}
+
+					from = to;
+					break;
+				case PathIterator.SEG_CLOSE:
+					line = new LineSegment(from, first);
+					closestPoint = line.closestPoint(c);
+					dist = c.distance(closestPoint);
+					if ((dist < minDist)) {
+						resul = new Point2D.Double(closestPoint.x, closestPoint.y);
+						minDist = dist;
+					}
+
+					from = first;
+					break;
+
+
+			} //end switch
+
+			theIterator.next();
+		}
+
+		return resul;
+	}
+
+	public String getToolTipText() {
+		return Messages.getText("Nearest_point");
+	}
+
+	/*
+	 * (non-Javadoc)
+	 * @see org.gvsig.fmap.mapcontrol.tools.snapping.snappers.ISnapper#draw(org.gvsig.fmap.mapcontrol.PrimitivesDrawer, java.awt.geom.Point2D)
+	 */
+	public void draw(PrimitivesDrawer primitivesDrawer, Point2D pPixels) {
+		primitivesDrawer.setColor(getColor());
+		int half = getSizePixels() / 2;
+		int x1 = (int) (pPixels.getX() - half);
+		int x2 = (int) (pPixels.getX() + half);
+		int y1 = (int) (pPixels.getY() - half);
+		int y2 = (int) (pPixels.getY() + half);
+
+		primitivesDrawer.drawLine(x1, y1, x2, y1); // abajo
+		primitivesDrawer.drawLine(x1, y2, x2, y2); // arriba
+		primitivesDrawer.drawLine(x1, y1, x2, y2); // abajo - arriba
+		primitivesDrawer.drawLine(x1, y2, x2, y1); // arriba - abajo
+	}
+}
Index: tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/app/project/documents/view/toolListeners/snapping/snappers/InsertPointSnapper.java
===================================================================
--- tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/app/project/documents/view/toolListeners/snapping/snappers/InsertPointSnapper.java	(revision 0)
+++ tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/app/project/documents/view/toolListeners/snapping/snappers/InsertPointSnapper.java	(revision 38653)
@@ -0,0 +1,63 @@
+package org.gvsig.app.project.documents.view.toolListeners.snapping.snappers;
+
+import java.awt.geom.Point2D;
+
+import org.gvsig.fmap.geom.Geometry;
+import org.gvsig.fmap.mapcontrol.PrimitivesDrawer;
+import org.gvsig.fmap.mapcontrol.tools.snapping.snappers.ISnapperVectorial;
+import org.gvsig.fmap.mapcontrol.tools.snapping.snappers.impl.AbstractSnapper;
+import org.gvsig.i18n.Messages;
+
+
+
+/**
+ * Insert point snapper.
+ *
+ * @author Vicente Caballero Navarro
+ */
+public class InsertPointSnapper extends AbstractSnapper
+    implements ISnapperVectorial {
+	/* (non-Javadoc)
+     * @see com.iver.cit.gvsig.gui.cad.snapping.ISnapper#getSnapPoint(Point2D point,
+     * IGeometry geom,double tolerance, Point2D lastPointEntered)
+     */
+    public Point2D getSnapPoint(Point2D point, Geometry geom,
+        double tolerance, Point2D lastPointEntered) {
+        Point2D resul = null;
+
+        return resul;
+    }
+
+    /* (non-Javadoc)
+     * @see com.iver.cit.gvsig.gui.cad.snapping.ISnapper#getToolTipText()
+     */
+    public String getToolTipText() {
+        return Messages.getText("Insert_point");
+    }
+
+    /*
+     * (non-Javadoc)
+     * @see org.gvsig.fmap.mapcontrol.tools.snapping.snappers.ISnapper#draw(org.gvsig.fmap.mapcontrol.PrimitivesDrawer, java.awt.geom.Point2D)
+     */
+    public void draw(PrimitivesDrawer primitivesDrawer, Point2D pPixels) {
+    	primitivesDrawer.setColor(getColor());
+
+        int half = getSizePixels() / 2;
+        int x1 = (int) (pPixels.getX() - half);
+        int x2 = (int) (pPixels.getX() + half);
+        int x3 = (int) pPixels.getX();
+        int y1 = (int) (pPixels.getY() - half);
+        int y2 = (int) (pPixels.getY() + half);
+        int y3 = (int) pPixels.getY();
+
+        primitivesDrawer.drawLine(x1, y1, x3, y1);
+        primitivesDrawer.drawLine(x1, y1, x1, y3);
+        primitivesDrawer.drawLine(x1, y3, x3, y3);
+        primitivesDrawer.drawLine(x3, y1, x3, y3);
+
+        primitivesDrawer.drawLine(x3, y3, x2, y3);
+        primitivesDrawer.drawLine(x3, y3, x3, y2);
+        primitivesDrawer.drawLine(x3, y2, x2, y2);
+        primitivesDrawer.drawLine(x2, y3, x2, y2);
+    }
+}
Index: tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/app/project/documents/view/toolListeners/snapping/snappers/IntersectionPointSnapper.java
===================================================================
--- tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/app/project/documents/view/toolListeners/snapping/snappers/IntersectionPointSnapper.java	(revision 0)
+++ tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/app/project/documents/view/toolListeners/snapping/snappers/IntersectionPointSnapper.java	(revision 38653)
@@ -0,0 +1,101 @@
+package org.gvsig.app.project.documents.view.toolListeners.snapping.snappers;
+
+import java.awt.geom.Point2D;
+import java.util.List;
+
+import org.slf4j.Logger;
+import org.slf4j.LoggerFactory;
+
+import org.gvsig.fmap.geom.Geometry;
+import org.gvsig.fmap.geom.operation.GeometryOperationException;
+import org.gvsig.fmap.geom.operation.GeometryOperationNotSupportedException;
+import org.gvsig.fmap.geom.primitive.Curve;
+import org.gvsig.fmap.mapcontrol.PrimitivesDrawer;
+import org.gvsig.fmap.mapcontrol.tools.snapping.snappers.ISnapperGeometriesVectorial;
+import org.gvsig.fmap.mapcontrol.tools.snapping.snappers.impl.AbstractSnapper;
+import org.gvsig.i18n.Messages;
+
+
+/**
+ * Intersection point snapper.
+ *
+ * @author Vicente Caballero Navarro
+ */
+public class IntersectionPointSnapper extends AbstractSnapper
+    implements ISnapperGeometriesVectorial {
+    private static final Logger LOG = LoggerFactory.getLogger(IntersectionPointSnapper.class);
+    
+	private static int maxPointsGeom = 1000;
+	private List<Geometry> geometries;
+
+    public Point2D getSnapPoint(Point2D point, Geometry geom,
+        double tolerance, Point2D lastPointEntered) {
+    	if (!(geom instanceof Curve)){
+    		return null;
+    	}
+    	Point2D result = null;
+
+        if (geometries == null) {
+            return null;
+        }
+
+        for (int i = 0; i < geometries.size(); i++) {
+        	Point2D r = intersects(geom, geometries.get(i), point, tolerance);
+
+            if (r != null) {
+                result = r;
+            }
+        }
+
+        return result;
+    }
+
+    private Point2D intersects(Geometry geometry1, Geometry geometry2, Point2D point,
+            double tolerance) {
+    	
+    	//If there is a topology error don't intersects
+    	if ((geometry1 == null) || (geometry2 == null)){
+    	    return null;
+    	}
+    	
+    	//The getNumCoords is not a getNumPoints but it is a good approximation...    	
+    	if (geometry1.getGeneralPath().getNumCoords() > maxPointsGeom || geometry2.getGeneralPath().getNumCoords() > maxPointsGeom){
+    		return null;
+    	}
+    	
+    	Geometry geometry;
+        try {
+            geometry = geometry1.intersection(geometry2);
+            if ((geometry != null) && (geometry.getType() == Geometry.TYPES.POINT)){
+                return geometry.getHandlers(Geometry.SELECTHANDLER)[0].getPoint();
+            }
+        } catch (GeometryOperationNotSupportedException e) {
+            LOG.error("Is not possible to intersect these geometries", e);
+        } catch (GeometryOperationException e) {
+            LOG.error("Is not possible to intersect these geometries", e);
+        }    
+    	
+    	return null;
+    }
+
+    public void draw(PrimitivesDrawer primitivesDrawer, Point2D pPixels) {
+    	primitivesDrawer.setColor(getColor());
+
+        int half = getSizePixels() / 2;
+        int x1 = (int) (pPixels.getX() - half);
+        int x2 = (int) (pPixels.getX() + half);
+        int y1 = (int) (pPixels.getY() - half);
+        int y2 = (int) (pPixels.getY() + half);
+
+        primitivesDrawer.drawLine(x1, y1, x2, y2);
+        primitivesDrawer.drawLine(x1, y2, x2, y1);
+    }
+
+    public String getToolTipText() {
+        return Messages.getText("Intersection_point");
+    }
+
+	public void setGeometries(List geoms) {
+	    this.geometries = geoms;		
+	}
+}
Index: tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/app/project/documents/view/toolListeners/snapping/snappers/PixelSnapper.java
===================================================================
--- tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/app/project/documents/view/toolListeners/snapping/snappers/PixelSnapper.java	(revision 0)
+++ tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/app/project/documents/view/toolListeners/snapping/snappers/PixelSnapper.java	(revision 38653)
@@ -0,0 +1,147 @@
+/* gvSIG. Sistema de Informaci�n Geogr�fica de la Generalitat Valenciana
+ *
+ * Copyright (C) 2004 IVER T.I. and Generalitat Valenciana.
+ *
+ * This program is free software; you can redistribute it and/or
+ * modify it under the terms of the GNU General Public License
+ * as published by the Free Software Foundation; either version 2
+ * of the License, or (at your option) any later version.
+ *
+ * This program is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
+ * GNU General Public License for more details.
+ *
+ * You should have received a copy of the GNU General Public License
+ * along with this program; if not, write to the Free Software
+ * Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA  02111-1307,USA.
+ *
+ * For more information, contact:
+ *
+ *  Generalitat Valenciana
+ *   Conselleria d'Infraestructures i Transport
+ *   Av. Blasco Ib��ez, 50
+ *   46010 VALENCIA
+ *   SPAIN
+ *
+ *      +34 963862235
+ *   gvsig@gva.es
+ *      www.gvsig.gva.es
+ *
+ *    or
+ *
+ *   IVER T.I. S.A
+ *   Salamanca 50
+ *   46005 Valencia
+ *   Spain
+ *
+ *   +34 963163400
+ *   dac@iver.es
+ */
+package org.gvsig.app.project.documents.view.toolListeners.snapping.snappers;
+
+import java.awt.Color;
+import java.awt.geom.Point2D;
+import java.awt.image.BufferedImage;
+import java.awt.image.ColorModel;
+
+import org.gvsig.fmap.mapcontext.ViewPort;
+import org.gvsig.fmap.mapcontrol.PrimitivesDrawer;
+import org.gvsig.fmap.mapcontrol.MapControl;
+import org.gvsig.fmap.mapcontrol.tools.snapping.snappers.ISnapperRaster;
+import org.gvsig.fmap.mapcontrol.tools.snapping.snappers.impl.AbstractSnapper;
+import org.gvsig.i18n.Messages;
+
+import com.vividsolutions.jts.geom.Coordinate;
+
+public class PixelSnapper extends AbstractSnapper implements ISnapperRaster {
+	private Color refColor = Color.BLACK;
+	private int tolColorR = 100;
+	private int tolColorG = 100;
+	private int tolColorB = 100;
+	/* (non-Javadoc)
+	 * @see com.iver.cit.gvsig.gui.cad.snapping.ISnapperRaster#getSnapPoint(java.awt.image.BufferedImage, java.awt.geom.Point2D, double, java.awt.geom.Point2D)
+	 */
+	public Point2D getSnapPoint(MapControl mapControl, Point2D point,
+			double mapTolerance, Point2D lastPoint) {
+		// Miramos dentro del rect�ngulo que define la tolerancia
+		// y nos quedamos con el pixel que m�s se acerca al que buscamos
+		BufferedImage img = mapControl.getImage();
+		ViewPort vp = mapControl.getViewPort();
+		Point2D pPixel = vp.fromMapPoint(point);
+		int xPixel = (int) pPixel.getX();
+		int yPixel = (int) pPixel.getY();
+//		int centerRGB = img.getRGB(xPixel, yPixel);
+		int centerRGB = refColor.getRGB();
+		double x1 = ColorModel.getRGBdefault().getRed(centerRGB);
+		double y1 = ColorModel.getRGBdefault().getGreen(centerRGB);
+		double z1 = ColorModel.getRGBdefault().getBlue(centerRGB);
+		Coordinate c = new Coordinate(x1, y1, z1);
+
+		int half = vp.fromMapDistance(mapTolerance) / 2;
+		double minDistColor = Double.MAX_VALUE;
+		int xSnapped = -1;
+		int ySnapped = -1;
+		int fromX =xPixel -half;
+		if (fromX <0) fromX = 0;
+		int fromY =yPixel -half;
+		if (fromY <0) fromY = 0;
+
+		int toX =xPixel + half;
+		if (toX > vp.getImageWidth()) toX = vp.getImageWidth();
+		int toY =yPixel + half;
+		if (toY > vp.getImageHeight()) toY = vp.getImageHeight();
+
+		for (int testX= fromX; testX< toX; testX++)
+		{
+			for (int testY= fromY; testY< toY; testY++)
+			{
+				// System.out.println("Testing: " + testX + ", " + testY);
+				int testRGB = img.getRGB(testX, testY);
+				// TODO: Aqu� deber�amos trabajar con un ColorSpace y usar toCIEXYZ. Por ahora lo calculo con RGB.
+				int r = ColorModel.getRGBdefault().getRed(testRGB);
+				int g = ColorModel.getRGBdefault().getGreen(testRGB);
+				int b = ColorModel.getRGBdefault().getBlue(testRGB);
+				Coordinate cAux = new Coordinate(r, g, b);
+
+				if (Math.abs(r-x1) < tolColorR)
+					if (Math.abs(g-y1) < tolColorG)
+						if (Math.abs(b-z1) < tolColorB)
+						{
+							double dist = c.distance(cAux);
+							if (dist < minDistColor)
+							{
+								minDistColor = dist;
+								xSnapped = testX;
+								ySnapped = testY;
+							}
+						}
+			}
+		}
+		Point2D pResul = null;
+		if (xSnapped != -1)
+		{
+			pResul = vp.toMapPoint(xSnapped, ySnapped);
+		}
+		return pResul;
+	}
+
+	/*
+	 * (non-Javadoc)
+	 * @see org.gvsig.fmap.mapcontrol.tools.snapping.snappers.ISnapper#draw(org.gvsig.fmap.mapcontrol.PrimitivesDrawer, java.awt.geom.Point2D)
+	 */
+	public void draw(PrimitivesDrawer primitivesDrawer, Point2D pPixels) {
+		primitivesDrawer.setColor(getColor());
+		int half = getSizePixels() / 2;
+		primitivesDrawer.drawOval((int) (pPixels.getX() - half),
+				(int) (pPixels.getY() - half),
+				getSizePixels(), getSizePixels());
+	}
+
+	public String getToolTipText() {
+		return Messages.getText("Pixel_point");
+	}
+
+}
+
+
Index: tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/app/project/documents/view/toolListeners/snapping/Snapping.java
===================================================================
--- tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/app/project/documents/view/toolListeners/snapping/Snapping.java	(revision 0)
+++ tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/app/project/documents/view/toolListeners/snapping/Snapping.java	(revision 38653)
@@ -0,0 +1,47 @@
+package org.gvsig.app.project.documents.view.toolListeners.snapping;
+
+
+import org.gvsig.app.project.documents.view.toolListeners.snapping.snappers.CentralPointSnapper;
+import org.gvsig.app.project.documents.view.toolListeners.snapping.snappers.FinalPointSnapper;
+import org.gvsig.app.project.documents.view.toolListeners.snapping.snappers.IntersectionPointSnapper;
+import org.gvsig.app.project.documents.view.toolListeners.snapping.snappers.MediumPointSnapper;
+import org.gvsig.app.project.documents.view.toolListeners.snapping.snappers.NearestPointSnapper;
+import org.gvsig.app.project.documents.view.toolListeners.snapping.snappers.PerpendicularPointSnapper;
+import org.gvsig.app.project.documents.view.toolListeners.snapping.snappers.PixelSnapper;
+import org.gvsig.app.project.documents.view.toolListeners.snapping.snappers.QuadrantPointSnapper;
+import org.gvsig.app.project.documents.view.toolListeners.snapping.snappers.TangentPointSnapper;
+import org.gvsig.fmap.mapcontrol.MapControlLocator;
+import org.gvsig.fmap.mapcontrol.MapControlManager;
+import org.gvsig.fmap.mapcontrol.impl.DefaultMapControlLibrary;
+import org.gvsig.fmap.mapcontrol.impl.DefaultMapControlManager;
+import org.gvsig.tools.ToolsLocator;
+import org.gvsig.tools.extensionpoint.ExtensionPoint;
+
+
+/**
+ * DOCUMENT ME!
+ *
+ * @author Vicente Caballero Navarro
+ */
+public class Snapping {
+    /**
+     * DOCUMENT ME!
+     */
+    public static void register() {    	//TODO delete when the system to load libraries is finished
+    	if (MapControlLocator.getMapControlManager() == null){
+    		MapControlLocator.registerMapControlManager(DefaultMapControlManager.class);
+    	}
+    	MapControlManager mapControlManager = MapControlLocator.getMapControlManager();
+    	    	
+    	mapControlManager.registerSnapper("FinalPointSnapper", FinalPointSnapper.class);
+    	mapControlManager.registerSnapper("NearestPointSnapper", NearestPointSnapper.class);
+    	mapControlManager.registerSnapper("PixelSnapper", PixelSnapper.class);
+    	mapControlManager.registerSnapper("CentralPointSnapper", CentralPointSnapper.class);
+    	mapControlManager.registerSnapper("QuadrantPointSnapper", QuadrantPointSnapper.class);
+//		mapControlManager.registerSnapper("InsertPointSnapper", new InsertPointSnapper.class);
+    	mapControlManager.registerSnapper("IntersectionPointSnapper", IntersectionPointSnapper.class);
+    	mapControlManager.registerSnapper("MediumPointSnapper", MediumPointSnapper.class);
+    	mapControlManager.registerSnapper("PerpendicularPointSnapper", PerpendicularPointSnapper.class);
+    	mapControlManager.registerSnapper("TangentPointSnapper", TangentPointSnapper.class);
+    }
+}
Index: tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/app/project/documents/view/toolListeners/snapping/gui/DefaultConfigurePanel.java
===================================================================
--- tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/app/project/documents/view/toolListeners/snapping/gui/DefaultConfigurePanel.java	(revision 0)
+++ tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/app/project/documents/view/toolListeners/snapping/gui/DefaultConfigurePanel.java	(revision 38653)
@@ -0,0 +1,105 @@
+package org.gvsig.app.project.documents.view.toolListeners.snapping.gui;
+
+import java.awt.event.ActionListener;
+
+import javax.swing.JButton;
+import javax.swing.JDialog;
+import javax.swing.JLabel;
+import javax.swing.JPanel;
+
+import org.gvsig.andami.PluginServices;
+import org.gvsig.andami.ui.mdiManager.IWindow;
+import org.gvsig.andami.ui.mdiManager.WindowInfo;
+import org.gvsig.fmap.mapcontrol.tools.snapping.snappers.ISnapper;
+import org.gvsig.gui.beans.AcceptCancelPanel;
+
+
+public class DefaultConfigurePanel extends JPanel implements IWindow {
+	private ISnapper snapper;
+	private JLabel lblColor = null;
+	private JButton bColor = null;
+	private WindowInfo wi=null;
+	private AcceptCancelPanel acceptCancelPanel;
+	/**
+	 * This is the default constructor
+	 */
+	public DefaultConfigurePanel() {
+		super();
+		initialize();
+	}
+
+	/**
+	 * This method initializes this
+	 *
+	 * @return void
+	 */
+	private void initialize() {
+		lblColor = new JLabel();
+		lblColor.setText("color");
+		this.setSize(269, 91);
+		this.add(lblColor, null);
+		this.add(getBColor(), null);
+		this.add(getPAcceptCancel(),null);
+	}
+	public void setSnapper(ISnapper snapper) {
+		this.snapper=snapper;
+		//((AbstractSnapper)this.snapper).setColor(Color.blue);
+	}
+
+	/**
+	 * This method initializes bColor
+	 *
+	 * @return javax.swing.JButton
+	 */
+	private JButton getBColor() {
+		if (bColor == null) {
+			bColor = new JButton();
+			bColor.setText("...");
+		}
+		return bColor;
+	}
+
+	protected AcceptCancelPanel getPAcceptCancel() {
+		if (acceptCancelPanel==null) {
+			ActionListener okAction = new java.awt.event.ActionListener() {
+				public void actionPerformed(java.awt.event.ActionEvent e) {
+
+					if (PluginServices.getMainFrame() == null) {
+                        ((JDialog) (getParent().getParent().getParent()
+                                .getParent())).dispose();
+                    } else {
+                        PluginServices.getMDIManager().closeWindow(DefaultConfigurePanel.this);
+                    }
+				}
+			};
+			ActionListener cancelAction = new java.awt.event.ActionListener() {
+				public void actionPerformed(java.awt.event.ActionEvent e) {
+                    if (PluginServices.getMainFrame() != null) {
+                        PluginServices.getMDIManager().closeWindow(DefaultConfigurePanel.this);
+                    } else {
+                        ((JDialog) (getParent().getParent().getParent()
+                                        .getParent())).dispose();
+                    }
+				}
+			};
+			acceptCancelPanel=new AcceptCancelPanel(okAction,cancelAction);
+
+		}
+		return acceptCancelPanel;
+	}
+
+	public WindowInfo getWindowInfo() {
+		if (wi==null) {
+			wi=new WindowInfo(WindowInfo.MODALDIALOG|WindowInfo.RESIZABLE);
+			wi.setWidth(this.getWidth());
+			wi.setHeight(this.getHeight());
+			wi.setTitle(PluginServices.getText(this,"propiedades"));
+		}
+		return wi;
+	}
+
+	public Object getWindowProfile() {
+		return WindowInfo.DIALOG_PROFILE;
+	}
+
+}  //  @jve:decl-index=0:visual-constraint="10,10"
Index: tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/app/project/documents/view/toolListeners/snapping/gui/DrawSnapCellRenderer.java
===================================================================
--- tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/app/project/documents/view/toolListeners/snapping/gui/DrawSnapCellRenderer.java	(revision 0)
+++ tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/app/project/documents/view/toolListeners/snapping/gui/DrawSnapCellRenderer.java	(revision 38653)
@@ -0,0 +1,84 @@
+/* gvSIG. Sistema de Informaci�n Geogr�fica de la Generalitat Valenciana
+ *
+ * Copyright (C) 2004 IVER T.I. and Generalitat Valenciana.
+ *
+ * This program is free software; you can redistribute it and/or
+ * modify it under the terms of the GNU General Public License
+ * as published by the Free Software Foundation; either version 2
+ * of the License, or (at your option) any later version.
+ *
+ * This program is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
+ * GNU General Public License for more details.
+ *
+ * You should have received a copy of the GNU General Public License
+ * along with this program; if not, write to the Free Software
+ * Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA  02111-1307,USA.
+ *
+ * For more information, contact:
+ *
+ *  Generalitat Valenciana
+ *   Conselleria d'Infraestructures i Transport
+ *   Av. Blasco Ib��ez, 50
+ *   46010 VALENCIA
+ *   SPAIN
+ *
+ *      +34 963862235
+ *   gvsig@gva.es
+ *      www.gvsig.gva.es
+ *
+ *    or
+ *
+ *   IVER T.I. S.A
+ *   Salamanca 50
+ *   46005 Valencia
+ *   Spain
+ *
+ *   +34 963163400
+ *   dac@iver.es
+ */
+package org.gvsig.app.project.documents.view.toolListeners.snapping.gui;
+
+import java.awt.Color;
+import java.awt.Component;
+import java.awt.Graphics;
+import java.awt.geom.Point2D;
+
+import javax.swing.JPanel;
+import javax.swing.JTable;
+import javax.swing.table.TableCellRenderer;
+
+import org.gvsig.fmap.mapcontrol.MapControlLocator;
+import org.gvsig.fmap.mapcontrol.MapControlManager;
+import org.gvsig.fmap.mapcontrol.PrimitivesDrawer;
+import org.gvsig.fmap.mapcontrol.impl.DefaultPrimitivesDrawer;
+
+/**
+ * Cell Renderer del s�mbolo de cada uno de los ISnapper.
+ *
+ * @author Vicente Caballero Navarro
+ */
+public class DrawSnapCellRenderer extends JPanel implements TableCellRenderer {
+	private static Point2D position = new Point2D.Double(7,7);
+	private static MapControlManager mapControlManager = MapControlLocator.getMapControlManager();
+	private PrimitivesDrawer primitivesDrawer = new DefaultPrimitivesDrawer();
+	
+	private int row;
+	public DrawSnapCellRenderer() {
+		this.setBackground(Color.white);
+	}
+	public Component getTableCellRendererComponent(JTable table, Object value, boolean isSelected, boolean hasFocus, int row, int column) {
+		this.row=row;
+		return this;
+	}
+	protected void paintComponent(Graphics g) {
+		super.paintComponent(g);
+		
+		primitivesDrawer.setGraphics(g);
+		
+		(mapControlManager.getSnapperAt(row)).draw(primitivesDrawer, position);
+	}
+
+
+}
Index: tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/app/project/documents/view/toolListeners/snapping/gui/SnapConfig.java
===================================================================
--- tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/app/project/documents/view/toolListeners/snapping/gui/SnapConfig.java	(revision 0)
+++ tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/app/project/documents/view/toolListeners/snapping/gui/SnapConfig.java	(revision 38653)
@@ -0,0 +1,347 @@
+/* gvSIG. Sistema de Informaci�n Geogr�fica de la Generalitat Valenciana
+ *
+ * Copyright (C) 2004 IVER T.I. and Generalitat Valenciana.
+ *
+ * This program is free software; you can redistribute it and/or
+ * modify it under the terms of the GNU General Public License
+ * as published by the Free Software Foundation; either version 2
+ * of the License, or (at your option) any later version.
+ *
+ * This program is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
+ * GNU General Public License for more details.
+ *
+ * You should have received a copy of the GNU General Public License
+ * along with this program; if not, write to the Free Software
+ * Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA  02111-1307,USA.
+ *
+ * For more information, contact:
+ *
+ *  Generalitat Valenciana
+ *   Conselleria d'Infraestructures i Transport
+ *   Av. Blasco Ib��ez, 50
+ *   46010 VALENCIA
+ *   SPAIN
+ *
+ *      +34 963862235
+ *   gvsig@gva.es
+ *      www.gvsig.gva.es
+ *
+ *    or
+ *
+ *   IVER T.I. S.A
+ *   Salamanca 50
+ *   46005 Valencia
+ *   Spain
+ *
+ *   +34 963163400
+ *   dac@iver.es
+ */
+package org.gvsig.app.project.documents.view.toolListeners.snapping.gui;
+
+import java.awt.BorderLayout;
+import java.awt.Component;
+import java.util.ArrayList;
+import java.util.Map;
+
+import javax.swing.JButton;
+import javax.swing.JCheckBox;
+import javax.swing.JList;
+import javax.swing.JPanel;
+import javax.swing.JScrollPane;
+import javax.swing.JTable;
+import javax.swing.ListCellRenderer;
+import javax.swing.border.EmptyBorder;
+import javax.swing.table.AbstractTableModel;
+import javax.swing.table.TableColumn;
+import javax.swing.table.TableModel;
+
+import org.gvsig.andami.PluginServices;
+import org.gvsig.fmap.mapcontrol.MapControl;
+import org.gvsig.fmap.mapcontrol.MapControlLocator;
+import org.gvsig.fmap.mapcontrol.MapControlManager;
+import org.gvsig.fmap.mapcontrol.tools.snapping.snappers.ISnapper;
+import java.util.TreeMap;
+
+/**
+ * @author fjp
+ *
+ * Necesitamos un sitio donde est�n registrados todos los snappers que
+ * se pueden usar. ExtensionPoints es el sitio adecuado.
+ * Este di�logo recuperar� esa lista para que el usuario marque los
+ * snappers con los que desea trabajar.
+ */
+public class SnapConfig extends JPanel {
+
+	private JCheckBox jChkBoxRefentActive = null;
+	private JTable jListSnappers = null;
+	private JPanel jPanel = null;
+	private JScrollPane jScrollPane = null;
+
+	//	private ArrayList snappers;
+	private MapControl mc;
+	private static MapControlManager mapControlManager = MapControlLocator.getMapControlManager();
+
+	/**
+	 * @author fjp
+	 * primera columna editable con un check box para habilitar/deshabilitar el snapper
+	 * segunda columna con el s�mbolo del snapper
+	 * tercera con el tooltip
+	 * cuarta con un bot�n para configurar el snapper si es necesario.
+	 */
+	class MyTableModel extends AbstractTableModel {
+
+		public MyTableModel()
+		{
+			
+		}
+
+		public int getColumnCount() {
+			return 5;
+		}
+
+		public int getRowCount() {
+			return mapControlManager.getSnapperCount();
+		}
+
+		public boolean isCellEditable(int rowIndex, int columnIndex) {
+			if (columnIndex == 0 || columnIndex == 3)
+				return true;
+			return false;
+		}
+
+		public void setValueAt(Object aValue, int rowIndex, int columnIndex) {
+			ISnapper snap = mapControlManager.getSnapperAt(rowIndex);
+			switch (columnIndex)
+			{
+			case 0://CheckBox
+				snap.setEnabled(((Boolean)aValue).booleanValue());
+				break;
+			case 3://Prioridad
+				snap.setPriority(((Integer)aValue).intValue());
+				break;
+			}
+		}
+
+		public Object getValueAt(int rowIndex, int columnIndex) {
+			ISnapper snap = mapControlManager.getSnapperAt(rowIndex);
+			switch (columnIndex)
+			{
+			case 0:
+				return new Boolean(snap.isEnabled());
+			case 1:
+				return snap.getClass().getName();
+			case 2:
+				return snap.getToolTipText();
+			case 3:
+				return new Integer(snap.getPriority());
+			case 4:
+				return new JButton();
+			}
+			return null;
+		}
+
+		public Class getColumnClass(int columnIndex) {
+			switch (columnIndex)
+			{
+			case 0:
+				return Boolean.class;
+			case 1:
+				return String.class;
+			case 2:
+				return String.class;
+			case 3:
+				return Integer.class;
+			case 4:
+				return JButton.class;
+			}
+			return null;
+		}
+
+		public String getColumnName(int columnIndex) {
+			switch (columnIndex){
+			case 0:
+				return PluginServices.getText(this,"aplicar");
+			case 1:
+				return PluginServices.getText(this,"simbolo");
+			case 2:
+				return PluginServices.getText(this,"tipo");
+			case 3:
+				return PluginServices.getText(this,"prioridad");
+			case 4:
+				return PluginServices.getText(this,"propiedades");
+			}
+			return null;
+		}
+
+	}
+
+	class MyCellRenderer extends JCheckBox implements ListCellRenderer {
+
+		// This is the only method defined by ListCellRenderer.
+		// We just reconfigure the JLabel each time we're called.
+
+		public Component getListCellRendererComponent(
+				JList list,
+				Object value,            // value to display
+				int index,               // cell index
+				boolean isSelected,      // is the cell selected
+				boolean cellHasFocus)    // the list and the cell have the focus
+		{
+			ISnapper snapper = (ISnapper) value;
+			String s = snapper.getToolTipText();
+			setText(s);
+
+			if (isSelected) {
+				setBackground(list.getSelectionBackground());
+				setForeground(list.getSelectionForeground());
+			}
+			else {
+				setBackground(list.getBackground());
+				setForeground(list.getForeground());
+			}
+			setEnabled(list.isEnabled());
+			setFont(list.getFont());
+			setOpaque(true);
+			return this;
+		}
+
+		public void doClick() {
+			super.doClick();
+			System.out.println("Click");
+		}
+
+
+	}
+
+
+	/**
+	 * This method initializes
+	 *
+	 */
+	public SnapConfig(MapControl mc) {
+		super();
+		this.mc=mc;
+		initialize();
+	}
+
+	/**
+	 * This method initializes this
+	 *
+	 */
+	private void initialize() {
+		this.setLayout(new BorderLayout());
+		this.setBorder(new EmptyBorder(10, 10, 10, 10));
+		this.setSize(new java.awt.Dimension(463,239));
+		this.setPreferredSize(new java.awt.Dimension(463,239));
+		this.add(getJChkBoxRefentActive(), BorderLayout.NORTH);
+		this.add(getJPanel(), BorderLayout.CENTER);
+
+	}
+
+	/**
+	 * This method initializes jChkBoxRefentActive
+	 *
+	 * @return javax.swing.JCheckBox
+	 */
+	private JCheckBox getJChkBoxRefentActive() {
+		if (jChkBoxRefentActive == null) {
+			jChkBoxRefentActive = new JCheckBox();
+			jChkBoxRefentActive.setText("Referencia a Objetos Activada:");
+			jChkBoxRefentActive.setBounds(new java.awt.Rectangle(26,10,418,23));
+		}
+		return jChkBoxRefentActive;
+	}
+
+	/**
+	 * This method initializes jListSnappers
+	 *
+	 * @return javax.swing.JList
+	 */
+	private JTable getJListSnappers() {
+		if (jListSnappers == null) {
+			jListSnappers = new JTable();
+			// jListSnappers.setCellRenderer(new MyCellRenderer());
+		}
+		return jListSnappers;
+	}
+
+	/**
+	 * This method initializes jPanel
+	 *
+	 * @return javax.swing.JPanel
+	 */
+	private JPanel getJPanel() {
+		if (jPanel == null) {
+			jPanel = new JPanel();
+			jPanel.setLayout(new BorderLayout());
+			jPanel.setBorder(new EmptyBorder(5, 0, 0, 0));
+			jPanel.setBounds(new java.awt.Rectangle(19,40,423,181));
+			jPanel.add(getJScrollPane(), BorderLayout.CENTER);
+		}
+		return jPanel;
+	}
+
+	/**
+	 * This method initializes jScrollPane
+	 *
+	 * @return javax.swing.JScrollPane
+	 */
+	private JScrollPane getJScrollPane() {
+		if (jScrollPane == null) {
+			jScrollPane = new JScrollPane();
+			jScrollPane.setBounds(new java.awt.Rectangle(9,9,402,163));
+			jScrollPane.setViewportView(getJListSnappers());
+		}
+		return jScrollPane;
+	}
+
+	//	public ArrayList getSnappers() {
+	//		return snappers;
+	//	}
+
+	public void setSnappers() {		
+		MyTableModel listModel = new MyTableModel();
+		getJListSnappers().setModel(listModel);
+		TableColumn tc=getJListSnappers().getColumnModel().getColumn(0);
+		setUpSymbolColumn(getJListSnappers().getColumnModel().getColumn(1));
+		setUpPropertyColumn(getJListSnappers().getColumnModel().getColumn(4));
+		getJListSnappers().setCellSelectionEnabled(false);
+		tc.setMaxWidth(40);
+		tc.setMinWidth(20);
+	}
+	public TableModel getTableModel() {
+		return getJListSnappers().getModel();
+	}
+	public boolean applySnappers() {
+		return getJChkBoxRefentActive().isSelected();
+	}
+
+
+	public void selectSnappers() {
+		for (int i=0;i<mapControlManager.getSnapperCount();i++) {
+			getTableModel().setValueAt(mapControlManager.getSnapperAt(i).isEnabled(),i,0);			
+		}
+
+	}
+
+	public void setApplySnappers(boolean applySnappers) {
+		getJChkBoxRefentActive().setSelected(applySnappers);
+	}
+
+	public void setUpSymbolColumn(TableColumn column) {
+		DrawSnapCellRenderer symbolCellRenderer = new DrawSnapCellRenderer();
+		column.setCellRenderer(symbolCellRenderer);
+	}
+	public void setUpPropertyColumn(TableColumn column) {
+
+		PropertySnapCellEditor propertyeditor = new PropertySnapCellEditor();
+		column.setCellEditor(propertyeditor);
+
+		PropertySnapCellRenderer renderer = new PropertySnapCellRenderer();
+		column.setCellRenderer(renderer);
+	}
+}  //  @jve:decl-index=0:visual-constraint="10,10"
+
+
Index: tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/app/project/documents/view/toolListeners/snapping/gui/PropertySnapCellEditor.java
===================================================================
--- tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/app/project/documents/view/toolListeners/snapping/gui/PropertySnapCellEditor.java	(revision 0)
+++ tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/app/project/documents/view/toolListeners/snapping/gui/PropertySnapCellEditor.java	(revision 38653)
@@ -0,0 +1,124 @@
+package org.gvsig.app.project.documents.view.toolListeners.snapping.gui;
+
+import java.awt.Color;
+import java.awt.Component;
+import java.awt.event.MouseEvent;
+import java.awt.event.MouseListener;
+import java.util.ArrayList;
+import java.util.EventObject;
+
+import javax.swing.JButton;
+import javax.swing.JTable;
+import javax.swing.event.CellEditorListener;
+import javax.swing.table.TableCellEditor;
+
+import org.gvsig.andami.PluginServices;
+import org.gvsig.andami.ui.mdiManager.IWindow;
+import org.gvsig.fmap.mapcontrol.MapControlLocator;
+import org.gvsig.fmap.mapcontrol.MapControlManager;
+import org.gvsig.fmap.mapcontrol.tools.snapping.snappers.ISnapper;
+
+
+public class PropertySnapCellEditor extends JButton implements TableCellEditor{
+	private int row;
+	private IWindow panel;
+	private static MapControlManager mapControlManager = MapControlLocator.getMapControlManager();
+	
+	public PropertySnapCellEditor() {		
+		this.addMouseListener(new MouseListener() {
+
+			public void mouseClicked(MouseEvent e) {
+				if (e.getClickCount()==2) {
+					if (panel!=null)
+						openConfigurePanel();
+				}
+			}
+
+			public void mouseEntered(MouseEvent e) {
+				// TODO Auto-generated method stub
+
+			}
+
+			public void mouseExited(MouseEvent e) {
+				// TODO Auto-generated method stub
+
+			}
+
+			public void mousePressed(MouseEvent e) {
+				// TODO Auto-generated method stub
+
+			}
+
+			public void mouseReleased(MouseEvent e) {
+				// TODO Auto-generated method stub
+
+			}
+
+		});
+	}
+//	class WinConfigure extends JPanel implements IWindow {
+//
+//		private WindowInfo wi=null;
+//
+//		public WindowInfo getWindowInfo() {
+//			if (wi==null) {
+//				wi=new WindowInfo(WindowInfo.MODALDIALOG|WindowInfo.RESIZABLE);
+//				wi.setWidth(panel.getWidth());
+//				wi.setHeight(panel.getHeight());
+//				wi.setTitle(PluginServices.getText(this,"propiedades"));
+//			}
+//			return wi;
+//		}
+//	}
+	private void openConfigurePanel() {
+		//IWindow window=new WinConfigure();
+		((DefaultConfigurePanel)panel).setSnapper(mapControlManager.getSnapperAt(row));
+		PluginServices.getMDIManager().addWindow(panel);
+	}
+	public Component getTableCellEditorComponent(JTable table, Object value, boolean isSelected, int row, int column) {
+		this.row=row;
+		panel=(IWindow)(mapControlManager.getSnapperAt(row)).getConfigurator();
+		if (panel!=null) {
+			this.setEnabled(true);
+		}else {
+			this.setEnabled(false);
+			this.setBackground(Color.white);
+		}
+		return this;
+	}
+
+	public void cancelCellEditing() {
+		// TODO Auto-generated method stub
+
+	}
+
+	public boolean stopCellEditing() {
+		// TODO Auto-generated method stub
+		return false;
+	}
+
+	public Object getCellEditorValue() {
+		// TODO Auto-generated method stub
+		return null;
+	}
+
+	public boolean isCellEditable(EventObject anEvent) {
+		return true;
+	}
+
+	public boolean shouldSelectCell(EventObject anEvent) {
+		// TODO Auto-generated method stub
+		return false;
+	}
+
+	public void addCellEditorListener(CellEditorListener l) {
+		// TODO Auto-generated method stub
+
+	}
+
+	public void removeCellEditorListener(CellEditorListener l) {
+		// TODO Auto-generated method stub
+
+	}
+
+}
Index: tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/app/project/documents/view/toolListeners/snapping/gui/PropertySnapCellRenderer.java
===================================================================
--- tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/app/project/documents/view/toolListeners/snapping/gui/PropertySnapCellRenderer.java	(revision 0)
+++ tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/app/project/documents/view/toolListeners/snapping/gui/PropertySnapCellRenderer.java	(revision 38653)
@@ -0,0 +1,35 @@
+package org.gvsig.app.project.documents.view.toolListeners.snapping.gui;
+
+import java.awt.Color;
+import java.awt.Component;
+import java.util.ArrayList;
+
+import javax.swing.JButton;
+import javax.swing.JPanel;
+import javax.swing.JTable;
+import javax.swing.table.TableCellRenderer;
+
+import org.gvsig.fmap.mapcontrol.MapControlLocator;
+import org.gvsig.fmap.mapcontrol.MapControlManager;
+import org.gvsig.fmap.mapcontrol.tools.snapping.snappers.ISnapper;
+
+
+public class PropertySnapCellRenderer extends JButton implements TableCellRenderer{
+	private JPanel panel;
+	private static MapControlManager mapControlManager = MapControlLocator.getMapControlManager();
+	
+	public PropertySnapCellRenderer() {
+		this.setText("...");
+	}
+	public Component getTableCellRendererComponent(JTable table, Object value, boolean isSelected, boolean hasFocus, int row, int column) {
+		panel=(JPanel)(mapControlManager.getSnapperAt(row)).getConfigurator();
+		if (panel!=null) {
+			this.setEnabled(true);
+		}else {
+			this.setEnabled(false);
+			this.setBackground(Color.white);
+		}
+		return this;
+	}
+
+}
Index: tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/app/project/documents/view/toolListeners/snapping/gui/testDialog.java
===================================================================
--- tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/app/project/documents/view/toolListeners/snapping/gui/testDialog.java	(revision 0)
+++ tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/app/project/documents/view/toolListeners/snapping/gui/testDialog.java	(revision 38653)
@@ -0,0 +1,108 @@
+/* gvSIG. Sistema de Informaci�n Geogr�fica de la Generalitat Valenciana
+ *
+ * Copyright (C) 2004 IVER T.I. and Generalitat Valenciana.
+ *
+ * This program is free software; you can redistribute it and/or
+ * modify it under the terms of the GNU General Public License
+ * as published by the Free Software Foundation; either version 2
+ * of the License, or (at your option) any later version.
+ *
+ * This program is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
+ * GNU General Public License for more details.
+ *
+ * You should have received a copy of the GNU General Public License
+ * along with this program; if not, write to the Free Software
+ * Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA  02111-1307,USA.
+ *
+ * For more information, contact:
+ *
+ *  Generalitat Valenciana
+ *   Conselleria d'Infraestructures i Transport
+ *   Av. Blasco Ib��ez, 50
+ *   46010 VALENCIA
+ *   SPAIN
+ *
+ *      +34 963862235
+ *   gvsig@gva.es
+ *      www.gvsig.gva.es
+ *
+ *    or
+ *
+ *   IVER T.I. S.A
+ *   Salamanca 50
+ *   46005 Valencia
+ *   Spain
+ *
+ *   +34 963163400
+ *   dac@iver.es
+ */
+package org.gvsig.app.project.documents.view.toolListeners.snapping.gui;
+
+import java.util.ArrayList;
+
+import javax.swing.AbstractAction;
+import javax.swing.Action;
+import javax.swing.JButton;
+import javax.swing.JDialog;
+import javax.swing.UIManager;
+import javax.swing.UnsupportedLookAndFeelException;
+
+import org.gvsig.app.project.documents.view.toolListeners.snapping.snappers.FinalPointSnapper;
+import org.gvsig.fmap.mapcontrol.MapControl;
+
+
+public class testDialog {
+	public static void main(String[] args) {
+
+		try {
+			UIManager.setLookAndFeel(UIManager.getSystemLookAndFeelClassName());
+		} catch (ClassNotFoundException e) {
+			// TODO Auto-generated catch block
+			e.printStackTrace();
+		} catch (InstantiationException e) {
+			// TODO Auto-generated catch block
+			e.printStackTrace();
+		} catch (IllegalAccessException e) {
+			// TODO Auto-generated catch block
+			e.printStackTrace();
+		} catch (UnsupportedLookAndFeelException e) {
+			// TODO Auto-generated catch block
+			e.printStackTrace();
+		}
+
+		JDialog dlg = new JDialog();
+
+		ArrayList list = new ArrayList();
+		for (int i=0; i < 20; i++)
+			list.add(new FinalPointSnapper());
+		SnapConfig panel = new SnapConfig(new MapControl());
+		panel.setSnappers();
+		Action act = new AbstractAction(){
+			public void actionPerformed(java.awt.event.ActionEvent arg0) {
+				System.out.println("HOla");
+//				HashPrintRequestAttributeSet att = new HashPrintRequestAttributeSet();
+//
+//				PrinterJob job = PrinterJob.getPrinterJob();
+//				PageFormat defaulFormat = job.defaultPage();
+//				// PageFormat selectedFormat = job.pageDialog(defaulFormat);
+//				Paper paper = new Paper();
+//				paper.setSize(MediaSize.ISO.A5.getX(MediaSize.INCH),MediaSize.ISO.A5.getY(MediaSize.INCH));
+//				defaulFormat.setPaper(paper);
+//				job.defaultPage(defaulFormat);
+//				if (job.printDialog()) {
+//					// System.out.println(job.)
+//				}
+			};
+		};
+		JButton btnPrint = new JButton(act);
+
+		dlg.getContentPane().add(panel);
+		// dlg.getContentPane().add(btnPrint);
+		// dlg.getContentPane().setSize(panel.getSize());
+		dlg.pack();
+		dlg.show(true);
+	}
+
+}
Index: tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/app/project/documents/view/toolListeners/InfoListener.java
===================================================================
--- tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/app/project/documents/view/toolListeners/InfoListener.java	(revision 0)
+++ tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/app/project/documents/view/toolListeners/InfoListener.java	(revision 38653)
@@ -0,0 +1,230 @@
+/* gvSIG. Sistema de Informaci�n Geogr�fica de la Generalitat Valenciana
+ *
+ * Copyright (C) 2004 IVER T.I. and Generalitat Valenciana.
+ *
+ * This program is free software; you can redistribute it and/or
+ * modify it under the terms of the GNU General Public License
+ * as published by the Free Software Foundation; either version 2
+ * of the License, or (at your option) any later version.
+ *
+ * This program is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
+ * GNU General Public License for more details.
+ *
+ * You should have received a copy of the GNU General Public License
+ * along with this program; if not, write to the Free Software
+ * Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA  02111-1307,USA.
+ *
+ * For more information, contact:
+ *
+ *  Generalitat Valenciana
+ *   Conselleria d'Infraestructures i Transport
+ *   Av. Blasco Ib��ez, 50
+ *   46010 VALENCIA
+ *   SPAIN
+ *
+ *      +34 963862235
+ *   gvsig@gva.es
+ *      www.gvsig.gva.es
+ *
+ *    or
+ *
+ *   IVER T.I. S.A
+ *   Salamanca 50
+ *   46005 Valencia
+ *   Spain
+ *
+ *   +34 963163400
+ *   dac@iver.es
+ */
+package org.gvsig.app.project.documents.view.toolListeners;
+
+import java.awt.GridBagConstraints;
+import java.awt.Image;
+import java.util.HashMap;
+import java.util.Map;
+
+import org.slf4j.Logger;
+import org.slf4j.LoggerFactory;
+
+import org.gvsig.andami.PluginServices;
+import org.gvsig.andami.messages.NotificationManager;
+import org.gvsig.andami.ui.mdiManager.IWindow;
+import org.gvsig.andami.ui.mdiManager.SingletonWindow;
+import org.gvsig.app.ApplicationLocator;
+import org.gvsig.app.ApplicationManager;
+import org.gvsig.app.project.documents.view.info.gui.FInfoDialog;
+import org.gvsig.fmap.geom.primitive.Point;
+import org.gvsig.fmap.mapcontext.layers.FLayer;
+import org.gvsig.fmap.mapcontext.layers.operations.InfoByPoint;
+import org.gvsig.fmap.mapcontrol.MapControl;
+import org.gvsig.fmap.mapcontrol.MapControlLocator;
+import org.gvsig.fmap.mapcontrol.swing.dynobject.LayersDynObjectSetComponent;
+import org.gvsig.fmap.mapcontrol.tools.BehaviorException;
+import org.gvsig.fmap.mapcontrol.tools.Events.PointEvent;
+import org.gvsig.fmap.mapcontrol.tools.Listeners.PointListener;
+import org.gvsig.tools.ToolsLocator;
+import org.gvsig.tools.dynobject.DynObjectSet;
+import org.gvsig.tools.extensionpoint.ExtensionPoint;
+import org.gvsig.tools.extensionpoint.ExtensionPointManager;
+import org.gvsig.tools.extensionpoint.ExtensionSingleton;
+
+/**
+ * Listener that looks for information at the point selected by one
+ * click of any mouse's button, in the active layers of the associated
+ * <code>MapControl</code>, and displays that data on a {@link FInfoDialog
+ * FInfoDialog} dialog.
+ * 
+ * @author -2009 Vicente Caballero Navarro
+ * @author 2009- gvSIG Team
+ */
+public class InfoListener implements PointListener {
+
+    /**
+     * Object used to log messages for this listener.
+     */
+//    
+    private static final Logger logger = LoggerFactory.getLogger(InfoListener.class);
+
+    private static final String EP_INFOTOOL_NAME = "org.gvsig.app.infotool"; 
+    private static final String EP_INFOTOOL_RENDERER = "renderer"; 
+
+    public static void initializeExtensionPoint() {
+        ExtensionPointManager manager = ToolsLocator.getExtensionPointManager();
+        ExtensionPoint point = manager.add(EP_INFOTOOL_NAME, "Register of data relative to infotool");
+        point.append(
+            EP_INFOTOOL_RENDERER, 
+            "Renderer used to show in a panel the info by point tool.", 
+            new DefaultInfoByPointRenderer()
+        );
+    }
+    
+    /**
+     * The image to display when the cursor is active.
+     */
+    private final Image img = PluginServices.getIconTheme()
+        .get("cursor-info-by-point").getImage();
+
+    /**
+     * Reference to the <code>MapControl</code> object that uses.
+     */
+    private MapControl mapCtrl;
+
+    /**
+     * Radius as tolerance around the selected point, the area will be used to
+     * look for information.
+     */
+    private static int TOL = 7;
+
+    /**
+     * <p>
+     * Creates a new <code>InfoListener</code> object.
+     * </p>
+     * 
+     * @param mc
+     *            the <code>MapControl</code> where will be applied the changes
+     */
+    public InfoListener(MapControl mc) {
+        this.mapCtrl = mc;
+    }
+
+    public void point(PointEvent event) throws BehaviorException {
+        try {
+            ApplicationManager application = ApplicationLocator.getManager();
+            int numLayersInfoable = 0;
+            Point point = event.getMapPoint();
+            double tolerance = mapCtrl.getViewPort().toMapDistance(TOL);
+
+            FLayer[] sel = mapCtrl.getMapContext().getLayers().getActives();
+            Map<String, DynObjectSet> layer2info =
+                new HashMap<String, DynObjectSet>(sel.length);
+
+            for (int i = 0; i < sel.length; i++) {
+                FLayer laCapa = sel[i];
+                if (laCapa instanceof InfoByPoint) {
+                    InfoByPoint layer = (InfoByPoint) laCapa;
+                    DynObjectSet info = layer.getInfo(point, tolerance);
+                    layer2info.put(laCapa.getName(), info);
+                    numLayersInfoable++;
+                }
+            }
+            
+            if (numLayersInfoable == 0) {
+                return;
+            }
+
+            ExtensionPointManager extensionPoints = ToolsLocator.getExtensionPointManager();
+            InfoByPointRenderer renderer = (InfoByPointRenderer)extensionPoints.get(EP_INFOTOOL_NAME).create(EP_INFOTOOL_RENDERER);
+            
+            IWindow window = renderer.getPanel(layer2info);
+
+            if (window == null) {
+                logger.info("Error. Unable to create info panel.");
+                return;
+            }
+
+            PluginServices.getMDIManager().addWindow(window, GridBagConstraints.LAST_LINE_END);
+
+        } catch (Exception e) {
+            NotificationManager.addError("Info by Point", e);
+            e.printStackTrace();
+        }
+    }
+
+    /**
+     * @param window
+     * @return whether the window is currently one the app windows
+     */
+    private boolean isCurrentlyAdded(IWindow iw) {
+        
+        IWindow[] iws = PluginServices.getMDIManager().getAllWindows();
+        for (int i=0; i<iws.length; i++) {
+            if (iws[i] == iw) {
+                return true;
+            }
+        }
+        return false;
+    }
+
+    public Image getImageCursor() {
+        return img;
+    }
+
+    public boolean cancelDrawing() {
+        return false;
+    }
+
+    public void pointDoubleClick(PointEvent event) throws BehaviorException {
+        // Nothing to do
+    }
+    
+    public interface InfoByPointRenderer {
+        
+       public SingletonWindow getPanel(Map<String, DynObjectSet> layersInfo);
+       
+    }
+    
+    public static class DefaultInfoByPointRenderer implements InfoByPointRenderer, ExtensionSingleton {
+        
+        private FInfoDialog dlgInfo = null;
+        
+        public SingletonWindow getPanel(Map<String, DynObjectSet> layersInfo) {
+            // TODO: set the writable parameter to true to activate
+            // edition of the info by point information.
+            LayersDynObjectSetComponent infoComponent =
+                MapControlLocator.getMapControlManager()
+                    .createLayersDynObjectSetComponent(layersInfo, false);
+            
+            if (dlgInfo == null) {
+                dlgInfo = new FInfoDialog(infoComponent);
+            } else {
+                dlgInfo.setInfo(infoComponent);
+            }
+            return dlgInfo;
+        }
+       
+    }
+    
+    
+}

Property changes on: tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/app/project/documents/view/toolListeners/InfoListener.java
___________________________________________________________________
Added: svn:eol-style
   + native
Added: svn:keywords
   + Author Date Id Revision

Index: tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/app/project/documents/view/toolListeners/ZoomInListener.java
===================================================================
--- tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/app/project/documents/view/toolListeners/ZoomInListener.java	(revision 0)
+++ tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/app/project/documents/view/toolListeners/ZoomInListener.java	(revision 38653)
@@ -0,0 +1,77 @@
+/* gvSIG. Sistema de Informaci�n Geogr�fica de la Generalitat Valenciana
+ *
+ * Copyright (C) 2004 IVER T.I. and Generalitat Valenciana.
+ *
+ * This program is free software; you can redistribute it and/or
+ * modify it under the terms of the GNU General Public License
+ * as published by the Free Software Foundation; either version 2
+ * of the License, or (at your option) any later version.
+ *
+ * This program is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
+ * GNU General Public License for more details.
+ *
+ * You should have received a copy of the GNU General Public License
+ * along with this program; if not, write to the Free Software
+ * Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA  02111-1307,USA.
+ *
+ * For more information, contact:
+ *
+ *  Generalitat Valenciana
+ *   Conselleria d'Infraestructures i Transport
+ *   Av. Blasco Ib��ez, 50
+ *   46010 VALENCIA
+ *   SPAIN
+ *
+ *      +34 963862235
+ *   gvsig@gva.es
+ *      www.gvsig.gva.es
+ *
+ *    or
+ *
+ *   IVER T.I. S.A
+ *   Salamanca 50
+ *   46005 Valencia
+ *   Spain
+ *
+ *   +34 963163400
+ *   dac@iver.es
+ */
+package org.gvsig.app.project.documents.view.toolListeners;
+
+import org.gvsig.andami.PluginServices;
+import org.gvsig.fmap.mapcontrol.MapControl;
+import org.gvsig.fmap.mapcontrol.tools.ZoomInListenerImpl;
+import org.gvsig.fmap.mapcontrol.tools.Events.EnvelopeEvent;
+
+
+
+/**
+ * <p>Inherits {@link ZoomInListenerImpl ZoomInListenerImpl} enabling/disabling special
+ *  controls for managing the data selected.</p>
+ *
+ * @see ZoomInListenerImpl
+ *
+ * @author Vicente Caballero Navarro
+ */
+public class ZoomInListener extends ZoomInListenerImpl {
+	/**
+	 * <p>Creates a new <code>ZoomInListener</code> object.</p>
+	 * 
+	 * @param mapCtrl the <code>MapControl</code> where be applied the changes
+	 */
+	public ZoomInListener(MapControl mapCtrl) {
+		super(mapCtrl);
+	}
+
+	/*
+	 * (non-Javadoc)
+	 * @see com.iver.cit.gvsig.fmap.tools.ZoomInListenerImpl#rectangle(com.iver.cit.gvsig.fmap.tools.Events.RectangleEvent)
+	 */
+	public void rectangle(EnvelopeEvent event) {
+		super.rectangle(event);
+		if (PluginServices.getMainFrame() != null)
+		    PluginServices.getMainFrame().enableControls();
+	}
+}

Property changes on: tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/app/project/documents/view/toolListeners/ZoomInListener.java
___________________________________________________________________
Added: svn:keywords
   + Author Date Id Revision
Added: svn:eol-style
   + native

Index: tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/app/project/documents/view/toolListeners/ZoomOutListener.java
===================================================================
--- tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/app/project/documents/view/toolListeners/ZoomOutListener.java	(revision 0)
+++ tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/app/project/documents/view/toolListeners/ZoomOutListener.java	(revision 38653)
@@ -0,0 +1,76 @@
+/* gvSIG. Sistema de Informaci�n Geogr�fica de la Generalitat Valenciana
+ *
+ * Copyright (C) 2004 IVER T.I. and Generalitat Valenciana.
+ *
+ * This program is free software; you can redistribute it and/or
+ * modify it under the terms of the GNU General Public License
+ * as published by the Free Software Foundation; either version 2
+ * of the License, or (at your option) any later version.
+ *
+ * This program is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
+ * GNU General Public License for more details.
+ *
+ * You should have received a copy of the GNU General Public License
+ * along with this program; if not, write to the Free Software
+ * Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA  02111-1307,USA.
+ *
+ * For more information, contact:
+ *
+ *  Generalitat Valenciana
+ *   Conselleria d'Infraestructures i Transport
+ *   Av. Blasco Ib��ez, 50
+ *   46010 VALENCIA
+ *   SPAIN
+ *
+ *      +34 963862235
+ *   gvsig@gva.es
+ *      www.gvsig.gva.es
+ *
+ *    or
+ *
+ *   IVER T.I. S.A
+ *   Salamanca 50
+ *   46005 Valencia
+ *   Spain
+ *
+ *   +34 963163400
+ *   dac@iver.es
+ */
+package org.gvsig.app.project.documents.view.toolListeners;
+
+import org.gvsig.andami.PluginServices;
+import org.gvsig.fmap.mapcontrol.MapControl;
+import org.gvsig.fmap.mapcontrol.tools.ZoomOutListenerImpl;
+import org.gvsig.fmap.mapcontrol.tools.Events.PointEvent;
+
+
+
+/**
+ * <p>Inherits {@link ZoomOutListenerImpl ZoomOutListenerImpl} enabling/disabling special
+ *  controls for managing the data selected.</p>
+ *
+ * @see ZoomOutListenerImpl
+ *
+ * @author Vicente Caballero Navarro
+ */
+public class ZoomOutListener extends ZoomOutListenerImpl {
+	/**
+	 * <p>Creates a new <code>ZoomOutListener</code> object.</p>
+	 * 
+	 * @param mapCtrl the <code>MapControl</code> where be applied the changes
+	 */
+	public ZoomOutListener(MapControl mapCtrl) {
+		super(mapCtrl);
+	}
+
+	/*
+	 * (non-Javadoc)
+	 * @see com.iver.cit.gvsig.fmap.tools.ZoomOutListenerImpl#point(com.iver.cit.gvsig.fmap.tools.Events.PointEvent)
+	 */
+	public void point(PointEvent event) {
+		super.point(event);
+		PluginServices.getMainFrame().enableControls();
+	}
+}

Property changes on: tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/app/project/documents/view/toolListeners/ZoomOutListener.java
___________________________________________________________________
Added: svn:keywords
   + Author Date Id Revision
Added: svn:eol-style
   + native

Index: tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/app/project/documents/view/Encuadrator.java
===================================================================
--- tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/app/project/documents/view/Encuadrator.java	(revision 0)
+++ tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/app/project/documents/view/Encuadrator.java	(revision 38653)
@@ -0,0 +1,89 @@
+/* gvSIG. Sistema de Informaci�n Geogr�fica de la Generalitat Valenciana
+ *
+ * Copyright (C) 2004 IVER T.I. and Generalitat Valenciana.
+ *
+ * This program is free software; you can redistribute it and/or
+ * modify it under the terms of the GNU General Public License
+ * as published by the Free Software Foundation; either version 2
+ * of the License, or (at your option) any later version.
+ *
+ * This program is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
+ * GNU General Public License for more details.
+ *
+ * You should have received a copy of the GNU General Public License
+ * along with this program; if not, write to the Free Software
+ * Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA  02111-1307,USA.
+ *
+ * For more information, contact:
+ *
+ *  Generalitat Valenciana
+ *   Conselleria d'Infraestructures i Transport
+ *   Av. Blasco Ib��ez, 50
+ *   46010 VALENCIA
+ *   SPAIN
+ *
+ *      +34 963862235
+ *   gvsig@gva.es
+ *      www.gvsig.gva.es
+ *
+ *    or
+ *
+ *   IVER T.I. S.A
+ *   Salamanca 50
+ *   46005 Valencia
+ *   Spain
+ *
+ *   +34 963163400
+ *   dac@iver.es
+ */
+package org.gvsig.app.project.documents.view;
+
+import org.gvsig.app.project.Project;
+import org.gvsig.app.project.ProjectExtent;
+import org.gvsig.app.project.ProjectManager;
+import org.gvsig.app.project.documents.view.gui.DefaultViewPanel;
+import org.gvsig.fmap.mapcontext.MapContext;
+
+
+
+public class Encuadrator implements ListSelectorListener {
+
+	private Project project;
+//	private View vista;
+	private MapContext mapa;
+
+	public Encuadrator(Project project, MapContext map, DefaultViewPanel vista){
+		this.project = project;
+//		this.vista = vista;
+		mapa = map;
+	}
+
+	/**
+	 * @see com.iver.utiles.ListSelectorListener#indexesSelected(int[])
+	 */
+	public void indexesSelected(int[] indices) {
+		mapa.getViewPort().setEnvelope(project.getExtents()[indices[0]].getExtent());
+	}
+
+	/**
+	 * @see com.iver.utiles.ListSelectorListener#indexesRemoved(int[])
+	 */
+	public void indexesRemoved(int[] indices) {
+		for (int i = 0; i < indices.length; i++){
+			project.removeExtent(indices[i]);		
+		}
+	}
+
+	/* (non-Javadoc)
+	 * @see com.iver.utiles.ListSelectorListener#newElement(java.lang.String)
+	 */
+	public void newElement(String name) {
+		ProjectExtent extent = ProjectManager.getInstance().createExtent();
+		extent.setDescription(name);
+		extent.setExtent(mapa.getViewPort().getEnvelope());
+		project.addExtent(extent);
+	}
+
+}

Property changes on: tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/app/project/documents/view/Encuadrator.java
___________________________________________________________________
Added: svn:keywords
   + Author Date Id Revision
Added: svn:eol-style
   + native

Index: tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/app/project/documents/view/ViewDocument.java
===================================================================
--- tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/app/project/documents/view/ViewDocument.java	(revision 0)
+++ tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/app/project/documents/view/ViewDocument.java	(revision 38653)
@@ -0,0 +1,62 @@
+package org.gvsig.app.project.documents.view;
+
+import java.beans.PropertyChangeListener;
+
+import org.gvsig.app.project.Project;
+import org.gvsig.app.project.documents.Document;
+import org.gvsig.fmap.mapcontext.MapContext;
+
+
+public interface ViewDocument extends Document {
+
+	/**
+	 * Gets the FMap's contexts of the main map in the view.
+	 *
+	 * @return
+	 */
+	public MapContext getMapContext();
+
+	/**
+	 * Gets the FMap's context from the locator, which is the
+	 * small map in the left-bottom corner of the View.
+	 *
+	 * @return
+	 */
+	public MapContext getMapOverViewContext();
+
+	/**
+	 * @see org.gvsig.app.project.documents.view.DefaultViewDocument#setMapContext(org.gvsig.fmap.mapcontext.MapContext)
+	 */
+	public void setMapContext(MapContext fmap);
+
+	public void setMapOverViewContext(MapContext fmap);
+
+	public String getName();
+
+	public Project getProject();
+
+	public void addPropertyChangeListener(PropertyChangeListener listener);
+
+//	public String getExtLink();
+//
+//	public int getTypeLink();
+//
+//	/**
+//     * Se selecciona la extensi�n para realizar cuando se quiera el link.
+//     *
+//     * @param s nombre del campo.
+//     */
+//	public void setExtLink(String s);
+//
+//	/**
+//     * Se selecciona el tipo de fichero para realizar cuando se quiera el link.
+//     *
+//     * @param i tipo de fichero.
+//     */
+//	public void setTypeLink(int i);
+//
+//	public void setSelectedField(String s);
+//
+//	public String getSelectedField();
+	
+}
\ No newline at end of file

Property changes on: tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/app/project/documents/view/ViewDocument.java
___________________________________________________________________
Added: svn:keywords
   + Author Date Id Revision
Added: svn:eol-style
   + native

Index: tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/app/project/documents/view/AbstractContextMenuAction.java
===================================================================
--- tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/app/project/documents/view/AbstractContextMenuAction.java	(revision 0)
+++ tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/app/project/documents/view/AbstractContextMenuAction.java	(revision 38653)
@@ -0,0 +1,35 @@
+package org.gvsig.app.project.documents.view;
+
+import org.gvsig.tools.extensionpoint.ExtensionBuilder;
+
+
+public abstract class AbstractContextMenuAction implements IContextMenuAction,
+		ExtensionBuilder {
+
+	public boolean isVisible(Object item, Object[] selectedItems) {
+		return true;
+	}
+
+	public boolean isEnabled(Object item, Object[] selectedItems) {
+		return true;
+	}
+
+	public String getGroup() {
+		return "general";
+	}
+
+	public int getGroupOrder() {
+		return 50;
+	}
+
+	public int getOrder() {
+		return 0;
+	}
+
+	public String getDescription() {
+		// TODO Auto-generated method stub
+		return null;
+	}
+
+
+}

Property changes on: tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/app/project/documents/view/AbstractContextMenuAction.java
___________________________________________________________________
Added: svn:eol-style
   + native

Index: tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/app/project/documents/view/info/gui/IXULInfoToolSupport.java
===================================================================
--- tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/app/project/documents/view/info/gui/IXULInfoToolSupport.java	(revision 0)
+++ tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/app/project/documents/view/info/gui/IXULInfoToolSupport.java	(revision 38653)
@@ -0,0 +1,9 @@
+package org.gvsig.app.project.documents.view.info.gui;
+
+import java.io.IOException;
+
+public interface IXULInfoToolSupport extends IInfoToolPanel {
+
+	public void setXULFile(String xulFile) throws IOException;
+
+}

Property changes on: tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/app/project/documents/view/info/gui/IXULInfoToolSupport.java
___________________________________________________________________
Added: svn:keywords
   + Author Date Id Revision
Added: svn:eol-style
   + native

Index: tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/app/project/documents/view/info/gui/VectorialXMLItem.java
===================================================================
--- tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/app/project/documents/view/info/gui/VectorialXMLItem.java	(revision 0)
+++ tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/app/project/documents/view/info/gui/VectorialXMLItem.java	(revision 38653)
@@ -0,0 +1,126 @@
+/* gvSIG. Geographic Information System of the Valencian Government
+*
+* Copyright (C) 2007-2008 Infrastructures and Transports Department
+* of the Valencian Government (CIT)
+* 
+* This program is free software; you can redistribute it and/or
+* modify it under the terms of the GNU General Public License
+* as published by the Free Software Foundation; either version 2
+* of the License, or (at your option) any later version.
+* 
+* This program is distributed in the hope that it will be useful,
+* but WITHOUT ANY WARRANTY; without even the implied warranty of
+* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
+* GNU General Public License for more details.
+* 
+* You should have received a copy of the GNU General Public License
+* along with this program; if not, write to the Free Software
+* Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, 
+* MA  02110-1301, USA.
+* 
+*/
+
+/*
+* AUTHORS (In addition to CIT):
+* 2009 {Iver T.I.}   {Task}
+*/
+ 
+package org.gvsig.app.project.documents.view.info.gui;
+
+import org.gvsig.fmap.dal.exception.DataException;
+import org.gvsig.fmap.dal.exception.ReadException;
+import org.gvsig.tools.dispose.DisposableIterator;
+import org.gvsig.fmap.dal.feature.Feature;
+import org.gvsig.fmap.dal.feature.FeatureAttributeDescriptor;
+import org.gvsig.fmap.dal.feature.FeatureSet;
+import org.gvsig.fmap.dal.feature.FeatureType;
+import org.gvsig.fmap.mapcontext.layers.FLayer;
+import org.gvsig.fmap.mapcontext.layers.vectorial.FLyrVect;
+import org.gvsig.tools.dispose.DisposeUtils;
+import org.xml.sax.ContentHandler;
+import org.xml.sax.SAXException;
+import org.xml.sax.helpers.AttributesImpl;
+
+/**
+ * @author <a href="mailto:jpiera@gvsig.org">Jorge Piera</a>
+ */
+public class VectorialXMLItem implements XMLItem {
+
+	private FeatureSet selection;
+	private FLayer layer;
+
+	public VectorialXMLItem(FeatureSet selection, FLayer layer) {
+		this.selection = selection;
+		this.layer = layer;
+	}
+
+	public FLayer getLayer(){
+		return layer;
+	}
+	/**
+	 * @see org.gvsig.app.project.documents.view.info.gui.iver.cit.gvsig.gui.toolListeners.InfoListener.XMLItem#parse(org.xml.sax.ContentHandler)
+	 */
+	public void parse(ContentHandler handler) throws SAXException {
+		AttributesImpl aii = new AttributesImpl();
+		handler.startElement("", "", (layer).getName(), aii);
+		DisposableIterator iterator = null;
+		try {
+
+//			FeatureStore ds = ((FLyrVect) layer).getFeatureStore();
+			iterator = selection.iterator();
+			int j=0;
+			FeatureAttributeDescriptor attr;
+			Object value;
+			String strValue;
+			while (iterator.hasNext()) {
+				Feature feature = (Feature) iterator.next();
+				AttributesImpl ai = new AttributesImpl();
+				FeatureType featureType=((FLyrVect) layer).getFeatureStore().getDefaultFeatureType();
+				for (int k = 0; k < featureType.size(); k++) {
+					attr = (FeatureAttributeDescriptor) featureType
+							.get(k);
+					value = feature.get(k);
+					if (value == null) {
+						strValue = "{null}";
+					} else {
+						strValue = value.toString();
+					}
+					ai.addAttribute("", attr.getName(), attr.getName(),
+					"xs:string",
+							strValue);
+				}
+				handler.startElement("", "", String.valueOf(j), ai);
+				handler.endElement("", "", String.valueOf(j));
+				j++;
+			}
+
+			//TODO
+//			ds.start();
+//
+//			for (int j = bitset.nextSetBit(0); j >= 0; j = bitset
+//					.nextSetBit(j + 1)) {
+//				AttributesImpl ai = new AttributesImpl();
+//
+//				for (int k = 0; k < ds.getFieldCount(); k++) {
+//					ai.addAttribute("", ds.getFieldName(k), "",
+//							"xs:string", ds.getFieldValue(j, k).toString());
+//				}
+//				handler.startElement("", "", String.valueOf(j), ai);
+//				handler.endElement("", "", String.valueOf(j));
+//			}
+//
+//			ds.stop();
+
+		} catch (ReadException e) {
+			throw new SAXException(e);
+		} catch (DataException e) {
+			throw new SAXException(e);
+		}
+		finally {
+			DisposeUtils.dispose(iterator);
+		}
+		handler.endElement("", "", (layer).getName());
+	}
+}
+
+

Property changes on: tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/app/project/documents/view/info/gui/VectorialXMLItem.java
___________________________________________________________________
Added: svn:mime-type
   + text/plain

Index: tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/app/project/documents/view/info/gui/CSSelectionDialog.java
===================================================================
--- tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/app/project/documents/view/info/gui/CSSelectionDialog.java	(revision 0)
+++ tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/app/project/documents/view/info/gui/CSSelectionDialog.java	(revision 38653)
@@ -0,0 +1,93 @@
+/*
+ * Created on 26-ene-2005
+ */
+package org.gvsig.app.project.documents.view.info.gui;
+
+import java.awt.Dimension;
+
+import org.cresques.cts.IProjection;
+import org.cresques.ui.cts.CSSelectionDialogPanel;
+
+import org.gvsig.andami.PluginServices;
+import org.gvsig.andami.ui.mdiManager.IWindow;
+import org.gvsig.andami.ui.mdiManager.WindowInfo;
+import org.gvsig.app.gui.panels.crs.ISelectCrsPanel;
+
+/**
+ * @author Luis W. Sevilla (sevilla_lui@gva.es)
+ */
+public class CSSelectionDialog extends CSSelectionDialogPanel implements
+    IWindow, ISelectCrsPanel {
+
+    private boolean okPressed = false;
+    private IProjection lastProj = null;
+
+    /**
+	 *
+	 */
+    public CSSelectionDialog() {
+        super();
+        this.init();
+    }
+
+    /**
+     * This method initializes this
+     * 
+     * @return void
+     */
+    private void init() {
+        getAcceptButton().addActionListener(
+            new java.awt.event.ActionListener() {
+
+                public void actionPerformed(java.awt.event.ActionEvent e) {
+                    PluginServices.getMDIManager().closeWindow(
+                        CSSelectionDialog.this);
+                    okPressed = true;
+                }
+            });
+        getCancelButton().addActionListener(
+            new java.awt.event.ActionListener() {
+
+                public void actionPerformed(java.awt.event.ActionEvent e) {
+                    setProjection(lastProj);
+                    PluginServices.getMDIManager().closeWindow(
+                        CSSelectionDialog.this);
+                    okPressed = false;
+                }
+            });
+    }
+
+    public WindowInfo getWindowInfo() {
+        WindowInfo m_viewinfo =
+            new WindowInfo(WindowInfo.MODALDIALOG | WindowInfo.RESIZABLE);
+        m_viewinfo.setTitle(PluginServices.getText(this,
+            "selecciona_sistema_de_referencia"));
+        Dimension dim = getPreferredSize();
+        m_viewinfo.setWidth(dim.width);
+        m_viewinfo.setHeight(dim.height);
+        return m_viewinfo;
+    }
+
+    public boolean isOkPressed() {
+        return okPressed;
+    }
+
+    /**
+     * @return
+     */
+    public IProjection getProjection() {
+        return getProjPanel().getProjection();
+    }
+
+    /**
+     * @param proj
+     */
+    public void setProjection(IProjection proj) {
+        lastProj = proj;
+        getProjPanel().setProjection(proj);
+    }
+
+    public Object getWindowProfile() {
+        return WindowInfo.DIALOG_PROFILE;
+    }
+}

Property changes on: tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/app/project/documents/view/info/gui/CSSelectionDialog.java
___________________________________________________________________
Added: svn:keywords
   + Author Date Id Revision
Added: svn:eol-style
   + native

Index: tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/app/project/documents/view/info/gui/InfoToolViewer.java
===================================================================
--- tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/app/project/documents/view/info/gui/InfoToolViewer.java	(revision 0)
+++ tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/app/project/documents/view/info/gui/InfoToolViewer.java	(revision 38653)
@@ -0,0 +1,311 @@
+package org.gvsig.app.project.documents.view.info.gui;
+
+import java.awt.Dimension;
+import java.awt.event.ComponentEvent;
+import java.awt.event.ComponentListener;
+import java.util.Vector;
+
+import javax.swing.JList;
+import javax.swing.JPanel;
+import javax.swing.event.ListSelectionListener;
+import javax.swing.tree.DefaultMutableTreeNode;
+import javax.swing.tree.DefaultTreeModel;
+import javax.swing.tree.TreePath;
+
+import org.gvsig.app.gui.wizards.FormatListModel;
+import org.gvsig.fmap.mapcontext.layers.FLayer;
+import org.gvsig.fmap.mapcontext.layers.FLyrDefault;
+import org.gvsig.fmap.mapcontext.layers.operations.InfoByPoint;
+import org.gvsig.utils.xmlViewer.XMLContent;
+import org.xml.sax.ContentHandler;
+import org.xml.sax.SAXException;
+
+/**
+ * This is the generic Feature Info Viewer
+ * 
+ * If the feature Info comes from a special layer which has registered
+ * the way to visualize itself, adds a panel that the layer should provide
+ * otherwise this viewer will add a panel to visualize HTML or a special
+ * viewer to show XML.
+ * 
+ * @author laura
+ *
+ */
+public class InfoToolViewer extends JPanel {
+	
+	public static Class XULPanelClass = null;
+	
+    private javax.swing.JScrollPane jScrollPane = null;
+    private JList layerList = null;
+    private javax.swing.JSplitPane jSplitPane1 = null;
+    private javax.swing.JPanel layerListPanel = null;
+	private JPanel infoViewerPanel;	
+	private XMLItem[] m_layers;
+	IInfoToolPanel infoPanel = null;
+
+    /**
+     * This is the default constructor
+     */
+    public InfoToolViewer() {
+        super();
+        initialize();
+        this.addComponentListener(new componentListener());
+    }
+    
+    public InfoToolViewer(XMLItem[] layers) {
+    	super();
+    	initialize();
+    	setLayers(layers);
+    }
+    
+    public void setLayers(XMLItem[] layers){    	
+    	m_layers = layers;
+    	initilizeLayerListModel();
+    	updateViewer(0);
+    	// layerList.setSelectedIndex(0);
+    }
+
+
+    /**
+     * This method initializes this
+     */
+    private void initialize() {
+        this.setLayout(new java.awt.BorderLayout());
+        this.add(getJSplitPane1(), java.awt.BorderLayout.CENTER);
+        this.setSize(600, 600);
+        this.setPreferredSize(new Dimension(600, 600));
+    }
+
+    /**
+     * This method initializes jScrollPane
+     *
+     * @return javax.swing.JScrollPane
+     */
+    private javax.swing.JScrollPane getJScrollPane() {
+        if (jScrollPane == null) {
+            jScrollPane = new javax.swing.JScrollPane();
+            jScrollPane.setSize(new Dimension(600,600));
+            jScrollPane.setPreferredSize( new Dimension(600,600));
+            jScrollPane.setViewportView(getLayerListPanel());
+        }
+
+        return jScrollPane;
+    }
+    
+    private void initilizeLayerListModel() {
+        Vector layerNames = new Vector();
+        if (m_layers != null)
+        {
+        	for (int i = 0; i < m_layers.length; i++)
+        	{
+        		layerNames.add(m_layers[i].getLayer().getName());
+        	}        	
+        }         
+        
+        FormatListModel model = new FormatListModel((String[])layerNames.toArray(new String[0])); 
+        getJList().setModel(model);    	
+    }
+
+    public JList getJList(){
+
+	  if (layerList == null) {
+		  layerList = new JList();
+		  initilizeLayerListModel();
+	      layerList.setSelectionMode(javax.swing.ListSelectionModel.SINGLE_SELECTION);
+	  }
+  
+      layerList.addListSelectionListener(new ListSelectionListener() { 
+				public void valueChanged(javax.swing.event.ListSelectionEvent e) {
+				  int changedIdx = layerList.getSelectedIndex();//e.getFirstIndex();
+				 
+				  if (changedIdx == -1) return;
+				  updateViewer(changedIdx);
+	           }
+          });    
+      return layerList;
+}
+    /**
+     * This method initializes jSplitPane1
+     *
+     * @return javax.swing.JSplitPane
+     */
+    private javax.swing.JSplitPane getJSplitPane1() {
+        if (jSplitPane1 == null) {
+            jSplitPane1 = new javax.swing.JSplitPane();
+            jSplitPane1.setLeftComponent(getJScrollPane());
+            jSplitPane1.setRightComponent(getInfoViewerPanel());
+            jSplitPane1.setDividerSize(4);
+            jSplitPane1.setDividerLocation(100);
+            jSplitPane1.setSize( new Dimension(600,600));
+            jSplitPane1.setPreferredSize( new Dimension(600,600));
+        }
+        return jSplitPane1;
+    }
+
+    /**
+     * This method initializes jPanel
+     *
+     * @return javax.swing.JPanel
+     */
+    private javax.swing.JPanel getLayerListPanel() {
+        if (layerListPanel == null) {
+            layerListPanel = new javax.swing.JPanel();
+            layerListPanel.setLayout(new java.awt.BorderLayout());
+            layerListPanel.add(getJList(), java.awt.BorderLayout.CENTER);
+        }
+
+        return layerListPanel;
+    }
+
+    /**
+     * This method initializes jPanel1
+     *
+     * @return javax.swing.JPanel
+     */
+    private javax.swing.JPanel getInfoViewerPanel() {
+        if (infoViewerPanel == null) {
+            infoViewerPanel = new javax.swing.JPanel();
+            infoViewerPanel.setLayout(new java.awt.BorderLayout());
+        }
+        validate();
+        return infoViewerPanel;
+    } 
+    
+    /**
+     * updates the layer to display
+     *
+     */
+    private void updateViewer(int changedIdx)
+    {
+    	if((m_layers == null) || (m_layers.length == 0)) return;    	  
+		  final XMLItem item = m_layers[changedIdx];
+		  FLayer layer = item.getLayer(); 
+		
+		  if (layer instanceof InfoByPoint){					  				
+			  FLyrDefault defaultLayer = (FLyrDefault)layer;
+              if ( XULPanelClass!=null && defaultLayer.getProperty("infoTool.XULFile") != null){
+            	try {
+					IXULInfoToolSupport infoPanel = (IXULInfoToolSupport) XULPanelClass.newInstance();
+					infoPanel.setXULFile((String)defaultLayer.getProperty("infoTool.XULFile"));
+					infoViewerPanel.removeAll();
+					infoViewerPanel.add((JPanel)infoPanel);
+					infoPanel.show(item);
+					infoViewerPanel.setVisible( true ); 
+					revalidate();
+					return;
+				} catch (Exception e) {
+					// TODO Auto-generated catch block
+					e.printStackTrace();
+				}
+            	  
+              }
+              
+              if (defaultLayer.getProperty("customPanel") != null){
+				  
+				Object o = (Object)defaultLayer.getProperty("customPanel");
+				if (o instanceof IInfoToolPanel) {
+					  infoPanel = (IInfoToolPanel)o;
+				} else {
+				 	try {
+						Class c = (Class)o;
+				 		infoPanel = (IInfoToolPanel)c.newInstance();
+					} catch (InstantiationException e1) {
+						e1.printStackTrace();
+					} catch (IllegalAccessException e1) {
+						e1.printStackTrace();
+					}
+				}
+				infoViewerPanel.removeAll();
+				infoViewerPanel.add((JPanel)infoPanel);
+				infoPanel.show(item);
+				infoViewerPanel.setVisible( true ); 
+				revalidate();
+
+			  } else {
+				  
+				  if (item.toString().toLowerCase().endsWith( "</html>"))//if (item.toString().toLowerCase().startsWith( "<html>"))
+				  {
+					  //skip the header info
+					  IInfoToolPanel htmlPanel = new HTMLInfoToolPanel();
+					 
+					  int idx = item.toString().toLowerCase().indexOf("<html");
+					  if (idx != -1){
+						  htmlPanel.show(item.toString().substring(idx));					  
+					  }else{
+						  htmlPanel.show(item.toString());
+					  }
+					  infoViewerPanel.removeAll();
+					  infoViewerPanel.add((JPanel)htmlPanel);
+					  infoViewerPanel.setVisible( true ); 							  
+					  revalidate();
+				  } else {
+					  FInfoDialogXML dlgXML = new FInfoDialogXML();
+						try {
+							dlgXML.setModel(new XMLContent() {
+								private ContentHandler handler;
+
+								public void setContentHandler(ContentHandler arg0) {
+									handler = arg0;
+								}
+
+								public void parse() throws SAXException {
+									handler.startDocument();
+									item.parse( handler);
+									handler.endDocument();
+								}
+							});
+							dlgXML.getXmlTree().setRootVisible(false);
+							DefaultTreeModel treeModel = (DefaultTreeModel) dlgXML
+									.getXmlTree().getModel();
+							DefaultMutableTreeNode n;
+							DefaultMutableTreeNode root = (DefaultMutableTreeNode) dlgXML
+									.getXmlTree().getModel().getRoot();
+							n = root.getFirstLeaf();
+							TreePath path = new TreePath(treeModel.getPathToRoot(n));
+							dlgXML.getXmlTree().expandPath(path);
+							dlgXML.getXmlTree().setSelectionPath(path);
+							//dlgXML.
+							
+							infoViewerPanel.removeAll();
+							infoViewerPanel.add(dlgXML);
+							infoViewerPanel.setVisible( true ); 
+							this.validate();
+	    					this.doLayout();	
+							
+						} catch (SAXException e1) {
+							e1.printStackTrace();
+						}
+				  }
+			  }
+		  }    	
+    }
+    
+    class componentListener implements ComponentListener{
+
+		public void componentHidden(ComponentEvent e) {
+			// TODO Auto-generated method stub
+			
+		}
+
+		public void componentMoved(ComponentEvent e) {
+			// TODO Auto-generated method stub
+			
+		}
+
+		public void componentResized(ComponentEvent e) {
+			
+			//if (e.getComponent() == )
+			if (infoPanel != null){
+				infoPanel.refreshSize();
+			}
+			
+			
+		}
+
+		public void componentShown(ComponentEvent e) {
+			// TODO Auto-generated method stub
+			
+		}
+    	
+    }
+}

Property changes on: tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/app/project/documents/view/info/gui/InfoToolViewer.java
___________________________________________________________________
Added: svn:keywords
   + Author Date Id Revision
Added: svn:eol-style
   + native

Index: tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/app/project/documents/view/info/gui/HTMLInfoToolPanel.java
===================================================================
--- tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/app/project/documents/view/info/gui/HTMLInfoToolPanel.java	(revision 0)
+++ tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/app/project/documents/view/info/gui/HTMLInfoToolPanel.java	(revision 38653)
@@ -0,0 +1,83 @@
+package org.gvsig.app.project.documents.view.info.gui;
+
+import java.awt.Dimension;
+import java.awt.HeadlessException;
+
+import javax.swing.JEditorPane;
+import javax.swing.JPanel;
+import javax.swing.JScrollPane;
+import javax.swing.event.HyperlinkEvent;
+import javax.swing.text.html.HTMLEditorKit;
+
+import org.gvsig.utils.BrowserControl;
+
+
+/**
+ * JPanel to show the feature information return in HTML code
+ * @author laura
+ *
+ */
+public class HTMLInfoToolPanel extends JPanel implements IInfoToolPanel{
+		
+	private boolean initialized = false;
+	private JEditorPane editor = null;
+	private JScrollPane scrollPane = null;
+
+	public HTMLInfoToolPanel() throws HeadlessException {
+		super();
+	}
+	
+	private void init() {
+		if (this.initialized ) return;
+				
+		this.setAutoscrolls(true);
+		this.setLocation(0,0);
+
+		scrollPane = new JScrollPane();		
+		scrollPane.setAutoscrolls(true);
+				
+		editor = new JEditorPane();
+		editor.setContentType("text/html");
+		editor.setAutoscrolls(true);
+		editor.setEditable(false);
+		editor.addHyperlinkListener(new javax.swing.event.HyperlinkListener() { 
+	          public void hyperlinkUpdate(javax.swing.event.HyperlinkEvent e) {
+	           if (e.getEventType() == HyperlinkEvent.EventType.ACTIVATED)
+	           {
+	        	   BrowserControl.displayURL(e.getURL().toString());
+	           }
+	          }
+		});
+		
+//azabala		this.add(editor);
+		
+		
+		this.setSize(new Dimension(640, 400));
+		editor.setSize(new Dimension(640, 400));
+		
+		
+		editor.setEditorKit(new HTMLEditorKit());
+        scrollPane.setViewportView(editor);
+//azabalA		
+		this.add(scrollPane);
+		
+//azabala		scrollPane.setLocation(0,0);
+	}
+	
+	public void show(String text) 
+	{
+		this.init();
+		this.setVisible(true);	
+		editor.setText(text.replaceFirst("Content-Type","Content-Typex"));		
+	}
+
+	public void refreshSize() {
+		// TODO Auto-generated method stub
+		
+	}
+
+	public void show(XMLItem item) {
+		// TODO Auto-generated method stub
+		
+	}
+}

Property changes on: tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/app/project/documents/view/info/gui/HTMLInfoToolPanel.java
___________________________________________________________________
Added: svn:eol-style
   + native
Added: svn:keywords
   + Author Date Id Revision

Index: tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/app/project/documents/view/info/gui/XMLItem.java
===================================================================
--- tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/app/project/documents/view/info/gui/XMLItem.java	(revision 0)
+++ tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/app/project/documents/view/info/gui/XMLItem.java	(revision 38653)
@@ -0,0 +1,42 @@
+/* gvSIG. Geographic Information System of the Valencian Government
+*
+* Copyright (C) 2007-2008 Infrastructures and Transports Department
+* of the Valencian Government (CIT)
+* 
+* This program is free software; you can redistribute it and/or
+* modify it under the terms of the GNU General Public License
+* as published by the Free Software Foundation; either version 2
+* of the License, or (at your option) any later version.
+* 
+* This program is distributed in the hope that it will be useful,
+* but WITHOUT ANY WARRANTY; without even the implied warranty of
+* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
+* GNU General Public License for more details.
+* 
+* You should have received a copy of the GNU General Public License
+* along with this program; if not, write to the Free Software
+* Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, 
+* MA  02110-1301, USA.
+* 
+*/
+
+/*
+* AUTHORS (In addition to CIT):
+* 2009 {Iver T.I.}   {Task}
+*/
+ 
+package org.gvsig.app.project.documents.view.info.gui;
+
+import org.gvsig.fmap.mapcontext.layers.FLayer;
+import org.xml.sax.ContentHandler;
+import org.xml.sax.SAXException;
+
+/**
+ * @author <a href="mailto:jpiera@gvsig.org">Jorge Piera</a>
+ */
+public interface XMLItem {
+	public void parse(ContentHandler handler) throws SAXException;
+	public FLayer getLayer();
+	
+}
+

Property changes on: tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/app/project/documents/view/info/gui/XMLItem.java
___________________________________________________________________
Added: svn:mime-type
   + text/plain

Index: tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/app/project/documents/view/info/gui/FInfoDialog.java
===================================================================
--- tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/app/project/documents/view/info/gui/FInfoDialog.java	(revision 0)
+++ tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/app/project/documents/view/info/gui/FInfoDialog.java	(revision 38653)
@@ -0,0 +1,86 @@
+
+package org.gvsig.app.project.documents.view.info.gui;
+
+import java.awt.BorderLayout;
+
+import javax.swing.JPanel;
+import javax.swing.JScrollPane;
+
+import org.gvsig.andami.PluginServices;
+import org.gvsig.andami.ui.mdiManager.IWindowListener;
+import org.gvsig.andami.ui.mdiManager.SingletonWindow;
+import org.gvsig.andami.ui.mdiManager.WindowInfo;
+import org.gvsig.fmap.mapcontrol.swing.dynobject.LayersDynObjectSetComponent;
+
+
+
+/**
+ * Dialog that contains the generic Feature Info Viewer
+ *
+ * @author laura
+ *
+ */
+public class FInfoDialog extends JPanel implements SingletonWindow,
+    IWindowListener {
+
+    private static final long serialVersionUID = -6707094091114785970L;
+    
+    private LayersDynObjectSetComponent infoViewer;
+    private JScrollPane scroll = null;
+
+    public FInfoDialog(LayersDynObjectSetComponent info) {
+        super(new BorderLayout());
+        this.infoViewer = info;
+        
+        scroll = new JScrollPane(
+            JScrollPane.VERTICAL_SCROLLBAR_AS_NEEDED,
+            JScrollPane.HORIZONTAL_SCROLLBAR_AS_NEEDED);
+        scroll.setViewportView(infoViewer.asJComponent());
+        add(scroll, BorderLayout.CENTER);
+		setSize(500, 375);
+	}
+    
+    public void setInfo(LayersDynObjectSetComponent info) {
+        
+        if (infoViewer != null) {
+            infoViewer.dispose();
+        }
+
+        this.removeAll();
+        this.infoViewer = info;
+        
+        scroll = new JScrollPane(
+            JScrollPane.VERTICAL_SCROLLBAR_AS_NEEDED,
+            JScrollPane.HORIZONTAL_SCROLLBAR_AS_NEEDED);
+        scroll.setViewportView(infoViewer.asJComponent());
+        add(scroll, BorderLayout.CENTER);
+    }
+
+	public WindowInfo getWindowInfo() {
+
+		WindowInfo m_viewinfo = new WindowInfo(WindowInfo.MODELESSDIALOG |
+				WindowInfo.RESIZABLE | WindowInfo.PALETTE);
+		m_viewinfo.setWidth(getWidth()+8);
+		m_viewinfo.setHeight(getHeight());
+		m_viewinfo.setTitle(PluginServices.getText(this,
+				"Identificar_Resultados"));
+
+		return m_viewinfo;
+	}
+
+	public Object getWindowModel() {
+		return "FInfoDialog";
+	}
+
+	public Object getWindowProfile() {
+		return WindowInfo.PROPERTIES_PROFILE;
+	}
+
+    public void windowActivated() {
+        // Nothing to do
+    }
+
+    public void windowClosed() {
+        infoViewer.dispose();
+    }
+}

Property changes on: tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/app/project/documents/view/info/gui/FInfoDialog.java
___________________________________________________________________
Added: svn:keywords
   + Author Date Id Revision
Added: svn:eol-style
   + native

Index: tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/app/project/documents/view/info/gui/FInfoDialogXML.java
===================================================================
--- tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/app/project/documents/view/info/gui/FInfoDialogXML.java	(revision 0)
+++ tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/app/project/documents/view/info/gui/FInfoDialogXML.java	(revision 38653)
@@ -0,0 +1,98 @@
+/*
+ * Created on 13-sep-2004
+ *
+ */
+/* gvSIG. Sistema de Informaci�n Geogr�fica de la Generalitat Valenciana
+ *
+ * Copyright (C) 2004 IVER T.I. and Generalitat Valenciana.
+ *
+ * This program is free software; you can redistribute it and/or
+ * modify it under the terms of the GNU General Public License
+ * as published by the Free Software Foundation; either version 2
+ * of the License, or (at your option) any later version.
+ *
+ * This program is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
+ * GNU General Public License for more details.
+ *
+ * You should have received a copy of the GNU General Public License
+ * along with this program; if not, write to the Free Software
+ * Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA  02111-1307,USA.
+ *
+ * For more information, contact:
+ *
+ *  Generalitat Valenciana
+ *   Conselleria d'Infraestructures i Transport
+ *   Av. Blasco Ib��ez, 50
+ *   46010 VALENCIA
+ *   SPAIN
+ *
+ *      +34 963862235
+ *   gvsig@gva.es
+ *      www.gvsig.gva.es
+ *
+ *    or
+ *
+ *   IVER T.I. S.A
+ *   Salamanca 50
+ *   46005 Valencia
+ *   Spain
+ *
+ *   +34 963163400
+ *   dac@iver.es
+ */
+package org.gvsig.app.project.documents.view.info.gui;
+
+import org.gvsig.andami.PluginServices;
+import org.gvsig.andami.ui.mdiManager.IWindow;
+import org.gvsig.andami.ui.mdiManager.WindowInfo;
+import org.gvsig.utils.xmlViewer.XMLViewer;
+
+
+
+/**
+ * Di�logo utilizado para mostrar la infromaci�n.
+ *
+ * @author fernando To change the template for this generated type comment go
+ * 		   to Window&gt;Preferences&gt;Java&gt;Code Generation&gt;Code and
+ * 		   Comments
+ */
+public class FInfoDialogXML extends XMLViewer implements IWindow {
+
+
+	public FInfoDialogXML(){
+		super();
+		setNamesColumn(new String[]{PluginServices.getText(this, "Atributo"), PluginServices.getText(this, "Valor")});
+		setSize(500, 375);
+	}
+	/**
+	 * @see com.iver.mdiApp.ui.MDIManager.IWindow#windowActivated()
+	 */
+	public void viewActivated() {
+	}
+
+	/* (non-Javadoc)
+	 * @see com.iver.mdiApp.ui.MDIManager.View#getViewInfo()
+	 */
+	public WindowInfo getWindowInfo() {
+		WindowInfo m_viewinfo = new WindowInfo(WindowInfo.MODELESSDIALOG |
+				WindowInfo.RESIZABLE | WindowInfo.PALETTE);
+		m_viewinfo.setWidth(getWidth()+8);
+		m_viewinfo.setHeight(getHeight());
+		m_viewinfo.setTitle(PluginServices.getText(this,
+				"Identificar_Resultados"));
+
+		return m_viewinfo;
+	}
+
+	/**
+	 * @see com.iver.mdiApp.ui.MDIManager.SingletonWindow#getWindowModel()
+	 */
+	public Object getViewModel() {
+		return "FInfoDialogXML";
+	}
+	public Object getWindowProfile() {
+		return WindowInfo.PROPERTIES_PROFILE;
+	}
+}

Property changes on: tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/app/project/documents/view/info/gui/FInfoDialogXML.java
___________________________________________________________________
Added: svn:keywords
   + Author Date Id Revision
Added: svn:eol-style
   + native

Index: tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/app/project/documents/view/info/gui/IInfoToolPanel.java
===================================================================
--- tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/app/project/documents/view/info/gui/IInfoToolPanel.java	(revision 0)
+++ tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/app/project/documents/view/info/gui/IInfoToolPanel.java	(revision 38653)
@@ -0,0 +1,16 @@
+package org.gvsig.app.project.documents.view.info.gui;
+
+
+/**
+ * Interface that must implement the panels provided from a layer
+ * to display its Feature Information
+ * 
+ * @author laura
+ *
+ */
+public interface IInfoToolPanel{
+
+	public void show(String s);
+	public void refreshSize();
+	public void show(XMLItem item);
+}

Property changes on: tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/app/project/documents/view/info/gui/IInfoToolPanel.java
___________________________________________________________________
Added: svn:keywords
   + Author Date Id Revision
Added: svn:eol-style
   + native

Index: tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/app/project/documents/view/DefaultViewDocument.java
===================================================================
--- tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/app/project/documents/view/DefaultViewDocument.java	(revision 0)
+++ tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/app/project/documents/view/DefaultViewDocument.java	(revision 38653)
@@ -0,0 +1,116 @@
+/* gvSIG. Geographic Information System of the Valencian Government
+*
+* Copyright (C) 2007-2009 Infrastructures and Transports Department
+* of the Valencian Government (CIT)
+* 
+* This program is free software; you can redistribute it and/or
+* modify it under the terms of the GNU General Public License
+* as published by the Free Software Foundation; either version 2
+* of the License, or (at your option) any later version.
+* 
+* This program is distributed in the hope that it will be useful,
+* but WITHOUT ANY WARRANTY; without even the implied warranty of
+* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
+* GNU General Public License for more details.
+* 
+* You should have received a copy of the GNU General Public License
+* along with this program; if not, write to the Free Software
+* Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, 
+* MA  02110-1301, USA.
+* 
+*/
+
+/*
+* AUTHORS (In addition to CIT):
+* 2004-2009 IVER TI
+*   
+*/
+package org.gvsig.app.project.documents.view;
+
+import org.gvsig.app.ApplicationLocator;
+import org.gvsig.app.project.ProjectPreferences;
+import org.gvsig.app.project.documents.DocumentManager;
+import org.gvsig.fmap.mapcontext.MapContext;
+import org.gvsig.fmap.mapcontext.ViewPort;
+import org.gvsig.tools.ToolsLocator;
+import org.gvsig.tools.dynobject.DynStruct;
+import org.gvsig.tools.persistence.PersistenceManager;
+import org.gvsig.tools.persistence.PersistentState;
+import org.gvsig.tools.persistence.exception.PersistenceException;
+
+
+
+/**
+ * Clase que representa una vista del proyecto
+ *
+ * @author 2004-2005 Fernando Gonz�lez Cort�s
+ * @author 2006-2009 Jose Manuel Vivo
+ * @author 2005-         Vicente Caballero
+ * @author 2009-         Joaquin del Cerro
+ * 
+ */
+
+public class DefaultViewDocument extends BaseViewDocument {
+
+	/**
+	 * 
+	 */
+	private static final long serialVersionUID = 676711512482334764L;
+
+	public static final String PERSISTENCE_DEFINITION_NAME = "DefaultViewDocument";
+	
+
+	public DefaultViewDocument() {
+		this(null);
+	}
+	
+	public DefaultViewDocument(DocumentManager factory) {
+		super(factory); 
+
+		ViewPort vp;
+	
+		ProjectPreferences preferences = (ProjectPreferences) ApplicationLocator.getManager().getPreferences("project");
+    	
+    	MapContext viewMapContext = new MapContext(
+				new ViewPort( preferences.getDefaultProjection() )
+		);
+		vp = viewMapContext.getViewPort();
+		vp.setBackColor(preferences.getDefaultViewBackColor());
+		vp.setDistanceUnits(preferences.getDefaultDistanceUnits());
+		vp.setDistanceArea(preferences.getDefaultDistanceArea());
+		vp.setMapUnits(preferences.getDefaultMapUnits());
+		this.setMapContext(viewMapContext);
+		
+		MapContext overviewMapContext = new MapContext(
+				new ViewPort( viewMapContext.getProjection() )
+		);
+		vp = viewMapContext.getViewPort();
+		vp.setBackColor(preferences.getDefaultViewBackColor());
+		this.setMapOverViewContext(overviewMapContext);
+	}
+	
+	public void saveToState(PersistentState state) throws PersistenceException {
+		super.saveToState(state);
+	}
+	
+	public void loadFromState(PersistentState state) throws PersistenceException {
+		super.loadFromState(state);
+	}
+
+	public String exportDocumentAsText() {
+		// FIXME: jjdc PersistentManager getStateAsText o similar
+//		 PersistenceManager manager = ToolsLocator.getPersistenceManager();
+//		 PersistentState state = manager.getState(this);
+//		 return manager.getStateAsText(state);
+		return null;
+	}
+
+	public void setStateFromText(String text) {
+		// FIXME: jjdc PersistentManager getStateFromText o similar
+//		 PersistenceManager manager = ToolsLocator.getPersistenceManager();
+//		 PersistentState state = manager.getStateFromText(text);
+//		 this.loadFromState(state);
+	}
+
+	
+}

Property changes on: tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/app/project/documents/view/DefaultViewDocument.java
___________________________________________________________________
Added: svn:eol-style
   + native
Added: svn:keywords
   + Author Date Id Revision

Index: tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/app/project/documents/view/legend/gui/LabelingManager.java
===================================================================
--- tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/app/project/documents/view/legend/gui/LabelingManager.java	(revision 0)
+++ tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/app/project/documents/view/legend/gui/LabelingManager.java	(revision 38653)
@@ -0,0 +1,309 @@
+/*
+ * Created on 01-jun-2004
+ *
+ */
+/* gvSIG. Sistema de Informaci�n Geogr�fica de la Generalitat Valenciana
+ *
+ * Copyright (C) 2004 IVER T.I. and Generalitat Valenciana.
+ *
+ * This program is free software; you can redistribute it and/or
+ * modify it under the terms of the GNU General Public License
+ * as published by the Free Software Foundation; either version 2
+ * of the License, or (at your option) any later version.
+ *
+ * This program is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
+ * GNU General Public License for more details.
+ *
+ * You should have received a copy of the GNU General Public License
+ * along with this program; if not, write to the Free Software
+ * Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA  02111-1307,USA.
+ *
+ * For more information, contact:
+ *
+ *  Generalitat Valenciana
+ *   Conselleria d'Infraestructures i Transport
+ *   Av. Blasco Ib��ez, 50
+ *   46010 VALENCIA
+ *   SPAIN
+ *
+ *      +34 963862235
+ *   gvsig@gva.es
+ *      www.gvsig.gva.es
+ *
+ *    or
+ *
+ *   IVER T.I. S.A
+ *   Salamanca 50
+ *   46005 Valencia
+ *   Spain
+ *
+ *   +34 963163400
+ *   dac@iver.es
+ */
+package org.gvsig.app.project.documents.view.legend.gui;
+
+import java.awt.BorderLayout;
+import java.awt.Component;
+import java.awt.FlowLayout;
+import java.awt.event.ActionEvent;
+import java.awt.event.ActionListener;
+import java.util.ArrayList;
+import java.util.Comparator;
+import java.util.Hashtable;
+import java.util.Iterator;
+import java.util.TreeMap;
+
+import javax.swing.BorderFactory;
+import javax.swing.JCheckBox;
+import javax.swing.JComponent;
+import javax.swing.JLabel;
+import javax.swing.JPanel;
+
+import org.gvsig.andami.PluginServices;
+import org.gvsig.andami.messages.NotificationManager;
+import org.gvsig.fmap.mapcontext.layers.FLayer;
+import org.gvsig.fmap.mapcontext.rendering.legend.styling.ILabelable;
+import org.gvsig.fmap.mapcontext.rendering.legend.styling.ILabelingStrategy;
+import org.gvsig.utils.swing.JComboBox;
+
+
+/**
+ *
+ * @author jaume dominguez faus - jaume.dominguez@iver.es
+ *
+ */
+public class LabelingManager extends AbstractThemeManagerPage implements ActionListener {
+	private static final long serialVersionUID = 856162295985695717L;
+	private static ArrayList<Class<? extends ILabelingStrategyPanel>> installedPanels = new ArrayList<Class<? extends ILabelingStrategyPanel>>();
+	private Comparator<Class<?>> comparator=new Comparator<Class<?>>(){
+
+		public int compare(Class<?> o1, Class<?> o2) {
+			return o1.getName().compareTo(o2.getName());
+		}
+
+	};
+	private TreeMap<Class<?>, ILabelingStrategyPanel> strategyPanels = new TreeMap<Class<?>, ILabelingStrategyPanel>(comparator);
+	private JCheckBox chkApplyLabels;
+	private ILabelable layer;
+	private JPanel content;
+	private JPanel pnlNorth;
+	private JComboBox cmbStrategy;
+
+
+	public LabelingManager() {
+		super();
+		initialize();
+	}
+
+	private class LabelingStrategyItem {
+		private ILabelingStrategyPanel strategyPanel;
+
+		private LabelingStrategyItem(ILabelingStrategyPanel strategyPanel) {
+			this.strategyPanel = strategyPanel;
+		}
+
+		public String toString() {
+			return strategyPanel.getLabelingStrategyName();
+		}
+
+		public boolean equals(Object obj) {
+			if (obj instanceof LabelingStrategyItem) {
+				LabelingStrategyItem item = (LabelingStrategyItem) obj;
+				return this.strategyPanel.getClass().equals(item.strategyPanel.getClass());
+
+			}
+			return super.equals(obj);
+		}
+
+	}
+
+	private void initialize() {
+		setLayout(new BorderLayout());
+		for (Iterator<Class<? extends ILabelingStrategyPanel>> it = installedPanels.iterator(); it.hasNext();) {
+			try {
+				ILabelingStrategyPanel pnl = (ILabelingStrategyPanel) it.next().newInstance();
+				strategyPanels.put(pnl.getLabelingStrategyClass(), pnl);
+			} catch (Exception e) {
+				/*
+				 *  can't happen
+				 *  this should never happen since instantiation and access exceptions have been
+				 *	controlled in the addLabelingStrategy method
+				 */
+				NotificationManager.addError(e);
+			}
+
+		}
+		content = new JPanel(new BorderLayout());
+		content.setBorder(BorderFactory.createEtchedBorder());
+		add(getPnlNorth(), BorderLayout.NORTH);
+		add(content, BorderLayout.SOUTH);
+
+	}
+
+	private JPanel getPnlNorth() {
+		if (pnlNorth == null) {
+			pnlNorth = new JPanel(new BorderLayout(5,5));
+			JPanel aux = new JPanel(new FlowLayout(FlowLayout.LEFT));
+
+			aux.add(getChkApplyLabels());
+			pnlNorth.add(aux, BorderLayout.NORTH);
+			aux = new JPanel(new FlowLayout(FlowLayout.LEFT));
+			aux.add(new JLabel(PluginServices.getText(this, "general")+":"));
+			aux.add(getCmbStrategy());
+			pnlNorth.add(aux, BorderLayout.CENTER);
+
+		}
+		return pnlNorth;
+	}
+
+	private JComboBox getCmbStrategy() {
+		if (cmbStrategy == null) {
+			Iterator<ILabelingStrategyPanel> it = strategyPanels.values().iterator();
+			final ArrayList<LabelingStrategyItem> aux = new ArrayList<LabelingStrategyItem>();
+			while (it.hasNext()) {
+				aux.add(new LabelingStrategyItem(it.next()));
+			}
+			final LabelingStrategyItem items[] = aux.toArray(new LabelingStrategyItem[aux.size()]);
+
+			cmbStrategy = new JComboBox(items) {
+				private static final long serialVersionUID = 7506754097091500846L;
+
+				@Override
+				public void setSelectedItem(Object anObject) {
+					if (anObject == null)
+						return;
+					if (anObject instanceof ILabelingStrategy) {
+						ILabelingStrategy st = (ILabelingStrategy) anObject;
+						for (ILabelingStrategyPanel pnl : strategyPanels.values()) {
+							if (pnl.getLabelingStrategyClass() != null &&
+								pnl.getLabelingStrategyClass().equals(st.getClass())) {
+								super.setSelectedItem(new LabelingStrategyItem(pnl));
+								return;
+							}
+						}
+					} else {
+						super.setSelectedItem(anObject);
+					}
+				}
+			};
+
+			cmbStrategy.setName("CMBMODE");
+			cmbStrategy.addActionListener(this);
+		}
+
+		return cmbStrategy;
+	}
+
+	private JCheckBox getChkApplyLabels() {
+		if (chkApplyLabels == null) {
+			chkApplyLabels = new JCheckBox(PluginServices.getText(this, "enable_labeling"));
+			chkApplyLabels.setName("CHKAPPLYLABELS");
+			chkApplyLabels.addActionListener(this);
+		}
+		return chkApplyLabels;
+	}
+
+	public static void addLabelingStrategy(Class<? extends ILabelingStrategyPanel> iLabelingStrategyPanelClass) {
+		installedPanels.add(iLabelingStrategyPanelClass);
+	}
+
+	private void setComponentEnabled(Component c, boolean b) {
+		c.setEnabled(b);
+	}
+
+
+	public void setModel(FLayer layer) throws IllegalArgumentException {
+		if (layer instanceof ILabelable) {
+			// get the labeling strategy
+			this.layer = (ILabelable) layer;
+			for (ILabelingStrategyPanel p : strategyPanels.values()) {
+				p.setModel(layer,((ILabelable) layer).getLabelingStrategy() );
+			}
+
+			setComponentEnabled(this, true);
+			refreshControls();
+
+
+			ActionEvent evt = new ActionEvent(chkApplyLabels, 0, null);
+			evt.setSource(chkApplyLabels);
+			actionPerformed(evt);
+
+			getCmbStrategy().setSelectedItem(this.layer.getLabelingStrategy());
+			evt.setSource(getCmbStrategy());
+			actionPerformed(evt);
+		} else {
+			setComponentEnabled(this, false);
+		}
+	}
+
+
+
+	private void refreshControls() {
+		if (layer == null) return;
+
+		// enables labeling
+		JCheckBox applyLabels = getChkApplyLabels();
+		applyLabels.setSelected(layer.isLabeled());
+	}
+
+
+
+
+	public void actionPerformed(ActionEvent e) {
+		JComponent c = (JComponent)e.getSource();
+
+		if (c.equals(chkApplyLabels)) {
+			boolean b = chkApplyLabels.isSelected();
+			// enables/disables all components
+			getCmbStrategy().setEnabled(b);
+			for (int i = 0; i < content.getComponentCount(); i++) {
+				Component c1 = content.getComponent(i);
+				if (!c1.equals(c))
+					setComponentEnabled(c1, b);
+			}
+
+		} else if (c.equals(cmbStrategy)) {
+			if (c.equals(cmbStrategy)) {
+				ILabelingStrategyPanel panel = ((LabelingStrategyItem) cmbStrategy.getSelectedItem()).strategyPanel;
+				if (panel!=null) {
+					try {
+						remove(content);
+
+						content.removeAll();
+						content.add((Component) panel);
+						add(content, BorderLayout.CENTER);
+						actionPerformed(new ActionEvent(chkApplyLabels, 0, null));
+						revalidate();
+						paintImmediately(getBounds());
+					} catch (Exception e1) {
+						e1.printStackTrace();
+					}
+				}
+			}
+		}
+	}
+
+	public void acceptAction() {
+
+	}
+
+	public void cancelAction() {
+
+	}
+
+	public void applyAction() {
+		if (layer != null) { // in other case the layer is not labelable
+			ILabelingStrategyPanel panel = ((LabelingStrategyItem) getCmbStrategy().getSelectedItem()).strategyPanel;
+			ILabelingStrategy strategy=panel.getLabelingStrategy();
+			layer.setLabelingStrategy(strategy);
+			layer.setIsLabeled(getChkApplyLabels().isSelected());
+		}
+	}
+
+
+	public String getName() {
+		return PluginServices.getText(this,"Etiquetados");
+	}
+}

Property changes on: tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/app/project/documents/view/legend/gui/LabelingManager.java
___________________________________________________________________
Added: svn:keywords
   + Author Date Id Revision
Added: svn:eol-style
   + native

Index: tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/app/project/documents/view/legend/gui/VectorialUniqueValue.java
===================================================================
--- tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/app/project/documents/view/legend/gui/VectorialUniqueValue.java	(revision 0)
+++ tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/app/project/documents/view/legend/gui/VectorialUniqueValue.java	(revision 38653)
@@ -0,0 +1,786 @@
+/* gvSIG. Sistema de Informaci�n Geogr�fica de la Generalitat Valenciana
+ *
+ * Copyright (C) 2004 IVER T.I. and Generalitat Valenciana.
+ *
+ * This program is free software; you can redistribute it and/or
+ * modify it under the terms of the GNU General Public License
+ * as published by the Free Software Foundation; either version 2
+ * of the License, or (at your option) any later version.
+ *
+ * This program is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
+ * GNU General Public License for more details.
+ *
+ * You should have received a copy of the GNU General Public License
+ * along with this program; if not, write to the Free Software
+ * Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA  02111-1307,USA.
+ *
+ * For more information, contact:
+ *
+ *  Generalitat Valenciana
+ *   Conselleria d'Infraestructures i Transport
+ *   Av. Blasco Ib��ez, 50
+ *   46010 VALENCIA
+ *   SPAIN
+ *
+ *      +34 963862235
+ *   gvsig@gva.es
+ *      www.gvsig.gva.es
+ *
+ *    or
+ *
+ *   IVER T.I. S.A
+ *   Salamanca 50
+ *   46005 Valencia
+ *   Spain
+ *
+ *   +34 963163400
+ *   dac@iver.es
+ */
+package org.gvsig.app.project.documents.view.legend.gui;
+
+import java.awt.BorderLayout;
+import java.awt.Color;
+import java.awt.Component;
+import java.awt.Dimension;
+import java.awt.GridLayout;
+import java.awt.event.ActionEvent;
+import java.awt.event.ActionListener;
+import java.util.ArrayList;
+import java.util.Iterator;
+import java.util.Random;
+
+import javax.swing.DefaultComboBoxModel;
+import javax.swing.ImageIcon;
+import javax.swing.JCheckBox;
+import javax.swing.JComboBox;
+import javax.swing.JLabel;
+import javax.swing.JOptionPane;
+import javax.swing.JPanel;
+
+import org.gvsig.andami.IconThemeHelper;
+import org.gvsig.andami.PluginServices;
+import org.gvsig.andami.messages.NotificationManager;
+import org.gvsig.app.gui.styling.JComboBoxColorScheme;
+import org.gvsig.app.gui.styling.SymbolLevelsWindow;
+import org.gvsig.fmap.dal.exception.DataException;
+import org.gvsig.fmap.dal.exception.ReadException;
+import org.gvsig.fmap.dal.feature.Feature;
+import org.gvsig.fmap.dal.feature.FeatureAttributeDescriptor;
+import org.gvsig.fmap.dal.feature.FeatureSet;
+import org.gvsig.fmap.dal.feature.FeatureStore;
+import org.gvsig.fmap.mapcontext.MapContextLocator;
+import org.gvsig.fmap.mapcontext.MapContextManager;
+import org.gvsig.fmap.mapcontext.layers.FLayer;
+import org.gvsig.fmap.mapcontext.layers.operations.ClassifiableVectorial;
+import org.gvsig.fmap.mapcontext.layers.vectorial.FLyrVect;
+import org.gvsig.fmap.mapcontext.rendering.legend.ILegend;
+import org.gvsig.fmap.mapcontext.rendering.legend.IVectorialUniqueValueLegend;
+import org.gvsig.fmap.mapcontext.rendering.legend.ZSort;
+import org.gvsig.fmap.mapcontext.rendering.symbols.ISymbol;
+import org.gvsig.gui.beans.swing.GridBagLayoutPanel;
+import org.gvsig.gui.beans.swing.JBlank;
+import org.gvsig.gui.beans.swing.JButton;
+import org.gvsig.symbology.fmap.mapcontext.rendering.legend.impl.AbstractClassifiedVectorLegend;
+import org.gvsig.symbology.fmap.mapcontext.rendering.legend.impl.VectorialUniqueValueLegend;
+import org.gvsig.tools.dispose.DisposableIterator;
+import org.slf4j.Logger;
+import org.slf4j.LoggerFactory;
+
+
+
+/**
+ * DOCUMENT ME!
+ *
+ * @author fjp To change the template for this generated type comment go to
+ *         Window&gt;Preferences&gt;Java&gt;Code Generation&gt;Code and
+ *         Comments
+ */
+public class VectorialUniqueValue extends JPanel implements ILegendPanel, ActionListener{
+    private static final Logger logger = LoggerFactory
+    .getLogger(VectorialUniqueValue.class);
+
+    protected VectorialUniqueValueLegend theLegend;
+    private ClassifiableVectorial layer;
+    private SymbolTable symbolTable;
+    protected JComboBox cmbFields;
+    private JButton btnRemoveAll;
+    private JButton btnRemove;
+    private JCheckBox chbUseDefault = null;
+    private JSymbolPreviewButton defaultSymbolPrev;
+    private VectorialUniqueValueLegend auxLegend;
+	private JPanel pnlCenter;
+	private JButton btnOpenSymbolLevelsEditor;
+
+	private JComboBoxColorScheme cmbColorScheme;
+	private GridBagLayoutPanel defaultSymbolPanel = new GridBagLayoutPanel();
+		
+	private MapContextManager mapContextManager = MapContextLocator
+			.getMapContextManager();
+
+    /**
+     *
+     */
+    public VectorialUniqueValue() {
+        super();
+        initComponents();
+    }
+
+    /**
+     * DOCUMENT ME!
+     */
+    protected void initComponents() {
+        JPanel pnlButtons = new JPanel();
+
+        JButton btnAddAll = new JButton(PluginServices.getText(this,
+                    "Anadir_todos"));
+        btnAddAll.setActionCommand("ADD_ALL_VALUES");
+        btnAddAll.addActionListener(this);
+        pnlButtons.add(btnAddAll);
+
+        JButton btnAdd = new JButton(PluginServices.getText(this, "Anadir"));
+        btnAdd.setActionCommand("ADD_VALUE");
+        btnAdd.addActionListener(this);
+        pnlButtons.add(btnAdd);
+
+        btnRemoveAll = new JButton(PluginServices.getText(this, "Quitar_todos"));
+        btnRemoveAll.setActionCommand("REMOVE_ALL");
+        btnRemoveAll.addActionListener(this);
+        pnlButtons.add(btnRemoveAll);
+
+        btnRemove = new JButton(PluginServices.getText(this, "Quitar"));
+        btnRemove.setActionCommand("REMOVE");
+        btnRemove.addActionListener(this);
+        pnlButtons.add(btnRemove);
+
+        btnOpenSymbolLevelsEditor = new JButton(PluginServices.getText(this, "symbol_levels"));
+        btnOpenSymbolLevelsEditor.addActionListener(this);
+        btnOpenSymbolLevelsEditor.setActionCommand("OPEN_SYMBOL_LEVEL_EDITOR");
+        pnlButtons.add(btnOpenSymbolLevelsEditor);
+		btnOpenSymbolLevelsEditor.setEnabled(symbolTable != null && symbolTable.getRowCount()>0);
+
+		pnlCenter = new JPanel();
+        pnlCenter.setLayout(new BorderLayout());
+
+        cmbFields = new JComboBox();
+        cmbFields.setActionCommand("FIELD_SELECTED");
+        cmbFields.addActionListener(this);
+        cmbFields.setVisible(true);
+
+		JPanel pnlNorth = new JPanel();
+		pnlNorth.setLayout(new GridLayout(0,2));
+
+		GridBagLayoutPanel auxPanel = new GridBagLayoutPanel();
+		JLabel lblFieldClassification = new JLabel(PluginServices.getText(
+				this, "Campo_de_clasificacion")+": ");
+		auxPanel.add(lblFieldClassification);
+		auxPanel.add(cmbFields);
+		pnlNorth.add(auxPanel);
+
+		auxPanel = new GridBagLayoutPanel();
+		auxPanel.add(new JLabel(PluginServices.getText(this, "color_scheme")+": "));
+		cmbColorScheme = new JComboBoxColorScheme(false);
+		cmbColorScheme.addActionListener(this);
+		auxPanel.add(cmbColorScheme);
+		pnlNorth.add(auxPanel);
+
+
+		defaultSymbolPanel.add(getChbUseDefault(), null);
+		pnlNorth.add(defaultSymbolPanel);
+		pnlNorth.add(new JBlank(0,30));
+
+		this.setLayout(new BorderLayout());
+		this.add(pnlNorth, BorderLayout.NORTH);
+		this.add(pnlCenter, BorderLayout.CENTER);
+		this.add(pnlButtons, BorderLayout.SOUTH);
+
+
+    }
+
+    /**
+     * DOCUMENT ME!
+     */
+    private void fillTableValues() {
+        FeatureStore elRs;
+
+        try {
+            elRs = ((FLyrVect) layer).getFeatureStore();
+//            logger.debug("elRs.start()");
+//            elRs.start();
+
+//            int idField = -1;
+            String fieldName = (String) cmbFields.getSelectedItem();
+            if (fieldName==null) {
+            	JOptionPane.showMessageDialog((Component)PluginServices.getMainFrame(),PluginServices.getText(this,"no_hay_campo_seleccionado"));
+            	return;
+            }
+
+//            idField = elRs.getFieldIndexByName(fieldName);
+            auxLegend.setClassifyingFieldNames(new String[] {fieldName});
+
+            //long numReg = elRs.getRowCount();
+//            if (idField == -1) {
+//                NotificationManager.addWarning(
+//                		PluginServices.getText(this, "unrecognized_field_name")+" " + fieldName, null);
+//
+//                return;
+//            }
+
+            symbolTable.removeAllItems();
+
+            int numSymbols = 0;
+            ISymbol theSymbol = null;
+
+            //auxLegend=(VectorialUniqueValueLegend)m_lyr.getLegend();
+
+            //            auxLegend = LegendFactory.createVectorialUniqueValueLegend(layer.getShapeType());
+            auxLegend = (VectorialUniqueValueLegend) MapContextLocator
+					.getMapContextManager().createLegend(
+							IVectorialUniqueValueLegend.LEGEND_NAME);
+            auxLegend.setShapeType(layer.getShapeType());
+
+            Object clave=null;
+
+            //Object resul;
+            if (chbUseDefault.isSelected()) {
+                auxLegend.getDefaultSymbol().setDescription("Default");
+                auxLegend.addSymbol(null, auxLegend.getDefaultSymbol());
+            }
+
+            Color[] colorScheme = cmbColorScheme.getSelectedColors();
+
+            Color[] colors = new Color[colorScheme.length];
+			for (int i = 0; i < colorScheme.length; i++) {
+				colors[i] = colorScheme[i];
+			}
+			auxLegend.setColorScheme(colors);
+
+            Random rand = new Random(System.currentTimeMillis());
+
+            FeatureSet set = null;
+			DisposableIterator iterator = null;
+
+			try {
+				set = elRs.getFeatureSet();
+
+				int count = 0;
+
+				iterator = set.iterator();
+				while (iterator.hasNext()) {
+					Feature feature = (Feature) iterator.next();
+					clave = feature.get(fieldName);
+					// }
+					// for (int j = 0; j < elRs.getRowCount(); j++) {
+					// clave = elRs.getFieldValue(j, idField);
+
+//					if (clave instanceof NullValue) {
+//						continue;
+//					}
+					if (clave == null) {
+						continue;
+					}
+
+					// //Comprobar que no esta repetido y no hace falta
+					// introducir en el hashtable el campo junto con el simbolo.
+					if (auxLegend.getSymbolByValue(clave) == null) {
+
+						if (count == 100) {
+							int resp = JOptionPane.showConfirmDialog(this,
+									PluginServices.getText(this,
+											"mas_de_100_simbolos"),
+									PluginServices.getText(this,
+											"quiere_continuar"),
+									JOptionPane.YES_NO_OPTION,
+									JOptionPane.WARNING_MESSAGE);
+
+							if ((resp == JOptionPane.NO_OPTION)
+									|| (resp == JOptionPane.DEFAULT_OPTION)) {
+								break;
+							}
+						}
+
+
+						// si no esta creado el simbolo se crea
+						// jaume (moved to ISymbol); theSymbol = new
+						// FSymbol(layer.getShapeType());
+						theSymbol =
+								mapContextManager.getSymbolManager()
+										.createSymbol(
+												layer
+										.getShapeType(), colorScheme[rand
+										.nextInt(colorScheme.length)]);
+						theSymbol.setDescription(clave.toString());
+						auxLegend.addSymbol(clave, theSymbol);
+						count++;
+					}
+
+				} // for
+			}finally{
+				if (iterator != null){
+					iterator.dispose();
+				}
+				if (set != null) {
+					set.dispose();
+				}
+			}
+
+			Object[] values = auxLegend.getValues();
+			String[] descriptions = new String[values.length];
+			ISymbol[] symbols = new ISymbol[values.length];
+			
+			for (int i = 0; i < values.length; i++) {
+				Object value = values[i];
+				symbols[i] = auxLegend.getSymbolByValue(value);
+				descriptions[i] = symbols[i].getDescription();
+			}
+			
+            symbolTable.fillTableFromSymbolList(symbols,
+                values, descriptions);
+//            elRs.stop();
+//            set.dispose();
+        } catch (DataException e) {
+        	NotificationManager.addError(PluginServices.getText(this, "recovering_recordset"), e);
+        }
+
+        btnRemoveAll.setEnabled(true);
+        btnRemove.setEnabled(true);
+
+        //m_bCacheDirty = false;
+    }
+
+	private boolean compareClassifyingFieldNames(String[] a, String[] b){
+		if (a==b) {
+			return true;
+		}
+		if (a == null || b == null) {
+			return false;
+		}
+		if (a.length != b.length) {
+			return false;
+		}
+		for (int i=0; i<a.length; i++){
+			if (!a[i].equals(b[i])) {
+				return false;
+			}
+		}
+		return true;
+	}
+
+	private boolean compareClassifyingFieldTypes(int[] a, int[] b){
+		if (a==b) {
+			return true;
+		}
+		if (a == null || b == null) {
+			return false;
+		}
+		if (a.length != b.length) {
+			return false;
+		}
+		for (int i=0; i<a.length; i++){
+			if (a[i]!=b[i]) {
+				return false;
+			}
+		}
+		return true;
+	}
+
+    /**
+     * A partir de los registros de la tabla, regenera el FRenderer. (No solo
+     * el symbolList, si no tambi�n el arrayKeys y el defaultRenderer
+     */
+    private void fillSymbolListFromTable() {
+        Object clave=null;
+        ISymbol theSymbol;
+		ArrayList visitedKeys = new ArrayList();
+		boolean changedLegend = false;
+
+    	String fieldName = (String) cmbFields.getSelectedItem();
+		String[] classifyingFieldNames = new String[] {fieldName};
+		if(auxLegend!=null){
+			if(!compareClassifyingFieldNames(classifyingFieldNames,auxLegend.getClassifyingFieldNames())){
+				auxLegend.setClassifyingFieldNames(classifyingFieldNames);
+				changedLegend = true;
+			}
+		} else {
+			auxLegend.setClassifyingFieldNames(classifyingFieldNames);
+			changedLegend = true;
+		}
+
+		FLyrVect m = (FLyrVect) layer;
+
+        try {
+        	int fieldType = m.getFeatureStore().getDefaultFeatureType()
+					.getAttributeDescriptor(cmbFields.getSelectedIndex())
+					.getType();
+//        	int fieldType = m.getSource().getRecordset().getFieldType((int)cmbFields.getSelectedIndex());
+			int[] classifyingFieldTypes = new int[] {fieldType};
+			if(auxLegend!=null){
+				if(!compareClassifyingFieldTypes(classifyingFieldTypes,auxLegend.getClassifyingFieldTypes())){
+					auxLegend.setClassifyingFieldTypes(classifyingFieldTypes);
+					changedLegend = true;
+				}
+			} else {
+				auxLegend.setClassifyingFieldTypes(classifyingFieldTypes);
+				changedLegend = true;
+			}
+        } catch (DataException e) {
+        	NotificationManager.addError(PluginServices.getText(this, "could_not_setup_legend"), e);
+        } catch (Exception e) {
+			NotificationManager.showMessageWarning(PluginServices.getText(this, "could_not_setup_legend"), e);
+		}
+
+		if(changedLegend){
+			auxLegend.clear();
+		}
+
+        for (int row = 0; row < symbolTable.getRowCount(); row++) {
+            clave = symbolTable.getFieldValue(row, 1);
+            theSymbol = (ISymbol) symbolTable.getFieldValue(row, 0);
+			String description = (String) symbolTable.getFieldValue(row, 2);
+			theSymbol.setDescription(description);
+			ISymbol legendSymbol = null;
+			if (auxLegend != null){
+				legendSymbol = auxLegend.getSymbolByValue(clave);
+			}
+			if( legendSymbol == null || ( auxLegend.isUseDefaultSymbol() && legendSymbol == auxLegend.getDefaultSymbol())){
+				if (auxLegend != null){
+					auxLegend.addSymbol(clave, theSymbol);
+				}
+			} else {
+			    
+			    // avoid same instance
+			    if (legendSymbol != theSymbol) {
+
+			        /*
+			         * Perhaps use this "if" when implementations of ISymbol
+			         * properly implement the equals method. 
+			         */
+			        // if (!legendSymbol.equals(theSymbol)) {
+			            auxLegend.replace(legendSymbol, theSymbol);
+			        // }
+			    }
+			}
+			visitedKeys.add(clave);
+		}
+		if(auxLegend != null){
+			Object[] keys = auxLegend.getValues();
+			for(int i=0; i<keys.length; i++){
+				Object key = keys[i];
+				if(!visitedKeys.contains(key)){
+					auxLegend.delSymbol(key);
+				}
+			}
+		}
+		clave = null;
+		if(chbUseDefault.isSelected()){
+			theSymbol = defaultSymbolPrev.getSymbol();
+			if(theSymbol != null){
+				String description = PluginServices.getText(this,"default");
+				theSymbol.setDescription(description);
+				ISymbol legendSymbol = null;
+				if (auxLegend != null){
+					legendSymbol = auxLegend.getSymbolByValue(clave);
+				}
+				if( legendSymbol == null){
+					auxLegend.addSymbol(clave, theSymbol);
+				} else {
+//					if(!legendSymbol.equals(theSymbol)){
+					if(legendSymbol!=theSymbol){
+						auxLegend.replace(legendSymbol, theSymbol);
+					}
+				}
+			}
+		} else {
+			if (auxLegend != null){
+				ISymbol legendSymbol = auxLegend.getSymbolByValue(clave);
+				if( legendSymbol != null){
+					auxLegend.replace(legendSymbol, null);
+				}
+			}
+		}
+	}
+
+    /**
+     * DOCUMENT ME!
+     */
+    private void fillFieldNames() {
+        FeatureStore rs;
+
+        try {
+            rs = ((FLyrVect) layer).getFeatureStore();
+//            logger.debug("rs.start()");
+//            rs.start();
+
+            ArrayList names=new ArrayList();
+            Iterator iterator=rs.getDefaultFeatureType().iterator();
+            while (iterator.hasNext()) {
+				FeatureAttributeDescriptor descriptor = (FeatureAttributeDescriptor) iterator.next();
+				names.add(descriptor.getName());
+			}
+//            String[] nomFields = new String[rs.getFieldCount()];
+//
+//            for (int i = 0; i < rs.getFieldCount(); i++) {
+//                nomFields[i] = rs.getFieldName(i).trim();
+//            }
+//
+//            rs.stop();
+
+            DefaultComboBoxModel cM = new DefaultComboBoxModel(names.toArray(new String[0]));
+            cmbFields.setModel(cM);
+
+            // fieldsListValor.setSelectedIndex(0);
+        } catch (DataException e) {
+        	NotificationManager.addError(PluginServices.getText(this, "recovering_recordset"), e);
+        }
+    }
+
+    public void setData(FLayer layer, ILegend legend) {
+    	this.layer = (ClassifiableVectorial) layer;
+      	int shapeType = 0;
+      	try {
+      		shapeType = this.layer.getShapeType();
+      	} catch (ReadException e) {
+    		NotificationManager.addError(PluginServices.getText(this, "generating_intervals"), e);
+		}
+
+      	getDefaultSymbolPrev(shapeType);
+
+      	if (symbolTable != null) {
+			pnlCenter.remove(symbolTable);
+		}
+      	symbolTable = new SymbolTable(this, SymbolTable.VALUES_TYPE, shapeType);
+      	pnlCenter.add(symbolTable, BorderLayout.CENTER);
+
+        fillFieldNames();
+
+        symbolTable.removeAllItems();
+
+    	if (VectorialUniqueValueLegend.class.equals(legend.getClass())) {
+			auxLegend = (VectorialUniqueValueLegend) legend.cloneLegend();
+			getChbUseDefault().setSelected(auxLegend.isUseDefaultSymbol());
+			cmbFields.getModel().setSelectedItem(auxLegend.getClassifyingFieldNames()[0]);
+			setColorScheme();
+			
+			Object[] values = auxLegend.getValues();
+			String[] descriptions = new String[values.length];
+			ISymbol[] symbols = new ISymbol[values.length];
+			
+			for (int i = 0; i < values.length; i++) {
+				Object value = values[i];
+				symbols[i] = auxLegend.getSymbolByValue(value);
+				descriptions[i] = symbols[i].getDescription();
+			}
+
+			symbolTable.fillTableFromSymbolList(symbols,
+					values,descriptions);
+			chbUseDefault.setSelected(auxLegend.isUseDefaultSymbol());
+		} else {
+			auxLegend = new VectorialUniqueValueLegend(shapeType);
+		}
+		defaultSymbolPrev.setSymbol(auxLegend.getDefaultSymbol());
+		btnOpenSymbolLevelsEditor.setEnabled(symbolTable != null && symbolTable.getRowCount()>0);
+    }
+
+
+    private void setColorScheme(){
+
+		if(auxLegend.getColorScheme() != null) {
+			Color[] colorScheme = auxLegend.getColorScheme();
+//			ColorItem[] colors = new ColorItem[auxLegend.getColorScheme().length];
+//			for (int i = 0; i < auxLegend.getColorScheme().length; i++) {
+//				colors[i] = new ColorItem();
+//				colors[i].setColor(auxLegend.getColorScheme()[i]);
+//			}
+			cmbColorScheme.setSelectedColors(colorScheme);
+		}
+	}
+
+    private void getDefaultSymbolPrev(int shapeType) {
+		if(defaultSymbolPrev == null){
+			defaultSymbolPrev = new JSymbolPreviewButton(shapeType);
+			defaultSymbolPrev.setPreferredSize(new Dimension(110,20));
+			defaultSymbolPrev.addActionListener(this);
+			defaultSymbolPanel.add(defaultSymbolPrev,null);
+		}
+	}
+
+    /* (non-Javadoc)
+     * @see com.iver.cit.gvsig.gui.legendmanager.panels.ILegendPanel#getLegend()
+     */
+    public ILegend getLegend() {
+    	fillSymbolListFromTable();
+
+    	if (auxLegend != null) {
+    		// your settings that are not the set of symbols must be located here
+//  		auxLegend.setClassifyingFieldNames(
+//  		new String[] {(String) cmbFields.getSelectedItem()});
+
+    		ISymbol defaultSymbolLegend = auxLegend.getDefaultSymbol();
+    		ISymbol symbol = defaultSymbolPrev.getSymbol();
+    		if(symbol != null){
+    			if(symbol!=defaultSymbolLegend){
+    				auxLegend.setDefaultSymbol(symbol);
+    			}
+    		}
+
+    		auxLegend.useDefaultSymbol(chbUseDefault.isSelected());
+
+    		theLegend = (VectorialUniqueValueLegend) auxLegend.cloneLegend();
+    		theLegend.setZSort(auxLegend.getZSort());
+    	}
+
+    	return theLegend;
+    }
+
+    private JCheckBox getChbUseDefault() {
+    	if (chbUseDefault == null) {
+			chbUseDefault = new JCheckBox();
+			chbUseDefault.setSelected(false);
+			chbUseDefault.addActionListener(new java.awt.event.ActionListener() {
+				public void actionPerformed(java.awt.event.ActionEvent e) {
+					if (chbUseDefault.isSelected()) {
+						auxLegend.useDefaultSymbol(true);
+					} else {
+						auxLegend.useDefaultSymbol(false);
+					}
+				}
+			});
+			chbUseDefault.setText(PluginServices.getText(this, "resto_valores")+ ": ");
+		}
+
+		return chbUseDefault;
+    }
+
+    /**
+     * A�ade el resto de valores.
+     */
+    private void addDefault() {
+        auxLegend.getDefaultSymbol().setDescription("Default");
+        auxLegend.addSymbol(null, auxLegend.getDefaultSymbol());
+        symbolTable.addTableRecord(auxLegend.getDefaultSymbol(),
+            null, auxLegend.getDefaultSymbol().getDescription());
+        symbolTable.repaint();
+    }
+
+    /**
+     * Elimina el resto de valores que no estan representados por ning�n otro s�mbolo..
+     */
+    private void delDefault() {
+        auxLegend.delSymbol(null);
+        symbolTable.removeRow(null);
+        symbolTable.repaint();
+    }
+
+
+    public void actionPerformed(ActionEvent e) {
+
+    	//modificar el combobox de valor
+    	if (e.getActionCommand() == "FIELD_SELECTED") {
+    		JComboBox cb = (JComboBox) e.getSource();
+    		String fieldName = (String) cb.getSelectedItem();
+    		symbolTable.removeAllItems();
+			btnOpenSymbolLevelsEditor.setEnabled(false);
+
+
+//    		if (theLegend.getClassifyingFieldNames()!=null && fieldName != theLegend.getClassifyingFieldNames()[0]) {
+//    			//m_bCacheDirty = true;
+//    			theLegend.setClassifyingFieldNames(new String[] {fieldName});
+//    		}
+//
+//    		//////////////////////////////////////////PEPE
+//    		FLyrVect m = (FLyrVect) layer;
+//    		try {
+//    			int fieldType = m.getSource().getRecordset().getFieldType((int)cb.getSelectedIndex());
+//    			if (theLegend.getClassifyingFieldTypes()!=null && fieldType != theLegend.getClassifyingFieldTypes()[0]) {
+//    				//m_bCacheDirty = true;
+//    				theLegend.setClassifyingFieldTypes(new int[] {fieldType});
+//    			}
+//    		} catch (ReadDriverException e1) {
+//    			NotificationManager.addError(PluginServices.getText(this, "could_not_setup_legend"), e1);
+//    		}
+//    		/////////////////////////////////////////PEPE
+    	}
+
+    	// add all elements by value
+    	if (e.getActionCommand() == "ADD_ALL_VALUES") {
+    		fillTableValues();
+			btnOpenSymbolLevelsEditor.setEnabled(symbolTable != null && symbolTable.getRowCount()>0);
+    	}
+
+    	// add only one value
+    	if (e.getActionCommand() == "ADD_VALUE") {
+    		try {
+				ISymbol symbol =
+						mapContextManager.getSymbolManager().createSymbol(
+								layer.getShapeType());
+				Double clave = new Double(0.0);
+				symbolTable.addTableRecord(symbol,
+						clave,"0 - 0");
+				btnOpenSymbolLevelsEditor.setEnabled(true);
+    		} catch (ReadException ex) {
+    			NotificationManager.addError(PluginServices.getText(this, "getting_shape_type"), ex);
+    		}
+    	}
+
+    	//Vacia la tabla
+    	if (e.getActionCommand() == "REMOVE_ALL") {
+    		symbolTable.removeAllItems();
+    		auxLegend.setZSort(null);
+			btnOpenSymbolLevelsEditor.setEnabled(false);
+
+    	}
+
+    	//Quitar solo el elemento seleccionado
+    	if (e.getActionCommand() == "REMOVE") {
+    		symbolTable.removeSelectedRows();
+			btnOpenSymbolLevelsEditor.setEnabled(symbolTable.getRowCount()>0);
+    	}
+
+    	if (e.getActionCommand() == "OPEN_SYMBOL_LEVEL_EDITOR") {
+			ZSort myZSort = null;
+			if (auxLegend != null) {
+				myZSort = ((AbstractClassifiedVectorLegend) getLegend()).getZSort();
+				if(myZSort == null){
+					myZSort = new ZSort(auxLegend);
+				}
+			}
+			if (myZSort == null && theLegend != null) {
+				myZSort = new ZSort(theLegend);
+			}
+			SymbolLevelsWindow sl = new SymbolLevelsWindow(myZSort);
+			PluginServices.getMDIManager().addWindow(sl);
+			auxLegend.setZSort(sl.getZSort());
+		}
+    }
+
+	public String getDescription() {
+		return PluginServices.getText(this,"Dado_un_campo_de_atributos") + "," + PluginServices.getText(this,"muestra_los_elementos_de_la_capa_usando_un_simbolo_por_cada_valor_unico") + ".";
+	}
+
+	public ImageIcon getIcon() {
+	    return IconThemeHelper.getImageIcon(
+	        "legend-overview-vectorial-unique-value");
+	}
+
+	public Class getParentClass() {
+		return Categories.class;
+	}
+
+	public String getTitle() {
+		return PluginServices.getText(this,"Valores_unicos");
+	}
+
+	public JPanel getPanel() {
+		return this;
+	}
+
+	public Class getLegendClass() {
+		return VectorialUniqueValueLegend.class;
+	}
+
+
+	public boolean isSuitableFor(FLayer layer) {
+		return (layer instanceof FLyrVect);
+	}
+}

Property changes on: tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/app/project/documents/view/legend/gui/VectorialUniqueValue.java
___________________________________________________________________
Added: svn:keywords
   + Author Date Id Revision
Added: svn:eol-style
   + native

Index: tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/app/project/documents/view/legend/gui/General.java
===================================================================
--- tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/app/project/documents/view/legend/gui/General.java	(revision 0)
+++ tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/app/project/documents/view/legend/gui/General.java	(revision 38653)
@@ -0,0 +1,850 @@
+/*
+ * Created on 31-ene-2005
+ *
+ * gvSIG. Sistema de Informaci�n Geogr�fica de la Generalitat Valenciana
+ *
+ * Copyright (C) 2004 IVER T.I. and Generalitat Valenciana.
+ *
+ * This program is free software; you can redistribute it and/or
+ * modify it under the terms of the GNU General Public License
+ * as published by the Free Software Foundation; either version 2
+ * of the License, or (at your option) any later version.
+ *
+ * This program is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
+ * GNU General Public License for more details.
+ *
+ * You should have received a copy of the GNU General Public License
+ * along with this program; if not, write to the Free Software
+ * Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA  02111-1307,USA.
+ *
+ * For more information, contact:
+ *
+ *  Generalitat Valenciana
+ *   Conselleria d'Infraestructures i Transport
+ *   Av. Blasco Ib��ez, 50
+ *   46010 VALENCIA
+ *   SPAIN
+ *
+ *      +34 963862235
+ *   gvsig@gva.es
+ *      www.gvsig.gva.es
+ *
+ *    or
+ *
+ *   IVER T.I. S.A
+ *   Salamanca 50
+ *   46005 Valencia
+ *   Spain
+ *
+ *   +34 963163400
+ *   dac@iver.es
+ */
+package org.gvsig.app.project.documents.view.legend.gui;
+
+import java.awt.BorderLayout;
+import java.awt.ComponentOrientation;
+import java.awt.Dimension;
+import java.awt.FlowLayout;
+import java.awt.GridLayout;
+import java.awt.SystemColor;
+import java.awt.event.ActionEvent;
+import java.awt.event.ActionListener;
+import java.text.NumberFormat;
+import java.text.ParseException;
+
+import javax.swing.BorderFactory;
+import javax.swing.ButtonGroup;
+import javax.swing.JCheckBox;
+import javax.swing.JLabel;
+import javax.swing.JPanel;
+import javax.swing.JRadioButton;
+import javax.swing.JScrollPane;
+import javax.swing.JTextArea;
+import javax.swing.JTextField;
+import javax.swing.border.BevelBorder;
+import javax.swing.border.EtchedBorder;
+import javax.swing.border.TitledBorder;
+
+import org.cresques.cts.ICoordTrans;
+import org.cresques.cts.IProjection;
+import org.gvsig.andami.PluginServices;
+import org.gvsig.andami.messages.NotificationManager;
+import org.gvsig.fmap.dal.DataStoreParameters;
+import org.gvsig.fmap.dal.exception.DataException;
+import org.gvsig.fmap.dal.exception.ReadException;
+import org.gvsig.fmap.dal.feature.FeatureStore;
+import org.gvsig.fmap.dal.serverexplorer.filesystem.FilesystemStoreParameters;
+import org.gvsig.fmap.geom.primitive.Envelope;
+import org.gvsig.fmap.geom.type.GeometryType;
+import org.gvsig.fmap.geom.type.GeometryTypeNotSupportedException;
+import org.gvsig.fmap.geom.type.GeometryTypeNotValidException;
+import org.gvsig.fmap.mapcontext.layers.FLayer;
+import org.gvsig.fmap.mapcontext.layers.FLyrDefault;
+import org.gvsig.fmap.mapcontext.layers.vectorial.FLyrVect;
+import org.gvsig.gui.beans.swing.GridBagLayoutPanel;
+import org.gvsig.gui.beans.swing.JBlank;
+import org.gvsig.tools.locator.LocatorException;
+
+
+
+
+/**
+ * This class implements an useful and intuitive graphic interface to change some
+ * properties of the layer. This class extends AbstractThemeManager. The properties
+ * that allow modified are the name of the layer, the scale, if the user want to use
+ * Spatial index or not and the HyperLink. Also shows a scroll with a little resume
+ * with the properties of the layer.
+ * @author jmorell
+ *
+ * TODO To change the template for this generated type comment go to
+ * Window - Preferences - Java - Code Style - Code Templates
+ */
+public class General extends AbstractThemeManagerPage {
+
+	private static final long serialVersionUID = 1L;
+    private FLayer layer;
+	private NumberFormat nf = NumberFormat.getInstance();
+	private JPanel pnlLayerName = null;
+	private GridBagLayoutPanel pnlScale = null;
+	private JPanel pnlProperties = null;
+	private JLabel lblLayerName = null;
+	private JTextField txtLayerName = null;
+	private JTextField txtMaxScale = null;
+	private JTextArea propertiesTextArea = null;
+	private JRadioButton rdBtnShowAlways = null;
+	private JRadioButton rdBtnDoNotShow = null;
+	private JTextField txtMinScale = null;
+    private JCheckBox jCheckBoxSpatialIndex = null;
+
+//	private ViewDocument view;
+//    private JTextField txtLinkExtension = null;
+//	private JComboBox cmbLinkField = null;
+//    private JComboBox cmbLinkType = null;
+//    private JPanel pnlHyperLink;
+//	private JLabel lblLinkExtension;
+//	private JLabel lblLinkField;
+//	private JPanel pnlFieldAndExtension;
+//	private JPanel pnlHyperLinkAction;
+//	
+//	private JLabel lblDefaultAction;
+	private JScrollPane scrlProperties;
+
+    /**
+	 * This is the default constructor.
+	 */
+	public General() {
+		super();
+		initialize();
+	}
+	/**
+	 * This method initializes this
+	 *
+	 * @return void
+	 */
+	private  void initialize() {
+		this.setLayout(new BorderLayout());
+		GridBagLayoutPanel aux = new GridBagLayoutPanel();
+		aux.addComponent(getPnlLayerName());
+		aux.addComponent(new JBlank(10, 10));
+		aux.addComponent(getJCheckBoxSpatialIndex());
+		aux.addComponent("", getPnlScale());
+		JPanel aux2 = new JPanel(new GridLayout(1,2));
+		aux2.add(getPnlProperties());
+//		aux2.add(getPnlHyperLink());
+		aux.addComponent(aux2);
+
+
+
+		aux.setPreferredSize(getPreferredSize());
+		this.add(aux, BorderLayout.CENTER);
+		this.add(new JBlank(5, 10), BorderLayout.WEST);
+		this.add(new JBlank(5, 10), BorderLayout.EAST);
+
+	}
+
+
+	/**
+	 * Sets the necessary properties in the panel. This properties are
+	 * extracted from the layer. With this properties fills the TextFields,
+	 * ComboBoxes and the rest of GUI components.
+	 * @param FLayer layer,
+	 */
+	public void setModel(FLayer layer) {
+		this.layer = layer;
+
+        if (layer instanceof FLyrVect) {
+//            FLyrVect lyrVect = (FLyrVect) layer;
+
+
+            //TODO
+//            if(lyrVect.getISpatialIndex() == null) {
+//                getJCheckBoxSpatialIndex().setSelected(false);
+//            } else {
+//                getJCheckBoxSpatialIndex().setSelected(true);
+//            }
+        }
+		if (layer.getMinScale() != -1) {
+			getTxtMaxScale().setText(nf.format(layer.getMinScale()));
+		}
+		if (layer.getMaxScale() != -1) {
+			getTxtMinScale().setText(nf.format(layer.getMaxScale()));
+		}
+		if (layer.getMinScale() == -1 && layer.getMaxScale() == -1) {
+			getRdBtnShowAlways().setSelected(true);
+			txtMaxScale.setEnabled(false);
+			txtMinScale.setEnabled(false);
+
+		} else {
+			getRdBtnDoNotShowWhen().setSelected(true);
+			txtMaxScale.setEnabled(true);
+			txtMinScale.setEnabled(true);
+		}
+		txtLayerName.setText(layer.getName());
+		showLayerInfo();
+
+
+//		if (PluginServices.getMainFrame() != null) {
+//			if  (PluginServices.getMDIManager().getActiveWindow() instanceof AbstractViewPanel ){
+//			    AbstractViewPanel theView = (AbstractViewPanel)PluginServices.getMDIManager().getActiveWindow();
+//			    view = theView.getModel();
+//			    try {
+//			        if (layer instanceof FLyrVect) {
+//			            FLyrVect ad = (FLyrVect) layer;
+//			            FeatureStore fs;
+//			            fs = ad.getFeatureStore();
+//			            FeatureType ftype = fs.getDefaultFeatureType();
+//			            String[] names = new String[ftype.size()];
+//			            Iterator iter = ftype.iterator();
+//			            int i=0;
+//			            while (iter.hasNext()){
+//			                names[i] = ((FeatureAttributeDescriptor)iter.next()).getName();
+//			                i++;
+//			            }
+//			            DefaultComboBoxModel defaultModel = new DefaultComboBoxModel(names);
+//			            cmbLinkField.setModel(defaultModel);
+//
+//			            if (layer.getLinkProperties().getField()!=null) {
+//							cmbLinkField.setSelectedItem(layer.getLinkProperties().getField());
+//						} else {
+//							cmbLinkField.setSelectedItem(view.getSelectedField());
+//						}
+//			        } else {
+//			            cmbLinkField = new JComboBox();
+//			        }
+//			     } catch (DataException e) {
+//			        NotificationManager.addError("No se pudo obtener la tabla", e);
+//			    }
+//
+//
+//			    if(layer.getLinkProperties().getExt()!=null) {
+//					getTxtLinkExtension().setText(layer.getLinkProperties().getExt());
+//				}
+//
+//			    getCmbLinkType().addItem(PluginServices.getText(this,
+//			       	"Enlazar_a_ficheros_de_imagen"));
+//			    getCmbLinkType().addItem(PluginServices.getText(this,
+//			    	"Enlazar_a_fichero_de_texto"));
+//
+//			    getCmbLinkType().addItem(PluginServices.getText(this,
+//			    	"Enlazar_a_documento_PDF"));
+//			    getCmbLinkType().addItem(PluginServices.getText(this,
+//					"Enlazar_a_imagen_SVG"));
+//
+//			    if (layer.getLinkProperties().getType()!=-1) {
+//					getCmbLinkType().setSelectedIndex(layer.getLinkProperties().getType());
+//				}
+//
+//			}
+//		}
+
+	}
+
+	/**
+	 * This method initializes jPanel
+	 *
+	 * @return javax.swing.JPanel
+	 */
+	private JPanel getPnlLayerName() {
+		if (pnlLayerName == null) {
+			lblLayerName = new JLabel();
+			pnlLayerName = new JPanel();
+			lblLayerName.setText(PluginServices.getText(this,"Nombre") + ":");
+			lblLayerName.setComponentOrientation(ComponentOrientation.UNKNOWN);
+			pnlLayerName.setComponentOrientation(ComponentOrientation.UNKNOWN);
+			pnlLayerName.add(lblLayerName, null);
+			pnlLayerName.add(getTxtLayerName(), null);
+		}
+		return pnlLayerName;
+	}
+	/**
+	 * This method initializes jPanel1
+	 *
+	 * @return javax.swing.JPanel
+	 */
+	private GridBagLayoutPanel getPnlScale() {
+		if (pnlScale == null) {
+			pnlScale = new GridBagLayoutPanel();
+			pnlScale.setBorder(BorderFactory.createTitledBorder(
+    				BorderFactory.createEtchedBorder(EtchedBorder.LOWERED),
+					PluginServices.getText(this, "rango_de_escalas"),
+					TitledBorder.DEFAULT_JUSTIFICATION,
+					TitledBorder.DEFAULT_POSITION, null, null)
+				);
+			ButtonGroup buttonGroup = new ButtonGroup();
+			buttonGroup.add(getRdBtnShowAlways());
+			buttonGroup.add(getRdBtnDoNotShowWhen());
+			pnlScale.addComponent(getRdBtnShowAlways());
+			pnlScale.addComponent(getRdBtnDoNotShowWhen());
+			JPanel aux;
+
+
+			aux = new JPanel(new FlowLayout(FlowLayout.LEFT));
+			aux.add(getTxtMaxScale());
+			aux.add(new JLabel("(" + PluginServices.getText(this,"escala_maxima") + ")"));
+
+			GridBagLayoutPanel aux2;
+			aux2 = new GridBagLayoutPanel();
+			aux2.addComponent(PluginServices.getText(
+					this,"este_por_encima_de")+" 1:",
+					aux);
+			aux = new JPanel(new FlowLayout(FlowLayout.LEFT));
+			aux.add(getTxtMinScale());
+			aux.add(new JLabel("(" + PluginServices.getText(this,"escala_minima") + ")"));
+
+			aux2.addComponent(PluginServices.getText(
+					this,"este_por_debajo_de_")+" 1:",
+					aux);
+
+			pnlScale.addComponent(new JBlank(20, 1), aux2);
+
+			pnlScale.addComponent(new JBlank(20, 1), aux2);
+
+		}
+		return pnlScale;
+	}
+	/**
+	 * This method initializes jPanel2, this contains the ScrollPane with the
+	 * properies.
+	 *
+	 * @return javax.swing.JPanel
+	 */
+	private JPanel getPnlProperties() {
+		if (pnlProperties == null) {
+			pnlProperties = new JPanel();
+			pnlProperties.setBorder(BorderFactory.createTitledBorder(
+    				BorderFactory.createEtchedBorder(EtchedBorder.LOWERED),
+					PluginServices.getText(this, "propiedades"),
+					TitledBorder.DEFAULT_JUSTIFICATION,
+					TitledBorder.DEFAULT_POSITION, null, null)
+				);
+			pnlProperties.add(getScrlProperties(), null);
+		}
+		return pnlProperties;
+	}
+
+	/**
+	 * This method initializes jTextField
+	 *
+	 * @return javax.swing.JTextField
+	 */
+	private JTextField getTxtLayerName() {
+		if (txtLayerName == null) {
+			txtLayerName = new JTextField(25);
+			txtLayerName.setEditable(true);
+		}
+		return txtLayerName;
+	}
+
+	/**
+	 * This method initializes TxtMaxScale
+	 * @return jTextField1
+	 */
+	private JTextField getTxtMaxScale() {
+		if (txtMaxScale == null) {
+			txtMaxScale = new JTextField(15);
+			txtMaxScale.setEnabled(false);
+		}
+		return txtMaxScale;
+	}
+	/**
+	 * This method initilizes TxtArea, in this TextArea sets the text with
+	 * the properties of the layer
+	 * @return
+	 */
+	private JTextArea getPropertiesTextArea() {
+		if (propertiesTextArea == null) {
+			propertiesTextArea = new JTextArea();
+			propertiesTextArea.setEditable(false);
+			propertiesTextArea.setBackground(SystemColor.control);
+
+		}
+		return propertiesTextArea;
+	}
+
+	/**
+	 * This method initializes jScrollPane
+	 *
+	 * @return javax.swing.JScrollPane
+	 */
+	private JScrollPane getScrlProperties() {
+		if (scrlProperties == null) {
+			scrlProperties = new JScrollPane();
+			scrlProperties.setViewportView(getPropertiesTextArea());
+			scrlProperties.setBorder(BorderFactory.createBevelBorder(BevelBorder.LOWERED));
+			scrlProperties.setPreferredSize(new Dimension(350, 180));
+		}
+		return scrlProperties;
+	}
+	/**
+	 * This method initializes jRadioButton
+	 *
+	 * @return javax.swing.JRadioButton
+	 */
+	private JRadioButton getRdBtnShowAlways() {
+		if (rdBtnShowAlways == null) {
+			rdBtnShowAlways = new JRadioButton();
+			rdBtnShowAlways.setText(PluginServices.getText(this,"Mostrar_siempre"));
+			rdBtnShowAlways.setSelected(true);
+			rdBtnShowAlways.addActionListener(new ActionListener() {
+				public void actionPerformed(ActionEvent e) {
+					txtMaxScale.setEnabled(false);
+					txtMinScale.setEnabled(false);
+				}
+			});
+		}
+		return rdBtnShowAlways;
+	}
+	/**
+	 * This method initializes jRadioButton1
+	 *
+	 * @return javax.swing.JRadioButton
+	 */
+	private JRadioButton getRdBtnDoNotShowWhen() {
+		if (rdBtnDoNotShow == null) {
+			rdBtnDoNotShow = new JRadioButton();
+			rdBtnDoNotShow.setText(PluginServices.getText(this,"No_mostrar_la_capa_cuando_la_escala"));
+			rdBtnDoNotShow.addActionListener(new ActionListener() {
+				public void actionPerformed(ActionEvent e) {
+					txtMaxScale.setEnabled(true);
+					txtMinScale.setEnabled(true);
+				}
+			});
+		}
+		return rdBtnDoNotShow;
+	}
+	/**
+	 * This method initializes jTextField2
+	 *
+	 * @return javax.swing.JTextField
+	 */
+	private JTextField getTxtMinScale() {
+		if (txtMinScale == null) {
+			txtMinScale = new JTextField(15);
+			txtMinScale.setEnabled(false);
+		}
+		return txtMinScale;
+	}
+
+	private String getLayerName(){
+		return txtLayerName.getText().toString();
+	}
+//    /**
+//     * This method initializes jPanel3, this panel contains the components of the
+//     * HyperLink
+//     *
+//     * @return javax.swing.JPanel
+//     */
+//    private JPanel getPnlHyperLink() {
+//    	if (pnlHyperLink == null) {
+//    		pnlHyperLink = new JPanel();
+//    		pnlHyperLink.setBorder(BorderFactory.createTitledBorder(
+//    				BorderFactory.createEtchedBorder(EtchedBorder.LOWERED),
+//    					PluginServices.getText(this, "Hiperenlace"),
+//    					TitledBorder.DEFAULT_JUSTIFICATION,
+//    					TitledBorder.DEFAULT_POSITION, null, null)
+//    				);
+//    		JPanel aux = new JPanel(new BorderLayout());
+//    		pnlHyperLink.setLayout(new BorderLayout());
+//    		aux.setBorder(BorderFactory.createBevelBorder(BevelBorder.LOWERED));
+//    		aux.add(getPnlFieldAndExtension(), BorderLayout.NORTH);
+//    		aux.add(getPnlHyperLinkAction(), BorderLayout.CENTER);
+//    		pnlHyperLink.add(aux);
+//    	}
+//    	return pnlHyperLink;
+//    }
+//
+//
+//    private JPanel getPnlFieldAndExtension() {
+//    	if (pnlFieldAndExtension == null) {
+//    		lblLinkExtension = new JLabel();
+//    		lblLinkExtension.setText(" \t \t"+PluginServices.getText(this,"extension"));
+//    		lblLinkField = new JLabel();
+//    		lblLinkField.setText(PluginServices.getText(this, "Campo"));
+//    		pnlFieldAndExtension = new JPanel();
+//    		pnlFieldAndExtension.add(lblLinkField, null);
+//    		pnlFieldAndExtension.add(getCmbLinkField(), null);
+//    		pnlFieldAndExtension.add(lblLinkExtension, null);
+//    		pnlFieldAndExtension.add(getTxtLinkExtension(), null);
+//    	}
+//    	return pnlFieldAndExtension;
+//    }
+//    /**
+//     * This method initializes jPanel8. This panel contains the ComboBox to select
+//     * the action, (type of HyperLink)
+//     *
+//     * @return javax.swing.JPanel
+//     */
+//    private JPanel getPnlHyperLinkAction() {
+//    	if (pnlHyperLinkAction == null) {
+//    		lblDefaultAction = new JLabel();
+//    		lblDefaultAction.setText(PluginServices.getText(this, "Accion_Predefinida") + "  ");
+//    		pnlHyperLinkAction = new JPanel();
+//    		pnlHyperLinkAction.add(lblDefaultAction, null);
+//    		pnlHyperLinkAction.add(getCmbLinkType(), null);
+//    	}
+//    	return pnlHyperLinkAction;
+//    }
+//    /**
+//     * This method initializes jComboBox
+//     *
+//     * @return javax.swing.JComboBox
+//     */
+//    private JComboBox getCmbLinkField() {
+//    	if (cmbLinkField == null) {
+//            cmbLinkField = new JComboBox();
+//    	}
+//    	return cmbLinkField;
+//    }
+//    /**
+//     * This method initializes jTextField
+//     *
+//     * @return javax.swing.JTextField
+//     */
+//    private JTextField getTxtLinkExtension() {
+//    	if (txtLinkExtension == null) {
+//    		txtLinkExtension = new JTextField();
+//            txtLinkExtension.setPreferredSize(new Dimension(40,20));
+//    	}
+//    	return txtLinkExtension;
+//    }
+//    /**
+//     * This method initializes jComboBox1
+//     *
+//     * @return javax.swing.JComboBox
+//     */
+//    private JComboBox getCmbLinkType() {
+//    	if (cmbLinkType == null) {
+//    		cmbLinkType = new JComboBox();
+//    	}
+//    	return cmbLinkType;
+//    }
+//
+//	/**
+//     * @return Returns the view.
+//     */
+//    private ViewDocument getView() {
+//        return view;
+//    }
+    /**
+     * This method initializes jCheckBox
+     *
+     * @return javax.swing.JCheckBox
+     */
+    private JCheckBox getJCheckBoxSpatialIndex() {
+    	if (jCheckBoxSpatialIndex == null) {
+    		jCheckBoxSpatialIndex = new JCheckBox();
+    		jCheckBoxSpatialIndex.setBounds(2, 33, 242, 23);
+    		jCheckBoxSpatialIndex.setText(PluginServices.getText(this,"Usar_indice_espacial"));
+    	}
+    	return jCheckBoxSpatialIndex;
+    }
+
+//    /**
+//     * Returns the selected Type in the ComboBox
+//     */
+//    private int getLinkType() {
+//        return getCmbLinkType().getSelectedIndex();
+//
+//    }
+//
+//    /**
+//     * Returns the Selected Field in the ComboBox
+//     */
+//    private String getSelectedLinkField() {
+//        return (String) getCmbLinkField().getSelectedItem();
+//    }
+//
+//    /**
+//     * Returns the Extension in the TextField
+//     */
+//    private String getExtensionLink() {
+//        return getTxtLinkExtension().getText();
+//    }
+//
+//    /**
+//     * Returns true or false if the CheckBox is marked or not
+//     */
+//    private boolean isSpatialIndexSelected() {
+//        return getJCheckBoxSpatialIndex().isSelected();
+//    }
+
+    /**
+     * Add the information of the layer to the textArea
+     */
+    private void showLayerInfo() {
+		try {
+			String info = ((FLyrDefault)layer).getInfoString();
+			if (info == null) {
+				StringBuffer buff= new StringBuffer();
+				Envelope fullExtentViewPort = layer.getFullEnvelope();
+				IProjection viewPortProj = layer.getMapContext().getProjection();
+				buff.append(PluginServices.getText(this,"Extent"));
+				buff.append(" ");
+				buff.append(viewPortProj.getAbrev());
+				buff.append(" (" + PluginServices.getText(this, "view_projection") + "):\n\t");
+				buff.append(PluginServices.getText(this,"Superior") + ":\t" + fullExtentViewPort.getMaximum(1) + "\n\t");
+				buff.append(PluginServices.getText(this,"Inferior") + ":\t" + fullExtentViewPort.getMinimum(1) + "\n\t");
+				buff.append(PluginServices.getText(this,"Izquierda") + ":\t" + fullExtentViewPort.getMinimum(0) + "\n\t");
+				buff.append(PluginServices.getText(this,"Derecha") + ":\t" + fullExtentViewPort.getMaximum(0) + "\n");
+				// show layer native projection
+				if (layer.getProjection() != null
+						&& !layer.getProjection().getAbrev().equals(
+								viewPortProj.getAbrev())) {
+					IProjection nativeLayerProj = layer.getProjection();
+					ICoordTrans ct = viewPortProj.getCT(nativeLayerProj);
+//					Rectangle2D r=new Rectangle2D.Double(fullExtentViewPort.getMinimum(0),fullExtentViewPort.getMinimum(1),fullExtentViewPort.getLength(0),fullExtentViewPort.getLength(1));
+//					Rectangle2D nativeLayerExtent = ct.convert(r);
+					Envelope nativeLayerExtent = fullExtentViewPort.convert(ct);
+					buff.append(PluginServices.getText(this,"Extent") + " ");
+					buff.append(nativeLayerProj.getAbrev());
+					buff.append(" (" + PluginServices.getText(this, "layer_native_projection") + "):\n\t");
+					buff.append(PluginServices.getText(this, "Superior")
+							+ ":\t" + nativeLayerExtent.getMaximum(1) + "\n\t");
+					buff.append(PluginServices.getText(this, "Inferior")
+							+ ":\t" + nativeLayerExtent.getMinimum(1) + "\n\t");
+					buff.append(PluginServices.getText(this, "Izquierda")
+							+ ":\t" + nativeLayerExtent.getMinimum(0) + "\n\t");
+					buff.append(PluginServices.getText(this, "Derecha") + ":\t"
+							+ nativeLayerExtent.getMaximum(0) + "\n");
+
+				}
+				if (layer instanceof FLyrVect) {
+					FeatureStore fStore=((FLyrVect)layer).getFeatureStore();
+//					if (rv instanceof VectorialEditableAdapter) {
+//						rv=((VectorialEditableAdapter) ((FLyrVect)layer).getSource()).getOriginalAdapter();
+//					}
+
+					buff.append(PluginServices.getText(this,"Origen_de_datos") + ": ");
+					buff.append(fStore.getName());
+					info=buff.toString();
+
+					DataStoreParameters parameters=fStore.getParameters();
+					if (parameters instanceof FilesystemStoreParameters) {
+						info = info  + "\n" +
+						PluginServices.getText(this, "fichero")
+								+ ": "
+								+ ((FilesystemStoreParameters) parameters)
+										.getFile();
+//					FIXME
+//					}else if (parameters instanceof DBParameters){
+//						info = info + "\n" + fStore.getName() + "\n";
+//
+//						try {
+//							info = info +
+//							PluginServices.getText(this,"url") +": " + ((DBParameters)parameters).getHost() + "\n";
+//						} catch (Exception e) {
+//							//TODO: Que hacer aqui?
+//							e.printStackTrace();
+//						}
+//
+//						info = info +
+//						PluginServices.getText(this, "Tabla")
+//								+ ": "
+//								+ ((DBStoreParameters) parameters)
+//										.getTableName() + "\n";
+					}else{
+						info = info + "\n" + fStore.getName() + "\n";
+					}
+//					if (rv instanceof VectorialFileAdapter) {
+//						info = info + "\n" + rv.getDriver().getName() + "\n" +
+//						PluginServices.getText(this,"fichero") +": " + ((VectorialFileAdapter)rv).getFile();
+//
+//					} else if (rv instanceof VectorialDBAdapter) {
+//						DBLayerDefinition dbdef = ((VectorialDBAdapter) rv).getLyrDef();
+//						info = info + "\n" + rv.getDriver().getName() + "\n";
+//
+//						try {
+//							info = info +
+//							PluginServices.getText(this,"url") +": " + dbdef.getConnection().getURL() + "\n";
+//						} catch (Exception e) {
+//							//TODO: Que hacer aqui?
+//							e.printStackTrace();
+//						}
+//
+//						info = info +
+//						PluginServices.getText(this,"Tabla") +": " + dbdef.getTableName() + "\n";
+//					} else if (rv instanceof VectorialAdapter){
+//						info = info + "\n" + rv.getDriver().getName() + "\n";
+//					}
+					String sGeomType= "Unknow";
+
+					try {
+						GeometryType geomType = ((FLyrVect)layer).getTypeVectorLayer();
+						sGeomType = geomType.getName();
+					} catch (LocatorException e) {
+						NotificationManager.addError(e);
+					} catch (GeometryTypeNotSupportedException e) {
+						NotificationManager.showMessageWarning("Not supported GeometryType", e);
+					} catch (GeometryTypeNotValidException e) {
+						NotificationManager.showMessageWarning("Not valid GeometryType", e);
+					}
+
+					info += "\n" + PluginServices.getText(this,"type")+ ": "+sGeomType + "\n";
+
+				} else {
+					info=buff.toString();
+					info = info + PluginServices.getText(this,"Origen_de_datos") + ": " + layer.getName();
+				}
+
+			}
+			getPropertiesTextArea().setText(info);
+
+		} catch (ReadException e) {
+			NotificationManager.addError(e.getMessage(), e);
+		} catch (DataException e) {
+			NotificationManager.addError(e.getMessage(), e);
+		}
+
+    }
+
+    /**
+     * Returns true or false if the scale is activa
+     */
+	private boolean isScaleActive() {
+		return getRdBtnDoNotShowWhen().isSelected();
+	}
+
+//    /**
+//     * Instanciates a ITask (@see com.iver.utiles.swing.threads.ITask)
+//     * to create a spatial index for the selected layer in background.
+//     * This task also allow to monitor process evolution, and to cancel
+//     * this process.
+//     */
+//    private IMonitorableTask getCreateSpatialIndexTask() throws DataException {
+//    	// FIXME REVISAR ESTO (Quizas lanzar TaskException)
+//    	return new CreateSpatialIndexMonitorableTask((FLyrVect)layer);
+//    }
+
+	public void acceptAction() {
+//	     // Implementaci�n para hacer funcionar el hyperlink ...
+//        //com.iver.cit.gvsig.gui.View theView = (com.iver.cit.gvsig.gui.View)PluginServices.getMDIManager().getActiveView();
+//        //ProjectView view = theView.getModel();
+//    	if (PluginServices.getMainFrame() != null)
+//    	{
+//    		ViewDocument view = getView();
+//    		view.setTypeLink(getLinkType());
+//    		if (getSelectedLinkField()!=null)
+//    		{
+//    			view.setSelectedField(getSelectedLinkField().toString().trim());
+//    			view.setExtLink(getExtensionLink());
+//
+//    		}
+//    	}
+
+
+	}
+
+	public void cancelAction() {
+		// does nothing
+	}
+
+	/**
+	 * When we press the apply button, sets the new properties of the layer thar the
+	 * user modified using the UI components
+	 */
+	public void applyAction() {
+		if (isScaleActive()) {
+			try	{
+				layer.setMinScale((nf.parse(getTxtMaxScale().getText())).doubleValue());
+			} catch (ParseException ex)	{
+			    if (getTxtMaxScale().getText().compareTo("") == 0) {
+					layer.setMinScale(-1);
+				} else {
+					System.err.print(ex.getLocalizedMessage());
+				}
+			}
+
+			try	{
+			    layer.setMaxScale((nf.parse(getTxtMinScale().getText())).doubleValue());
+			} catch (ParseException ex)	{
+			    if (getTxtMinScale().getText().compareTo("") == 0) {
+					layer.setMaxScale(-1);
+				} else {
+					System.err.print(ex.getLocalizedMessage());
+				}
+			}
+
+		} else {
+	        layer.setMinScale(-1);
+	        layer.setMaxScale(-1);
+		}
+
+		if (!getLayerName().equals(layer.getName())){
+			layer.setName(getLayerName());
+		}
+
+//        if (layer instanceof FLyrVect){
+//            FLyrVect lyrVect = (FLyrVect) layer;
+//            if (isSpatialIndexSelected()) {
+//        		// TODO
+//
+//            	if(lyrVect.getISpatialIndex() == null) {
+//                	//AZABALA
+//                	try {
+//						PluginServices.
+//							cancelableBackgroundExecution(getCreateSpatialIndexTask());
+//					} catch (ReadDriverException e) {
+//						// TODO Auto-generated catch block
+//						NotificationManager.addError(e.getMessage(), e);
+//					}
+//                }
+//            }
+//            //AZABALA
+//            /*
+//             * If we unselect the spatial index checkbox...Must we delete
+//             * spatial index file, or we only have to put Spatial Index
+//             * reference to null?. I have followed the second choice
+//             */
+//            else{
+////                lyrVect.deleteSpatialIndex();
+//            }
+//
+//
+//        }
+//        //Codigo relacionado
+//        if (layer instanceof FLyrVect ){
+//			FLyrVect vectlyr=(FLyrVect) layer;
+//			if (getSelectedLinkField()!=null){
+//				vectlyr.getLinkProperties().setExt(getExtensionLink());
+//				vectlyr.getLinkProperties().setField(getSelectedLinkField().toString().trim());
+//				vectlyr.getLinkProperties().setType(getLinkType());
+//
+//				System.out.println("Link Properties");
+//				System.out.println("Extensi�n: " + vectlyr.getLinkProperties().getExt());
+//				System.out.println("Campo: " + vectlyr.getLinkProperties().getField());
+//				System.out.println("Tipo: " + vectlyr.getLinkProperties().getType());
+//			}
+//        }
+	}
+
+	/*
+	 *  (non-Javadoc)
+	 * @see java.awt.Component#getName()
+	 */
+	public String getName() {
+		return PluginServices.getText(this,"General");
+	}
+}  //  @jve:decl-index=0:visual-constraint="10,10"
+

Property changes on: tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/app/project/documents/view/legend/gui/General.java
___________________________________________________________________
Added: svn:eol-style
   + native
Added: svn:keywords
   + Author Date Id Revision

Index: tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/app/project/documents/view/legend/gui/SymbolTable.java
===================================================================
--- tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/app/project/documents/view/legend/gui/SymbolTable.java	(revision 0)
+++ tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/app/project/documents/view/legend/gui/SymbolTable.java	(revision 38653)
@@ -0,0 +1,417 @@
+/*
+ * Created on 27-abr-2004
+ *
+ * To change the template for this generated file go to
+ * Window&gt;Preferences&gt;Java&gt;Code Generation&gt;Code and Comments
+ */
+/* gvSIG. Sistema de Informaci�n Geogr�fica de la Generalitat Valenciana
+ *
+ * Copyright (C) 2004 IVER T.I. and Generalitat Valenciana.
+ *
+ * This program is free software; you can redistribute it and/or
+ * modify it under the terms of the GNU General Public License
+ * as published by the Free Software Foundation; either version 2
+ * of the License, or (at your option) any later version.
+ *
+ * This program is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
+ * GNU General Public License for more details.
+ *
+ * You should have received a copy of the GNU General Public License
+ * along with this program; if not, write to the Free Software
+ * Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA  02111-1307,USA.
+ *
+ * For more information, contact:
+ *
+ *  Generalitat Valenciana
+ *   Conselleria d'Infraestructures i Transport
+ *   Av. Blasco Ib��ez, 50
+ *   46010 VALENCIA
+ *   SPAIN
+ *
+ *      +34 963862235
+ *   gvsig@gva.es
+ *      www.gvsig.gva.es
+ *
+ *    or
+ *
+ *   IVER T.I. S.A
+ *   Salamanca 50
+ *   46005 Valencia
+ *   Spain
+ *
+ *   +34 963163400
+ *   dac@iver.es
+ */
+package org.gvsig.app.project.documents.view.legend.gui;
+
+import java.awt.Component;
+import java.awt.Dimension;
+import java.awt.GridLayout;
+import java.util.Hashtable;
+
+import javax.swing.JPanel;
+import javax.swing.JScrollPane;
+import javax.swing.table.DefaultTableModel;
+import javax.swing.table.TableCellEditor;
+import javax.swing.table.TableColumn;
+
+import org.gvsig.andami.PluginServices;
+import org.gvsig.app.project.documents.gui.SymbolCellEditor;
+import org.gvsig.app.project.documents.gui.TableSymbolCellRenderer;
+import org.gvsig.app.project.documents.view.legend.edition.gui.IntervalCellEditor;
+import org.gvsig.app.project.documents.view.legend.edition.gui.ValueCellEditor;
+import org.gvsig.fmap.mapcontext.rendering.symbols.ISymbol;
+import org.gvsig.utils.swing.jtable.JTable;
+import org.gvsig.utils.swing.jtable.TextFieldCellEditor;
+
+
+/**
+ * JPanel que contiene la tabla con los s�mbolos intervalos o valores y
+ * etiquetado de estos valores.
+ *
+ * @author Vicente Caballero Navarro
+ */
+public class SymbolTable extends JPanel {
+	private static final long serialVersionUID = -8694846716328735113L;
+	private static Hashtable<String,TableCellEditor> cellEditors = new Hashtable<String,TableCellEditor>();
+
+	public static final String VALUES_TYPE = "values";
+	public static final String INTERVALS_TYPE = "intervals";
+	private JTable table;
+	private String type;
+	private int shapeType;
+
+	/**
+	 * Crea un nuevo FSymbolTable.
+	 *
+	 * @param type
+	 *            tipo de valor si es intervalo: "intervals" y si es por
+	 *            valores: "values".
+	 */
+	public SymbolTable(Component ownerComponent, String type, int shapeType) {
+		super(new GridLayout(1, 0));
+		this.type = type;
+		this.shapeType = shapeType;
+
+		table = new JTable();
+		table.setModel(new MyTableModel());
+		table.setPreferredScrollableViewportSize(new Dimension(480, 110));
+
+		initializeCellEditors();
+
+		// Create the scroll pane and add the table to it.
+		JScrollPane scrollPane = new JScrollPane(table);
+
+		// Set up column sizes.
+		// initColumnSizes(table);
+		setUpSymbolColumn(table, table.getColumnModel().getColumn(0));
+
+		if(cellEditors.get(type) == null)
+			throw new Error("Symbol table type not set!");
+
+		setUpValueColumn(table, table.getColumnModel().getColumn(1),cellEditors.get(this.type));
+		setUpLabelColumn(table, table.getColumnModel().getColumn(2));
+
+		// Add the scroll pane to this panel.
+		add(scrollPane);
+		table.setRowSelectionAllowed(true);
+	}
+	/**
+	 * Inicializa los valores de los CellEditors que la SymbolTable poseer� por defecto
+	 */
+	private void initializeCellEditors() {
+		this.cellEditors.put(this.INTERVALS_TYPE,new IntervalCellEditor());
+		this.cellEditors.put(this.VALUES_TYPE, new ValueCellEditor());
+	}
+	/**
+	 * A�ade un nuevo CellEditor a la lista de disponibles
+	 *
+	 * @param key String con el nombre identificativo del CellEditor
+	 * @param cellEditor CellEditor que va a ser a�adido
+	 */
+	public static void addNewCellEditor(String key,TableCellEditor cellEditor ) {
+		cellEditors.put(key, cellEditor);
+	}
+	/**
+	 * Obtiene el valor de los elementos de una fila seleccionada
+	 *
+	 * @return Object[] Array con los objetos de cada una de las columnas de la fila seleccionada
+	 */
+	public Object[] getSelectedRowElements() {
+		Object[] values = new Object[3];
+
+		MyTableModel m = (MyTableModel) table.getModel();
+		int[] selectedRows = table.getSelectedRows();
+
+		if(selectedRows.length != 1)
+			return null;
+
+		for (int i = 0; i < 3; i++) {
+			values[i] = m.getValueAt(selectedRows[0], i);
+		}
+
+		return values;
+	}
+	/**
+	 * A�ade una fila al modelo.
+	 *
+	 * @param vector
+	 *            Fila en forma de vector de Object para a�adir al modelo.
+	 */
+	public void addRow(Object[] vector) {
+		MyTableModel m = (MyTableModel) table.getModel();
+		m.addRow(vector);
+
+	}
+
+	/**
+	 * Elimina la fila que tiene como clave el objeto que se pasa como
+	 * par�metro.
+	 *
+	 * @param obj
+	 *            clave del objeto a eliminar.
+	 */
+	public void removeRow(Object obj) {
+		MyTableModel m = (MyTableModel) table.getModel();
+
+		for (int i = 0; i < m.getRowCount(); i++) {
+//			if (m.getValueAt(i, 1) instanceof NullUniqueValue
+//					|| m.getValueAt(i, 1) instanceof NullIntervalValue) {
+//				m.removeRow(i);
+//			}
+			if (m.getValueAt(i, 1) == null) {
+				m.removeRow(i);
+			}
+		}
+	}
+
+	/**
+	 * Elimina las filas que est�n seleccionadas.
+	 */
+	public void removeSelectedRows() {
+		if (table.getCellEditor() != null) {
+			table.getCellEditor().cancelCellEditing();
+		}
+
+		MyTableModel m = (MyTableModel) table.getModel();
+		int[] selectedRows = table.getSelectedRows();
+
+		for (int i = selectedRows.length - 1; i >= 0; i--) {
+			m.removeRow(selectedRows[i]);
+		}
+	}
+
+	/**
+	 * Rellena la tabla con los s�mbolos valores y descripciones que se pasan
+	 * como par�metro.
+	 *
+	 * @param symbols
+	 *            Array de s�mbolos
+	 * @param values
+	 *            Array de valores.
+	 * @param descriptions
+	 *            Array de descripciones.
+	 */
+	public void fillTableFromSymbolList(ISymbol[] symbols, Object[] values,
+			String[] descriptions) {
+		ISymbol theSymbol;
+
+		for (int i = 0; i < symbols.length; i++) {
+			theSymbol = symbols[i];
+//			if(!(values[i] instanceof NullIntervalValue) && !(values[i] instanceof NullUniqueValue))
+//				addTableRecord(theSymbol, values[i], descriptions[i]);
+			if(!(values[i] == null))
+				addTableRecord(theSymbol, values[i], descriptions[i]);
+		}
+	}
+
+	/**
+	 * A�ade una fila con los objetos que se pasan como par�metros.
+	 *
+	 * @param symbol
+	 *            s�mbolo de la fila.
+	 * @param value
+	 *            Valor de la fila.
+	 * @param description
+	 *            Descripci�n.
+	 */
+	public void addTableRecord(ISymbol symbol, Object value, String description) {
+		Object[] theRow = new Object[3];
+		theRow[0] = symbol;
+		theRow[1] = value;
+		theRow[2] = description;
+		addRow(theRow);
+	}
+
+	/**
+	 * Devuelve el valor a partie del n�mero de fila y columna.
+	 *
+	 * @param row
+	 *            n�mero de fila.
+	 * @param col
+	 *            n�mero de columna.
+	 *
+	 * @return Objeto.
+	 */
+	public Object getFieldValue(int row, int col) {
+		MyTableModel m = (MyTableModel) table.getModel();
+
+		return m.getValueAt(row, col);
+	}
+
+	/**
+	 * Devuelve el n�mero total de filas que contiene el modelo.
+	 *
+	 * @return N�mero de filas.
+	 */
+	public int getRowCount() {
+		MyTableModel m = (MyTableModel) table.getModel();
+
+		return m.getRowCount();
+	}
+
+	/**
+	 * Elimina todas las filas del modelo.
+	 */
+	public void removeAllItems() {
+		table.setModel(new MyTableModel());
+		setUpSymbolColumn(table, table.getColumnModel().getColumn(0));
+		setUpValueColumn(table, table.getColumnModel().getColumn(1),cellEditors.get(this.type));
+		setUpLabelColumn(table, table.getColumnModel().getColumn(2));
+	}
+
+	/**
+	 * Inicializa el cell editor de tipo descripci�n de la columna que se pasa
+	 * como par�metro.
+	 *
+	 * @param table2
+	 *            Tabla.
+	 * @param column
+	 *            Columna.
+	 */
+	public void setUpLabelColumn(JTable table2, TableColumn column) {
+		TextFieldCellEditor labeleditor = new TextFieldCellEditor();
+		column.setCellEditor(labeleditor);
+	}
+
+	/**
+	 * Inicializa el cell editor de tipo valor de la columna que se pasa como
+	 * par�metro.
+	 *
+	 * @param table2
+	 *            Tabla.
+	 * @param column
+	 *            Columna.
+	 * @param tableCellEditor
+	 */
+	public void setUpValueColumn(JTable table2,TableColumn column, TableCellEditor tableCellEditor) {
+		column.setCellEditor(tableCellEditor);
+	}
+	/**
+	 * Inicializa el cell editor de tipo s�mbolo de la columna que se pasa como
+	 * par�metro.
+	 *
+	 * @param table2
+	 *            Tabla.
+	 * @param column
+	 *            Columna.
+	 */
+	public void setUpSymbolColumn(JTable table2, TableColumn column) {
+		// Set up the editor
+		column.setMaxWidth(100);
+		column.setWidth(60);
+		column.setPreferredWidth(60);
+		column.setMinWidth(50);
+
+		// FSymbolCellEditor symboleditor = new FSymbolCellEditor();
+		SymbolCellEditor symboleditor = new SymbolCellEditor(shapeType);
+		column.setCellEditor(symboleditor);
+
+		TableSymbolCellRenderer renderer = new TableSymbolCellRenderer(true);
+		column.setCellRenderer(renderer);
+	}
+
+	/**
+	 * Modelo que propio que se aplica a la tabla.
+	 *
+	 * @author Vicente Caballero Navarro
+	 */
+	class MyTableModel extends DefaultTableModel {
+		private static final long serialVersionUID = 1L;
+
+		// AbstractTableModel {
+		private String[] columnNames = {
+				PluginServices.getText(this, "Simbolo"),
+				PluginServices.getText(this, "Valor"),
+				PluginServices.getText(this, "Etiqueta") };
+
+		/**
+		 * Devuelve el n�mero de columnas.
+		 *
+		 * @return N�mero de columnas.
+		 */
+		public int getColumnCount() {
+			return columnNames.length;
+		}
+
+		/**
+		 * Devuelve el String del valor de la columna.
+		 *
+		 * @param col
+		 *            N�mero de columna.
+		 *
+		 * @return Nombre de la columna.
+		 */
+		public String getColumnName(int col) {
+			return columnNames[col];
+		}
+
+		public Class getColumnClass(int c) {
+            switch (c) {
+            case 0:
+                return ISymbol.class;
+            case 1:
+                // TODO: take the value from the related FeatureType attribute
+                Object value = getValueAt(0, c);
+                return value == null ? Object.class : value.getClass();
+            case 2:
+                return String.class;
+            default:
+                return Object.class;
+            }
+		}
+
+		/*
+		 * Don't need to implement this method unless your table's editable.
+		 */
+		public boolean isCellEditable(int row, int col) {
+			// Note that the data/cell address is constant,
+			// no matter where the cell appears onscreen.
+			// if (col > 0) {
+			return true;
+		}
+
+		@Override
+		public Object getValueAt(int row, int column) {
+			if(column == 2)
+				return ((ISymbol)getValueAt(row,0)).getDescription();
+
+			return super.getValueAt(row, column);
+		}
+
+		@Override
+		public void setValueAt(Object aValue, int row, int column) {
+
+			if(column == 2){
+				ISymbol symbol = (ISymbol) getValueAt(row,0);
+				symbol.setDescription((String) aValue);
+				setValueAt(symbol,row,0);
+			}
+
+			super.setValueAt(aValue, row, column);
+		}
+
+	}
+}

Property changes on: tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/app/project/documents/view/legend/gui/SymbolTable.java
___________________________________________________________________
Added: svn:keywords
   + Author Date Id Revision
Added: svn:eol-style
   + native

Index: tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/app/project/documents/view/legend/gui/AbstractThemeManagerPage.java
===================================================================
--- tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/app/project/documents/view/legend/gui/AbstractThemeManagerPage.java	(revision 0)
+++ tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/app/project/documents/view/legend/gui/AbstractThemeManagerPage.java	(revision 38653)
@@ -0,0 +1,112 @@
+package org.gvsig.app.project.documents.view.legend.gui;
+
+import javax.swing.JOptionPane;
+import javax.swing.JPanel;
+
+import org.gvsig.andami.PluginServices;
+import org.gvsig.andami.messages.Messages;
+import org.gvsig.fmap.mapcontext.layers.FLayer;
+import org.gvsig.fmap.mapcontext.layers.FLayers;
+import org.gvsig.fmap.mapcontext.layers.operations.Classifiable;
+import org.gvsig.fmap.mapcontext.rendering.legend.ILegend;
+import org.gvsig.fmap.mapcontext.rendering.legend.IVectorLegend;
+
+
+public abstract class AbstractThemeManagerPage extends JPanel {
+	/**
+	 * Cuando hay varios capas vectoriales seleccionados, devolver� el �ltimo.
+	 *
+	 * @param layers Grupo de layers.
+	 *
+	 * @return la primera flayer seleccionada.
+	 */
+	protected FLayer getFirstActiveLayerVect(FLayers layers) {
+		// Comprobar en openLegendManager que hay alg�n capa activo!
+		FLayer[] activeLyrs = layers.getActives();
+
+		if (activeLyrs.length == 0) {
+			JOptionPane.showMessageDialog(null,
+				Messages.getString("necesita_una_capa_activa"), "",
+				JOptionPane.ERROR_MESSAGE);
+
+			return null;
+		}
+
+		FLayer lyr = null;
+
+		for (int i = 0; i < activeLyrs.length; i++) {
+			if (activeLyrs[i] instanceof FLayers) {
+				lyr = getFirstActiveLayerVect((FLayers) activeLyrs[i]);
+			}
+
+			if (activeLyrs[i] instanceof Classifiable) {
+				Classifiable auxC = (Classifiable) activeLyrs[i];
+				ILegend theLegend = auxC.getLegend();
+
+				if (theLegend instanceof IVectorLegend) {
+					lyr = (FLayer) auxC;
+				}
+			}
+		}
+
+		if (lyr == null) {
+			JOptionPane.showMessageDialog(null,
+				Messages.getString(
+						PluginServices.getText(this, "necesita_una_capa_vectorial_activa") +
+						"\n\n"+
+						PluginServices.getText(this, "Por_favor_active_la_capa") + "."),
+				"",
+				JOptionPane.ERROR_MESSAGE);
+			return null;
+		}
+
+		return lyr;
+	}
+
+	/**
+	 * Returns the name of this ThemeManagerPage's tab, the text returned by this
+	 * method will be shown in the text of this panel's tab.
+	 */
+	public abstract String getName();
+
+	/**
+	 * <p>
+	 * Method invoked when the Ok button is pressed from the ThemeManagerWindow.
+	 * It will cause the changes performed by the user to take effect into the
+	 * layer if the Apply button wasn't pressed yet. In case Apply button was
+	 * pressed, then the programmer can choose between apply the changes again or
+	 * not.<br>
+	 * </p>
+	 * <p>
+	 * It shouldn't be a problem rather than the potential consumption of time
+	 * required in when applying such changes.<br>
+	 * </p>
+	 * <p>
+	 * <b>Notice</b> that after the call of this method the ThemeManagerWindow will be closed.
+	 * </p>
+	 */
+	public abstract void acceptAction();
+
+	/**
+	 * <p>
+	 * Method invoked when the Cancel button is pressed from the ThemeManagerWindow.
+	 * It will cause that the changes performed will be discarded.
+	 * </p>
+	 */
+	public abstract void cancelAction();
+
+	/**
+	 * Method invoked when the Apply button is pressed from the ThemeManagerWindow.
+	 * It will cause the changes performed by the user to take effect inmediately
+	 * into the the layer.
+	 */
+	public abstract void applyAction();
+
+	/**
+	 * This method is invoked during the initialization of the ThemeManagerWindow
+	 * and causes the dialog to be updated to reflect the current settings of
+	 * the layer in the context that this panel was designed for.
+	 * @param layer, the target FLayer
+	 */
+	public abstract void setModel(FLayer layer);
+}

Property changes on: tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/app/project/documents/view/legend/gui/AbstractThemeManagerPage.java
___________________________________________________________________
Added: svn:keywords
   + Author Date Id Revision
Added: svn:eol-style
   + native

Index: tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/app/project/documents/view/legend/gui/Features.java
===================================================================
--- tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/app/project/documents/view/legend/gui/Features.java	(revision 0)
+++ tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/app/project/documents/view/legend/gui/Features.java	(revision 38653)
@@ -0,0 +1,78 @@
+/* gvSIG. Sistema de Informaci�n Geogr�fica de la Generalitat Valenciana
+ *
+ * Copyright (C) 2005 IVER T.I. and Generalitat Valenciana.
+ *
+ * This program is free software; you can redistribute it and/or
+ * modify it under the terms of the GNU General Public License
+ * as published by the Free Software Foundation; either version 2
+ * of the License, or (at your option) any later version.
+ *
+ * This program is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
+ * GNU General Public License for more details.
+ *
+ * You should have received a copy of the GNU General Public License
+ * along with this program; if not, write to the Free Software
+ * Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA  02111-1307,USA.
+ *
+ * For more information, contact:
+ *
+ *  Generalitat Valenciana
+ *   Conselleria d'Infraestructures i Transport
+ *   Av. Blasco Ib��ez, 50
+ *   46010 VALENCIA
+ *   SPAIN
+ *
+ *      +34 963862235
+ *   gvsig@gva.es
+ *      www.gvsig.gva.es
+ *
+ *    or
+ *
+ *   IVER T.I. S.A
+ *   Salamanca 50
+ *   46005 Valencia
+ *   Spain
+ *
+ *   +34 963163400
+ *   dac@iver.es
+ */
+
+/* CVS MESSAGES:
+*
+* $Id$
+* $Log$
+* Revision 1.3  2007-05-17 09:32:37  jaume
+* *** empty log message ***
+*
+* Revision 1.2  2007/03/09 11:25:00  jaume
+* Advanced symbology (start committing)
+*
+* Revision 1.1.2.1  2007/01/26 13:49:03  jaume
+* *** empty log message ***
+*
+*
+*/
+package org.gvsig.app.project.documents.view.legend.gui;
+
+import org.gvsig.andami.PluginServices;
+import org.gvsig.fmap.mapcontext.layers.FLayer;
+import org.gvsig.fmap.mapcontext.layers.vectorial.FLyrVect;
+
+
+public class Features extends AbstractParentPanel {
+
+	public String getDescription() {
+		// TODO Implement it
+		throw new Error("Not yet implemented!");
+
+	}
+	public String getTitle() {
+		return PluginServices.getText(Features.class, "features");
+	}
+
+	public boolean isSuitableFor(FLayer layer) {
+		return layer instanceof FLyrVect;
+	}
+}

Property changes on: tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/app/project/documents/view/legend/gui/Features.java
___________________________________________________________________
Added: svn:keywords
   + Author Date Id Revision
Added: svn:eol-style
   + native

Index: tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/app/project/documents/view/legend/gui/ThemeManagerWindow.java
===================================================================
--- tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/app/project/documents/view/legend/gui/ThemeManagerWindow.java	(revision 0)
+++ tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/app/project/documents/view/legend/gui/ThemeManagerWindow.java	(revision 38653)
@@ -0,0 +1,273 @@
+/*
+ *
+ * gvSIG. Sistema de Informaci�n Geogr�fica de la Generalitat Valenciana
+ *
+ * Copyright (C) 2004 IVER T.I. and Generalitat Valenciana.
+ *
+ * This program is free software; you can redistribute it and/or
+ * modify it under the terms of the GNU General Public License
+ * as published by the Free Software Foundation; either version 2
+ * of the License, or (at your option) any later version.
+ *
+ * This program is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
+ * GNU General Public License for more details.
+ *
+ * You should have received a copy of the GNU General Public License
+ * along with this program; if not, write to the Free Software
+ * Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA  02111-1307,USA.
+ *
+ * For more information, contact:
+ *
+ *  Generalitat Valenciana
+ *   Conselleria d'Infraestructures i Transport
+ *   Av. Blasco Ib��ez, 50
+ *   46010 VALENCIA
+ *   SPAIN
+ *
+ *      +34 963862235
+ *   gvsig@gva.es
+ *      www.gvsig.gva.es
+ *
+ *    or
+ *
+ *   IVER T.I. S.A
+ *   Salamanca 50
+ *   46005 Valencia
+ *   Spain
+ *
+ *   +34 963163400
+ *   dac@iver.es
+ */
+package org.gvsig.app.project.documents.view.legend.gui;
+
+import java.awt.BorderLayout;
+import java.awt.Dimension;
+import java.awt.FlowLayout;
+import java.awt.event.ActionEvent;
+import java.awt.event.ActionListener;
+import java.util.ArrayList;
+import java.util.Hashtable;
+
+import javax.swing.JOptionPane;
+import javax.swing.JPanel;
+import javax.swing.JTabbedPane;
+import javax.swing.event.ChangeListener;
+
+import org.gvsig.andami.PluginServices;
+import org.gvsig.andami.messages.NotificationManager;
+import org.gvsig.andami.ui.mdiFrame.MDIFrame;
+import org.gvsig.andami.ui.mdiManager.IWindow;
+import org.gvsig.andami.ui.mdiManager.MDIManagerFactory;
+import org.gvsig.andami.ui.mdiManager.WindowInfo;
+import org.gvsig.app.ApplicationLocator;
+import org.gvsig.app.ApplicationManager;
+import org.gvsig.fmap.mapcontext.layers.FLayer;
+import org.gvsig.fmap.mapcontext.layers.FLyrDefault;
+import org.gvsig.gui.beans.swing.JButton;
+import org.slf4j.Logger;
+import org.slf4j.LoggerFactory;
+
+
+/**
+ *
+ * @author jaume dominguez faus - jaume.dominguez@iver.es
+ * @version 01-feb-2007
+ */
+public final class ThemeManagerWindow extends JPanel implements IWindow, ActionListener {
+	private static final Logger logger = LoggerFactory.getLogger(ThemeManagerWindow.class);
+			
+	private static final long serialVersionUID = 4650656815369149211L;
+	private static int selectedTabIndex = 0;
+	private static ArrayList<Class<? extends AbstractThemeManagerPage>> pages =
+			new ArrayList<Class<? extends AbstractThemeManagerPage>>();
+	private FLayer layer;
+	//private Legend legend; // Le asignaremos la leyenda del primer tema activo.
+	private JTabbedPane tabs = new JTabbedPane();  //  @jve:decl-index=0:
+	private JPanel panelButtons;
+	private static Hashtable<Class<? extends AbstractThemeManagerPage>, ArrayList<Class<? extends FLyrDefault>>> s =
+		new Hashtable<Class<? extends AbstractThemeManagerPage>, ArrayList<Class<? extends FLyrDefault>>>();
+
+
+	/**
+	 * Sobrecarga del constructor. Este se utiliza cuando se llama a este
+	 * di�logo desde la barra de comandos.
+	 *
+	 */
+	public ThemeManagerWindow(FLayer l) {
+		this.layer = l;
+
+		// TODO falta definir leyenda para cualquier tipo de capa
+		// y decidir entonces qu� opciones soporta cada una para
+		// que el di�logo se autorrellene
+		initialize();
+	}
+
+	private  void initialize() {
+		StringBuffer msgerr = new StringBuffer(); 
+		for (int i = 0; i < pages.size(); i++) {
+			Class<? extends AbstractThemeManagerPage> pageClass = pages.get(i);
+			AbstractThemeManagerPage tab = null;
+			try {
+				tab = pageClass.newInstance();
+			} catch (Exception e) {
+				msgerr.append(translate("_Cant_add_property_page_related_to_{0}", pageClass.getName()))
+					.append("\n");
+				logger.info("Can't instance propety page from class "+pageClass.getName(),e);
+				continue;
+			}
+			if (tab!=null){
+			    if (s.get(tab.getClass()).contains(layer.getClass())){
+			    	String tabName = null;
+			    	try {
+			    		tab.setModel(layer);
+			    		tabName = tab.getName();
+			    	} catch( Throwable ex) {
+						msgerr.append(translate("_Cant_initialice_property_page_{0}", tabName))
+							.append("\n");
+			    		logger.info("Can't set model of property page '"+tabName+"' from class '"+pageClass.getName()+"'.");
+			    	}
+			        tabs.addTab(tabName, tab);
+			    }
+			}
+		}
+
+		if (tabs.getComponentCount()>selectedTabIndex) {
+			tabs.setSelectedIndex(selectedTabIndex);
+		}
+		tabs.setPreferredSize(new java.awt.Dimension(640,390));
+
+
+		setLayout(new BorderLayout());
+		add(tabs, java.awt.BorderLayout.CENTER);
+
+		// The listener must be added after the tabs are added to the window
+		tabs.addChangeListener(new ChangeListener() {
+			public void stateChanged(javax.swing.event.ChangeEvent e) {
+				//remember the visible tab
+				selectedTabIndex = tabs.getSelectedIndex();
+				if (selectedTabIndex<0) {
+					selectedTabIndex = 0;
+				}
+			};
+		});
+		add(getPanelButtons(), java.awt.BorderLayout.SOUTH);
+		setSize(new Dimension(780, 540));
+		if( msgerr.length()>0 ) {
+			PluginServices.getMainFrame().messageDialog(msgerr.toString(), "_Warning", JOptionPane.WARNING_MESSAGE);
+		}
+	}
+
+	private String translate(String msg, String arg1) {
+		String[] args = null;
+		String translation = null;
+        if (msg == null) {
+            return "";
+        }
+        if( arg1 != null ) {
+        	args = new String[] { arg1 };
+        }
+        translation = org.gvsig.i18n.Messages.getText(msg, args);
+        if (translation == null) {
+        	return "_"+msg.replace("_", " ");
+        }
+        return translation;
+	}
+	
+	private JPanel getPanelButtons() {
+		if (panelButtons == null) {
+			panelButtons = new JPanel(new FlowLayout(FlowLayout.RIGHT, 5,5));
+
+			JButton btnAceptar = new JButton(PluginServices.getText(this,"Aceptar"));
+			btnAceptar.setActionCommand("OK");
+			btnAceptar.addActionListener(this);
+
+			JButton btnApply = new JButton(PluginServices.getText(this,"Apply"));
+			btnApply.setActionCommand("APPLY");
+			btnApply.addActionListener(this);
+
+
+			JButton btnCancelar = new JButton(PluginServices.getText(this,"Cerrar"));
+			btnCancelar.setActionCommand("CANCEL");
+			btnCancelar.addActionListener(this);
+			panelButtons.setPreferredSize(new java.awt.Dimension(493,33));
+			panelButtons.add(btnCancelar);
+			panelButtons.add(btnApply);
+			panelButtons.add(btnAceptar);
+		}
+		return panelButtons;
+	}
+
+	public void actionPerformed(ActionEvent e) {
+		if (e.getActionCommand() == "OK") {
+			/* Causes all the tabs in the ThemeManagerWindow to perform THEIR apply-action
+			 * then fires the LegendChanged event that causes the view to be refreshed.
+			 * After that, it closes the window.
+			 */
+			actionPerformed(new ActionEvent(e.getSource(), e.getID(), "APPLY"));
+
+			close();
+		} else if (e.getActionCommand() == "CANCEL") {
+			/* Causes all the tabs in the ThemeManagerWindow to perform THEIR cancel-action
+			 * then closes the window.
+			 */
+			for (int i = 0; i < tabs.getTabCount(); i++) {
+				AbstractThemeManagerPage tab = (AbstractThemeManagerPage) tabs.getComponentAt(i);
+				tab.cancelAction();
+			}
+			close();
+		} else if (e.getActionCommand() == "APPLY") {
+			/* Causes the current visible tab in the ThemeManagerWindow to perform
+			 * ITS specific apply-action.
+			 */
+			for (int i = 0; i < tabs.getTabCount(); i++) {
+				AbstractThemeManagerPage tab = (AbstractThemeManagerPage) tabs.getComponentAt(i);
+				tab.applyAction();
+			}
+			layer.getMapContext().callLegendChanged();
+		} else {}
+//		 Lots of temporary objects were create.
+		// let's try some memory cleanup
+		System.gc();
+	}
+
+	private void close() {
+		PluginServices.getMDIManager().closeWindow(ThemeManagerWindow.this);
+	}
+
+	public WindowInfo getWindowInfo() {
+		WindowInfo viewInfo = new WindowInfo(WindowInfo.MODELESSDIALOG|WindowInfo.RESIZABLE);
+		viewInfo.setWidth(getWidth());
+		viewInfo.setHeight(getHeight());
+		viewInfo.setTitle(PluginServices.getText(this,"propiedades_de_la_capa"));
+		return viewInfo;
+	}
+
+	public static void addPage(Class<? extends AbstractThemeManagerPage> abstractThemeManagerPageClass) {
+		pages.add(abstractThemeManagerPageClass);
+	}
+
+	public static void setTabEnabledForLayer(Class<? extends AbstractThemeManagerPage> abstractThemeManagerPageClass, Class<? extends FLyrDefault> fLayerClazz, boolean enabled) {
+		ArrayList<Class<? extends FLyrDefault>> enabledLayers;
+		if (enabled == true) {
+			if (!s.containsKey(abstractThemeManagerPageClass)) {
+				enabledLayers = new ArrayList<Class<? extends FLyrDefault>> ();
+				enabledLayers.add(fLayerClazz);
+				s.put(abstractThemeManagerPageClass, enabledLayers);
+			} else {
+				enabledLayers = s.get(abstractThemeManagerPageClass);
+				enabledLayers.add(fLayerClazz);
+			}
+		} else {
+			if (!s.containsKey(abstractThemeManagerPageClass)) {
+				return;
+			}
+				enabledLayers = s.get(abstractThemeManagerPageClass);
+			enabledLayers.remove(fLayerClazz);
+		}
+	};
+	public Object getWindowProfile() {
+		return WindowInfo.TOOL_PROFILE;
+	};
+}  //  @jve:decl-index=0:visual-constraint="10,10"

Property changes on: tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/app/project/documents/view/legend/gui/ThemeManagerWindow.java
___________________________________________________________________
Added: svn:keywords
   + Author Date Id Revision
Added: svn:eol-style
   + native

Index: tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/app/project/documents/view/legend/gui/Categories.java
===================================================================
--- tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/app/project/documents/view/legend/gui/Categories.java	(revision 0)
+++ tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/app/project/documents/view/legend/gui/Categories.java	(revision 38653)
@@ -0,0 +1,79 @@
+/* gvSIG. Sistema de Informaci�n Geogr�fica de la Generalitat Valenciana
+ *
+ * Copyright (C) 2005 IVER T.I. and Generalitat Valenciana.
+ *
+ * This program is free software; you can redistribute it and/or
+ * modify it under the terms of the GNU General Public License
+ * as published by the Free Software Foundation; either version 2
+ * of the License, or (at your option) any later version.
+ *
+ * This program is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
+ * GNU General Public License for more details.
+ *
+ * You should have received a copy of the GNU General Public License
+ * along with this program; if not, write to the Free Software
+ * Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA  02111-1307,USA.
+ *
+ * For more information, contact:
+ *
+ *  Generalitat Valenciana
+ *   Conselleria d'Infraestructures i Transport
+ *   Av. Blasco Ib��ez, 50
+ *   46010 VALENCIA
+ *   SPAIN
+ *
+ *      +34 963862235
+ *   gvsig@gva.es
+ *      www.gvsig.gva.es
+ *
+ *    or
+ *
+ *   IVER T.I. S.A
+ *   Salamanca 50
+ *   46005 Valencia
+ *   Spain
+ *
+ *   +34 963163400
+ *   dac@iver.es
+ */
+
+/* CVS MESSAGES:
+*
+* $Id$
+* $Log$
+* Revision 1.3  2007-05-17 09:32:37  jaume
+* *** empty log message ***
+*
+* Revision 1.2  2007/03/09 11:25:00  jaume
+* Advanced symbology (start committing)
+*
+* Revision 1.1.2.1  2007/01/26 13:49:03  jaume
+* *** empty log message ***
+*
+*
+*/
+package org.gvsig.app.project.documents.view.legend.gui;
+
+import org.gvsig.andami.PluginServices;
+import org.gvsig.fmap.mapcontext.layers.FLayer;
+import org.gvsig.fmap.mapcontext.layers.vectorial.FLyrVect;
+
+
+public class Categories extends AbstractParentPanel {
+
+	public String getDescription() {
+		// TODO Implement it
+		throw new Error("Not yet implemented!");
+
+	}
+
+	public String getTitle() {
+		return PluginServices.getText(Categories.class, "categories");
+	}
+
+	public boolean isSuitableFor(FLayer layer) {
+		return layer instanceof FLyrVect;
+	}
+}

Property changes on: tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/app/project/documents/view/legend/gui/Categories.java
___________________________________________________________________
Added: svn:keywords
   + Author Date Id Revision
Added: svn:eol-style
   + native

Index: tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/app/project/documents/view/legend/gui/Quantities.java
===================================================================
--- tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/app/project/documents/view/legend/gui/Quantities.java	(revision 0)
+++ tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/app/project/documents/view/legend/gui/Quantities.java	(revision 38653)
@@ -0,0 +1,81 @@
+/* gvSIG. Sistema de Informaci�n Geogr�fica de la Generalitat Valenciana
+ *
+ * Copyright (C) 2005 IVER T.I. and Generalitat Valenciana.
+ *
+ * This program is free software; you can redistribute it and/or
+ * modify it under the terms of the GNU General Public License
+ * as published by the Free Software Foundation; either version 2
+ * of the License, or (at your option) any later version.
+ *
+ * This program is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
+ * GNU General Public License for more details.
+ *
+ * You should have received a copy of the GNU General Public License
+ * along with this program; if not, write to the Free Software
+ * Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA  02111-1307,USA.
+ *
+ * For more information, contact:
+ *
+ *  Generalitat Valenciana
+ *   Conselleria d'Infraestructures i Transport
+ *   Av. Blasco Ib��ez, 50
+ *   46010 VALENCIA
+ *   SPAIN
+ *
+ *      +34 963862235
+ *   gvsig@gva.es
+ *      www.gvsig.gva.es
+ *
+ *    or
+ *
+ *   IVER T.I. S.A
+ *   Salamanca 50
+ *   46005 Valencia
+ *   Spain
+ *
+ *   +34 963163400
+ *   dac@iver.es
+ */
+
+/* CVS MESSAGES:
+*
+* $Id$
+* $Log$
+* Revision 1.3  2007-05-17 09:32:37  jaume
+* *** empty log message ***
+*
+* Revision 1.2  2007/03/09 11:25:00  jaume
+* Advanced symbology (start committing)
+*
+* Revision 1.1.2.1  2007/01/26 13:49:03  jaume
+* *** empty log message ***
+*
+*
+*/
+package org.gvsig.app.project.documents.view.legend.gui;
+
+import org.gvsig.andami.PluginServices;
+import org.gvsig.fmap.mapcontext.layers.FLayer;
+import org.gvsig.fmap.mapcontext.layers.vectorial.FLyrVect;
+
+
+public class Quantities extends AbstractParentPanel {
+
+	public String getDescription() {
+		return "testing per a comprovar l'agrupament";
+	}
+
+	public String getParentTitle() {
+		return null;
+	}
+
+	public String getTitle() {
+		return PluginServices.getText(Quantities.class, "quantities");
+	}
+
+	public boolean isSuitableFor(FLayer layer) {
+		return layer instanceof FLyrVect;
+	}
+}

Property changes on: tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/app/project/documents/view/legend/gui/Quantities.java
___________________________________________________________________
Added: svn:keywords
   + Author Date Id Revision
Added: svn:eol-style
   + native

Index: tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/app/project/documents/view/legend/gui/ILegendPanel.java
===================================================================
--- tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/app/project/documents/view/legend/gui/ILegendPanel.java	(revision 0)
+++ tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/app/project/documents/view/legend/gui/ILegendPanel.java	(revision 38653)
@@ -0,0 +1,128 @@
+/*
+ * Created on 14-dic-2004
+ *
+ * TODO To change the template for this generated file go to
+ * Window - Preferences - Java - Code Generation - Code and Comments
+ */
+/* gvSIG. Sistema de Informaci�n Geogr�fica de la Generalitat Valenciana
+ *
+ * Copyright (C) 2004 IVER T.I. and Generalitat Valenciana.
+ *
+ * This program is free software; you can redistribute it and/or
+ * modify it under the terms of the GNU General Public License
+ * as published by the Free Software Foundation; either version 2
+ * of the License, or (at your option) any later version.
+ *
+ * This program is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
+ * GNU General Public License for more details.
+ *
+ * You should have received a copy of the GNU General Public License
+ * along with this program; if not, write to the Free Software
+ * Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA  02111-1307,USA.
+ *
+ * For more information, contact:
+ *
+ *  Generalitat Valenciana
+ *   Conselleria d'Infraestructures i Transport
+ *   Av. Blasco Ib��ez, 50
+ *   46010 VALENCIA
+ *   SPAIN
+ *
+ *      +34 963862235
+ *   gvsig@gva.es
+ *      www.gvsig.gva.es
+ *
+ *    or
+ *
+ *   IVER T.I. S.A
+ *   Salamanca 50
+ *   46005 Valencia
+ *   Spain
+ *
+ *   +34 963163400
+ *   dac@iver.es
+ */
+package org.gvsig.app.project.documents.view.legend.gui;
+
+import javax.swing.ImageIcon;
+import javax.swing.JPanel;
+
+import org.gvsig.fmap.mapcontext.layers.FLayer;
+import org.gvsig.fmap.mapcontext.rendering.legend.ILegend;
+
+
+/**
+ * @author jaume dominguez faus - jaume.dominguez@iver.es
+ *
+ * Este interfaz es el que debe cumplir cualquier panel que empleemos
+ * para confeccionar una leyenda. Se le pasa una capa para que
+ * tome su leyenda, y con el m�todo getLegend tomamos la leyenda
+ * que ha confeccionado el usuario.
+ */
+public interface ILegendPanel {
+	/**
+	 * Initializes the data required for this legend panel. That is, the layer that
+	 * will adopt the changes and the current legend that this layer has. If the
+	 * legend is not the type of legend that this panel manages then it initializes
+	 * the panel with the default values. In case it is, then the panel should
+	 * refresh its components with the current values of the Legend.
+	 * @param lyr,  target layer
+	 * @param legend, the legend currently applied to lyr
+	 */
+	public void setData(FLayer lyr, ILegend legend);
+
+	/**
+	 * Returns an instance of Legend
+	 * @return Legend, the legend result of the settings
+	 */
+	public ILegend getLegend();
+
+	/**
+	 * Returns a brief human-readable description about what kind of legend builds this panel
+	 * @return String with a brief description
+	 */
+	public String getDescription();
+
+	/**
+	 * Returns the icon which should graphically describe what this panel's legend does.
+	 * @return ImageIcon with the icon to be displayed
+	 */
+	public ImageIcon getIcon();
+
+	/**
+	 * If this panel should appear as a subnode of the legends tree, in other words it is not
+	 * a first-level node, then this method would return <b>its parent's class</b>. Otherwise, if
+	 * it is a first-level node, then it will return <b>null</b>.
+	 * @return String containing the parent's title.
+	 */
+	public Class getParentClass();
+
+	/**
+	 * Returns the title (a human-readable one) of this panel.
+	 */
+	public String getTitle();
+
+	/**
+	 * <p>If this is a complete panel (it is a child node in the legend tree) to set up a legend
+	 * this method will return a <b>JPanel</b> containing the necessary components. Otherwise, if
+	 * it is just a classification node (it has children) in the legend tree it will return
+	 * just <b>null</b>.<br></p>
+	 *
+	 * <p>If <b>null</b> is returned, the ILegendPanel that will be shown and selected each time
+	 * it is selected is the very first child of this parent node.</p>
+	 */
+	public JPanel getPanel();
+
+	/**
+	 * Returns the class of the legend produced by this ILegendPanel.
+	 */
+	public Class getLegendClass();
+
+	/**
+	 * Returns <b>true</b> if this legend is applicable to this layer, <b>false</b> otherwise.
+	 */
+	public boolean isSuitableFor(FLayer layer);
+}
+

Property changes on: tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/app/project/documents/view/legend/gui/ILegendPanel.java
___________________________________________________________________
Added: svn:keywords
   + Author Date Id Revision
Added: svn:eol-style
   + native

Index: tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/app/project/documents/view/legend/gui/ILabelingStrategyPanel.java
===================================================================
--- tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/app/project/documents/view/legend/gui/ILabelingStrategyPanel.java	(revision 0)
+++ tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/app/project/documents/view/legend/gui/ILabelingStrategyPanel.java	(revision 38653)
@@ -0,0 +1,99 @@
+/* gvSIG. Sistema de Informaci�n Geogr�fica de la Generalitat Valenciana
+ *
+ * Copyright (C) 2005 IVER T.I. and Generalitat Valenciana.
+ *
+ * This program is free software; you can redistribute it and/or
+ * modify it under the terms of the GNU General Public License
+ * as published by the Free Software Foundation; either version 2
+ * of the License, or (at your option) any later version.
+ *
+ * This program is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
+ * GNU General Public License for more details.
+ *
+ * You should have received a copy of the GNU General Public License
+ * along with this program; if not, write to the Free Software
+ * Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA  02111-1307,USA.
+ *
+ * For more information, contact:
+ *
+ *  Generalitat Valenciana
+ *   Conselleria d'Infraestructures i Transport
+ *   Av. Blasco Ib��ez, 50
+ *   46010 VALENCIA
+ *   SPAIN
+ *
+ *      +34 963862235
+ *   gvsig@gva.es
+ *      www.gvsig.gva.es
+ *
+ *    or
+ *
+ *   IVER T.I. S.A
+ *   Salamanca 50
+ *   46005 Valencia
+ *   Spain
+ *
+ *   +34 963163400
+ *   dac@iver.es
+ */
+package org.gvsig.app.project.documents.view.legend.gui;
+
+import org.gvsig.fmap.mapcontext.layers.FLayer;
+import org.gvsig.fmap.mapcontext.rendering.legend.styling.ILabelingStrategy;
+
+
+/**
+ * Interface to be implemented for those panels whose purpose is to
+ * set up labeling strategies.
+ *
+ * ILabelingStrategyPanel.java
+ *
+ *
+ * @author jaume dominguez faus - jaume.dominguez@iver.es Jun 13, 2008
+ *
+ */
+public interface ILabelingStrategyPanel {
+	/**
+	 * Invoked when de user accepts the settings, the returned value
+	 * is a always ready-to-work labeling strategy.
+	 *
+	 * @return ILabelingStrategy, a labeling strategy completely set up.
+	 */
+	public ILabelingStrategy getLabelingStrategy();
+
+	/**
+	 * Sets the model of the panel. As a general contract, after invoke
+	 * this method, the panel should be filled with all the values
+	 * needed and be able to be repainted successfully.
+	 *
+	 * @param layer, the layer to whom the labeling strategy is associated.
+	 * @param str, the current labeling strategy.
+	 */
+	public void setModel(FLayer layer, ILabelingStrategy str);
+
+	/**
+	 * A human-readable localized text to make this strategy easily
+	 * recognizable among all the available strategies.
+	 * @return
+	 */
+	public String getLabelingStrategyName();
+
+	/**
+	 * <p>
+	 * The panel shown in the layer properties dialog is selected through
+	 * the class of the labeling strategy. This method returns such class.
+	 * <br>
+	 * </p>
+	 * <p>
+	 * <b>Note</b> that, as a collateral effect, the panel that sets up a labeling strategy
+	 * can be substituted programatically by other of your wish if
+	 * you return the same labeling strategy class than the one to
+	 * be replaced with your new one. The last panel installed, will
+	 * be the one to be shown.
+	 * </p>
+	 * @return Class, the labeling strategy's Class
+	 */
+	public Class getLabelingStrategyClass();
+}
Index: tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/app/project/documents/view/legend/gui/LegendManager.java
===================================================================
--- tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/app/project/documents/view/legend/gui/LegendManager.java	(revision 0)
+++ tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/app/project/documents/view/legend/gui/LegendManager.java	(revision 38653)
@@ -0,0 +1,1049 @@
+/*
+ * Created on 08-feb-2005
+ *
+ * gvSIG. Sistema de Informaci�n Geogr�fica de la Generalitat Valenciana
+ *
+ * Copyright (C) 2004 IVER T.I. and Generalitat Valenciana.
+ *
+ * This program is free software; you can redistribute it and/or
+ * modify it under the terms of the GNU General Public License
+ * as published by the Free Software Foundation; either version 2
+ * of the License, or (at your option) any later version.
+ *
+ * This program is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
+ * GNU General Public License for more details.
+ *
+ * You should have received a copy of the GNU General Public License
+ * along with this program; if not, write to the Free Software
+ * Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA  02111-1307,USA.
+ *
+ * For more information, contact:
+ *
+ *  Generalitat Valenciana
+ *   Conselleria d'Infraestructures i Transport
+ *   Av. Blasco Ib��ez, 50
+ *   46010 VALENCIA
+ *   SPAIN
+ *
+ *      +34 963862235
+ *   gvsig@gva.es
+ *      www.gvsig.gva.es
+ *
+ *    or
+ *
+ *   IVER T.I. S.A
+ *   Salamanca 50
+ *   46005 Valencia
+ *   Spain
+ *
+ *   +34 963163400
+ *   dac@iver.es
+ */
+package org.gvsig.app.project.documents.view.legend.gui;
+
+import java.awt.BorderLayout;
+import java.awt.Color;
+import java.awt.Component;
+import java.awt.Dimension;
+import java.awt.FlowLayout;
+import java.awt.event.ActionListener;
+import java.io.File;
+import java.io.FileInputStream;
+import java.io.FileNotFoundException;
+import java.io.FileOutputStream;
+import java.io.InputStream;
+import java.io.OutputStream;
+import java.util.ArrayList;
+import java.util.Enumeration;
+import java.util.Hashtable;
+import java.util.prefs.Preferences;
+
+import javax.swing.ImageIcon;
+import javax.swing.JButton;
+import javax.swing.JComponent;
+import javax.swing.JFileChooser;
+import javax.swing.JLabel;
+import javax.swing.JOptionPane;
+import javax.swing.JPanel;
+import javax.swing.JScrollPane;
+import javax.swing.JSplitPane;
+import javax.swing.JTextArea;
+import javax.swing.JTree;
+import javax.swing.filechooser.FileFilter;
+import javax.swing.tree.DefaultMutableTreeNode;
+import javax.swing.tree.DefaultTreeCellRenderer;
+import javax.swing.tree.DefaultTreeModel;
+import javax.swing.tree.TreePath;
+import javax.swing.tree.TreeSelectionModel;
+
+import org.gvsig.andami.PluginServices;
+import org.gvsig.andami.messages.NotificationManager;
+import org.gvsig.fmap.mapcontext.exceptions.LegendLayerException;
+import org.gvsig.fmap.mapcontext.layers.FLayer;
+import org.gvsig.fmap.mapcontext.layers.FLayers;
+import org.gvsig.fmap.mapcontext.layers.operations.Classifiable;
+import org.gvsig.fmap.mapcontext.layers.operations.ClassifiableVectorial;
+import org.gvsig.fmap.mapcontext.layers.vectorial.FLyrVect;
+import org.gvsig.fmap.mapcontext.rendering.legend.IClassifiedVectorLegend;
+import org.gvsig.fmap.mapcontext.rendering.legend.ILegend;
+import org.gvsig.fmap.mapcontext.rendering.legend.IVectorLegend;
+import org.gvsig.fmap.mapcontext.rendering.symbols.SymbolManager;
+import org.gvsig.tools.ToolsLocator;
+import org.gvsig.tools.persistence.PersistenceManager;
+
+/**
+ * Implements the panel which allows the user to control all the information
+ * about the
+ * legends of a layer in order to improve the information that it offers to the
+ * user.
+ * There are options to create, save or load an existing legend.
+ * 
+ * @author jaume dominguez faus - jaume.dominguez@iver.es
+ */
+public class LegendManager extends AbstractThemeManagerPage {
+
+    private static final long serialVersionUID = 7989057553773181019L;
+    private static ArrayList<Class<? extends ILegendPanel>> legendPool =
+        new ArrayList<Class<? extends ILegendPanel>>();
+    // private static ArrayList<Class<? extends IFMapLegendDriver>>
+    // legendDriverPool = new ArrayList<Class<? extends IFMapLegendDriver>>();
+
+    private FLayer layer;
+    private ILegend legend; // Le asignaremos la leyenda del primer tema activo.
+    private Hashtable<Class<? extends ILegendPanel>, ILegendPanel> pages =
+        new Hashtable<Class<? extends ILegendPanel>, ILegendPanel>();
+    private JPanel topPanel = null;
+    private JTextArea titleArea = null;
+    private JPanel preview = null;
+    private JScrollPane jTitleScrollPane = null;
+    private JTree jTreeLegends;
+    private ILegendPanel activePanel;
+    private JScrollPane legendTreeScrollPane;
+    private boolean dirtyTree;
+    private DefaultMutableTreeNode root = new DefaultMutableTreeNode();
+    private DefaultTreeModel treeModel;
+    private JScrollPane jPanelContainer;
+    private JPanel jCentralPanel;
+    private JSplitPane jSplitPane;
+    private boolean isTreeListenerDisabled;
+    private JButton btnSaveLegend;
+    private JButton btnLoadLegend;
+    private Hashtable<FLayer, ILegend> table = null;
+    private boolean empty = true;
+    private JLabel iconLabel;
+
+    public static String defaultLegendFolderPath;
+    {
+
+        Preferences prefs = Preferences.userRoot().node("gvsig.foldering");
+        defaultLegendFolderPath = prefs.get("LegendsFolder", "");
+    }
+    private ActionListener loadSaveLegendAction = new ActionListener() {
+
+        public void actionPerformed(java.awt.event.ActionEvent e) {
+            JComponent c = (JComponent) e.getSource();
+            if (c.equals(getBtnSaveLegend())) {
+                saveLegend();
+
+            } else
+                if (c.equals(getBtnLoadLegend())) {
+                    loadLegend();
+                }
+        }
+
+        private void saveLegend() {
+            ILegend legend = activePanel.getLegend();
+
+            PersistenceManager manager = ToolsLocator.getPersistenceManager();
+            JFileChooser fileChooser = new JFileChooser();
+            fileChooser.setAcceptAllFileFilterUsed(false);
+
+            fileChooser.setFileFilter(new FileFilter() {
+
+                @Override
+                public String getDescription() {
+                    return "Legend files (*"
+                        + SymbolManager.LEGEND_FILE_EXTENSION + ")";
+                }
+
+                @Override
+                public boolean accept(File f) {
+                    if (f.isDirectory()) {
+                        return true;
+                    } else
+                        if (f.isFile() && getExtension(f) != null) {
+                            return getExtension(f).equals(
+                                SymbolManager.LEGEND_FILE_EXTENSION);
+                        } else {
+                            return false;
+                        }
+                }
+            });
+
+            if (fileChooser.showSaveDialog((Component) PluginServices
+                .getMainFrame()) == JFileChooser.APPROVE_OPTION) {
+                OutputStream os;
+                File selectedFile = fileChooser.getSelectedFile();
+
+                if (getExtension(selectedFile) == null
+                    || !getExtension(selectedFile).equals(
+                        SymbolManager.LEGEND_FILE_EXTENSION)) {
+                    File selectedFileWithExtension =
+                        new File(selectedFile.getAbsolutePath()
+                            + SymbolManager.LEGEND_FILE_EXTENSION);
+                    selectedFile = selectedFileWithExtension;
+                }
+
+                try {
+                    os = new FileOutputStream(selectedFile);
+                } catch (FileNotFoundException e) {
+                    JOptionPane.showMessageDialog(null,
+                        "_cant_open_the_input_file_legend");
+                    return;
+                }
+
+                manager.putObject(os, legend);
+            }
+        }
+
+        private void loadLegend() {
+
+            JFileChooser fileChooser = new JFileChooser();
+            fileChooser.setAcceptAllFileFilterUsed(false);
+
+            // fileChooser filter
+            fileChooser.setFileFilter(new FileFilter() {
+
+                @Override
+                public String getDescription() {
+                    // get this extension from manager or somewhere!
+
+                    return "Legend files (*"
+                        + SymbolManager.LEGEND_FILE_EXTENSION + ")";
+                }
+
+                @Override
+                public boolean accept(File f) {
+                    if (f.isDirectory()) {
+                        return true;
+                    } else
+                        if (f.isFile() && getExtension(f) != null) {
+
+                            return getExtension(f).equals(
+                                SymbolManager.LEGEND_FILE_EXTENSION);
+                        } else {
+                            return false;
+                        }
+                }
+            });
+
+            // open a file
+            if (fileChooser.showOpenDialog((Component) PluginServices
+                .getMainFrame()) == JFileChooser.APPROVE_OPTION) {
+                File file = fileChooser.getSelectedFile();
+                PersistenceManager manager =
+                    ToolsLocator.getPersistenceManager();
+                InputStream is;
+
+                try {
+                    is = new FileInputStream(file);
+                } catch (FileNotFoundException e) {
+                    JOptionPane.showMessageDialog(null,
+                        "_cant_open_the_input_file_legend");
+                    return;
+                }
+                ILegend legend = (ILegend) manager.getObject(is);
+                applyLegend(legend);
+            }
+        }
+    };
+
+    //
+    // JLegendFileChooser jfc = new
+    // JLegendFileChooser(getLegendDrivers(),true);
+    // jfc.setAcceptAllFileFilterUsed(false);
+    //
+    //
+    // File basedir = null;
+    // jfc.setCurrentDirectory(basedir);
+    // if (jfc.showSaveDialog((Component) PluginServices.getMainFrame())
+    // == JFileChooser.APPROVE_OPTION) {
+    //
+    // File file = jfc.getSelectedFile();
+    // String version = jfc.getDriverVersion();
+    // IFMapLegendDriver driver = jfc.getSuitableDriver();
+    //
+    // if(!(driver instanceof FMapGVLDriver)){
+    // Object[] options = {PluginServices.getText(this, "yes"),
+    // PluginServices.getText(this, "no")};
+    //
+    // int answer =
+    // JOptionPane.showOptionDialog((Component)PluginServices.getMainFrame(),
+    // PluginServices.getText(this, "not_GVSLEG_save_question")+"\n"+ //GVL
+    // changed to GVSLEG, be aware
+    // PluginServices.getText(this, "desea_continuar"),
+    // PluginServices.getText(this, "confirmation_dialog"),
+    // JOptionPane.YES_NO_OPTION,
+    // JOptionPane.QUESTION_MESSAGE,
+    // null,
+    // options, options[1]);
+    // if (answer!=JOptionPane.OK_OPTION) {
+    // // 'Cancel' pressed or window closed: don't save anythig, exit
+    // save dialog
+    // return;
+    // }
+    // }
+    //
+    // if (file.exists()) {
+    // Object[] options = {PluginServices.getText(this, "yes"),
+    // PluginServices.getText(this, "no"),
+    // PluginServices.getText(this, "Cancel")};
+    //
+    // int answer =
+    // JOptionPane.showOptionDialog((Component)PluginServices.getMainFrame(),
+    // PluginServices.getText(this,
+    // "fichero_ya_existe_seguro_desea_guardarlo"),
+    // PluginServices.getText(this, "confirmation_dialog"),
+    // JOptionPane.YES_NO_CANCEL_OPTION,
+    // JOptionPane.QUESTION_MESSAGE,
+    // null,
+    // options, options[1]);
+    // if (answer!=JOptionPane.OK_OPTION) {
+    // // 'Cancel' pressed or window closed: don't save anythig, exit
+    // save dialog
+    // return;
+    // }
+    // }
+    //
+    //
+    // try {
+    // driver.write(layer.getMapContext().getLayers(),layer,
+    // activePanel.getLegend(), file, version);
+    //
+    // } catch (LegendDriverException e1) {
+    // int type = e1.getType();
+    // String message=PluginServices.getText(this,
+    // "could_not_save_legend")+":\n";
+    //
+    // if ((type & LegendDriverException.SAVE_LEGEND_ERROR) != 0){
+    // type = type & ~LegendDriverException.SAVE_LEGEND_ERROR;
+    // message += PluginServices.getText(this,
+    // "error_writing_file")+".\n";
+    // }
+    // if ((type & LegendDriverException.UNSUPPORTED_LEGEND_CREATION) !=
+    // 0){
+    // type = type & ~LegendDriverException.UNSUPPORTED_LEGEND_CREATION;
+    // message += "-"+ PluginServices.getText(this,
+    // "legend_format_not_yet_supported")+"\n";
+    // }
+    // if (type != 0) {
+    // message = "-"+PluginServices.getText(this, "unknown_error")+"\n";
+    // }
+    // JOptionPane.showMessageDialog((Component)PluginServices.getMainFrame(),
+    // message);
+    // }
+    // }
+    // } else if (c.equals(getBtnLoadLegend())) {
+    //
+    // JLegendFileChooser jfc = new
+    // JLegendFileChooser(getLegendDrivers());
+    // jfc.setAcceptAllFileFilterUsed(false);
+    //
+    // if (jfc.showOpenDialog((Component) PluginServices.getMainFrame())
+    // == JFileChooser.APPROVE_OPTION) {
+    // File file=jfc.getSelectedFile();
+    // IFMapLegendDriver driver = jfc.getSuitableDriver();
+    // String path = file.getAbsolutePath();
+    // defaultLegendFolderPath = path.substring(0,
+    // path.lastIndexOf(File.separator));
+    //
+    // try {
+    // table = driver.read(layer.getMapContext().getLayers(),layer,
+    // file);
+    //
+    // if(table.containsKey(layer))
+    // applyLegend((ILegend) table.get(layer));
+    //
+    //
+    // } catch (LegendDriverException e1) {
+    // int type = e1.getType();
+    // String message = PluginServices.getText(this,
+    // "the_legend_will_not_be_applied")+":\n";
+    // boolean hasReason = false;
+    //
+    // if ((type &
+    // LegendDriverException.CLASSIFICATION_FIELDS_NOT_FOUND) != 0){
+    // type = type &
+    // ~LegendDriverException.CLASSIFICATION_FIELDS_NOT_FOUND;
+    // message +="-"+ PluginServices.getText(this,
+    // "classification_field_does_not_exists")+"\n";
+    // hasReason = true;
+    // }
+    // if ((type & LegendDriverException.LEGEND_TYPE_NOT_YET_SUPPORTED)
+    // != 0){
+    // type = type &
+    // ~LegendDriverException.LEGEND_TYPE_NOT_YET_SUPPORTED;
+    // message += "-"+ PluginServices.getText(this,
+    // "legend_type_not_yet_supported")+"\n";
+    // hasReason = true;
+    // }
+    // if ((type & LegendDriverException.SYMBOL_TYPE_NOT_YET_SUPPORTED)
+    // != 0){
+    // type = type &
+    // ~LegendDriverException.SYMBOL_TYPE_NOT_YET_SUPPORTED;
+    // message += "-"+ PluginServices.getText(this,
+    // "unsupported_symbol_type")+"\n";
+    // hasReason = true;
+    // }
+    // if ((type & LegendDriverException.LAYER_SHAPETYPE_MISMATCH) !=
+    // 0){
+    // type = type & ~LegendDriverException.LAYER_SHAPETYPE_MISMATCH;
+    // message += "-"+ PluginServices.getText(this,
+    // "layer_geometry_and_legend_types_are_incompatible")+"\n";
+    // hasReason = true;
+    // }
+    // if ((type & LegendDriverException.PARSE_LEGEND_FILE_ERROR) != 0){
+    // type = type & ~LegendDriverException.PARSE_LEGEND_FILE_ERROR;
+    // message += "-"+ PluginServices.getText(this,
+    // "failed_reading_file")+"\n";
+    // hasReason = true;
+    // }
+    // if ((type &
+    // LegendDriverException.UNSUPPORTED_LEGEND_FILE_VERSION) != 0){
+    // type = type &
+    // ~LegendDriverException.UNSUPPORTED_LEGEND_FILE_VERSION;
+    // message += "-"+ PluginServices.getText(this,
+    // "unsupported_legend_file_version")+"\n";
+    // hasReason = true;
+    // }
+    // if ((type & LegendDriverException.UNSUPPORTED_LEGEND_READING) !=
+    // 0){
+    // type = type & ~LegendDriverException.UNSUPPORTED_LEGEND_READING;
+    // message +="-"+ PluginServices.getText(this,
+    // "unsupported_legend_file_format")+"\n";
+    // hasReason = true;
+    // }
+    // if ((type & LegendDriverException.LAYER_NAME_NOT_FOUND) != 0){
+    // type = type & ~LegendDriverException.UNSUPPORTED_LEGEND_READING;
+    // message +="-"+ PluginServices.getText(this,
+    // "could_not_find_layer")+"\n";
+    // hasReason = true;
+    // }
+    // if (!hasReason) {
+    // message = "-"+ PluginServices.getText(this,
+    // "unknown_error")+"\n";
+    // }
+    // JOptionPane.showMessageDialog((Component)PluginServices.getMainFrame(),
+    // message);
+    // }
+    // }
+    // }
+
+    // private IFMapLegendDriver[] getLegendDrivers() {
+    // Class<?>[] legendDriverClasses = legendDriverPool.toArray(new Class[0]);
+    // ArrayList<IFMapLegendDriver> drivers = new
+    // ArrayList<IFMapLegendDriver>();
+    // for (int i = 0; i < legendDriverClasses.length; i++) {
+    // String message = PluginServices.getText(this,
+    // "adding_legend_file_format_support")+": ";
+    // try {
+    // Class<?> c = legendDriverClasses[i];
+    // drivers.add((IFMapLegendDriver) c.newInstance());
+    // } catch (Exception e) {
+    // NotificationManager.addError(message+PluginServices.getText(this,
+    // "failed"), e);
+    // }
+    // NotificationManager.addInfo(message+PluginServices.getText(this, "OK"));
+    //
+    // }
+    // return (IFMapLegendDriver[]) drivers.toArray(new IFMapLegendDriver[0]);
+    // };
+
+    private String getExtension(File f) {
+        String ext = null;
+        String s = f.getName();
+        int i = s.lastIndexOf('.');
+
+        if (i > 0 && i < s.length() - 1) {
+            // ext = s.substring(i + 1).toLowerCase();
+            ext = s.substring(i).toLowerCase();
+        }
+        return ext;
+    }
+
+    public LegendManager() {
+        initialize();
+    }
+
+    private void initialize() {
+        setLayout(new BorderLayout());
+        add(getTopPanel(), BorderLayout.NORTH);
+        add(getSplitPane(), BorderLayout.CENTER);
+        setSize(500, 360);
+        treeModel = new DefaultTreeModel(root);
+    }
+
+    private JSplitPane getSplitPane() {
+        if (jSplitPane == null) {
+            jSplitPane = new JSplitPane(JSplitPane.HORIZONTAL_SPLIT);
+            JPanel aux = new JPanel(new BorderLayout(0, 5));
+            aux.add(getLegendTreeScrollPane(), BorderLayout.CENTER);
+            aux.add(getPreviewPanel(), BorderLayout.SOUTH);
+            jSplitPane.setLeftComponent(aux);
+            jSplitPane.setRightComponent(getCentralPanel());
+            jSplitPane.setDividerLocation(150);
+        }
+        return jSplitPane;
+    }
+
+    private JPanel getCentralPanel() {
+        if (jCentralPanel == null) {
+            jCentralPanel = new JPanel(new BorderLayout(0, 10));
+            jCentralPanel.add(getTitleScroll(), BorderLayout.NORTH);
+            jCentralPanel.add(getJPanelContainer(), BorderLayout.CENTER);
+        }
+        return jCentralPanel;
+    }
+
+    private JScrollPane getJPanelContainer() {
+        if (jPanelContainer == null) {
+            jPanelContainer = new JScrollPane();
+        }
+        return jPanelContainer;
+    }
+
+    /**
+     * This method initializes jPanel
+     * 
+     * @return javax.swing.JPanel
+     */
+    private JPanel getTopPanel() {
+        if (topPanel == null) {
+            topPanel = new JPanel(new FlowLayout(FlowLayout.RIGHT, 5, 0));
+            topPanel.setPreferredSize(new Dimension(638, 31));
+            topPanel.setBorder(javax.swing.BorderFactory.createTitledBorder(
+                null, "",
+                javax.swing.border.TitledBorder.DEFAULT_JUSTIFICATION,
+                javax.swing.border.TitledBorder.DEFAULT_POSITION, null, null));
+            topPanel.add(getBtnSaveLegend(), null);
+            topPanel.add(getBtnLoadLegend(), null);
+        }
+        return topPanel;
+    }
+
+    private JButton getBtnSaveLegend() {
+        if (btnSaveLegend == null) {
+            btnSaveLegend =
+                new JButton(PluginServices.getText(this, "Guardar_leyenda")
+                    + "...");
+            btnSaveLegend.addActionListener(loadSaveLegendAction);
+        }
+        return btnSaveLegend;
+    }
+
+    private JButton getBtnLoadLegend() {
+        if (btnLoadLegend == null) {
+            btnLoadLegend =
+                new JButton(PluginServices.getText(this, "Recuperar_leyenda")
+                    + "...");
+            btnLoadLegend.addActionListener(loadSaveLegendAction);
+        }
+        return btnLoadLegend;
+    }
+
+    /**
+     * This method initializes jTextArea
+     * 
+     * @return javax.swing.JTextArea
+     */
+    private JTextArea getTitleArea() {
+        if (titleArea == null) {
+            titleArea = new JTextArea();
+            titleArea.setBackground(java.awt.SystemColor.control);
+            titleArea.setLineWrap(true);
+            titleArea.setRows(0);
+            titleArea.setWrapStyleWord(false);
+            titleArea.setEditable(false);
+            titleArea.setPreferredSize(new java.awt.Dimension(495, 40));
+        }
+        return titleArea;
+    }
+
+    /**
+     * This method initializes jPanel1
+     * 
+     * @return javax.swing.JPanel
+     */
+    private JPanel getPreviewPanel() {
+        if (preview == null) {
+            preview = new JPanel();
+            preview.setBorder(javax.swing.BorderFactory
+                .createBevelBorder(javax.swing.border.BevelBorder.LOWERED));
+            preview.setBackground(java.awt.SystemColor.text);
+            preview.setLayout(new BorderLayout(5, 5));
+            preview.add(getIconLabel());
+            preview.setPreferredSize(new Dimension(getSplitPane()
+                .getDividerLocation(), 130));
+            preview.setBackground(Color.white);
+        }
+        return preview;
+    }
+
+    private JLabel getIconLabel() {
+        if (iconLabel == null) {
+            iconLabel = new JLabel();
+            iconLabel.setVerticalAlignment(JLabel.CENTER);
+            iconLabel.setHorizontalAlignment(JLabel.CENTER);
+        }
+
+        return iconLabel;
+    }
+
+    /**
+     * This method initializes jScrollPane
+     * 
+     * @return javax.swing.JScrollPane
+     */
+    private JScrollPane getLegendTreeScrollPane() {
+        if (legendTreeScrollPane == null) {
+            legendTreeScrollPane = new JScrollPane();
+            legendTreeScrollPane.setViewportView(getJTreeLegends());
+        }
+        return legendTreeScrollPane;
+    }
+
+    /**
+     * <p>
+     * Adds a new fully-featured legend panel to the LegendManager.<br>
+     * </p>
+     * 
+     * <p>
+     * <b>CAUTION:</b> Trying to add a child page whose parent hasn't been added
+     * yet causes the application to fall in an infinite loop. This is a known
+     * bug, sorry. Just avoid this case or try to fix it (lol).<br>
+     * </p>
+     * 
+     * <p>
+     * <b>Notice</b> that there is no type check so if you add a
+     * non-ILegendPanel class, you'll have a runtime error later.
+     * </p>
+     * 
+     * @param page
+     *            , Class of type ILegendPanel
+     */
+    public static void addLegendPage(
+        Class<? extends ILegendPanel> iLegendPanelClass) {
+        if (!legendPool.contains(iLegendPanelClass)) {
+            legendPool.add(iLegendPanelClass);
+        }
+    }
+
+    /**
+     * Causes the component to be autofilled with the legend pages that
+     * were added through the static method addLegendPage(ILegendPanel page)
+     */
+    private void fillDialog() {
+        if (empty) {
+            for (int i = 0; i < legendPool.size(); i++) {
+                Class<?> pageClass = (Class<?>) legendPool.get(i);
+                ILegendPanel page;
+                try {
+                    page = (ILegendPanel) pageClass.newInstance();
+                    if (page.isSuitableFor(layer)) {
+                        // this legend can be applied to this layer
+                        pages.put(page.getClass(), page);
+
+                        if (dirtyTree) {
+                            // rebuild page tree
+                            dirtyTree = false;
+
+                            ArrayList<ILegendPanel> legList =
+                                new ArrayList<ILegendPanel>(pages.values());
+                            ArrayList<ILegendPanel> alreadyAdded =
+                                new ArrayList<ILegendPanel>();
+                            DefaultTreeModel model = new DefaultTreeModel(root);
+                            while (legList.size() > 0) {
+                                ILegendPanel legend =
+                                    (ILegendPanel) legList.get(0);
+                                Class<? extends ILegendPanel> parent =
+                                    legend.getParentClass();
+                                while (parent != null
+                                    && !alreadyAdded
+                                        .contains(pages.get(parent))) {
+                                    legend = (ILegendPanel) pages.get(parent);
+                                }
+                                doInsertNode(model, legend);
+                                legList.remove(legend);
+                                alreadyAdded.add(legend);
+                            }
+                            treeModel = model;
+                            jTreeLegends.setModel(model);
+                        }
+                        doInsertNode(treeModel, page);
+
+                    }
+                    getJTreeLegends().setModel(treeModel);
+
+                } catch (InstantiationException e) {
+                    NotificationManager.addError(
+                        "Trying to instantiate an interface"
+                            + " or abstract class + " + pageClass.getName(), e);
+                } catch (IllegalAccessException e) {
+                    NotificationManager.addError(
+                        "IllegalAccessException: does " + pageClass.getName()
+                            + " class have an anonymous" + " constructor?", e);
+                }
+
+            }
+            getJTreeLegends().repaint();
+            empty = false;
+        }
+    }
+
+    @SuppressWarnings("unchecked")
+    private DefaultMutableTreeNode findNode(Class searchID) {
+        String title;
+        try {
+            title =
+                ((ILegendPanel) Class.forName(searchID.getName()).newInstance())
+                    .getTitle();
+        } catch (Exception e) {
+            // this should be impossible, but anyway this case will be treat as
+            // the node does not
+            // exist.
+            return null;
+        }
+
+        Enumeration e = root.breadthFirstEnumeration();
+        while (e.hasMoreElements()) {
+            DefaultMutableTreeNode nodeAux =
+                (DefaultMutableTreeNode) e.nextElement();
+            if (nodeAux != null) {
+                ILegendPanel legend = (ILegendPanel) nodeAux.getUserObject();
+                if (legend == null)
+                    continue; // Root node
+                if (legend.getTitle().equals(title)) {
+                    return nodeAux;
+                }
+            }
+        }
+        return null;
+    }
+
+    private void doInsertNode(DefaultTreeModel treeModel, ILegendPanel page) {
+        dirtyTree =
+            ((page.getParentClass() != null) && (findNode(page.getParentClass()) == null));
+        if (findNode(page.getClass()) != null) // It is already added
+            return;
+        if (page.getParentClass() != null) {
+            if (pages.containsKey(page.getParentClass())) {
+                ILegendPanel parent =
+                    (ILegendPanel) pages.get(page.getParentClass());
+                DefaultMutableTreeNode nodeParent = findNode(parent.getClass());
+                if (nodeParent == null) {
+                    // the parent is empty
+                    // Recursively add it
+                    doInsertNode(treeModel, parent);
+                } else {
+                    DefaultMutableTreeNode nodeValue =
+                        new DefaultMutableTreeNode(page);
+                    int children = nodeParent.getChildCount();
+                    int pos = 0;
+                    for (int i = 0; i < children; i++) {
+                        DefaultMutableTreeNode node =
+                            (DefaultMutableTreeNode) treeModel.getChild(
+                                nodeParent, i);
+                        if (node.getUserObject() instanceof ILegendPanel) {
+                            String pageTitle =
+                                ((ILegendPanel) node.getUserObject())
+                                    .getTitle();
+                            if (pageTitle.compareTo(page.getTitle()) < 0)
+                                ++pos;
+                        }
+                    }
+                    treeModel.insertNodeInto(nodeValue, nodeParent, pos);
+                }
+            }
+        } else {
+            // First level node
+            DefaultMutableTreeNode nodeValue = new DefaultMutableTreeNode(page);
+            int children = root.getChildCount();
+            int pos = 0;
+            for (int i = 0; i < children; i++) {
+                DefaultMutableTreeNode node =
+                    (DefaultMutableTreeNode) treeModel.getChild(root, i);
+                if (node.getUserObject() instanceof ILegendPanel) {
+                    String pageTitle =
+                        ((ILegendPanel) node.getUserObject()).getTitle();
+                    if (pageTitle.compareTo(page.getTitle()) < 0)
+                        ++pos;
+                }
+            }
+            treeModel.insertNodeInto(nodeValue, root, pos);
+        }
+    }
+
+    private JScrollPane getTitleScroll() {
+        if (jTitleScrollPane == null) {
+            jTitleScrollPane = new JScrollPane();
+            jTitleScrollPane.setBounds(2, 2, 498, 42);
+            jTitleScrollPane.setViewportView(getTitleArea());
+        }
+        return jTitleScrollPane;
+    }
+
+    private JTree getJTreeLegends() {
+        if (jTreeLegends == null) {
+            jTreeLegends = new JTree();
+            jTreeLegends.setRootVisible(false);
+            MyTreeCellRenderer treeCellRenderer = new MyTreeCellRenderer();
+            treeCellRenderer.setOpenIcon(null);
+            treeCellRenderer.setClosedIcon(null);
+            treeCellRenderer.setLeafIcon(null);
+
+            jTreeLegends.setCellRenderer(treeCellRenderer);
+            jTreeLegends.setShowsRootHandles(true);
+            jTreeLegends
+                .addTreeSelectionListener(new javax.swing.event.TreeSelectionListener() {
+
+                    public void valueChanged(
+                        javax.swing.event.TreeSelectionEvent e) {
+                        if (isTreeListenerDisabled)
+                            return;
+                        DefaultMutableTreeNode node =
+                            (DefaultMutableTreeNode) jTreeLegends
+                                .getLastSelectedPathComponent();
+
+                        if (node == null)
+                            return;
+                        setActivePage((ILegendPanel) node.getUserObject());
+                    }
+                });
+            jTreeLegends.putClientProperty("JTree.linestyle", "Angled");
+            jTreeLegends.getSelectionModel().setSelectionMode(
+                TreeSelectionModel.SINGLE_TREE_SELECTION);
+        }
+        return jTreeLegends;
+    }
+
+    private void setActivePage(ILegendPanel page) {
+        if (page.getPanel() == null) {
+            // this is what happens when the user clicked in a parent node
+            // which only acts as a folder, and does not manage any legend
+            // then it expands and selects the first child
+            DefaultMutableTreeNode node = findNode(page.getClass());
+            if (treeModel.getChildCount(node) > 0) {
+                DefaultMutableTreeNode dmn =
+                    (DefaultMutableTreeNode) treeModel.getChild(node, 0);
+                page = (ILegendPanel) dmn.getUserObject();
+                setActivePage(page);
+                expandAndSelect(page);
+            }
+        } else {
+            // show the page
+            activePanel = page;
+            setIcon(activePanel.getIcon());
+
+            activePanel.setData(layer, legend);
+            getTitleArea().setText(activePanel.getDescription());
+            jPanelContainer.setViewportView(activePanel.getPanel());
+        }
+    }
+
+    private void setIcon(ImageIcon icon) {
+        getIconLabel().setIcon(icon);
+    }
+
+    private class MyTreeCellRenderer extends DefaultTreeCellRenderer {
+
+        private static final long serialVersionUID = -6013698992263578041L;
+
+        public MyTreeCellRenderer() {
+        }
+
+        public Component getTreeCellRendererComponent(JTree tree, Object value,
+            boolean sel, boolean expanded, boolean leaf, int row,
+            boolean hasFocus) {
+
+            super.getTreeCellRendererComponent(tree, value, sel, expanded,
+                leaf, row, hasFocus);
+            if (value instanceof DefaultMutableTreeNode) {
+                DefaultMutableTreeNode node = (DefaultMutableTreeNode) value;
+                if (node.getUserObject() instanceof ILegendPanel) {
+                    ILegendPanel legend = (ILegendPanel) node.getUserObject();
+                    this
+                        .setText(legend.getPanel() == null ? "<html><b>"
+                            + legend.getTitle() + "</b></html>" : legend
+                            .getTitle());
+                }
+            }
+            return this;
+        }
+
+    }
+
+    private void expandAndSelect(Object node) {
+        isTreeListenerDisabled = true;
+        // will expand the tree and select the node
+        int i = 0;
+        boolean exit = false;
+
+        TreePath tp = null;
+        // find the page in the tree
+        while (i < jTreeLegends.getRowCount() && !exit) {
+            // see if this row is the node that we are looking for
+
+            tp = jTreeLegends.getPathForRow(i);
+            Object[] obj = tp.getPath();
+            for (int j = 0; j < obj.length && !exit; j++) {
+                Object o = ((DefaultMutableTreeNode) obj[j]).getUserObject();
+
+                if (o != null && o.getClass().equals(node.getClass())
+                    && o.equals(node)) {
+                    // found it! collapse the tree
+                    while (i >= 0) {
+                        jTreeLegends.collapseRow(i);
+                        i--;
+                    }
+                    exit = true;
+                }
+            }
+            jTreeLegends.expandRow(i);
+            i++;
+        }
+
+        // expand the tree and set the selection
+        if (tp != null) {
+            jTreeLegends.expandPath(tp);
+            jTreeLegends.setSelectionPath(tp);
+        }
+        isTreeListenerDisabled = false;
+    }
+
+    public String getName() {
+        return PluginServices.getText(this, "Simbologia");
+    }
+
+    public void acceptAction() {
+        // automatically handled by the ThemeManagerWindow
+    }
+
+    public void cancelAction() {
+        // does nothing
+    }
+
+    public void applyAction() {
+        legend = activePanel.getLegend();
+
+        if (table != null && table.size() > 1)
+            applyRestOfLegends(table, layer.getMapContext().getLayers());
+
+        /*
+         * try to apply the legend to all the active layers that
+         * can accept it
+         */
+        FLayer[] activeLyrs = layer.getMapContext().getLayers().getActives();
+        for (int i = 0; i < activeLyrs.length; i++) {
+            FLayer laux = activeLyrs[i];
+
+            if (activeLyrs[i] instanceof FLayers) {
+                laux = getFirstActiveLayerVect((FLayers) activeLyrs[i]);
+            }
+
+            if (laux instanceof ClassifiableVectorial) {
+                ClassifiableVectorial aux2 = (ClassifiableVectorial) laux;
+                try {
+                    if (legend instanceof IClassifiedVectorLegend) {
+                        // Es una leyenda que necesita un recordset con un
+                        // nombre de campo. Comprobamos que ese recordset
+                        // tiene ese nombre de campo y es del tipo esperado
+                        IClassifiedVectorLegend cl =
+                            (IClassifiedVectorLegend) legend;
+
+                        if (aux2 instanceof FLyrVect) {
+
+                            if (cl.getValues().length == 0) {
+                                JOptionPane.showMessageDialog(
+                                    (Component) PluginServices.getMainFrame(),
+                                    PluginServices.getText(this,
+                                        "no_es_posible_aplicar_leyenda_vacia"));
+                                return;
+                            }
+
+                            aux2.setLegend((IVectorLegend) legend);
+                        }
+                    } else
+                        if (legend instanceof IVectorLegend) {
+                            aux2.setLegend((IVectorLegend) legend);
+                        }
+                } catch (LegendLayerException e) {
+                    NotificationManager.addError(PluginServices.getText(this,
+                        "legend_exception"), e);
+                }
+            }
+        }
+    }
+
+    private void applyRestOfLegends(Hashtable<FLayer, ILegend> table2,
+        FLayers layers) {
+
+        for (int i = 0; i < layers.getLayersCount(); i++) {
+            FLayer my_layer = layers.getLayer(i);
+
+            if (!(my_layer instanceof FLayers)) {
+                if (my_layer instanceof ClassifiableVectorial) {
+                    try {
+                        if (table.containsKey(my_layer)) {
+                            ClassifiableVectorial lyr =
+                                (ClassifiableVectorial) my_layer;
+                            lyr.setLegend((IVectorLegend) table.get(my_layer));
+                        }
+
+                    } catch (LegendLayerException e) {
+                        // TODO Auto-generated catch block
+                        e.printStackTrace();
+                    }
+                }
+            } else
+                applyRestOfLegends(table, (FLayers) my_layer);
+        }
+    }
+
+    @Override
+    public void setModel(FLayer layer) {
+        this.layer = layer;
+        applyLegend(((Classifiable) layer).getLegend());
+    }
+
+    /**
+     * Applies the legend to the layer.
+     * 
+     * @param aLegend
+     *            , legend that the user wants to apply
+     */
+    private void applyLegend(ILegend aLegend) {
+        this.legend = aLegend;
+        fillDialog();
+        Enumeration<Class<? extends ILegendPanel>> en = pages.keys();
+        while (en.hasMoreElements()) {
+            ILegendPanel page = (ILegendPanel) pages.get(en.nextElement());
+            if (legend.getClass().equals(page.getLegendClass())) {
+                setActivePage(page);
+                expandAndSelect(page);
+                return;
+            }
+        }
+        NotificationManager.addWarning(PluginServices.getText(this,
+            "caution_no_registered_panel_associated_to_"
+                + "loaded_legend_the_legend_wont_be_applied"));
+    }
+
+    // public static void addLegendDriver(Class<? extends IFMapLegendDriver>
+    // legendDriverClass) {
+    // if (!legendDriverPool.contains(legendDriverClass)) {
+    // legendDriverPool.add(legendDriverClass);
+    // }
+    // }
+}

Property changes on: tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/app/project/documents/view/legend/gui/LegendManager.java
___________________________________________________________________
Added: svn:keywords
   + Author Date Id Revision
Added: svn:eol-style
   + native

Index: tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/app/project/documents/view/legend/gui/JLegendFileChooser.java
===================================================================
--- tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/app/project/documents/view/legend/gui/JLegendFileChooser.java	(revision 0)
+++ tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/app/project/documents/view/legend/gui/JLegendFileChooser.java	(revision 38653)
@@ -0,0 +1,173 @@
+package org.gvsig.app.project.documents.view.legend.gui;
+
+import javax.swing.JFileChooser;
+
+
+/**
+ *
+ * JLegendFileChooser.java
+ *
+ *
+ * @author jaume dominguez faus - jaume.dominguez@iver.es Jul 22, 2008
+ *
+ */
+public class JLegendFileChooser extends JFileChooser  {
+	private static final long serialVersionUID = 8855060580358068594L;
+	private static String lastPath;
+//	private IFMapLegendDriver[] drivers;
+	private boolean write_mode = false;
+	public static String driverVersion;
+
+	public JLegendFileChooser() {
+		super();
+	}
+
+//	public JLegendFileChooser(IFMapLegendDriver[] legendDrivers) {
+//		this(legendDrivers, false);
+//	}
+//
+//	public JLegendFileChooser(final IFMapLegendDriver[] legendDrivers, boolean write_mode) {
+//		super(lastPath);
+//		this.write_mode = write_mode;
+//		this.drivers = legendDrivers;
+//
+//		setMultiSelectionEnabled(false);
+//
+//		if (!this.write_mode){//load method->"all the drivers in one"
+//
+//			this.setFileFilter(new FileFilter() {
+//				@Override
+//				public boolean accept(File f) {
+//					for (int i = 0; i < legendDrivers.length; i++) {
+//						if (legendDrivers[i].accept(f))
+//							return true;
+//					}
+//					return false;
+//				}
+//
+//				@Override
+//				public String getDescription() {
+//					String strLegendFormats = "";
+//					for (int i = 0; i < legendDrivers.length; i++) {
+//
+//						strLegendFormats += "*."+legendDrivers[i].getFileExtension();
+//						if (i<legendDrivers.length-1) strLegendFormats += ", ";
+//					}
+//
+//					return PluginServices.getText(this, "all_supported_legend_formats") +
+//					" ("+strLegendFormats+")";
+//				}
+//			});
+//		}
+//		else {//write method->all drivers are separated
+//			for (int i = 0; i < legendDrivers.length; i++) {
+//				final IFMapLegendDriver driver = legendDrivers[i];
+//
+//				if (driver.getSupportedVersions() != null) {
+//
+//					for (int j = 0; j < driver.getSupportedVersions().size(); j++) {
+//
+//						final String version = (String)driver.getSupportedVersions().get(j);
+//
+//						FileFilter aFilter = new FileFilter() {
+//
+//							@Override
+//							public boolean accept(File f) {
+//								return driver.accept(f);
+//							}
+//
+//							@Override
+//							public String getDescription() {
+//								return PluginServices.getText(this, driver.getDescription()+" "+version+" (*."+driver.getFileExtension()+")");
+//							}
+//
+//						};
+//						this.addChoosableFileFilter(aFilter);
+//					}
+//				}
+//				else {
+//
+//					FileFilter aFilter = new FileFilter() {
+//
+//						@Override
+//						public boolean accept(File f) {
+//							return driver.accept(f);
+//						}
+//
+//						@Override
+//						public String getDescription() {
+//							return PluginServices.getText(this, driver.getDescription()+" (*."+driver.getFileExtension()+")");
+//						}
+//
+//					};
+//					this.addChoosableFileFilter(aFilter);
+//				}
+//
+//			}
+//		}
+//	}
+//
+//
+//
+//	public IFMapLegendDriver getSuitableDriver() {
+//		File f = getSelectedFile();
+//
+//		for (int i = 0; drivers != null && i < drivers.length; i++) {
+//			if (drivers[i].accept(f))
+//				return drivers[i];
+//		}
+//		return null;
+//	}
+//
+//
+//
+//	public IFMapLegendDriver getDriverFromDescription(File file) {
+//		if (getFileFilter() != null){
+//			String descripFile = getFileFilter().getDescription();
+//			IFMapLegendDriver myDriver = null;
+//
+//			for (int i = 0; i < drivers.length; i++) {
+//
+//				myDriver = drivers[i];
+//				String driverDesc;
+//
+//				if(myDriver.getSupportedVersions() != null) {
+//					for (int j = 0; j < myDriver.getSupportedVersions().size(); j++) {
+//						driverDesc = myDriver.getDescription()+" "+myDriver.getSupportedVersions().get(j)+" (*."+myDriver.getFileExtension()+")";
+//						if (driverDesc.equals(descripFile)){
+//							driverVersion = (String)myDriver.getSupportedVersions().get(j);
+//							return myDriver;
+//						}
+//					}
+//				}
+//				else {
+//					driverDesc = myDriver.getDescription()+" (*."+myDriver.getFileExtension()+")";
+//					if (driverDesc.equals(descripFile)){
+//						driverVersion ="";
+//						return myDriver;
+//					}
+//				}
+//			}
+//		}
+//		return null;
+//	}
+//
+//	public File getSelectedFile() {
+//		File f = super.getSelectedFile();
+//
+//		IFMapLegendDriver myDriver = getDriverFromDescription(f);
+//		if (f!=null){
+//			if(myDriver != null && !(f.getPath().toLowerCase().endsWith("."+myDriver.getFileExtension()))){
+//				f = new File(f.getPath()+ "."+myDriver.getFileExtension());
+//			}
+//			lastPath = f.getAbsolutePath().substring(0, f.getAbsolutePath().lastIndexOf(File.separator));
+//		}
+//		return f;
+//	}
+
+	public static String getDriverVersion() {
+		return driverVersion;
+	}
+
+
+}
\ No newline at end of file
Index: tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/app/project/documents/view/legend/gui/PanelEditSymbol.java
===================================================================
--- tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/app/project/documents/view/legend/gui/PanelEditSymbol.java	(revision 0)
+++ tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/app/project/documents/view/legend/gui/PanelEditSymbol.java	(revision 38653)
@@ -0,0 +1,164 @@
+/* gvSIG. Sistema de Informaci�n Geogr�fica de la Generalitat Valenciana
+ *
+ * Copyright (C) 2004 IVER T.I. and Generalitat Valenciana.
+ *
+ * This program is free software; you can redistribute it and/or
+ * modify it under the terms of the GNU General Public License
+ * as published by the Free Software Foundation; either version 2
+ * of the License, or (at your option) any later version.
+ *
+ * This program is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
+ * GNU General Public License for more details.
+ *
+ * You should have received a copy of the GNU General Public License
+ * along with this program; if not, write to the Free Software
+ * Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA  02111-1307,USA.
+ *
+ * For more information, contact:
+ *
+ *  Generalitat Valenciana
+ *   Conselleria d'Infraestructures i Transport
+ *   Av. Blasco Ib��ez, 50
+ *   46010 VALENCIA
+ *   SPAIN
+ *
+ *      +34 963862235
+ *   gvsig@gva.es
+ *      www.gvsig.gva.es
+ *
+ *    or
+ *
+ *   IVER T.I. S.A
+ *   Salamanca 50
+ *   46005 Valencia
+ *   Spain
+ *
+ *   +34 963163400
+ *   dac@iver.es
+ */
+package org.gvsig.app.project.documents.view.legend.gui;
+
+import java.awt.BorderLayout;
+import java.awt.Dimension;
+
+import javax.swing.JButton;
+import javax.swing.JPanel;
+
+import org.gvsig.andami.PluginServices;
+import org.gvsig.andami.ui.mdiManager.IWindow;
+import org.gvsig.andami.ui.mdiManager.WindowInfo;
+import org.gvsig.fmap.mapcontext.rendering.symbols.ISymbol;
+
+
+
+/**
+ * Panel creado para editar el s�mbolo seleccionado.
+ *
+ * @author Vicente Caballero Navarro
+ */
+public class PanelEditSymbol extends JPanel implements IWindow {
+	private SingleSymbol panel = null;
+	private JButton bAceptar = null;  //  @jve:decl-index=0:visual-constraint="198,310"
+	private JPanel panelbutton = null;
+	private boolean ok=false;
+	//private FSymbol symbol;
+
+
+	public PanelEditSymbol(){
+		initialize();
+	}
+
+	/**
+	 * This method initializes this
+	 *
+	 */
+	private void initialize() {
+        this.setLayout(new BorderLayout());
+        this.setSize(450, 343);
+        this.add(getPanel(), java.awt.BorderLayout.NORTH);
+		this.add(getPanelbutton(),BorderLayout.SOUTH);
+	}
+	/**
+	 * DOCUMENT ME!
+	 *
+	 * @return DOCUMENT ME!
+	 */
+	public WindowInfo getWindowInfo() {
+		WindowInfo m_viewinfo = new WindowInfo(WindowInfo.MODALDIALOG);
+		m_viewinfo.setTitle(PluginServices.getText(this, "simbolo"));
+		m_viewinfo.setWidth(getWidth()+10);
+		m_viewinfo.setHeight(getHeight());
+		return m_viewinfo;
+	}
+
+	/**
+	 * This method initializes panel
+	 *
+	 * @return javax.swing.JPanel
+	 */
+	private SingleSymbol getPanel() {
+		if (panel == null) {
+			panel = new SingleSymbol();
+			panel.setPreferredSize(new Dimension(400, 300));
+			panel.setVisible(true);
+		}
+		return panel;
+	}
+
+	/**
+	 * This method initializes bAceptar
+	 *
+	 * @return javax.swing.JButton
+	 */
+	private JButton getBAceptar() {
+		if (bAceptar == null) {
+			bAceptar = new JButton();
+			bAceptar.setPreferredSize(new java.awt.Dimension(80,20));
+			bAceptar.setText("Aceptar");
+			bAceptar.addActionListener(new java.awt.event.ActionListener() {
+				public void actionPerformed(java.awt.event.ActionEvent e) {
+					ok=true;
+					PluginServices.getMDIManager().closeWindow(PanelEditSymbol.this);
+				}
+			});
+			bAceptar.setSize(35, 20);
+		}
+		return bAceptar;
+	}
+
+	public ISymbol getSymbol(){
+		return panel.getSymbol();
+	}
+
+	public void setSymbol(ISymbol s){
+		ok=false;
+		panel.setSymbol(s);
+	}
+
+	public boolean isOK(){
+		return ok;
+	}
+	/**
+	 * This method initializes panelbutton
+	 *
+	 * @return javax.swing.JPanel
+	 */
+	private JPanel getPanelbutton() {
+		if (panelbutton == null) {
+			panelbutton = new JPanel();
+			panelbutton.add(getBAceptar(), null);
+		}
+		return panelbutton;
+	}
+
+	public void setShapeType(int shapeType) {
+		getPanel().setShapeType(shapeType);
+	}
+
+	public Object getWindowProfile() {
+		return WindowInfo.DIALOG_PROFILE;
+	}
+
+}  //  @jve:decl-index=0:visual-constraint="10,10"

Property changes on: tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/app/project/documents/view/legend/gui/PanelEditSymbol.java
___________________________________________________________________
Added: svn:keywords
   + Author Date Id Revision
Added: svn:eol-style
   + native

Index: tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/app/project/documents/view/legend/gui/VectorialInterval.java
===================================================================
--- tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/app/project/documents/view/legend/gui/VectorialInterval.java	(revision 0)
+++ tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/app/project/documents/view/legend/gui/VectorialInterval.java	(revision 38653)
@@ -0,0 +1,896 @@
+/* gvSIG. Sistema de Informaci�n Geogr�fica de la Generalitat Valenciana
+ *
+ * Copyright (C) 2004 IVER T.I. and Generalitat Valenciana.
+ *
+ * This program is free software; you can redistribute it and/or
+ * modify it under the terms of the GNU General Public License
+ * as published by the Free Software Foundation; either version 2
+ * of the License, or (at your option) any later version.
+ *
+ * This program is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
+ * GNU General Public License for more details.
+ *
+ * You should have received a copy of the GNU General Public License
+ * along with this program; if not, write to the Free Software
+ * Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA  02111-1307,USA.
+ *
+ * For more information, contact:
+ *
+ *  Generalitat Valenciana
+ *   Conselleria d'Infraestructures i Transport
+ *   Av. Blasco Ib��ez, 50
+ *   46010 VALENCIA
+ *   SPAIN
+ *
+ *      +34 963862235
+ *   gvsig@gva.es
+ *      www.gvsig.gva.es
+ *
+ *    or
+ *
+ *   IVER T.I. S.A
+ *   Salamanca 50
+ *   46005 Valencia
+ *   Spain
+ *
+ *   +34 963163400
+ *   dac@iver.es
+ */
+package org.gvsig.app.project.documents.view.legend.gui;
+
+import java.awt.BorderLayout;
+import java.awt.Color;
+import java.awt.Dimension;
+import java.awt.FlowLayout;
+import java.awt.GridLayout;
+import java.awt.event.ActionEvent;
+import java.awt.event.ActionListener;
+import java.text.NumberFormat;
+import java.util.ArrayList;
+import java.util.Iterator;
+import java.util.List;
+
+import javax.swing.BorderFactory;
+import javax.swing.DefaultComboBoxModel;
+import javax.swing.ImageIcon;
+import javax.swing.JCheckBox;
+import javax.swing.JComboBox;
+import javax.swing.JOptionPane;
+import javax.swing.JPanel;
+import javax.swing.JTextField;
+
+import org.gvsig.andami.IconThemeHelper;
+import org.gvsig.andami.PluginServices;
+import org.gvsig.andami.messages.NotificationManager;
+import org.gvsig.app.gui.panels.ColorChooserPanel;
+import org.gvsig.fmap.dal.DataTypes;
+import org.gvsig.fmap.dal.exception.DataException;
+import org.gvsig.fmap.dal.feature.FeatureAttributeDescriptor;
+import org.gvsig.fmap.dal.feature.FeatureStore;
+import org.gvsig.fmap.dal.feature.FeatureType;
+import org.gvsig.fmap.mapcontext.MapContextLocator;
+import org.gvsig.fmap.mapcontext.MapContextManager;
+import org.gvsig.fmap.mapcontext.exceptions.LegendLayerException;
+import org.gvsig.fmap.mapcontext.layers.FLayer;
+import org.gvsig.fmap.mapcontext.layers.operations.ClassifiableVectorial;
+import org.gvsig.fmap.mapcontext.layers.vectorial.FLyrVect;
+import org.gvsig.fmap.mapcontext.rendering.legend.IInterval;
+import org.gvsig.fmap.mapcontext.rendering.legend.ILegend;
+import org.gvsig.fmap.mapcontext.rendering.legend.IVectorialIntervalLegend;
+import org.gvsig.fmap.mapcontext.rendering.symbols.ISymbol;
+import org.gvsig.gui.beans.swing.GridBagLayoutPanel;
+import org.gvsig.gui.beans.swing.JButton;
+import org.gvsig.symbology.fmap.mapcontext.rendering.legend.impl.FInterval;
+import org.gvsig.symbology.fmap.mapcontext.rendering.legend.impl.VectorialIntervalLegend;
+import org.slf4j.Logger;
+import org.slf4j.LoggerFactory;
+
+
+
+/**
+ * DOCUMENT ME!
+ *
+ * @author Vicente Caballero Navarro
+ */
+public class VectorialInterval extends JPanel implements ILegendPanel{
+    private static final Logger logger = LoggerFactory
+            .getLogger(VectorialInterval.class);
+    private GridBagLayoutPanel pnlGeneral = null;
+    protected JComboBox cmbField = null;
+    protected JTextField txtNumIntervals = null;
+    private ColorChooserPanel colorChooserPanel = null;
+    private ColorChooserPanel colorChooserPanel1 = null;
+    protected JCheckBox chkdefaultvalues = null;
+    protected JComboBox cmbFieldType = null;
+    private JPanel panelS = null;
+    private JButton bintervals = null;
+    private JButton bInsert = null;
+    protected JButton bDelAll = null;
+    protected JButton bDel = null;
+    private int count = 0;
+    protected ClassifiableVectorial layer;
+    protected VectorialIntervalLegend theLegend;
+    protected IVectorialIntervalLegend auxLegend = null;
+    protected SymbolTable symbolTable;
+    private MyListener listener = new MyListener();
+    protected JPanel pnlCenter = null;
+    protected JPanel optionPanel;
+    private JPanel pnlNorth;
+	protected JSymbolPreviewButton defaultSymbolPrev;
+	private GridBagLayoutPanel defaultSymbolPanel = new GridBagLayoutPanel();
+	
+	private MapContextManager mapContextManager = MapContextLocator
+			.getMapContextManager();
+
+    /**
+     * This is the default constructor
+     */
+    public VectorialInterval() {
+        super();
+        initialize();
+    }
+
+    /**
+     * This method initializes this
+     */
+    private void initialize() {
+        this.setLayout(new BorderLayout());
+        this.setSize(700, 350);
+        this.add(getPnlNorth(), BorderLayout.NORTH);
+
+        this.add(getPnlButtons(), BorderLayout.SOUTH);
+        this.add(getPnlCenter(), BorderLayout.CENTER);
+        setOptionPanel(getOptionPanel());
+    }
+
+    private JPanel getPnlNorth() {
+        if (pnlNorth == null) {
+            pnlNorth = new JPanel(new GridLayout(1, 2));
+            pnlNorth.add(getGeneralPanel());
+        }
+        return pnlNorth;
+    }
+
+    /**
+     * This method initializes panelN
+     *
+     * @return javax.swing.JPanel
+     */
+    private JPanel getGeneralPanel() {
+        if (pnlGeneral == null) {
+            pnlGeneral = new GridBagLayoutPanel();
+            pnlGeneral.setBorder(BorderFactory.
+                    createTitledBorder(null,
+                            PluginServices.getText(this, "fields")));
+            pnlGeneral.addComponent(PluginServices.getText(this, "Campo_de_clasificacion"),
+                    getCmbFields());
+            pnlGeneral.addComponent(PluginServices.getText(this, "tipo_de_intervalo"),
+                    getCmbIntervalTypes());
+
+            JPanel aux = new JPanel(new FlowLayout(FlowLayout.LEADING, 0, 0));
+            aux.add(getTxtNumIntervals());
+            pnlGeneral.addComponent(PluginServices.getText(this, "No_de_intervalos"),
+                    aux);
+            defaultSymbolPanel.add(getChkDefaultvalues(), null);
+			pnlGeneral.addComponent(defaultSymbolPanel);
+        }
+        return pnlGeneral;
+    }
+
+    public JPanel getOptionPanel() {
+        if (optionPanel == null) {
+            optionPanel = new JPanel(new FlowLayout(FlowLayout.LEADING));
+            optionPanel.setBorder(BorderFactory.
+                    createTitledBorder(null,
+                            PluginServices.getText(this, "color_ramp")));
+
+            GridBagLayoutPanel aux = new GridBagLayoutPanel();
+            aux.addComponent(PluginServices.getText(this, "Color_inicio"),
+                    getColorChooserPanel());
+            aux.addComponent(PluginServices.getText(this, "Color_final"),
+                    getColorChooserPanel1());
+            optionPanel.add(aux);
+        }
+        return optionPanel;
+    }
+
+    private void setOptionPanel(JPanel p) {
+        getPnlNorth().remove(getOptionPanel());
+        getPnlNorth().add(p, BorderLayout.NORTH);
+    }
+    /**
+     * This method initializes jComboBox
+     *
+     * @return javax.swing.JComboBox
+     */
+    private JComboBox getCmbFields() {
+        if (cmbField == null) {
+            cmbField = new JComboBox();
+            cmbField.setActionCommand("FIELD_SELECTED");
+            cmbField.addActionListener(listener);
+            cmbField.setVisible(true);
+        }
+
+        return cmbField;
+    }
+
+    /**
+     * This method initializes txtNumIntervals
+     *
+     * @return javax.swing.JTextField
+     */
+    private JTextField getTxtNumIntervals() {
+        if (txtNumIntervals == null) {
+            txtNumIntervals = new JTextField(5);
+            txtNumIntervals.setText("5");
+        }
+
+        return txtNumIntervals;
+    }
+
+    /**
+     * This method initializes colorChooserPanel
+     *
+     * @return com.iver.cit.gvsig.gui.Panels.ColorChooserPanel
+     */
+    private ColorChooserPanel getColorChooserPanel() {
+        if (colorChooserPanel == null) {
+            colorChooserPanel = new ColorChooserPanel();
+            colorChooserPanel.setBounds(new java.awt.Rectangle(108, 49, 54, 20));
+            colorChooserPanel.setAlpha(255);
+            colorChooserPanel.setColor(Color.red);
+        }
+
+        return colorChooserPanel;
+    }
+
+    /**
+     * This method initializes colorChooserPanel1
+     *
+     * @return com.iver.cit.gvsig.gui.Panels.ColorChooserPanel
+     */
+    private ColorChooserPanel getColorChooserPanel1() {
+        if (colorChooserPanel1 == null) {
+            colorChooserPanel1 = new ColorChooserPanel();
+            colorChooserPanel1.setBounds(new java.awt.Rectangle(251, 49, 54, 20));
+            colorChooserPanel1.setAlpha(255);
+            colorChooserPanel1.setColor(Color.blue);
+        }
+
+        return colorChooserPanel1;
+    }
+
+    /**
+     * This method initializes chkdefaultvalues
+     *
+     * @return javax.swing.JCheckBox
+     */
+    protected JCheckBox getChkDefaultvalues() {
+		if (chkdefaultvalues == null) {
+			chkdefaultvalues = new JCheckBox();
+			chkdefaultvalues.setText(PluginServices.getText(this,
+			"resto_valores")+": ");
+			chkdefaultvalues.setBounds(new java.awt.Rectangle(342, 26, 141, 20));
+			chkdefaultvalues.setSelected(false);
+			chkdefaultvalues.addActionListener(new java.awt.event.ActionListener() {
+				public void actionPerformed(java.awt.event.ActionEvent e) {
+					if (chkdefaultvalues.isSelected()) {
+						auxLegend.useDefaultSymbol(true);
+					} else {
+						auxLegend.useDefaultSymbol(false);
+					}
+				}
+			});
+		}
+
+		return chkdefaultvalues;
+	}
+
+    /**
+     * This method initializes jComboBox1
+     *
+     * @return javax.swing.JComboBox
+     */
+    private JComboBox getCmbIntervalTypes() {
+        if (cmbFieldType == null) {
+            cmbFieldType = new JComboBox();
+            cmbFieldType.setActionCommand("INTERVAL_TYPE");
+            cmbFieldType.addActionListener(listener);
+            cmbFieldType.addItem(PluginServices.getText(this, "equal_intervals"));
+            cmbFieldType.addItem(PluginServices.getText(this,
+                    "natural_intervals"));
+            cmbFieldType.addItem(PluginServices.getText(this,
+                    "quantile_intervals"));
+            cmbFieldType.setVisible(true);
+        }
+
+        return cmbFieldType;
+    }
+
+    /**
+     * This method initializes panelS
+     *
+     * @return javax.swing.JPanel
+     */
+    protected JPanel getPnlButtons() {
+        if (panelS == null) {
+            panelS = new JPanel();
+            panelS.setPreferredSize(new java.awt.Dimension(417, 32));
+            panelS.add(getBintervals(), null);
+            panelS.add(getBInsert(), null);
+            panelS.add(getBDelAll(), null);
+            panelS.add(getBDel(), null);
+        }
+
+        return panelS;
+    }
+
+    /**
+     * This method initializes bintervals
+     *
+     * @return javax.swing.JButton
+     */
+    private JButton getBintervals() {
+        if (bintervals == null) {
+            bintervals = new JButton();
+            bintervals.setActionCommand("ADD_ALL_VALUES");
+            bintervals.addActionListener(listener);
+            bintervals.setText(PluginServices.getText(this,
+                    "Calcular_intervalos"));
+        }
+
+        return bintervals;
+    }
+
+    /**
+     * This method initializes bInsert
+     *
+     * @return javax.swing.JButton
+     */
+    private JButton getBInsert() {
+        if (bInsert == null) {
+            bInsert = new JButton();
+            bInsert.setActionCommand("ADD_VALUE");
+            bInsert.addActionListener(listener);
+            bInsert.setText(PluginServices.getText(this, "Anadir"));
+        }
+
+        return bInsert;
+    }
+
+    /**
+     * This method initializes bDelAll
+     *
+     * @return javax.swing.JButton
+     */
+    private JButton getBDelAll() {
+        if (bDelAll == null) {
+            bDelAll = new JButton();
+            bDelAll.setActionCommand("REMOVE_ALL");
+            bDelAll.addActionListener(listener);
+            bDelAll.setText(PluginServices.getText(this, "Quitar_todos"));
+        }
+
+        return bDelAll;
+    }
+
+    /**
+     * This method initializes bDel
+     *
+     * @return javax.swing.JButton
+     */
+    private JButton getBDel() {
+        if (bDel == null) {
+            bDel = new JButton();
+            bDel.setText(PluginServices.getText(this, "Quitar"));
+            bDel.setActionCommand("REMOVE");
+            bDel.addActionListener(listener);
+        }
+
+        return bDel;
+    }
+
+
+    /**
+     * Damos una primera pasada para saber los l�mites inferior y superior y
+     * rellenar un array con los valores. Luego dividimos ese array en
+     * intervalos.
+     */
+    protected void fillTableValues() {
+
+        symbolTable.removeAllItems();
+
+        try {
+            IInterval[] arrayIntervalos = calculateIntervals();
+            if (arrayIntervalos == null) {
+				return;
+			}
+
+            IInterval interval;
+            NumberFormat.getInstance().setMaximumFractionDigits(2);
+            //theLegend.clear();
+            auxLegend.clear();
+
+            int r;
+            int g;
+            int b;
+            int stepR;
+            int stepG;
+            int stepB;
+
+            // Cogemos el tipo de gradaci�n de colores que quiere el usuario y
+            // Creamos el primer y �ltimo color.
+            Color startColor = colorChooserPanel.getColor();
+
+            Color endColor = colorChooserPanel1.getColor();
+
+            r = startColor.getRed();
+            g = startColor.getGreen();
+            b = startColor.getBlue();
+            stepR = (endColor.getRed() - r) / arrayIntervalos.length;
+            stepG = (endColor.getGreen() - g) / arrayIntervalos.length;
+            stepB = (endColor.getBlue() - b) / arrayIntervalos.length;
+
+//            auxLegend = LegendFactory.createVectorialIntervalLegend(layer.getShapeType());
+			auxLegend = (IVectorialIntervalLegend) MapContextLocator
+					.getMapContextManager().createLegend(
+							IVectorialIntervalLegend.LEGEND_NAME);
+            auxLegend.setShapeType(layer.getShapeType());
+            auxLegend.useDefaultSymbol(false);
+            auxLegend.setStartColor(startColor);
+            auxLegend.setEndColor(endColor);
+
+            int symbolType = layer.getShapeType();
+            int numSymbols = 0;
+
+            for (int k = 0; k < arrayIntervalos.length; k++) {
+                interval = arrayIntervalos[k];
+
+				ISymbol theSymbol =
+						mapContextManager.getSymbolManager().createSymbol(
+                		symbolType,
+                		new Color(r, g, b));
+                theSymbol.setDescription(NumberFormat.getInstance().format(interval.getMin()) +
+                    " - " +
+                    NumberFormat.getInstance().format(interval.getMax()));
+
+                //////////////////////////////////////
+                // CALCULAMOS UN COLOR APROPIADO
+                r = r + stepR;
+                g = g + stepG;
+                b = b + stepB;
+
+                /////////////////////////////////
+                auxLegend.addSymbol(interval, theSymbol);
+                System.out.println("addSymbol = " + interval +
+                    " theSymbol = " + theSymbol.getDescription());
+                numSymbols++;
+
+                if (numSymbols > 100) {
+                    int resp = JOptionPane.showConfirmDialog(this,
+                            PluginServices.getText(this, "mas_de_100_simbolos"),
+                            PluginServices.getText(this, "quiere_continuar"),
+                            JOptionPane.YES_NO_OPTION,
+                            JOptionPane.WARNING_MESSAGE);
+
+                    if ((resp == JOptionPane.NO_OPTION) ||
+                            (resp == JOptionPane.DEFAULT_OPTION)) {
+                        return;
+                    }
+                }
+
+                // }
+            } // for
+
+            System.out.println("Num. Simbolos = " +
+                auxLegend.getValues().length);
+          symbolTable.fillTableFromSymbolList(auxLegend.getSymbols(),
+          auxLegend.getValues(), auxLegend.getDescriptions());
+
+        } catch (DataException e) {
+        	NotificationManager.addError(PluginServices.getText(this, "could_not_get_shape_type"), e);
+        } catch (LegendLayerException e) {
+        	NotificationManager.addError(PluginServices.getText(this, "failed_computing_intervals"), e);
+		}
+
+        bDelAll.setEnabled(true);
+        bDel.setEnabled(true);
+    }
+
+    protected IInterval[] calculateIntervals() throws LegendLayerException {
+    	int intervalCount = 1;
+    	// ensure the interval value is an integer greather than 0
+    	try {
+    		intervalCount = (int) Double.
+    				parseDouble(txtNumIntervals.getText());
+    		if (intervalCount<1) {
+    			throw new Exception();
+    		}
+    	} catch (Exception e) {
+    		JOptionPane.showMessageDialog(this,
+    				PluginServices.getText(this, "invalid_interval_count_value"));
+    		return null;
+    	}
+
+    	try {
+            auxLegend.setIntervalType(getCmbIntervalTypes().getSelectedIndex());
+
+    		return auxLegend.calculateIntervals(
+    		//return theLegend.calculateIntervals(
+    				((FLyrVect) layer).getFeatureStore(),
+    				(String) cmbField.getSelectedItem(),
+    				intervalCount,
+    				layer.getShapeType()
+    				);
+    	} catch (DataException e) {
+    		return null;
+    	}
+    }
+
+    public void setData(FLayer layer, ILegend legend) {
+        this.layer = (ClassifiableVectorial) layer;
+    	int shapeType = 0;
+    	try {
+    		shapeType = this.layer.getShapeType();
+    	} catch (DataException e) {
+    		NotificationManager.addError(PluginServices.getText(this, "generating_intervals"), e);
+    	}
+
+    	if (symbolTable != null) {
+			pnlCenter.remove(symbolTable);
+		}
+
+    	getDefaultSymbolPrev(shapeType);
+
+    	symbolTable = new SymbolTable(this, SymbolTable.INTERVALS_TYPE, shapeType);
+    	pnlCenter.add(symbolTable);
+        fillFieldNames();
+
+/*        if (legend instanceof VectorialIntervalLegend) {
+            theLegend = (VectorialIntervalLegend) legend;
+            getChkDefaultvalues().setSelected(theLegend.isUseDefaultSymbol());
+            cmbField.getModel().setSelectedItem(theLegend.getClassifyingFieldNames()[0]);
+            symbolTable.fillTableFromSymbolList(theLegend.getSymbols(),
+                theLegend.getValues(), theLegend.getDescriptions());
+            colorChooserPanel.setColor(theLegend.getStartColor());
+            colorChooserPanel1.setColor(theLegend.getEndColor());
+            colorChooserPanel.repaint();
+            colorChooserPanel1.repaint();
+        } else {
+        		// Si la capa viene con otro tipo de leyenda, creamos
+        		// una nueva del tipo que maneja este panel
+        		theLegend = new VectorialIntervalLegend();
+        		theLegend.setShapeType(shapeType);
+        }
+
+
+        cmbFieldType.setSelectedIndex(theLegend.getIntervalType());
+*/
+		if (VectorialIntervalLegend.class.equals(legend.getClass())) {
+			auxLegend = (VectorialIntervalLegend) legend.cloneLegend();
+			chkdefaultvalues.setSelected(auxLegend.isUseDefaultSymbol());
+			cmbField.getModel().setSelectedItem(auxLegend.getClassifyingFieldNames()[0]);
+			
+			//Patch to fix an array overflow 
+            Object[] auxValues = auxLegend.getValues();
+            List<ISymbol> symbols = new ArrayList();
+            List<Object> values = new ArrayList();
+            List<String> descriptions = new ArrayList();
+            
+            for( int i=0; i<auxValues.length; i++){
+                Object key = auxValues[i];
+                if (key!=null){
+                    IInterval auxInterval = null;
+                    if (key instanceof IInterval){
+                        auxInterval = (IInterval) key;
+                        ISymbol symbol = auxLegend.getSymbolByInterval(auxInterval);
+                        symbols.add(symbol);
+                        values.add(auxValues[i]);
+                        descriptions.add(symbol.getDescription());
+                    }
+                }
+            }
+            symbolTable.fillTableFromSymbolList(
+                symbols.toArray(new ISymbol[0]),
+                values.toArray(),
+                descriptions.toArray(new String[0]));
+            //End Patch
+
+			colorChooserPanel.setColor(auxLegend.getStartColor());
+			colorChooserPanel1.setColor(auxLegend.getEndColor());
+			colorChooserPanel.repaint();
+			colorChooserPanel1.repaint();
+			if(auxLegend.isUseDefaultSymbol()) {
+				txtNumIntervals.setText(String.valueOf(auxLegend.getSymbols().length - 1));
+			} else {
+				txtNumIntervals.setText(String.valueOf(auxLegend.getSymbols().length));
+			}
+		} else {
+			// Si la capa viene con otro tipo de leyenda, creamos
+			// una nueva del tipo que maneja este panel
+			auxLegend = new VectorialIntervalLegend();
+			auxLegend.setShapeType(shapeType);
+			auxLegend.useDefaultSymbol(false);
+		}
+		defaultSymbolPrev.setSymbol(auxLegend.getDefaultSymbol());
+		cmbFieldType.setSelectedIndex(auxLegend.getIntervalType());
+    }
+
+
+	public void getDefaultSymbolPrev(int shapeType) {
+		if(defaultSymbolPrev == null){
+		defaultSymbolPrev = new JSymbolPreviewButton(shapeType);
+		defaultSymbolPrev.setPreferredSize(new Dimension(110,20));
+		defaultSymbolPanel.add(defaultSymbolPrev,null);
+		}
+	}
+
+    protected void fillFieldNames() {
+        FeatureStore rs = null;
+        ArrayList<String> nomFields = null;
+
+        try {
+            rs = ((FLyrVect) layer).getFeatureStore();
+//            logger.debug("rs.start()");
+//            rs.start();
+
+            nomFields = new ArrayList<String>();
+
+            int type;
+            Iterator<FeatureAttributeDescriptor> iterator=rs.getDefaultFeatureType().iterator();
+            while (iterator.hasNext()) {
+				FeatureAttributeDescriptor descriptor = iterator.next();
+
+//			}
+//            for (int i = 0; i < rs.getFieldCount(); i++) {
+                type = descriptor.getType();//rs.getFieldType(i);
+
+//                if (type.equals(FeatureAttributeDescriptor.) == Types.NULL) {
+//                    continue;
+//                }
+
+                if (type == DataTypes.INT ||
+                		type == DataTypes.DOUBLE ||
+                		type == DataTypes.FLOAT ||
+                		type  == DataTypes.LONG)
+                {
+                	nomFields.add(descriptor.getName());
+                }
+            }
+
+//            rs.stop();
+        } catch (DataException e) {
+        	NotificationManager.addError(PluginServices.getText(this, "recovering_recordset"), e);
+        }
+
+        DefaultComboBoxModel cM = new DefaultComboBoxModel(nomFields.toArray());
+        cmbField.setModel(cM);
+
+        symbolTable.removeAllItems();
+    }
+
+    /**
+     * @see com.iver.cit.gvsig.gui.legendmanager.panels.ILegendPanel#getLegend()
+     */
+     public ILegend getLegend() {
+		fillSymbolListFromTable();
+		if(defaultSymbolPrev.getSymbol() != null) {
+			auxLegend.setDefaultSymbol(defaultSymbolPrev.getSymbol());
+		}
+
+		auxLegend.useDefaultSymbol(chkdefaultvalues.isSelected());
+
+		theLegend = (VectorialIntervalLegend) auxLegend.cloneLegend();
+		return theLegend;
+	}
+
+    /**
+     * A partir de los registros de la tabla, regenera el FRenderer. (No solo
+     * el symbolList, si no tambi�n el arrayKeys y el defaultRenderer
+     */
+
+    private void fillSymbolListFromTable() {
+		ISymbol theSymbol;
+		IInterval theInterval = null;
+
+		// Borramos las anteriores listas:
+		auxLegend.clear();
+
+		String fieldName = (String) cmbField.getSelectedItem();
+		auxLegend.setClassifyingFieldNames(new String[] {fieldName});
+
+		auxLegend.useDefaultSymbol(chkdefaultvalues.isSelected());
+
+		FeatureStore rs;
+		try {
+
+			rs = ((FLyrVect) layer).getFeatureStore();
+//			rs.start();
+			FeatureType featureType=rs.getDefaultFeatureType();
+			auxLegend
+					.setClassifyingFieldTypes(new int[] { new Integer(
+							featureType.getAttributeDescriptor(fieldName)
+									.getType()) });
+			logger.debug("rs.start()");
+//			rs.stop();
+
+		} catch (DataException e) {
+			NotificationManager.addError(PluginServices.getText(this, "recovering_recordset"), e);
+		}
+
+
+
+		for (int row = 0; row < symbolTable.getRowCount(); row++) {
+			if (!(symbolTable.getFieldValue(row, 1) instanceof FInterval)) {
+				theSymbol = (ISymbol) symbolTable.getFieldValue(row, 0);
+				theSymbol.setDescription((String) symbolTable.getFieldValue(
+						row, 2));
+				auxLegend.addSymbol(null, theSymbol);
+			} else {
+				theInterval = (IInterval) symbolTable.getFieldValue(row, 1);
+				theSymbol = (ISymbol) symbolTable.getFieldValue(row, 0);
+				theSymbol.setDescription((String) symbolTable.getFieldValue(
+						row, 2));
+				auxLegend.addSymbol(theInterval, theSymbol);
+			}
+		}
+		if(chkdefaultvalues.isSelected()){
+			if(defaultSymbolPrev.getSymbol() != null){
+				String description = PluginServices.getText(this,"default");
+				defaultSymbolPrev.getSymbol().setDescription(description);
+				auxLegend.addSymbol(null, defaultSymbolPrev.getSymbol());
+			}
+		}
+	}
+
+    /**
+     * This method initializes panelC
+     *
+     * @return javax.swing.JPanel
+     */
+    private JPanel getPnlCenter() {
+        if (pnlCenter == null) {
+            pnlCenter = new JPanel();
+        }
+
+        return pnlCenter;
+    }
+
+    /**
+     * Listener.
+     *
+     * @author Vicente Caballero Navarro
+     */
+    class MyListener implements ActionListener {
+
+       public void actionPerformed(ActionEvent e) {
+            System.out.println("ActionEvent con " + e.getActionCommand());
+
+            //modificar el combobox de valor
+            if (e.getActionCommand() == "FIELD_SELECTED") {
+                JComboBox cb = (JComboBox) e.getSource();
+                String fieldName = (String) cb.getSelectedItem();
+                System.out.println("Nombre del campo: " + fieldName);
+                symbolTable.removeAllItems();
+
+                //theLegend.setClassifyingFieldNames(new String[] {fieldName});
+                auxLegend.setClassifyingFieldNames(new String[] {fieldName});
+            } else if (e.getActionCommand() == "INTERVAL_TYPE") {
+                JComboBox cb = (JComboBox) e.getSource();
+
+                //if ((theLegend != null) &&
+                if ((auxLegend != null) &&
+                    //    (cb.getSelectedIndex() != theLegend.getIntervalType())) {
+                        (cb.getSelectedIndex() != auxLegend.getIntervalType())) {
+                    //theLegend.setIntervalType(cb.getSelectedIndex());
+                    auxLegend.setIntervalType(cb.getSelectedIndex());
+                    symbolTable.removeAllItems();
+                }
+            }
+
+            //A�adir todos los elementos por valor
+            if (e.getActionCommand() == "ADD_ALL_VALUES") {
+                fillTableValues();
+            }
+
+            //A�adir un �nico elemento
+            if (e.getActionCommand() == "ADD_VALUE") {
+                try {
+                    symbolTable.addTableRecord(
+							mapContextManager.getSymbolManager().createSymbol(
+									layer.getShapeType()),
+                    		new FInterval(0, 0),
+                    		"0 - 0");
+                } catch (DataException e1) {
+                	NotificationManager.addError(PluginServices.getText(this, "could_not_get_shape_type"), e1);
+                }
+
+            }
+
+            //Vacia la tabla
+            if (e.getActionCommand() == "REMOVE_ALL") {
+                symbolTable.removeAllItems();
+
+            }
+
+            //Quitar solo el elemento seleccionado
+            if (e.getActionCommand() == "REMOVE") {
+                symbolTable.removeSelectedRows();
+            }
+        }
+    }
+
+    public String getDescription() {
+        return PluginServices.getText(this,"Muestra_los_elementos_de_la_capa_usando_una_gama_de_colores_en_funcion_del_valor_de_un_determinado_campo_de_atributos") + ".";
+    }
+
+    public ImageIcon getIcon() {
+        return IconThemeHelper.getImageIcon(
+            "legend-overview-vectorial-interval");
+    }
+
+    public Class getParentClass() {
+        return Quantities.class;
+    }
+
+    public String getTitle() {
+        return PluginServices.getText(this,"Intervalos");
+    }
+
+    public JPanel getPanel() {
+        return this;
+    }
+
+    public Class getLegendClass() {
+        return VectorialIntervalLegend.class;
+    }
+
+    private boolean isNumericField(int fieldType) {
+		if (fieldType == DataTypes.DOUBLE || fieldType == DataTypes.FLOAT
+				|| fieldType == DataTypes.LONG || fieldType == DataTypes.INT) {
+			return true;
+		}else{
+			return false;
+		}
+//    	switch (fieldType) {
+//		case Types.BIGINT:
+//		case Types.DECIMAL:
+//		case Types.DOUBLE:
+//		case Types.FLOAT:
+//		case Types.INTEGER:
+//		case Types.NUMERIC:
+//		case Types.REAL:
+//		case Types.SMALLINT:
+//		case Types.TINYINT:
+//			return true;
+//		default:
+//			return false;
+//		}
+
+	}
+	public boolean isSuitableFor(FLayer layer) {
+		if (layer instanceof FLyrVect) {
+			FeatureStore sds;
+			try {
+				sds = ((FLyrVect) layer).getFeatureStore();
+				FeatureType featureType=sds.getDefaultFeatureType();
+				Iterator iterator=featureType.iterator();
+				while (iterator.hasNext()) {
+					FeatureAttributeDescriptor descriptor = (FeatureAttributeDescriptor) iterator.next();
+
+//				}
+//				String[] fNames = sds.getFieldNames();
+//				for (int i = 0; i < fNames.length; i++) {
+					if (descriptor.getDataType().isNumeric() ) {
+						return true;
+					}
+				}
+			} catch (DataException e) {
+				return false;
+			}
+		}
+		return false;
+	}
+}

Property changes on: tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/app/project/documents/view/legend/gui/VectorialInterval.java
___________________________________________________________________
Added: svn:keywords
   + Author Date Id Revision
Added: svn:eol-style
   + native

Index: tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/app/project/documents/view/legend/gui/AbstractParentPanel.java
===================================================================
--- tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/app/project/documents/view/legend/gui/AbstractParentPanel.java	(revision 0)
+++ tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/app/project/documents/view/legend/gui/AbstractParentPanel.java	(revision 38653)
@@ -0,0 +1,96 @@
+/* gvSIG. Sistema de Informaci�n Geogr�fica de la Generalitat Valenciana
+ *
+ * Copyright (C) 2005 IVER T.I. and Generalitat Valenciana.
+ *
+ * This program is free software; you can redistribute it and/or
+ * modify it under the terms of the GNU General Public License
+ * as published by the Free Software Foundation; either version 2
+ * of the License, or (at your option) any later version.
+ *
+ * This program is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
+ * GNU General Public License for more details.
+ *
+ * You should have received a copy of the GNU General Public License
+ * along with this program; if not, write to the Free Software
+ * Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA  02111-1307,USA.
+ *
+ * For more information, contact:
+ *
+ *  Generalitat Valenciana
+ *   Conselleria d'Infraestructures i Transport
+ *   Av. Blasco Ib��ez, 50
+ *   46010 VALENCIA
+ *   SPAIN
+ *
+ *      +34 963862235
+ *   gvsig@gva.es
+ *      www.gvsig.gva.es
+ *
+ *    or
+ *
+ *   IVER T.I. S.A
+ *   Salamanca 50
+ *   46005 Valencia
+ *   Spain
+ *
+ *   +34 963163400
+ *   dac@iver.es
+ */
+
+/* CVS MESSAGES:
+*
+* $Id$
+* $Log$
+* Revision 1.3  2007-05-10 09:46:45  jaume
+* Refactored legend interface names
+*
+* Revision 1.2  2007/03/09 11:25:00  jaume
+* Advanced symbology (start committing)
+*
+* Revision 1.1.2.3  2007/02/21 07:35:14  jaume
+* *** empty log message ***
+*
+* Revision 1.1.2.2  2007/02/09 11:00:03  jaume
+* *** empty log message ***
+*
+* Revision 1.1.2.1  2007/01/26 13:49:03  jaume
+* *** empty log message ***
+*
+*
+*/
+package org.gvsig.app.project.documents.view.legend.gui;
+
+import javax.swing.ImageIcon;
+import javax.swing.JPanel;
+
+import org.gvsig.fmap.mapcontext.layers.FLayer;
+import org.gvsig.fmap.mapcontext.rendering.legend.ILegend;
+
+
+public abstract class AbstractParentPanel implements ILegendPanel {
+
+	public final void setData(FLayer lyr, ILegend legend) {}
+
+	public final ILegend getLegend() {
+		return null;
+	}
+
+	public final ImageIcon getIcon() {
+		return null;
+	}
+
+	public Class getParentClass() {
+		return null;
+	}
+
+	public final JPanel getPanel() {
+		return null;
+	}
+
+	public Class getLegendClass() {
+		return null;
+	}
+
+}

Property changes on: tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/app/project/documents/view/legend/gui/AbstractParentPanel.java
___________________________________________________________________
Added: svn:eol-style
   + native
Added: svn:keywords
   + Author Date Id Revision

Index: tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/app/project/documents/view/legend/gui/MultipleAttributes.java
===================================================================
--- tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/app/project/documents/view/legend/gui/MultipleAttributes.java	(revision 0)
+++ tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/app/project/documents/view/legend/gui/MultipleAttributes.java	(revision 38653)
@@ -0,0 +1,21 @@
+package org.gvsig.app.project.documents.view.legend.gui;
+
+import org.gvsig.andami.PluginServices;
+import org.gvsig.fmap.mapcontext.layers.FLayer;
+import org.gvsig.fmap.mapcontext.layers.vectorial.FLyrVect;
+
+
+public class MultipleAttributes extends AbstractParentPanel {
+
+	public String getDescription() {
+		return null;
+	}
+
+	public String getTitle() {
+		return PluginServices.getText(this, "multiple_atributes");
+	}
+
+	public boolean isSuitableFor(FLayer layer) {
+		return layer instanceof FLyrVect;
+	}
+}

Property changes on: tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/app/project/documents/view/legend/gui/MultipleAttributes.java
___________________________________________________________________
Added: svn:eol-style
   + native
Added: svn:keywords
   + Author Date Id Revision

Index: tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/app/project/documents/view/legend/gui/SingleSymbol.java
===================================================================
--- tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/app/project/documents/view/legend/gui/SingleSymbol.java	(revision 0)
+++ tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/app/project/documents/view/legend/gui/SingleSymbol.java	(revision 38653)
@@ -0,0 +1,280 @@
+/*
+ * Created on 30-abr-2004
+ *
+ * To change the template for this generated file go to
+ * Window&gt;Preferences&gt;Java&gt;Code Generation&gt;Code and Comments
+ */
+/* gvSIG. Sistema de Informaci�n Geogr�fica de la Generalitat Valenciana
+ *
+ * Copyright (C) 2004 IVER T.I. and Generalitat Valenciana.
+ *
+ * This program is free software; you can redistribute it and/or
+ * modify it under the terms of the GNU General Public License
+ * as published by the Free Software Foundation; either version 2
+ * of the License, or (at your option) any later version.
+ *
+ * This program is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
+ * GNU General Public License for more details.
+ *
+ * You should have received a copy of the GNU General Public License
+ * along with this program; if not, write to the Free Software
+ * Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA  02111-1307,USA.
+ *
+ * For more information, contact:
+ *
+ *  Generalitat Valenciana
+ *   Conselleria d'Infraestructures i Transport
+ *   Av. Blasco Ib��ez, 50
+ *   46010 VALENCIA
+ *   SPAIN
+ *
+ *      +34 963862235
+ *   gvsig@gva.es
+ *      www.gvsig.gva.es
+ *
+ *    or
+ *
+ *   IVER T.I. S.A
+ *   Salamanca 50
+ *   46005 Valencia
+ *   Spain
+ *
+ *   +34 963163400
+ *   dac@iver.es
+ */
+package org.gvsig.app.project.documents.view.legend.gui;
+
+import java.awt.Dimension;
+import java.awt.event.ActionEvent;
+import java.awt.event.ActionListener;
+
+import javax.swing.BorderFactory;
+import javax.swing.BoxLayout;
+import javax.swing.ImageIcon;
+import javax.swing.JComponent;
+import javax.swing.JPanel;
+import javax.swing.JTextField;
+import javax.swing.border.TitledBorder;
+
+import org.gvsig.andami.IconThemeHelper;
+import org.gvsig.andami.PluginServices;
+import org.gvsig.andami.messages.NotificationManager;
+import org.gvsig.app.gui.styling.SymbolLevelsWindow;
+import org.gvsig.app.gui.styling.SymbolPreviewer;
+import org.gvsig.app.gui.styling.SymbolSelector;
+import org.gvsig.fmap.dal.exception.ReadException;
+import org.gvsig.fmap.mapcontext.MapContextLocator;
+import org.gvsig.fmap.mapcontext.layers.FLayer;
+import org.gvsig.fmap.mapcontext.layers.vectorial.FLyrVect;
+import org.gvsig.fmap.mapcontext.rendering.legend.ILegend;
+import org.gvsig.fmap.mapcontext.rendering.legend.ZSort;
+import org.gvsig.fmap.mapcontext.rendering.symbols.ISymbol;
+import org.gvsig.gui.beans.swing.GridBagLayoutPanel;
+import org.gvsig.gui.beans.swing.JButton;
+import org.gvsig.symbology.fmap.mapcontext.rendering.legend.impl.AbstractVectorialLegend;
+import org.gvsig.symbology.fmap.mapcontext.rendering.legend.impl.SingleSymbolLegend;
+
+
+/**
+ * @author jaume dominguez faus - jaume.dominguez@iver.es
+ */
+public class SingleSymbol extends JPanel implements ILegendPanel, ActionListener {
+	private JPanel symbolPanel = null;
+	private int shapeType;
+	private GridBagLayoutPanel legendPanel = null;
+	private SymbolPreviewer symbolPreviewComponent;
+	private JButton btnOpenSymbolSelector;
+	private JTextField txtLabel;
+	private JButton btnOpenSymbolLevelsEditor;
+	private SingleSymbolLegend legend;
+	private ZSort zSort;
+
+
+	public SingleSymbol() {
+		super();
+		initialize();
+	}
+	/**
+	 * This method initializes this
+	 *
+	 */
+	private void initialize() {
+        this.setLayout(new BoxLayout(this, BoxLayout.Y_AXIS));
+        this.setSize(new java.awt.Dimension(490,379));
+        this.add(getSymbolPanel(), null);
+        this.add(getLegendPanel(), null);
+
+	}
+
+	public void setData(FLayer lyr, ILegend legend) {
+		try {
+			shapeType = ((FLyrVect) lyr).getShapeType();
+		} catch (ReadException e) {
+			NotificationManager.addError("Could not find out the shape type" ,e);
+		}
+		if (legend instanceof SingleSymbolLegend) {
+			setSymbol(legend.getDefaultSymbol());
+			this.legend = (SingleSymbolLegend) legend;
+
+		} else {
+			this.legend = (SingleSymbolLegend) MapContextLocator
+					.getMapContextManager().createLegend(
+							SingleSymbolLegend.LEGEND_NAME);
+			this.legend.setShapeType(shapeType);
+//			LegendFactory.
+//					createSingleSymbolLegend(shapeType);
+		}
+		getSymbolPreviewPanel().setSymbol(this.legend.getDefaultSymbol());
+		getBtnOpenSymbolLevelsEditor().setEnabled(legend!=null);
+		this.txtLabel.setText(legend.getDefaultSymbol().getDescription());
+	}
+
+	/* (non-Javadoc)
+	 * @see com.iver.cit.gvsig.gui.legendmanager.panels.ILegendPanel#getLegend()
+	 */
+	public ILegend getLegend() {
+		ISymbol symbol = getSymbolPreviewPanel().getSymbol();
+		symbol.setDescription(txtLabel.getText());
+		AbstractVectorialLegend leg = new SingleSymbolLegend(symbol);
+		leg.setZSort(zSort);
+		return leg;
+	}
+
+	public String getDescription() {
+		return PluginServices.getText(this,"Muestra_todos_s_elementos_de_una_capa_usando_el_mismo_simbolo");
+	}
+
+	public Class getParentClass() {
+		return Features.class;
+	}
+
+	public String getTitle() {
+		return PluginServices.getText(this,"Simbolo_unico");
+	}
+
+	public JPanel getPanel() {
+		return this;
+	}
+
+	public ImageIcon getIcon() {
+		return IconThemeHelper.getImageIcon("legend-overview-single-symbol");
+	}
+
+	public Class getLegendClass() {
+		return SingleSymbolLegend.class;
+	}
+	/**
+	 * This method initializes symbolPanel
+	 *
+	 * @return javax.swing.JPanel
+	 */
+	private JPanel getSymbolPanel() {
+		if (symbolPanel == null) {
+			symbolPanel = new JPanel();
+			symbolPanel.setBorder(
+					BorderFactory.createTitledBorder(null, "symbol", TitledBorder.DEFAULT_JUSTIFICATION, TitledBorder.DEFAULT_POSITION, null, null));
+			symbolPanel.add(getSymbolPreviewPanel());
+			symbolPanel.add(getBtnOpenSymbolSelector());
+			symbolPanel.add(getBtnOpenSymbolLevelsEditor());
+		}
+		return symbolPanel;
+	}
+
+	private JButton getBtnOpenSymbolLevelsEditor() {
+		if (btnOpenSymbolLevelsEditor == null) {
+			btnOpenSymbolLevelsEditor = new JButton(PluginServices.getText(this, "symbol_levels"));
+			btnOpenSymbolLevelsEditor.addActionListener(this);
+			btnOpenSymbolLevelsEditor.setEnabled(legend != null);
+		}
+
+		return btnOpenSymbolLevelsEditor;
+	}
+	private JButton getBtnOpenSymbolSelector() {
+		if (btnOpenSymbolSelector == null) {
+			btnOpenSymbolSelector = new JButton();
+			btnOpenSymbolSelector.setText(PluginServices.getText(this, "choose_symbol"));
+			btnOpenSymbolSelector.addActionListener(this);
+		}
+		return btnOpenSymbolSelector;
+	}
+
+	private SymbolPreviewer getSymbolPreviewPanel() {
+		if (symbolPreviewComponent == null) {
+			symbolPreviewComponent = new SymbolPreviewer();
+			symbolPreviewComponent.setBorder(BorderFactory.createBevelBorder(1));
+			symbolPreviewComponent.setPreferredSize(new Dimension(120, 40));
+		}
+		return symbolPreviewComponent;
+	}
+	/**
+	 * This method initializes legendPanel
+	 *
+	 * @return javax.swing.JPanel
+	 */
+	private GridBagLayoutPanel getLegendPanel() {
+		if (legendPanel == null) {
+			legendPanel = new GridBagLayoutPanel();
+			legendPanel.setBorder(BorderFactory.createTitledBorder(null,
+					PluginServices.getText(this, "legend"), TitledBorder.DEFAULT_JUSTIFICATION, TitledBorder.DEFAULT_POSITION, null, null));
+			legendPanel.addComponent(PluginServices.getText(this, "label_text_in_the_TOC") + ":", txtLabel = new JTextField(25));
+			txtLabel.addActionListener(this);
+		}
+		return legendPanel;
+	}
+
+	public void setShapeType(int shapeType) {
+		this.shapeType = shapeType;
+	}
+
+	public void setSymbol(ISymbol symbol) {
+		setOnlySymbol(symbol);
+		if(symbol.getDescription() != null) {
+			txtLabel.setText(symbol.getDescription());
+		}
+	}
+
+	private void setOnlySymbol(ISymbol symbol){
+		getSymbolPreviewPanel().setSymbol(symbol);
+		if (legend != null){
+			legend.setDefaultSymbol(symbol);
+		}
+	}
+
+
+	public ISymbol getSymbol() {
+		ISymbol symbol = getSymbolPreviewPanel().getSymbol();
+		symbol.setDescription(txtLabel.getText());
+		return symbol;
+	}
+	public boolean isSuitableFor(FLayer layer) {
+		return (layer instanceof FLyrVect) ;
+	}
+
+	public void actionPerformed(ActionEvent e) {
+		JComponent c = (JComponent) e.getSource();
+		if (c.equals(getBtnOpenSymbolSelector())){
+			ISymbolSelector se = SymbolSelector.createSymbolSelector(getSymbol(), shapeType);
+			PluginServices.getMDIManager().addWindow(se);
+			ISymbol sym = (ISymbol) se.getSelectedObject();
+			if (sym != null) {
+				// no symbol, no changes
+				setOnlySymbol(sym);
+			}
+		} else if (c.equals(getBtnOpenSymbolLevelsEditor())){
+			if (legend != null) {
+				ZSort myZSort = legend.getZSort();
+				if (myZSort == null) {
+					myZSort = new ZSort(legend);
+				}
+				SymbolLevelsWindow sl = new SymbolLevelsWindow(myZSort);
+				PluginServices.getMDIManager().addWindow(sl);
+				zSort = sl.getZSort();
+			}
+		}else if (c.equals(txtLabel)){
+			getSymbolPreviewPanel().getSymbol().setDescription(txtLabel.getText());
+		}
+	}
+
+}
\ No newline at end of file

Property changes on: tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/app/project/documents/view/legend/gui/SingleSymbol.java
___________________________________________________________________
Added: svn:eol-style
   + native
Added: svn:keywords
   + Author Date Id Revision

Index: tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/app/project/documents/view/legend/gui/AttrInTableLabeling.java
===================================================================
--- tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/app/project/documents/view/legend/gui/AttrInTableLabeling.java	(revision 0)
+++ tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/app/project/documents/view/legend/gui/AttrInTableLabeling.java	(revision 38653)
@@ -0,0 +1,544 @@
+/* gvSIG. Sistema de Informaci�n Geogr�fica de la Generalitat Valenciana
+ *
+ * Copyright (C) 2005 IVER T.I. and Generalitat Valenciana.
+ *
+ * This program is free software; you can redistribute it and/or
+ * modify it under the terms of the GNU General Public License
+ * as published by the Free Software Foundation; either version 2
+ * of the License, or (at your option) any later version.
+ *
+ * This program is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
+ * GNU General Public License for more details.
+ *
+ * You should have received a copy of the GNU General Public License
+ * along with this program; if not, write to the Free Software
+ * Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA  02111-1307,USA.
+ *
+ * For more information, contact:
+ *
+ *  Generalitat Valenciana
+ *   Conselleria d'Infraestructures i Transport
+ *   Av. Blasco Ib��ez, 50
+ *   46010 VALENCIA
+ *   SPAIN
+ *
+ *      +34 963862235
+ *   gvsig@gva.es
+ *      www.gvsig.gva.es
+ *
+ *    or
+ *
+ *   IVER T.I. S.A
+ *   Salamanca 50
+ *   46005 Valencia
+ *   Spain
+ *
+ *   +34 963163400
+ *   dac@iver.es
+ */
+package org.gvsig.app.project.documents.view.legend.gui;
+
+import java.awt.Dimension;
+import java.awt.FlowLayout;
+import java.awt.Font;
+import java.awt.event.ActionEvent;
+import java.awt.event.ActionListener;
+import java.util.ArrayList;
+import java.util.Iterator;
+
+import javax.swing.BorderFactory;
+import javax.swing.ButtonGroup;
+import javax.swing.JButton;
+import javax.swing.JPanel;
+import javax.swing.JRadioButton;
+import javax.swing.JTextField;
+
+import org.gvsig.andami.PluginServices;
+import org.gvsig.andami.messages.NotificationManager;
+import org.gvsig.app.ApplicationLocator;
+import org.gvsig.app.gui.JComboBoxUnits;
+import org.gvsig.app.gui.panels.ColorChooserPanel;
+import org.gvsig.app.gui.styling.JComboBoxUnitsReferenceSystem;
+import org.gvsig.app.gui.utils.FontChooser;
+import org.gvsig.fmap.dal.DataTypes;
+import org.gvsig.fmap.dal.exception.DataException;
+import org.gvsig.fmap.dal.feature.FeatureAttributeDescriptor;
+import org.gvsig.fmap.dal.feature.FeatureType;
+import org.gvsig.fmap.mapcontext.MapContextLocator;
+import org.gvsig.fmap.mapcontext.layers.FLayer;
+import org.gvsig.fmap.mapcontext.layers.vectorial.FLyrVect;
+import org.gvsig.fmap.mapcontext.rendering.legend.styling.ILabelingStrategy;
+import org.gvsig.gui.beans.swing.GridBagLayoutPanel;
+import org.gvsig.gui.beans.swing.JBlank;
+import org.gvsig.symbology.fmap.mapcontext.rendering.legend.styling.AttrInTableLabelingStrategy;
+import org.gvsig.symbology.fmap.mapcontext.rendering.legend.styling.IAttrInTableLabelingStrategy;
+import org.gvsig.utils.swing.JComboBox;
+
+
+public class AttrInTableLabeling extends JPanel implements  ILabelingStrategyPanel{
+	private static final long serialVersionUID = 8229927418031917075L;
+	private static final String NO_FIELD_ITEM = "-- " +
+			PluginServices.getText(LabelingManager.class, "none") + " --";
+	private String[] fieldNames;
+	private String[] numericFieldNames;
+	private String[] integerFieldNames;
+
+	private JRadioButton rdBtnFixedHeight;
+	private JRadioButton rdBtnHeightField;
+	private JRadioButton rdBtnFixedColor;
+	private JRadioButton rdBtnColorField;
+	private JComboBox cmbTextField;
+	private JComboBox cmbHeightField;
+	private JComboBox cmbRotationField;
+	private JComboBoxUnits cmbUnits;
+	private JComboBoxUnitsReferenceSystem cmbReferenceSystem;
+	private JTextField txtHeightField;
+	private FLyrVect layer;
+
+	private ColorChooserPanel colorChooser;
+	private JComboBox cmbColorField;
+	private JButton chooseFontBut;
+	private Font labelFont;
+
+	public AttrInTableLabeling() {
+		labelFont =
+				MapContextLocator.getSymbolManager()
+						.getSymbolPreferences()
+						.getDefaultSymbolFont();
+		initialize();
+	}
+
+	private void initialize() {
+		setLayout(new FlowLayout(FlowLayout.LEFT, 10, 10));
+		GridBagLayoutPanel panel = new GridBagLayoutPanel();
+
+		GridBagLayoutPanel aux = new GridBagLayoutPanel();
+		aux.addComponent(PluginServices.getText(this, "field_to_be_labeled") + ":", getCmbTextField());
+		aux.addComponent(getRdBtnHeightField(), getCmbHeightField());
+		aux.addComponent(getRdBtnFixedHeight(), getTxtHeightField());
+		aux.addComponent(PluginServices.getText(this, "rotation_height") + ":", getCmbRotationField());
+		aux.addComponent(PluginServices.getText(this, "units") + ":", getCmbUnits());
+		aux.addComponent(PluginServices.getText(this,""),getCmbReferenceSystem());
+		panel.add(aux);
+
+		aux = new GridBagLayoutPanel();
+		aux.addComponent(getChooseFontBut(),new JBlank(20,20));
+		GridBagLayoutPanel aux2 = new GridBagLayoutPanel();
+		aux2.setBorder(BorderFactory.createTitledBorder(null,PluginServices.getText(this,"color")));
+		aux2.addComponent(getRdBtnFixedColor(),colorChooser = new ColorChooserPanel(true));
+		aux2.addComponent(getRdBtnColorField(),getCmbColorField());
+		aux.addComponent(aux2);
+
+		panel.add(new JBlank(20,20));
+		panel.add(aux);
+
+
+		add(panel);
+
+
+		ButtonGroup group = new ButtonGroup();
+		group.add(getRdBtnFixedHeight());
+		group.add(getRdBtnHeightField());
+
+		ButtonGroup colorGroup = new ButtonGroup();
+		colorGroup.add(getRdBtnFixedColor());
+		colorGroup.add(getRdBtnColorField());
+
+//		getRdBtnHeightField().setEnabled(true);
+	}
+
+	private JButton getChooseFontBut() {
+		if(chooseFontBut == null){
+			chooseFontBut = new JButton(PluginServices.getText(this,"font"));
+			chooseFontBut.setPreferredSize(new Dimension(80,10));
+			chooseFontBut.addActionListener(new ActionListener(){
+
+				public void actionPerformed(ActionEvent e) {
+					Font newFont;
+
+					newFont = FontChooser.showDialog("Choose Font", labelFont);
+					if (newFont == null) {
+						return;
+					}
+
+					labelFont = newFont;
+				}
+
+			});
+		}
+		return chooseFontBut;
+	}
+
+	private JRadioButton getRdBtnFixedHeight() {
+		if (rdBtnFixedHeight == null) {
+			rdBtnFixedHeight = new JRadioButton(PluginServices.getText(this, "fixed_height") + ":");
+			rdBtnFixedHeight.setSelected(false);
+			rdBtnFixedHeight.setName("RDFIXEDHEIGHT");
+		}
+
+		return rdBtnFixedHeight;
+	}
+
+	private JRadioButton getRdBtnHeightField() {
+		if (rdBtnHeightField == null) {
+			rdBtnHeightField = new JRadioButton(PluginServices.getText(this, "text_height_field") + ":");
+			rdBtnHeightField.setSelected(true);
+			rdBtnHeightField.setName("RDHEIGHTFIELD");
+		}
+
+		return rdBtnHeightField;
+	}
+
+	private JRadioButton getRdBtnFixedColor() {
+		if (rdBtnFixedColor == null) {
+			rdBtnFixedColor = new JRadioButton(PluginServices.getText(this, "fixed_color") + ":");
+			rdBtnFixedColor.setSelected(false);
+			rdBtnFixedColor.setName("RDFIXEDCOLOR");
+		}
+
+		return rdBtnFixedColor;
+	}
+
+	private JRadioButton getRdBtnColorField() {
+		if (rdBtnColorField == null) {
+			rdBtnColorField = new JRadioButton(PluginServices.getText(this, "color_field") + ":");
+			rdBtnColorField.setSelected(true);
+			rdBtnColorField.setName("RDCOLORFIELD");
+		}
+
+		return rdBtnColorField;
+	}
+
+	private JComboBoxUnits getCmbUnits() {
+		if (cmbUnits == null) {
+			cmbUnits = new JComboBoxUnits();
+			cmbUnits.setSelectedIndex(
+					ApplicationLocator.getManager().getPreferences().getInt("DefaultDistanceUnits", 0)
+			);
+			cmbUnits.setName("CMBUNITS");
+		}
+
+		return cmbUnits;
+	}
+
+	private JComboBoxUnitsReferenceSystem getCmbReferenceSystem(){
+		if(cmbReferenceSystem == null){
+			cmbReferenceSystem = new JComboBoxUnitsReferenceSystem();
+			cmbReferenceSystem.setName("CMBREFSYST");
+		}
+		return cmbReferenceSystem;
+	}
+
+	private JComboBox getCmbColorField() {
+		if (cmbColorField == null) {
+			cmbColorField = new JComboBox();
+			cmbColorField.setName("CMBCOLOR");
+		}
+
+		return cmbColorField;
+	}
+
+	private void refreshControls() {
+		// When the attributes are in the table -----
+		//      field with the text
+		refreshCmbTextField();
+
+		//      field with the rotation
+		refreshCmbRotationField();
+
+		//      field with the text height or the text size
+		refreshTextHeight();
+
+		//		the text size unit name
+		refreshCmbUnits();
+
+		refreshCmbRefSystem();
+		//		the font for the text
+		refreshFont();
+		//		the color for the font
+		refreshColorFont();
+	}
+
+	private JComboBox getCmbRotationField() {
+		if (cmbRotationField == null) {
+			cmbRotationField = new JComboBox();
+			cmbRotationField.setPreferredSize(new Dimension(200, 20));
+			cmbRotationField.setName("CMBROTATIONFIELD");
+		}
+		return cmbRotationField;
+	}
+
+	private JComboBox getCmbHeightField() {
+		if (cmbHeightField == null) {
+			cmbHeightField = new JComboBox();
+			cmbHeightField.setPreferredSize(new Dimension(200, 20));
+			cmbHeightField.setName("CMBHEIGHTFIELD");
+		}
+		return cmbHeightField;
+	}
+
+	private JComboBox getCmbTextField() {
+		if (cmbTextField == null) {
+			cmbTextField = new JComboBox();
+			cmbTextField.setPreferredSize(new Dimension(200, 20));
+			cmbTextField.setName("CMBTEXTFIELD");
+		}
+		return cmbTextField;
+	}
+
+
+	private JTextField getTxtHeightField() {
+		if (txtHeightField == null) {
+			txtHeightField = new JTextField(10);
+			txtHeightField.setText("10");
+			txtHeightField.setName("TXTHEIGHTFIELD");
+		}
+
+		return txtHeightField;
+	}
+
+	public void actionPerformed(ActionEvent e) {
+		// TODO Auto-generated method stub
+		throw new Error("Not yet implemented!");
+
+	}
+	private ColorChooserPanel getColorChooser() {
+		if (colorChooser == null){
+			colorChooser = new ColorChooserPanel(true);
+		}
+		return colorChooser;
+	}
+
+	public ILabelingStrategy getLabelingStrategy() {
+		// user selected to define each label attributes from values
+		// contained in the table for each feature row.
+
+		double fixedSize;
+		try {
+			fixedSize = Double.parseDouble(getTxtHeightField().getText());
+		} catch (Exception e) {
+			fixedSize = 10;
+		}
+		AttrInTableLabelingStrategy strategy = new AttrInTableLabelingStrategy();
+		strategy.setLayer(layer);
+
+		if(getCmbHeightField().getItemCount() > 0 && !rdBtnFixedHeight.isSelected()) {
+			strategy.setHeightField(
+				(String) getCmbHeightField().getSelectedItem());
+		}
+		if(getCmbRotationField().getItemCount() > 0) {
+			if(!getCmbRotationField().getSelectedItem().equals(NO_FIELD_ITEM)) {
+				strategy.setRotationField(
+						(String) getCmbRotationField().getSelectedItem());
+			} else {
+				strategy.setRotationField(null);
+			}
+		}
+
+		if(getCmbTextField().getItemCount() > 0) {
+			strategy.setTextField(
+				(String) getCmbTextField().getSelectedItem());
+		}
+
+		strategy.setUsesFixedSize(getRdBtnFixedHeight().isSelected());
+		strategy.setFixedSize(fixedSize);
+
+		if(getCmbUnits().getItemCount() > 0) {
+			strategy.setUnit(getCmbUnits().getSelectedUnitIndex());
+		}
+		if(getCmbReferenceSystem().getItemCount() > 0) {
+			strategy.setReferenceSystem(getCmbReferenceSystem().getSelectedIndex());
+		}
+
+		strategy.setUsesFixedColor(getRdBtnFixedColor().isSelected());
+		strategy.setFixedColor(getColorChooser().getColor());
+
+		if(getCmbColorField().getItemCount() > 0 && !rdBtnFixedColor.isSelected()) {
+			strategy.setColorField((String) getCmbColorField().getSelectedItem());
+		}
+
+
+		strategy.setFont(labelFont);
+		return strategy;
+	}
+
+	public void setModel(FLayer layer, ILabelingStrategy str) {
+		this.layer = (FLyrVect) layer;
+		// to allow the labeling of non-FLyrVect layers
+		if (layer instanceof FLyrVect) {
+			FLyrVect lv = (FLyrVect) layer;
+			try {
+				FeatureType featureType = lv.getFeatureStore()
+						.getDefaultFeatureType();
+				fieldNames = new String[featureType.size()];
+				Iterator<FeatureAttributeDescriptor> iterator = featureType
+						.iterator();
+				ArrayList<String> l = new ArrayList<String>();
+				ArrayList<String> lColors = new ArrayList<String>();
+				String name;
+				FeatureAttributeDescriptor descriptor;
+				while (iterator.hasNext()) {
+					descriptor = iterator.next();
+
+					name = descriptor.getName();
+					fieldNames[descriptor.getIndex()] = name;
+					switch (descriptor.getType()) {
+//					case DataTypes.DECIMAL:
+//					case DataTypes.NUMERIC:
+					case DataTypes.FLOAT:
+//					case DataTypes.REAL:
+					case DataTypes.DOUBLE:
+						l.add(name);
+						break;
+					case DataTypes.INT:
+//					case DataTypes.SMALLINT:
+//					case DataTypes.TINYINT:
+					case DataTypes.LONG:
+						lColors.add(name);
+						l.add(name);
+						break;
+					}
+				}
+				numericFieldNames = l.toArray(new String[l.size()]);
+				integerFieldNames = lColors.toArray(new String[lColors.size()]);
+			} catch (DataException e) {
+				NotificationManager.addError(PluginServices.getText(this, "accessing_file_structure"), e);
+			}
+			refreshControls();
+		}
+	}
+
+	private void refreshColorFont(){
+
+		getCmbColorField().removeAllItems();
+
+		boolean enabled = integerFieldNames.length>0;
+		getCmbColorField().setEnabled(enabled);
+		getRdBtnColorField().setEnabled(enabled);
+
+		if (!enabled) {
+			getRdBtnFixedColor().setSelected(true);
+		}
+
+		for (int i = 0; i < integerFieldNames.length; i++) {
+			getCmbColorField().addItem(integerFieldNames[i]);
+		}
+
+		if (layer.getLabelingStrategy() instanceof AttrInTableLabelingStrategy) {
+			IAttrInTableLabelingStrategy aux = (IAttrInTableLabelingStrategy) layer.getLabelingStrategy();
+			getRdBtnFixedColor().setSelected(aux.usesFixedColor());
+			getRdBtnColorField().setSelected(!aux.usesFixedColor());
+
+			String item = aux.getColorField();
+			getCmbColorField().setSelectedItem(item);
+			getColorChooser().setColor(aux.getFixedColor());
+		}
+	}
+
+	private void refreshFont(){
+
+		if (layer.getLabelingStrategy() instanceof AttrInTableLabelingStrategy) {
+			IAttrInTableLabelingStrategy aux = (IAttrInTableLabelingStrategy) layer.getLabelingStrategy();
+			labelFont = aux.getFont();
+		}
+	}
+
+	private void refreshCmbUnits() {
+
+		if (layer.getLabelingStrategy() instanceof AttrInTableLabelingStrategy) {
+			AttrInTableLabelingStrategy aux = (AttrInTableLabelingStrategy) layer.getLabelingStrategy();
+			getCmbUnits().setSelectedUnitIndex(aux.getUnit());
+		}
+	}
+
+	private void refreshCmbRefSystem() {
+
+		if (layer.getLabelingStrategy() instanceof AttrInTableLabelingStrategy) {
+			AttrInTableLabelingStrategy aux = (AttrInTableLabelingStrategy) layer.getLabelingStrategy();
+			getCmbReferenceSystem().setSelectedIndex(aux.getReferenceSystem());
+		}
+	}
+
+	private void refreshTextHeight() {
+		getCmbHeightField().removeAllItems();
+
+		boolean enabled = numericFieldNames.length>0;
+//		getCmbHeightField().setEnabled(enabled);
+//		getRdBtnHeightField().setEnabled(enabled);
+
+		if (!enabled) {
+			getRdBtnFixedHeight().setSelected(true);
+		}
+
+		for (int i = 0; i < numericFieldNames.length; i++) {
+			getCmbHeightField().addItem(numericFieldNames[i]);
+		}
+
+		if (layer.getLabelingStrategy() instanceof AttrInTableLabelingStrategy) {
+			IAttrInTableLabelingStrategy aux = (IAttrInTableLabelingStrategy) layer.getLabelingStrategy();
+			getTxtHeightField().setText(String.valueOf(aux.getFixedSize()));
+			getRdBtnFixedHeight().setSelected(aux.usesFixedSize());
+			getRdBtnHeightField().setSelected(!aux.usesFixedSize());
+
+			String item = aux.getHeightField();
+			getCmbHeightField().setSelectedItem(item);
+
+		}
+
+	}
+
+	private void refreshCmbRotationField() {
+		getCmbRotationField().removeAllItems();
+		getCmbRotationField().addItem(NO_FIELD_ITEM);
+		for (int i = 0; i < numericFieldNames.length; i++) {
+			getCmbRotationField().addItem(numericFieldNames[i]);
+		}
+
+		if (layer.getLabelingStrategy() instanceof AttrInTableLabelingStrategy) {
+			IAttrInTableLabelingStrategy aux = (IAttrInTableLabelingStrategy) layer.getLabelingStrategy();
+			String item = aux.getRotationField();
+			getCmbRotationField().setSelectedItem(item != null? item : NO_FIELD_ITEM);
+		}
+	}
+
+	private void refreshCmbTextField() {
+		getCmbTextField().removeAllItems();
+		for (int i = 0; i < fieldNames.length; i++) {
+			getCmbTextField().addItem(fieldNames[i]);
+		}
+
+		if (layer.getLabelingStrategy() instanceof AttrInTableLabelingStrategy) {
+			IAttrInTableLabelingStrategy aux = (IAttrInTableLabelingStrategy) layer.getLabelingStrategy();
+			String item = aux.getTextField();
+			getCmbTextField().setSelectedItem(item != null? item : NO_FIELD_ITEM);
+		}
+	}
+
+	public String getLabelingStrategyName() {
+		return PluginServices.getText(this, "label_attributes_defined_in_table");
+	}
+
+	public Class getLabelingStrategyClass() {
+		return AttrInTableLabelingStrategy.class;
+	}
+
+	public void setEnabled(boolean enabled) {
+		super.setEnabled(enabled);
+		getChooseFontBut().setEnabled(enabled);
+		getCmbColorField().setEnabled(enabled);
+		getCmbHeightField().setEnabled(enabled);
+		getCmbReferenceSystem().setEnabled(enabled);
+		getCmbRotationField().setEnabled(enabled);
+		getCmbTextField().setEnabled(enabled);
+		getCmbUnits().setEnabled(enabled);
+		getColorChooser().setEnabled(enabled);
+		getRdBtnColorField().setEnabled(enabled);
+		getRdBtnFixedColor().setEnabled(enabled);
+		getRdBtnFixedHeight().setEnabled(enabled);
+		getRdBtnHeightField().setEnabled(enabled);
+		getTxtHeightField().setEnabled(enabled);
+
+	}
+}
Index: tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/app/project/documents/view/legend/CreateSpatialIndexMonitorableTask.java
===================================================================
--- tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/app/project/documents/view/legend/CreateSpatialIndexMonitorableTask.java	(revision 0)
+++ tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/app/project/documents/view/legend/CreateSpatialIndexMonitorableTask.java	(revision 38653)
@@ -0,0 +1,182 @@
+/*
+ * Created on 03-may-2006
+ *
+ * gvSIG. Sistema de Informaci�n Geogr�fica de la Generalitat Valenciana
+ *
+ * Copyright (C) 2004 IVER T.I. and Generalitat Valenciana.
+ *
+ * This program is free software; you can redistribute it and/or
+ * modify it under the terms of the GNU General Public License
+ * as published by the Free Software Foundation; either version 2
+ * of the License, or (at your option) any later version.
+ *
+ * This program is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
+ * GNU General Public License for more details.
+ *
+ * You should have received a copy of the GNU General Public License
+ * along with this program; if not, write to the Free Software
+ * Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA  02111-1307,USA.
+ *
+ * For more information, contact:
+ *
+ *  Generalitat Valenciana
+ *   Conselleria d'Infraestructures i Transport
+ *   Av. Blasco Ib��ez, 50
+ *   46010 VALENCIA
+ *   SPAIN
+ *
+ *      +34 963862235
+ *   gvsig@gva.es
+ *      www.gvsig.gva.es
+ *
+ *    or
+ *
+ *   IVER T.I. S.A
+ *   Salamanca 50
+ *   46005 Valencia
+ *   Spain
+ *
+ *   +34 963163400
+ *   dac@iver.es
+ */
+/* CVS MESSAGES:
+*
+* $Id$
+* $Log$
+* Revision 1.4  2007-07-30 12:56:04  jaume
+* organize imports, java 5 code downgraded to 1.4 and added PictureFillSymbol
+*
+* Revision 1.3  2007/05/15 07:22:56  cesar
+* Add the finished method for execution from Event Dispatch Thread
+*
+* Revision 1.2  2007/03/06 16:37:08  caballero
+* Exceptions
+*
+* Revision 1.1  2006/09/15 10:41:30  caballero
+* extensibilidad de documentos
+*
+* Revision 1.2  2006/05/22 10:35:41  fjp
+* Monitorable tasks easy
+*
+* Revision 1.1  2006/05/08 15:41:06  azabala
+* added rtree spatial indexing capabilities
+*
+*
+*/
+package org.gvsig.app.project.documents.view.legend;
+
+import org.gvsig.andami.PluginServices;
+import org.gvsig.fmap.dal.exception.DataException;
+import org.gvsig.fmap.dal.feature.FeatureStore;
+import org.gvsig.fmap.mapcontext.layers.vectorial.FLyrVect;
+import org.gvsig.utils.swing.threads.CancellableMonitorable;
+import org.gvsig.utils.swing.threads.DefaultCancellableMonitorable;
+import org.gvsig.utils.swing.threads.IMonitorableTask;
+
+
+public class CreateSpatialIndexMonitorableTask implements IMonitorableTask{
+
+	String MAIN_MESSAGE;
+	String HULL_MESSAGE = PluginServices.getText(this, "Indexando");
+	String OF = "de";
+
+	FLyrVect layer;
+	/**
+	 * It monitors advance of indexing process
+	 */
+	private CancellableMonitorable cancelMonitor = null;
+	/**
+	 * flag to tell if the process is finished
+	 */
+	private boolean finished = false;
+
+	/**
+	 * Default constructor
+	 * @throws DriverIOException
+	 * @throws DriverException
+	 */
+	public CreateSpatialIndexMonitorableTask(FLyrVect layer)
+			throws DataException {
+		this.layer = layer;
+		MAIN_MESSAGE = PluginServices.getText(this, "Indexando_espacialmente") +
+								layer.getName();
+//		cancelMonitor = createCancelMonitor();
+	}
+
+	/**
+	 * Creates a CancellableMonitorable instance to monitor
+	 * progress and to cancel the process.
+	 * @return
+	 * @throws DriverIOException
+	 * @throws DriverException
+	 */
+//	private CancellableMonitorable createCancelMonitor()
+//				throws ReadException {
+//		DefaultCancellableMonitorable monitor =
+//			new DefaultCancellableMonitorable();
+//		monitor.setInitialStep(0);
+//		monitor.setDeterminatedProcess(true);
+//		int numSteps = ((FLyrVect)layer).getFeatureStore().getDataCollection().size();
+//		monitor.setFinalStep(numSteps);
+//		return monitor;
+//	}
+
+	public void run() throws Exception {
+		FeatureStore fs=(layer).getFeatureStore();
+		//TODO comentado para que compile
+//		fs.createIndex(fs.getDefaultFeatureType());
+		finished = true;
+	}
+
+	public int getInitialStep() {
+		return cancelMonitor.getInitialStep();
+	}
+
+	public int getFinishStep() {
+		return cancelMonitor.getFinalStep();
+	}
+
+	public int getCurrentStep() {
+		return cancelMonitor.getCurrentStep();
+	}
+
+	public String getStatusMessage() {
+		return MAIN_MESSAGE;
+	}
+
+	public String getNote() {
+		return HULL_MESSAGE + " " +
+		getCurrentStep()+ " " +
+		OF  + " "+
+		getFinishStep();
+	}
+	//FIXME Borrar los ficheros de indice en caso de cancelacion
+	public void cancel() {
+		((DefaultCancellableMonitorable) cancelMonitor).setCanceled(true);
+	}
+	/**
+	 * Tells if it is a defined process (we know its number of steps)
+	 */
+	public boolean isDefined() {
+		return true;
+	}
+	public boolean isCanceled() {
+		return cancelMonitor.isCanceled();
+	}
+
+	public boolean isFinished() {
+		return finished;
+	}
+
+	/* (non-Javadoc)
+	 * @see com.iver.utiles.swing.threads.IMonitorableTask#finished()
+	 */
+	public void finished() {
+		// TODO Auto-generated method stub
+
+	}
+}//CreateSpatialIndexMonitorableTask
+
+

Property changes on: tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/app/project/documents/view/legend/CreateSpatialIndexMonitorableTask.java
___________________________________________________________________
Added: svn:keywords
   + Author Date Id Revision
Added: svn:eol-style
   + native

Index: tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/app/project/documents/view/legend/edition/gui/PanelEditInterval.java
===================================================================
--- tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/app/project/documents/view/legend/edition/gui/PanelEditInterval.java	(revision 0)
+++ tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/app/project/documents/view/legend/edition/gui/PanelEditInterval.java	(revision 38653)
@@ -0,0 +1,244 @@
+/*
+ * Created on 24-may-2004
+ *
+ * To change the template for this generated file go to
+ * Window&gt;Preferences&gt;Java&gt;Code Generation&gt;Code and Comments
+ */
+/* gvSIG. Sistema de Informaci�n Geogr�fica de la Generalitat Valenciana
+ *
+ * Copyright (C) 2004 IVER T.I. and Generalitat Valenciana.
+ *
+ * This program is free software; you can redistribute it and/or
+ * modify it under the terms of the GNU General Public License
+ * as published by the Free Software Foundation; either version 2
+ * of the License, or (at your option) any later version.
+ *
+ * This program is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
+ * GNU General Public License for more details.
+ *
+ * You should have received a copy of the GNU General Public License
+ * along with this program; if not, write to the Free Software
+ * Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA  02111-1307,USA.
+ *
+ * For more information, contact:
+ *
+ *  Generalitat Valenciana
+ *   Conselleria d'Infraestructures i Transport
+ *   Av. Blasco Ib��ez, 50
+ *   46010 VALENCIA
+ *   SPAIN
+ *
+ *      +34 963862235
+ *   gvsig@gva.es
+ *      www.gvsig.gva.es
+ *
+ *    or
+ *
+ *   IVER T.I. S.A
+ *   Salamanca 50
+ *   46005 Valencia
+ *   Spain
+ *
+ *   +34 963163400
+ *   dac@iver.es
+ */
+package org.gvsig.app.project.documents.view.legend.edition.gui;
+
+
+import javax.swing.JButton;
+import javax.swing.JLabel;
+import javax.swing.JOptionPane;
+import javax.swing.JPanel;
+import javax.swing.JTextField;
+
+import org.gvsig.andami.PluginServices;
+import org.gvsig.andami.ui.mdiManager.IWindow;
+import org.gvsig.andami.ui.mdiManager.WindowInfo;
+import org.gvsig.fmap.mapcontext.rendering.legend.IInterval;
+import org.gvsig.symbology.fmap.mapcontext.rendering.legend.impl.FInterval;
+
+
+
+/**
+ * DOCUMENT ME!
+ *
+ * @author fjp To change the template for this generated type comment go to
+ *         Window&gt;Preferences&gt;Java&gt;Code Generation&gt;Code and
+ *         Comments
+*/
+public class PanelEditInterval extends JPanel implements IWindow  {
+	private JButton jButton = null;
+	//private FIntervalCellEditor intervaleditor;
+	private JPanel jPanel = null;
+	private JPanel jPanel1 = null;
+	private JLabel jLabel = null;
+	private JTextField m_txtMin1 = null;
+	private JPanel jPanel2 = null;
+	private JLabel jLabel1 = null;
+	private JTextField m_txtMax1 = null;
+	private boolean ok=false;
+	/**
+     * This is the default constructor
+     */
+    public PanelEditInterval() {
+        super();
+        initialize();
+		//intervaleditor=ice;
+    }
+
+    /**
+     * DOCUMENT ME!
+     *
+     * @param i DOCUMENT ME!
+     */
+    public void setFInterval(IInterval i) {
+    	ok=false;
+		if (i instanceof FInterval){
+
+			m_txtMin1.setText(String.valueOf(((FInterval)i).getMin()));
+			m_txtMax1.setText(String.valueOf(((FInterval)i).getMax()));
+		}
+	}
+
+    /**
+     * DOCUMENT ME!
+     *
+     * @return DOCUMENT ME!
+     */
+    public FInterval getFInterval() {
+		double from=0;
+		double to=0;
+		try{
+        from = Double.parseDouble(m_txtMin1.getText());
+        to =Double.parseDouble(m_txtMax1.getText());
+
+		}catch (NumberFormatException e) {
+			JOptionPane.showMessageDialog(null, PluginServices.getText(this,"Formato_de_numero_erroneo")+".");
+		}
+		FInterval i = new FInterval(from, to);
+        return i;
+    }
+
+    /**
+     * This method initializes this
+     */
+    private void initialize() {
+        this.setSize(316, 124);
+		this.add(getJPanel1(), null);
+		this.add(getJPanel2(), null);
+		this.add(getJPanel(), null);
+
+
+    }
+
+	public WindowInfo getWindowInfo() {
+		WindowInfo m_viewinfo = new WindowInfo(WindowInfo.MODALDIALOG);
+		m_viewinfo.setTitle(PluginServices.getText(this, "Intervalo"));
+		m_viewinfo.setWidth(this.getWidth());
+		m_viewinfo.setHeight(this.getHeight());
+		return m_viewinfo;
+	}
+
+	/**
+	 * This method initializes jButton
+	 *
+	 * @return javax.swing.JButton
+	 */
+	private JButton getJButton() {
+		if (jButton == null) {
+			jButton = new JButton();
+			jButton.setText("aceptar");
+			jButton.setPreferredSize(new java.awt.Dimension(90,26));
+			jButton.addActionListener(new java.awt.event.ActionListener() {
+				public void actionPerformed(java.awt.event.ActionEvent e) {
+					//intervaleditor.setCurrentInterval(getFInterval());
+					ok=true;
+					PluginServices.getMDIManager().closeWindow(PanelEditInterval.this);
+				}
+			});
+		}
+		return jButton;
+	}
+	public boolean isOK(){
+		return ok;
+	}
+	/**
+	 * This method initializes jPanel
+	 *
+	 * @return javax.swing.JPanel
+	 */
+	private JPanel getJPanel() {
+		if (jPanel == null) {
+			jPanel = new JPanel();
+			jPanel.setPreferredSize(new java.awt.Dimension(140,36));
+			jPanel.add(getJButton(), null);
+		}
+		return jPanel;
+	}
+
+	/**
+	 * This method initializes jPanel1
+	 *
+	 * @return javax.swing.JPanel
+	 */
+	private JPanel getJPanel1() {
+		if (jPanel1 == null) {
+			jLabel = new JLabel();
+			jLabel.setText("Valor minimo");
+			jPanel1 = new JPanel();
+			jPanel1.add(jLabel, null);
+			jPanel1.add(getM_txtMin1(), null);
+
+		}
+		return jPanel1;
+	}
+
+	/**
+	 * This method initializes jTextField
+	 *
+	 * @return javax.swing.JTextField
+	 */
+	private JTextField getM_txtMin1() {
+		if (m_txtMin1 == null) {
+			m_txtMin1 = new JTextField();
+			m_txtMin1.setPreferredSize(new java.awt.Dimension(100,20));
+		}
+		return m_txtMin1;
+	}
+
+	/**
+	 * This method initializes jPanel2
+	 *
+	 * @return javax.swing.JPanel
+	 */
+	private JPanel getJPanel2() {
+		if (jPanel2 == null) {
+			jLabel1 = new JLabel();
+			jLabel1.setText("Valor maximo");
+			jPanel2 = new JPanel();
+			jPanel2.add(jLabel1, null);
+			jPanel2.add(getM_txtMax1(), null);
+
+		}
+		return jPanel2;
+	}
+
+	/**
+	 * This method initializes jTextField
+	 *
+	 * @return javax.swing.JTextField
+	 */
+	private JTextField getM_txtMax1() {
+		if (m_txtMax1 == null) {
+			m_txtMax1 = new JTextField();
+			m_txtMax1.setPreferredSize(new java.awt.Dimension(100,20));
+		}
+		return m_txtMax1;
+	}
+	public Object getWindowProfile() {
+		return WindowInfo.DIALOG_PROFILE;
+	}
+
+}  //  @jve:decl-index=0:visual-constraint="10,10"

Property changes on: tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/app/project/documents/view/legend/edition/gui/PanelEditInterval.java
___________________________________________________________________
Added: svn:keywords
   + Author Date Id Revision
Added: svn:eol-style
   + native

Index: tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/app/project/documents/view/legend/edition/gui/PreviewIcon.java
===================================================================
--- tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/app/project/documents/view/legend/edition/gui/PreviewIcon.java	(revision 0)
+++ tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/app/project/documents/view/legend/edition/gui/PreviewIcon.java	(revision 38653)
@@ -0,0 +1,80 @@
+package org.gvsig.app.project.documents.view.legend.edition.gui;
+import java.awt.Color;
+import java.awt.Graphics;
+import java.awt.Graphics2D;
+import java.awt.event.MouseListener;
+
+import javax.swing.ImageIcon;
+import javax.swing.JPanel;
+
+
+public class PreviewIcon extends JPanel {
+	private ImageIcon icon;
+	private boolean isSelected;
+
+	/**
+	 *
+	 */
+	public PreviewIcon() {
+		super();
+			initialize();
+	}
+
+
+	/**
+	 * This method initializes this
+	 *
+	 * @return void
+	 */
+	private void initialize() {
+        this.setSize(70, 52);
+
+	}
+	protected void paintComponent(Graphics g) {
+		super.paintComponent(g);
+		if (icon == null)
+			return;
+
+		Graphics2D g2 = (Graphics2D) g;
+		//g2.setRenderingHint(RenderingHints.KEY_ANTIALIASING, RenderingHints.VALUE_ANTIALIAS_ON);
+		//g.setClip(0,0,getWidth(), getHeight());
+		//Rectangle r = g.getClipBounds(); //getClipRect();
+		if (isSelected)
+			g2.setColor(Color.blue);
+		else
+			g2.setColor(Color.white);
+
+		//g2.setColor(color);
+		g2.fillRect(0,0,getWidth(),getHeight());
+		g2.drawImage(icon.getImage(),0,0,this);
+
+	}
+	public void setSelected(boolean b) {
+		isSelected=b;
+	}
+	public void setIcon(ImageIcon icon) {
+		this.icon=icon;
+		repaint();
+	}
+	public ImageIcon getIcon() {
+		return icon;
+	}
+
+	/* (non-Javadoc)
+	 * @see java.awt.Component#isShowing()
+	 */
+	public boolean isShowing() {
+		return true; // super.isShowing();
+	}
+
+
+	public boolean isSelected() {
+		return isSelected;
+	}
+
+
+	public synchronized void addMouseListener(MouseListener arg0) {
+		super.addMouseListener(arg0);
+
+	}
+}  //  @jve:visual-info  decl-index=0 visual-constraint="10,10"

Property changes on: tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/app/project/documents/view/legend/edition/gui/PreviewIcon.java
___________________________________________________________________
Added: svn:keywords
   + Author Date Id Revision
Added: svn:eol-style
   + native

Index: tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/app/project/documents/view/legend/edition/gui/IntervalCellEditor.java
===================================================================
--- tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/app/project/documents/view/legend/edition/gui/IntervalCellEditor.java	(revision 0)
+++ tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/app/project/documents/view/legend/edition/gui/IntervalCellEditor.java	(revision 38653)
@@ -0,0 +1,183 @@
+/* gvSIG. Sistema de Informaci�n Geogr�fica de la Generalitat Valenciana
+*
+* Copyright (C) 2004 IVER T.I. and Generalitat Valenciana.
+*
+* This program is free software; you can redistribute it and/or
+* modify it under the terms of the GNU General Public License
+* as published by the Free Software Foundation; either version 2
+* of the License, or (at your option) any later version.
+*
+* This program is distributed in the hope that it will be useful,
+* but WITHOUT ANY WARRANTY; without even the implied warranty of
+* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
+* GNU General Public License for more details.
+*
+* You should have received a copy of the GNU General Public License
+* along with this program; if not, write to the Free Software
+* Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA  02111-1307,USA.
+*
+* For more information, contact:
+*
+*  Generalitat Valenciana
+*   Conselleria d'Infraestructures i Transport
+*   Av. Blasco Ib��ez, 50
+*   46010 VALENCIA
+*   SPAIN
+*
+*      +34 963862235
+*   gvsig@gva.es
+*      www.gvsig.gva.es
+*
+*    or
+*
+*   IVER T.I. S.A
+*   Salamanca 50
+*   46005 Valencia
+*   Spain
+*
+*   +34 963163400
+*   dac@iver.es
+*/
+package org.gvsig.app.project.documents.view.legend.edition.gui;
+
+import java.awt.Color;
+import java.awt.Component;
+import java.awt.event.KeyAdapter;
+import java.awt.event.KeyEvent;
+import java.awt.event.MouseEvent;
+import java.awt.event.MouseListener;
+import java.util.ArrayList;
+import java.util.EventObject;
+import java.util.List;
+
+import javax.swing.JButton;
+import javax.swing.JTable;
+import javax.swing.event.CellEditorListener;
+import javax.swing.event.ChangeEvent;
+import javax.swing.table.TableCellEditor;
+
+import org.gvsig.andami.PluginServices;
+import org.gvsig.fmap.mapcontext.rendering.legend.IInterval;
+import org.gvsig.symbology.fmap.mapcontext.rendering.legend.impl.FInterval;
+
+
+
+/**
+ * Cell Editor de intervalos. Controla los eventos de edici�n que se realicen
+ * sobre la columna de intervalos.
+ *
+ * @author Vicente Caballero Navarro
+ */
+public class IntervalCellEditor extends JButton
+	implements TableCellEditor{
+
+	private static final long serialVersionUID = 2020808901328629215L;
+
+	private List listeners = new ArrayList();
+	private IInterval interval;
+	private PanelEditInterval editPanel;
+		/**
+	 * Crea un nuevo FIntervalCellEditor.
+	 */
+	public IntervalCellEditor() {
+		addMouseListener(new MouseListener(){
+
+			public void mouseClicked(MouseEvent e) {
+				if (e.getClickCount()==2){
+					if (interval instanceof IInterval){
+					editPanel.setFInterval(interval);
+					PluginServices.getMDIManager().addWindow(editPanel);
+					if (editPanel.isOK()){
+						interval = editPanel.getFInterval();
+						setBackground(Color.white);
+						setText(interval.toString());
+						stopCellEditing();
+					}
+					}
+				}
+			}
+
+			public void mouseEntered(MouseEvent e) {
+			}
+
+			public void mouseExited(MouseEvent e) {
+			}
+
+			public void mousePressed(MouseEvent e) {
+			}
+
+			public void mouseReleased(MouseEvent e) {
+			}
+			
+		});
+		addKeyListener(new KeyAdapter() {
+            public void keyReleased(KeyEvent e) {
+                if (e.getKeyCode() == KeyEvent.VK_ENTER){
+                    stopCellEditing();
+                }else if (e.getKeyCode() == KeyEvent.VK_ESCAPE){
+                    cancelCellEditing();
+                }
+            }
+        });
+		editPanel = new PanelEditInterval();
+		this.setBackground(Color.white);
+		
+	}
+
+	/**
+	 * Inserta el intervalo.
+	 *
+	 * @param i DOCUMENT ME!
+	 */
+	public void setCurrentInterval(FInterval i) {
+		interval = i;
+		this.setText(i.toString());
+	}
+
+	//Implement the one CellEditor method that AbstractCellEditor doesn't.
+	public Object getCellEditorValue() {
+		return interval;
+	}
+
+	//Implement the one method defined by TableCellEditor.
+	public Component getTableCellEditorComponent(JTable table, Object value,
+		boolean isSelected, int row, int column) {
+		interval = (IInterval) value;
+		this.setText(interval.toString());
+		editPanel.setFInterval(interval);
+		return this;
+	}
+
+	public void cancelCellEditing() {
+		for (int i = 0; i < listeners.size(); i++) {
+	        CellEditorListener l = (CellEditorListener) listeners.get(i);
+	        ChangeEvent evt = new ChangeEvent(this);
+	        l.editingCanceled(evt);
+	    }
+	}
+
+	public boolean stopCellEditing() {
+		for (int i = 0; i < listeners.size(); i++) {
+            CellEditorListener l = (CellEditorListener) listeners.get(i);
+            ChangeEvent evt = new ChangeEvent(this);
+            l.editingStopped(evt);
+        }
+        return true;
+	}
+
+	public boolean isCellEditable(EventObject anEvent) {
+		return true;
+	}
+
+	public boolean shouldSelectCell(EventObject anEvent) {
+		return true;
+	}
+
+	public void addCellEditorListener(CellEditorListener l) {
+		listeners.add(l);
+	}
+
+	public void removeCellEditorListener(CellEditorListener l) {
+		listeners.remove(l);
+	}
+}

Property changes on: tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/app/project/documents/view/legend/edition/gui/IntervalCellEditor.java
___________________________________________________________________
Added: svn:eol-style
   + native
Added: svn:keywords
   + Author Date Id Revision

Index: tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/app/project/documents/view/legend/edition/gui/ValueCellEditor.java
===================================================================
--- tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/app/project/documents/view/legend/edition/gui/ValueCellEditor.java	(revision 0)
+++ tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/app/project/documents/view/legend/edition/gui/ValueCellEditor.java	(revision 38653)
@@ -0,0 +1,231 @@
+/* gvSIG. Sistema de Informaci�n Geogr�fica de la Generalitat Valenciana
+ *
+ * Copyright (C) 2004 IVER T.I. and Generalitat Valenciana.
+ *
+ * This program is free software; you can redistribute it and/or
+ * modify it under the terms of the GNU General Public License
+ * as published by the Free Software Foundation; either version 2
+ * of the License, or (at your option) any later version.
+ *
+ * This program is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
+ * GNU General Public License for more details.
+ *
+ * You should have received a copy of the GNU General Public License
+ * along with this program; if not, write to the Free Software
+ * Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA  02111-1307,USA.
+ *
+ * For more information, contact:
+ *
+ *  Generalitat Valenciana
+ *   Conselleria d'Infraestructures i Transport
+ *   Av. Blasco Ib��ez, 50
+ *   46010 VALENCIA
+ *   SPAIN
+ *
+ *      +34 963862235
+ *   gvsig@gva.es
+ *      www.gvsig.gva.es
+ *
+ *    or
+ *
+ *   IVER T.I. S.A
+ *   Salamanca 50
+ *   46005 Valencia
+ *   Spain
+ *
+ *   +34 963163400
+ *   dac@iver.es
+ */
+package org.gvsig.app.project.documents.view.legend.edition.gui;
+
+import java.awt.Component;
+import java.awt.event.KeyAdapter;
+import java.awt.event.KeyEvent;
+import java.util.ArrayList;
+import java.util.EventObject;
+
+import javax.swing.JTable;
+import javax.swing.JTextField;
+import javax.swing.event.CellEditorListener;
+import javax.swing.event.ChangeEvent;
+import javax.swing.table.TableCellEditor;
+
+/**
+ * Cell Editor sobre los valores �nicos.
+ *
+ * @author Vicente Caballero Navarro
+ */
+public class ValueCellEditor extends JTextField implements TableCellEditor {
+	private ArrayList listeners = new ArrayList();
+	//private Value initialValue;
+
+	/**
+	 * Crea un nuevo FLabelCellEditor.
+	 */
+	public ValueCellEditor() {
+		addKeyListener(new KeyAdapter() {
+				public void keyReleased(KeyEvent e) {
+					if (e.getKeyCode() == KeyEvent.VK_ENTER) {
+						stopCellEditing();
+					} else if (e.getKeyCode() == KeyEvent.VK_ESCAPE) {
+						cancelCellEditing();
+					}
+				}
+			});
+	}
+
+	//Implement the one CellEditor method that AbstractCellEditor doesn't.
+	public Object getCellEditorValue() {
+		return getValue(getText());
+	}
+
+	//Implement the one method defined by TableCellEditor.
+	public Component getTableCellEditorComponent(JTable table, Object value,
+		boolean isSelected, int row, int column) {
+		//initialValue=(Value)value;
+		if (value == null) {
+			setText("");
+		} else {
+			setText(value.toString());
+		}
+
+		return this;
+	}
+
+	/**
+	 * @see javax.swing.CellEditor#cancelCellEditing()
+	 */
+	public void cancelCellEditing() {
+		//if (initialValue != null) {
+		//	setText(initialValue.toString());
+		//}
+
+		for (int i = 0; i < listeners.size(); i++) {
+			CellEditorListener l = (CellEditorListener) listeners.get(i);
+			ChangeEvent evt = new ChangeEvent(this);
+			l.editingCanceled(evt);
+		}
+	}
+
+	/**
+	 * @see javax.swing.CellEditor#stopCellEditing()
+	 */
+	public boolean stopCellEditing() {
+		for (int i = 0; i < listeners.size(); i++) {
+			CellEditorListener l = (CellEditorListener) listeners.get(i);
+			ChangeEvent evt = new ChangeEvent(this);
+			l.editingStopped(evt);
+		}
+
+		return true;
+	}
+
+	/**
+	 * @see javax.swing.CellEditor#isCellEditable(java.util.EventObject)
+	 */
+	public boolean isCellEditable(EventObject anEvent) {
+		return true;
+	}
+
+	/**
+	 * @see javax.swing.CellEditor#shouldSelectCell(java.util.EventObject)
+	 */
+	public boolean shouldSelectCell(EventObject anEvent) {
+		return true;
+	}
+
+	/**
+	 * @see javax.swing.CellEditor#addCellEditorListener(javax.swing.event.CellEditorListener)
+	 */
+	public void addCellEditorListener(CellEditorListener l) {
+		listeners.add(l);
+	}
+
+	/**
+	 * @see javax.swing.CellEditor#removeCellEditorListener(javax.swing.event.CellEditorListener)
+	 */
+	public void removeCellEditorListener(CellEditorListener l) {
+		listeners.remove(l);
+	}
+
+	/**
+	 * DOCUMENT ME!
+	 *
+	 * @param s DOCUMENT ME!
+	 *
+	 * @return DOCUMENT ME!
+	 */
+	private Object getValue(String s) {
+		Object val = null;
+		//Value cero = null;
+
+//		try {
+			try {
+				val = new Integer(s);//ValueFactory.createValueByType(s, Types.INTEGER);
+
+				return val;
+			} catch (NumberFormatException e) {
+			}
+
+			try {
+				val = new Long(s);//ValueFactory.createValueByType(s, Types.BIGINT);
+
+				return val;
+			} catch (NumberFormatException e) {
+			}
+
+			try {
+				val = new Float(s);//ValueFactory.createValueByType(s, Types.FLOAT);
+
+				return val;
+			} catch (NumberFormatException e) {
+			}
+
+			try {
+				val = new Double(s);//ValueFactory.createValueByType(s, Types.DOUBLE);
+
+				return val;
+			} catch (NumberFormatException e) {
+			}
+
+			val = s;//ValueFactory.createValueByType(s, Types.LONGVARCHAR);
+//		} catch (ParseException e) {
+//			e.printStackTrace();
+//		}
+
+		/*try {
+		   if (v instanceof DoubleValue) {
+		           val = ValueFactory.createValue(Double.parseDouble(s));
+		           cero = ValueFactory.createValue((double) 0);
+		   } else if (v instanceof StringValue) {
+		           val = ValueFactory.createValue(s);
+		           cero = ValueFactory.createValue((String) "");
+		   } else if (v instanceof LongValue) {
+		           val = ValueFactory.createValue(Long.parseLong(s));
+		           cero = ValueFactory.createValue((long) 0);
+		   } else if (v instanceof IntValue) {
+		           val = ValueFactory.createValue(Integer.parseInt(s));
+		           cero = ValueFactory.createValue((int) 0);
+		   } else if (v instanceof FloatValue) {
+		           val = ValueFactory.createValue(Float.parseFloat(s));
+		           cero = ValueFactory.createValue((float) 0);
+		   } else if (v instanceof ShortValue) {
+		           val = ValueFactory.createValue(Short.parseShort(s));
+		           cero = ValueFactory.createValue((short) 0);
+		   } else if (v instanceof BooleanValue) {
+		           val = ValueFactory.createValue(Boolean.getBoolean(s));
+		           cero = ValueFactory.createValue((boolean) false);
+		   } else if (v instanceof DateValue) {
+		           val = ValueFactory.createValue(Date.parse(s));
+		           cero = ValueFactory.createValue((Date) new Date());
+		   }
+		   } catch (NumberFormatException e) {
+		           ///JOptionPane.showMessageDialog(null, PluginServices...getText(this,"Formato de n�mero erroneo")+".");
+		           return cero;
+		   }
+		 */
+		return val;
+	}
+}

Property changes on: tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/app/project/documents/view/legend/edition/gui/ValueCellEditor.java
___________________________________________________________________
Added: svn:keywords
   + Author Date Id Revision
Added: svn:eol-style
   + native

Index: tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/app/project/documents/view/IContextMenuAction.java
===================================================================
--- tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/app/project/documents/view/IContextMenuAction.java	(revision 0)
+++ tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/app/project/documents/view/IContextMenuAction.java	(revision 38653)
@@ -0,0 +1,74 @@
+package org.gvsig.app.project.documents.view;
+
+
+/**
+ * Interface que deben de cumplir una acci�n aplicable dede un
+ * Menu contextual o popup.
+ * <br>
+ * Las acciones se deben registrar en el punto de extensi�n adecuado * 
+ * <br><br>
+ * Por lo general extender de la clase AbstractDocumentAction
+ * 
+ *  
+ * 
+ * @author Jose Manuel Viv� (Chema)
+ */
+
+public interface IContextMenuAction {
+	
+	/**
+	 * Dice si la acci�n es visible 
+	 * segun los documentos seleccionados
+	 * <br>
+	 * @param item elemento sobre el que se ha pulsado
+	 * @param selectedItems elementos seleccionados en el momento de pulsar
+	 * 
+	 */
+	public boolean isVisible(Object item, Object[] selectedItems);
+	
+	/**
+	 * Dice si la acci�n esta habilitada 
+	 * segun los documentos seleccionados
+	 * <br>
+	 * @param item elemento sobre el que se ha pulsado
+	 * @param selectedItems elementos seleccionados en el momento de pulsar
+	 * 
+	 */
+	public boolean isEnabled(Object item, Object[] selectedItems);
+	
+	/**
+	 * Ejecuta la acci�n sobre los documentos seleccionados
+	 * <br>
+	 * @param item elemento sobre el que se ha pulsado
+	 * @param selectedItems elementos seleccionados en el momento de pulsar
+	 * 
+	 */
+	public void execute(Object item, Object[] selectedItems);
+	
+	/**
+	 * Nombre del grupo al que pertenece la accion
+	 */
+	public String getGroup();
+	
+	/**
+	 * Orden del grupo al que pertenece la acci�n
+	 */
+	public int getGroupOrder();
+	
+	/**
+	 * Orden del elemento dentro del grupo
+	 */
+	public int getOrder();
+	
+	/**
+	 * Texto del elemento
+	 */
+	public String getText();
+	
+	/**
+	 * Descripci�n mas detallada de la acci�n
+	 * (se utilizar� como Tooltip)
+	 */
+	public String getDescription();	
+	
+}

Property changes on: tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/app/project/documents/view/IContextMenuAction.java
___________________________________________________________________
Added: svn:mime-type
   + text/plain

Index: tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/app/project/documents/view/metadata/gui/MetadataInfoManager.java
===================================================================
--- tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/app/project/documents/view/metadata/gui/MetadataInfoManager.java	(revision 0)
+++ tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/app/project/documents/view/metadata/gui/MetadataInfoManager.java	(revision 38653)
@@ -0,0 +1,142 @@
+/*
+ * Created on 31-ene-2005
+ *
+ * gvSIG. Sistema de Informaci�n Geogr�fica de la Generalitat Valenciana
+ *
+ * Copyright (C) 2004 IVER T.I. and Generalitat Valenciana.
+ *
+ * This program is free software; you can redistribute it and/or
+ * modify it under the terms of the GNU General Public License
+ * as published by the Free Software Foundation; either version 2
+ * of the License, or (at your option) any later version.
+ *
+ * This program is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
+ * GNU General Public License for more details.
+ *
+ * You should have received a copy of the GNU General Public License
+ * along with this program; if not, write to the Free Software
+ * Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA  02111-1307,USA.
+ */
+
+package org.gvsig.app.project.documents.view.metadata.gui;
+
+import java.awt.BorderLayout;
+
+import javax.swing.JOptionPane;
+
+import org.gvsig.andami.PluginServices;
+import org.gvsig.andami.messages.NotificationManager;
+import org.gvsig.app.project.documents.view.legend.gui.AbstractThemeManagerPage;
+import org.gvsig.fmap.mapcontext.layers.FLayer;
+import org.gvsig.gui.beans.swing.JBlank;
+import org.gvsig.metadata.swing.basic.api.JMetadataPanel;
+import org.gvsig.metadata.swing.basic.api.MetadataSwingLocator;
+import org.gvsig.metadata.swing.basic.api.MetadataSwingManager;
+import org.gvsig.tools.dynobject.exception.DynObjectValidateException;
+
+public class MetadataInfoManager extends AbstractThemeManagerPage {
+
+	/**
+	 * 
+	 */
+	private static final long serialVersionUID = 7432962479048597376L;
+	private JMetadataPanel metadataPanel;
+
+	/**
+	 * This is the default constructor.
+	 */
+	public MetadataInfoManager() {
+		super();
+		initialize();
+	}
+
+	private void initialize() {
+		this.setLayout(new BorderLayout());
+		this.add(new JBlank(5, 10), BorderLayout.WEST);
+		this.add(new JBlank(5, 10), BorderLayout.EAST);
+	}
+
+	/**
+	 * Sets the necessary properties in the panel. This properties are extracted
+	 * from the layer. With this properties fills the TextFields, ComboBoxes and
+	 * the rest of GUI components.
+	 * 
+	 * @param FLayer
+	 *            layer,
+	 */
+	public void setModel(FLayer layer) {
+		try {
+			MetadataSwingManager manager = MetadataSwingLocator
+					.getMetadataSwingManager();
+			this.metadataPanel = manager.createJMetadataPanel(layer);			
+			this.add(metadataPanel, BorderLayout.CENTER);
+
+		} catch (Exception e) {
+			NotificationManager.addError("Can't assign model", e);
+		}
+	}
+
+	public void acceptAction() {
+		if (metadataPanel == null) {
+			return;
+		}
+		saveMetadata();
+	}
+
+	private void saveMetadata() {
+		try {
+			this.metadataPanel.saveMetadata();
+		} catch (DynObjectValidateException e) {
+			JOptionPane.showMessageDialog(null, getInfoString(e),
+					"Metadata Validation Errors",
+					 JOptionPane.WARNING_MESSAGE);
+		}
+	}
+
+	private String getInfoString(DynObjectValidateException e) {
+		StringBuffer buffer = new StringBuffer();
+
+		buffer.append("<html>");
+		buffer.append("<body>");
+		buffer.append("<h2>Metadata values could not be stored due to the following errors:'")
+				.append(this.metadataPanel.getMetadata().getDynClass()
+						.getName()).append("'</h2>");
+		buffer.append("<p>");
+		buffer.append("<br>");
+		buffer.append("<ol>");
+		buffer.append("  " + e.getLocalizedMessageStack());
+		buffer.append("</ol>");
+		buffer.append("</p>");
+		buffer.append("</body>");
+		buffer.append("</html>");
+
+		return buffer.toString().replace("\n", "<br/>");
+	}
+
+	public void cancelAction() {
+		// does nothing
+	}
+
+	/**
+	 * When we press the apply button, sets the new properties of the layer that
+	 * the user modified using the UI components
+	 */
+	public void applyAction() {
+		if (metadataPanel == null) {
+			return;
+		}
+		saveMetadata();
+	}
+
+	/*
+	 * (non-Javadoc)
+	 * 
+	 * @see java.awt.Component#getName()
+	 */
+	public String getName() {
+		return PluginServices.getText(this, "_Metadata");
+	}
+
+}
Index: tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/app/project/documents/view/ListSelectorListener.java
===================================================================
--- tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/app/project/documents/view/ListSelectorListener.java	(revision 0)
+++ tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/app/project/documents/view/ListSelectorListener.java	(revision 38653)
@@ -0,0 +1,71 @@
+/* gvSIG. Sistema de Informaci�n Geogr�fica de la Generalitat Valenciana
+ *
+ * Copyright (C) 2004 IVER T.I. and Generalitat Valenciana.
+ *
+ * This program is free software; you can redistribute it and/or
+ * modify it under the terms of the GNU General Public License
+ * as published by the Free Software Foundation; either version 2
+ * of the License, or (at your option) any later version.
+ *
+ * This program is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
+ * GNU General Public License for more details.
+ *
+ * You should have received a copy of the GNU General Public License
+ * along with this program; if not, write to the Free Software
+ * Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA  02111-1307,USA.
+ *
+ * For more information, contact:
+ *
+ *  Generalitat Valenciana
+ *   Conselleria d'Infraestructures i Transport
+ *   Av. Blasco Ib��ez, 50
+ *   46010 VALENCIA
+ *   SPAIN
+ *
+ *      +34 963862235
+ *   gvsig@gva.es
+ *      www.gvsig.gva.es
+ *
+ *    or
+ *
+ *   IVER T.I. S.A
+ *   Salamanca 50
+ *   46005 Valencia
+ *   Spain
+ *
+ *   +34 963163400
+ *   dac@iver.es
+ */
+package org.gvsig.app.project.documents.view;
+
+/**
+ * Interfaz invocada por el FPanelExtentSelector cuando el usuario ha seleccionado al
+ * menos un elemento y pulsa el bot�n aceptar
+ *
+ * @author $author$
+ * @version $Revision$
+ */
+public interface ListSelectorListener {
+    /**
+     * M�todo invocado cuando el usuario pulsa aceptar y hay algo seleccionado
+     *
+     * @param indices Array con los �ndices de los elementos seleccionados
+     */
+    public void indexesSelected(int[] indices);
+
+    /**
+     * DOCUMENT ME!
+     *
+     * @param indices DOCUMENT ME!
+     */
+    public void indexesRemoved(int[] indices);
+
+    /**
+     * DOCUMENT ME!
+     *
+     * @param name DOCUMENT ME!
+     */
+    public void newElement(String name);
+}

Property changes on: tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/app/project/documents/view/ListSelectorListener.java
___________________________________________________________________
Added: svn:eol-style
   + native
Added: svn:keywords
   + Author Date Id Revision

Index: tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/app/project/documents/ProjectDocumentListener.java
===================================================================
--- tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/app/project/documents/ProjectDocumentListener.java	(revision 0)
+++ tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/app/project/documents/ProjectDocumentListener.java	(revision 38653)
@@ -0,0 +1,60 @@
+/* gvSIG. Sistema de Informaci�n Geogr�fica de la Generalitat Valenciana
+ *
+ * Copyright (C) 2004 IVER T.I. and Generalitat Valenciana.
+ *
+ * This program is free software; you can redistribute it and/or
+ * modify it under the terms of the GNU General Public License
+ * as published by the Free Software Foundation; either version 2
+ * of the License, or (at your option) any later version.
+ *
+ * This program is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
+ * GNU General Public License for more details.
+ *
+ * You should have received a copy of the GNU General Public License
+ * along with this program; if not, write to the Free Software
+ * Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA  02111-1307,USA.
+ *
+ * For more information, contact:
+ *
+ *  Generalitat Valenciana
+ *   Conselleria d'Infraestructures i Transport
+ *   Av. Blasco Ib��ez, 50
+ *   46010 VALENCIA
+ *   SPAIN
+ *
+ *      +34 963862235
+ *   gvsig@gva.es
+ *      www.gvsig.gva.es
+ *
+ *    or
+ *
+ *   IVER T.I. S.A
+ *   Salamanca 50
+ *   46005 Valencia
+ *   Spain
+ *
+ *   +34 963163400
+ *   dac@iver.es
+ */
+package org.gvsig.app.project.documents;
+
+import org.gvsig.andami.ui.mdiManager.IWindow;
+
+/**
+ * Listener para notificaci�n en los cambios de las vistas de un proyecto.
+ * 
+ * @author Nacho Brodin (nachobrodin@gmail.com)
+ *
+ */
+public interface ProjectDocumentListener {
+
+	/**
+	 * Evento lanzado cuando se crea una ventana de proyecto
+	 * @param  view
+	 *         Ventana creada
+	 */
+	public void windowCreated(IWindow window);
+
+}
Index: tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/app/project/documents/DocumentAction.java
===================================================================
--- tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/app/project/documents/DocumentAction.java	(revision 0)
+++ tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/app/project/documents/DocumentAction.java	(revision 38653)
@@ -0,0 +1,67 @@
+package org.gvsig.app.project.documents;
+
+import java.util.List;
+
+import org.gvsig.tools.extensionpoint.ExtensionSingleton;
+
+
+/**
+ * Interface que deben den cumplir las  acciones asociadas
+ * a un documento
+ * <br>
+ *  Las acciones de un documento se registraran  a traves
+ *  del metodo registerDocumentAction del ProjectFactory
+ *  <br><br>
+ * Por lo general extender de la clase AbstractDocumentAction
+ * 
+ *  
+ * 
+ */
+
+public interface DocumentAction extends ExtensionSingleton {
+
+	/**
+	 * Gets the unique identifier for this action.
+	 * 
+	 * @return id as String
+	 */
+	public String getId();
+
+	public boolean isVisible(Document document, List<Document> documents);
+	
+	public boolean isAvailable(Document document, List<Document> documents);
+	
+	public void execute(Document document, List<Document> documents);
+	
+	/**
+	 * Gets the group name for this action.
+	 * 
+	 * @return group name as String
+	 */
+	public DocumentActionGroup getGroup();
+	
+	/**
+	 * Representa el orden en el que se presentara la accion entre
+	 * elresto de acciones de este tipo documento alla donde estas se
+	 * presenten.
+	 * 
+	 * @return title as String 
+	 */
+	public int getOrder();
+	
+	/**
+	 * Returns a  phrase with the action title for this document.type.
+	 * 
+	 * @return description as String 
+	 */
+	public String getTitle();
+	
+	/**
+	 * Returns a  paragraph with the action description for this document 
+	 * type.
+	 * 
+	 * @return description as String 
+	 */
+	public String getDescription();	
+	
+}

Property changes on: tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/app/project/documents/DocumentAction.java
___________________________________________________________________
Added: svn:mime-type
   + text/plain

Index: tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/app/project/documents/AbstractDocumentManager.java
===================================================================
--- tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/app/project/documents/AbstractDocumentManager.java	(revision 0)
+++ tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/app/project/documents/AbstractDocumentManager.java	(revision 38653)
@@ -0,0 +1,265 @@
+/* gvSIG. Geographic Information System of the Valencian Government
+*
+* Copyright (C) 2007-2009 Infrastructures and Transports Department
+* of the Valencian Government (CIT)
+* 
+* This program is free software; you can redistribute it and/or
+* modify it under the terms of the GNU General Public License
+* as published by the Free Software Foundation; either version 2
+* of the License, or (at your option) any later version.
+* 
+* This program is distributed in the hope that it will be useful,
+* but WITHOUT ANY WARRANTY; without even the implied warranty of
+* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
+* GNU General Public License for more details.
+* 
+* You should have received a copy of the GNU General Public License
+* along with this program; if not, write to the Free Software
+* Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, 
+* MA  02110-1301, USA.
+* 
+*/
+
+/*
+* AUTHORS (In addition to CIT):
+* 2004-2009 IVER TI
+*   
+*/
+
+package org.gvsig.app.project.documents;
+
+import java.lang.reflect.Constructor;
+import java.util.ArrayList;
+import java.util.HashSet;
+import java.util.Iterator;
+import java.util.List;
+import java.util.Map;
+import java.util.Set;
+
+import javax.swing.ImageIcon;
+
+import org.slf4j.Logger;
+import org.slf4j.LoggerFactory;
+
+import org.gvsig.andami.PluginServices;
+import org.gvsig.andami.ui.mdiManager.IWindow;
+import org.gvsig.app.project.Project;
+import org.gvsig.app.project.documents.gui.IDocumentWindow;
+import org.gvsig.tools.dynobject.DynStruct;
+import org.gvsig.tools.extensionpoint.ExtensionBuilder;
+import org.gvsig.tools.persistence.PersistenceManager;
+import org.gvsig.tools.persistence.PersistentState;
+import org.gvsig.tools.persistence.exception.PersistenceException;
+
+
+
+/**
+ * Factory of ProjectDocument.
+ *
+ * @author 2005-         Vicente Caballero
+ * @author 2009-         Joaquin del Cerro
+ * 
+ */
+
+public abstract class AbstractDocumentManager implements DocumentManager {
+
+    private static final Logger logger = LoggerFactory.getLogger(AbstractDocumentManager.class);
+
+    /**
+     * Returns the type of document priority.
+     *
+     * This priority is used when order document factories in UI.
+     * 
+     * @return Priority.
+     */
+    public int getPriority() {
+        return 10;
+    }
+
+    /**
+     * Returns the icon for the type of document.
+     *
+     * @return Image.
+     */
+    public ImageIcon getIcon() {
+        return PluginServices.getIconTheme().get("document-icon-sel");
+    }
+
+    /**
+     * Returns the icon for the type of document when is selected
+     *
+     * @return Image.
+     */
+    public ImageIcon getIconSelected() {
+        return PluginServices.getIconTheme().get("document-icon");
+    }
+
+    /**
+     * Returns the title of type of document.
+     *
+     * @return String title for type of document
+     */
+    public String getTitle() {
+        return PluginServices.getText(this, "documento");
+    }
+
+    public AbstractDocument createDocumentByUser() {
+        return createDocument();
+    }
+
+    public Iterator<? extends Document> createDocumentsByUser() {
+        Set<AbstractDocument> doc = new HashSet<AbstractDocument>(1);
+        doc.add(createDocumentByUser());
+        return doc.iterator();
+    }
+
+    /**
+     * @see ExtensionBuilder
+     */
+    public Object create() {
+        return this;
+    }
+
+    /**
+     * @see ExtensionBuilder
+     */
+    public Object create(Object[] args) {
+        return this;
+    }
+
+    /**
+     * @see ExtensionBuilder
+     */
+    @SuppressWarnings("rawtypes")
+    public Object create(Map args) {
+        return this;
+    }
+
+    public IWindow getMainWindow(Document doc) {
+        return getMainWindow(doc, null);
+    }
+
+
+    /**
+     * Return true if the name exists to another document.
+     *
+     * @param project
+     * @param documentName
+     *
+     * @return True if the name exists.
+     * @deprecated use instead  project.getProjectDocument
+     */
+    public boolean existName(Project project, String documentName) {
+        return project.getDocument(documentName, getTypeName())!=null;
+    }
+
+    /**
+     * Return the class or interface for the documents managed by this factory.
+     * @return The document class;
+     */
+    @SuppressWarnings("rawtypes")
+    abstract protected Class getDocumentClass();
+
+    public Object createFromState(PersistentState state) throws PersistenceException {
+        Document doc = this.createDocument();
+        return doc;
+    }
+
+    public void loadFromState(PersistentState state, Object object) throws PersistenceException {
+        Document doc = (Document) object;
+        doc.loadFromState(state);
+    }
+
+    public void saveToState(PersistentState state, Object obj) throws PersistenceException {
+        Document doc = (Document) obj;
+        doc.saveToState(state);
+
+    }
+
+    @SuppressWarnings({ "rawtypes", "unchecked" })
+    public boolean manages(Class theClass) {
+        return this.getDocumentClass().isAssignableFrom(theClass);
+    }
+
+    @SuppressWarnings("rawtypes")
+    public boolean manages(PersistentState state) {
+        try {
+            Class theClass;
+            theClass = (Class) Class.forName(state.getTheClassName());
+            return manages(theClass);
+        } catch (ClassNotFoundException e) {
+            return false;
+        }
+    }
+
+    public List<DynStruct> getDefinitions() {
+        DynStruct definition = this.getDefinition(this.getDocumentClass().getName());
+        List<DynStruct> definitions = new ArrayList<DynStruct>();
+        definitions.add(definition);
+        return definitions;
+    }
+
+    public String getDomainName() {
+        return PersistenceManager.DEFAULT_DOMAIN_NAME;
+    }
+
+    public String getDomainURL() {
+        return PersistenceManager.DEFAULT_DOMAIN_URL;
+    }
+
+    @SuppressWarnings({ "unchecked", "rawtypes" })
+    public List getManagedClasses() {
+        List classes = new ArrayList();
+        classes.add(this.getDocumentClass());
+        return classes;
+    }
+
+    @SuppressWarnings("rawtypes")
+    public Class getManagedClass(Object object) {
+        return this.getDocumentClass();
+    }
+
+    @SuppressWarnings("rawtypes")
+    public Class getManagedClass(PersistentState state) {
+        return this.getDocumentClass();
+    }
+
+    @SuppressWarnings("rawtypes")
+    public Class getManagedClass(String name) {
+        return this.getDocumentClass();
+    }
+
+    @SuppressWarnings("rawtypes")
+    public String getManagedClassName(Object object) {
+        Class clazz = this.getManagedClass(object);
+        if (clazz != null){
+            return clazz.getName();
+        }
+        return null;
+    }
+
+    @SuppressWarnings("rawtypes")
+    protected IDocumentWindow createDocumentWindow(Document document) {
+        IDocumentWindow documentWindow = null;
+        Class windowClass = getMainWindowClass();
+
+        try {
+
+            try {
+                Constructor constructor;
+                constructor =
+                    windowClass.getConstructor(new Class[] { Document.class });
+                documentWindow =
+                    (IDocumentWindow) constructor
+                        .newInstance(new Object[] { document });
+            } catch (NoSuchMethodException e1) {
+                documentWindow = (IDocumentWindow) windowClass.newInstance();
+                documentWindow.setDocument(document);
+            }
+        } catch (Exception e) {
+            logger.warn("Can't create the document window.", e);
+            return null;
+        }
+        return documentWindow;
+    }
+}

Property changes on: tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/app/project/documents/AbstractDocumentManager.java
___________________________________________________________________
Added: svn:keywords
   + Author Date Id Revision
Added: svn:eol-style
   + native

Index: tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/app/project/documents/DefaultDocumentActionGroup.java
===================================================================
--- tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/app/project/documents/DefaultDocumentActionGroup.java	(revision 0)
+++ tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/app/project/documents/DefaultDocumentActionGroup.java	(revision 38653)
@@ -0,0 +1,33 @@
+package org.gvsig.app.project.documents;
+
+public class DefaultDocumentActionGroup implements DocumentActionGroup  {
+
+	private String title;
+	private String description;
+	private int order;
+	private String id;
+
+	public DefaultDocumentActionGroup(String id, String title, String description, int order) {
+		this.id = id;
+		this.title = title;
+		this.description = description;
+		this.order= order;
+	}
+	
+	public String getDescription() {
+		return this.description;
+	}
+
+	public int getOrder() {
+		return this.order;
+	}
+
+	public String getTitle() {
+		return this.title;
+	}
+
+	public String getId() {
+		return this.id;
+	}
+
+}

Property changes on: tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/app/project/documents/DefaultDocumentActionGroup.java
___________________________________________________________________
Added: svn:mime-type
   + text/plain

Index: tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/app/project/documents/Document.java
===================================================================
--- tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/app/project/documents/Document.java	(revision 0)
+++ tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/app/project/documents/Document.java	(revision 38653)
@@ -0,0 +1,127 @@
+package org.gvsig.app.project.documents;
+
+import java.beans.PropertyChangeListener;
+
+import org.gvsig.andami.ui.mdiManager.IWindow;
+import org.gvsig.app.project.Project;
+import org.gvsig.app.project.documents.gui.WindowLayout;
+import org.gvsig.tools.persistence.Persistent;
+
+public interface Document extends Persistent {
+
+	/**
+	 * Obtiene el nombre del elemento
+	 *
+	 * @return
+	 */
+	public String getName();
+
+	/**
+	 * Establece el nombre del elemento
+	 *
+	 * @param string
+	 */
+	public void setName(String string);
+
+	/**
+	 * Obtiene la fecha de creaci�n del elemento
+	 *
+	 * @return
+	 */
+	public String getCreationDate();
+
+	/**
+	 * Obtiene el propietario del elemento
+	 *
+	 * @return
+	 */
+	public String getOwner();
+
+	public String getTypeName();
+	
+	/**
+	 * Establece la fecha de creaci�n del elemento.
+	 *
+	 * @param string
+	 */
+	public void setCreationDate(String string);
+
+	/**
+	 * Establece el propietario del elemento
+	 *
+	 * @param string
+	 */
+	public void setOwner(String string);
+
+	/**
+	 * Obtiene los comentarios del proyecto
+	 *
+	 * @return
+	 */
+	public String getComment();
+
+	/**
+	 * Establece los comentarios del proyecto
+	 *
+	 * @param string
+	 */
+	public void setComment(String string);
+
+	public Project getProject();
+
+	public void setProject(Project project);
+	
+	/**
+	 * Locks this project element protecting it from deleting from the project.
+	 */
+	public abstract void lock();
+
+	/**
+	 * Unlocks this element. So, from now on, it can be removed from the project.
+	 */
+	public abstract void unlock();
+
+	/**
+	 * Tells whether if this project's element is locked/protected or not. A protected
+	 * element cannot be removed from the current project.
+	 *
+	 * @see <b>lock()</b> and <b>unlock()</b> methods.
+	 *
+	 * @return true if it is locked, false otherwise
+	 */
+	public abstract boolean isLocked();
+
+	public DocumentManager getFactory();
+
+	public boolean isModified();
+
+	public void setModified(boolean modified);
+
+	/**
+	 * Register a  ProjectDocumentListener.
+	 * @param  listener  ProjectDocumentListener
+	 */
+	public void addListener(ProjectDocumentListener listener);
+
+	/**
+	 * A�ade un listener para los cambios en las bounded properties
+	 *
+	 * @param listener
+	 */
+	public void addPropertyChangeListener(
+			PropertyChangeListener listener);
+
+	public void afterRemove();
+
+	public void afterAdd();
+
+	public WindowLayout getWindowLayout();
+	
+	public void setWindowLayout(WindowLayout layout) ;
+	
+	public IWindow getPropertiesWindow();
+	
+	public IWindow getMainWindow();
+	
+	
+}
\ No newline at end of file

Property changes on: tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/app/project/documents/Document.java
___________________________________________________________________
Added: svn:mime-type
   + text/plain

Index: tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/app/project/Project.java
===================================================================
--- tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/app/project/Project.java	(revision 0)
+++ tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/app/project/Project.java	(revision 38653)
@@ -0,0 +1,200 @@
+package org.gvsig.app.project;
+
+import java.awt.Color;
+import java.beans.PropertyChangeListener;
+import java.io.File;
+import java.io.InputStream;
+import java.io.OutputStream;
+import java.util.Iterator;
+import java.util.List;
+
+import org.cresques.cts.IProjection;
+
+import org.gvsig.app.project.documents.Document;
+import org.gvsig.fmap.mapcontext.layers.FLayer;
+import org.gvsig.tools.persistence.Persistent;
+import org.gvsig.tools.persistence.exception.PersistenceException;
+
+public interface Project extends Iterable<Document>,  Persistent{
+
+    public static final String FILE_EXTENSION = ".gvsproj";
+        
+	public void addPropertyChangeListener(PropertyChangeListener arg0);
+
+	/**
+	 * Return the creation date of the project
+	 *
+	 * @return
+	 */
+	public String getCreationDate();
+
+	/**
+	 * Return the name of the project
+	 *
+	 * @return
+	 */
+	public String getName();
+
+	/**
+	 * Set the name of he project.
+	 *
+	 * @param string
+	 */
+	public void setName(String name);
+
+	/**
+	 * Return the comments associateds with the project
+	 *
+	 * @return comments
+	 */
+	public String getComments();
+
+	/**
+	 * Set the comments associateds with the project
+	 *
+	 * @param comments as string
+	 */
+	public void setComments(String string);
+
+	/**
+	 * Retuen the modification date of the project.
+	 *
+	 * @return modification date as string
+	 */
+	public String getModificationDate();
+
+	/**
+	 * Return the author of the project,
+	 *
+	 * @return author as string
+	 */
+	public String getOwner();
+
+	/**
+	 * Sets the author of the project
+	 *
+	 * @param author name as string
+	 */
+	public void setOwner(String owner);
+
+	/**
+	 * Obtiene el color de selecci�n que se usar� en el proyecto
+	 *
+	 * @return
+	 */
+	public Color getSelectionColor();
+
+	/**
+	 * Sets the selecction color
+	 *
+	 * @param selection color as string
+	 */
+	public void setSelectionColor(String selectionColor);
+
+	/**
+	 * Sets the selecction color
+	 *
+	 * @param selection color as Color
+	 */
+	public void setSelectionColor(Color selectionColor);
+
+	public IProjection getProjection();
+
+	public void setProjection(IProjection projection);
+
+	/**
+	 * Sets the modified state of project.
+	 * 
+	 * Can't set to not modified.
+	 *
+	 * @param modified as boolean
+	 */
+	public void setModified(boolean modified);
+
+	public boolean hasChanged();
+
+	/**
+	 * Return a list of documents in the project.
+	 *
+	 * @return documents as List of IProjectDocument
+	 */
+	public List<Document> getDocuments();
+
+	/**
+	 * Return a list with all documents of especified type.
+	 *
+	 * @param type of document
+	 *
+	 * @return List of IProjectDocument
+	 */
+	public List<Document> getDocuments(String type);
+
+	/**
+	 * Adds a document to the project
+	 *
+	 * @param document as IProjectDocument
+	 */
+	public void add(Document document);
+
+	/**
+	 * Remove a document of the project
+	 *
+	 * @param document as IProjectDocument
+	 */
+	public void remove(Document doc);
+
+	public Iterator<Document> iterator();
+
+	public boolean isEmpty();
+
+	/**
+	 * Return the view that contains the especified layer.
+	 *
+	 * @param layer
+	 *
+	 * @return name of the view that contains the layer
+	 *
+	 * @throws RuntimeException 
+	 *             Si la capa que se pasa como par�metro no se encuentra en
+	 *             ninguna vista
+	 */
+	public String getViewName(FLayer layer);
+
+	public void addExtent(ProjectExtent arg1);
+
+	public ProjectExtent removeExtent(int arg0);
+
+	public ProjectExtent[] getExtents();
+
+	/**
+	 * Obtiene un documento a partir de su nombre y el nombre de registro en el
+	 * pointExtension, este �ltimo se puede obtener del
+	 * Project****Factory.registerName.
+	 *
+	 * @param name
+	 *            Nombre del documento
+	 * @param type
+	 *            nombre de registro en el extensionPoint
+	 *
+	 * @return Documento
+	 */
+	public Document getDocument(String name, String type);
+
+	public void saveState(File out) throws PersistenceException;
+	
+	public void saveState(OutputStream out) throws PersistenceException;
+
+	public void loadState(InputStream in);
+
+	public void loadState(File in);
+	
+	public String exportDocumentsAsText(List<Document> documents);
+	
+	public void importDocuments(String data, String doctype);
+	
+	public boolean canImportDocuments(String data, String doctype);
+	
+	public Document getActiveDocument();
+
+	public Document createDocument(String type);
+}
\ No newline at end of file

Property changes on: tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/app/project/Project.java
___________________________________________________________________
Added: svn:keywords
   + Author Date Id Revision
Added: svn:eol-style
   + native

Index: tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/app/project/ProjectPreferences.java
===================================================================
--- tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/app/project/ProjectPreferences.java	(revision 0)
+++ tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/app/project/ProjectPreferences.java	(revision 38653)
@@ -0,0 +1,281 @@
+/* gvSIG. Geographic Information System of the Valencian Government
+*
+* Copyright (C) 2007-2009 Infrastructures and Transports Department
+* of the Valencian Government (CIT)
+* 
+* This program is free software; you can redistribute it and/or
+* modify it under the terms of the GNU General Public License
+* as published by the Free Software Foundation; either version 2
+* of the License, or (at your option) any later version.
+* 
+* This program is distributed in the hope that it will be useful,
+* but WITHOUT ANY WARRANTY; without even the implied warranty of
+* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
+* GNU General Public License for more details.
+* 
+* You should have received a copy of the GNU General Public License
+* along with this program; if not, write to the Free Software
+* Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, 
+* MA  02110-1301, USA.
+* 
+*/
+
+/*
+* AUTHORS (In addition to CIT):
+* 2004-2009 IVER TI
+*   
+*/
+
+package org.gvsig.app.project;
+
+import java.awt.Color;
+
+import org.cresques.cts.IProjection;
+import org.gvsig.andami.PluginServices;
+import org.gvsig.app.imp.DefaultPreferencesNode;
+import org.gvsig.fmap.crs.CRSFactory;
+import org.gvsig.fmap.mapcontext.MapContext;
+import org.gvsig.utils.StringUtilities;
+import org.gvsig.utils.XMLEntity;
+
+/**
+ * Clase que representa las preferencias para el proyecto
+ *
+ * @author 2009-         Joaquin del Cerro
+ * 
+ */
+
+public class ProjectPreferences extends DefaultPreferencesNode {
+
+	private IProjection defaultProjection = null;
+
+	private IProjection defaultFactoryProjection = CRSFactory
+			.getCRS("EPSG:23030");
+
+	private Color defaultSelectionColor = Color.YELLOW;
+	
+	private Color defaultViewBackColor = Color.WHITE;
+
+	private Color defaultOverviewBackColor = Color.WHITE;	
+
+	private int defaultMapUnits = -1;
+
+	private int defaultDistanceUnits = -1;
+
+	private int defaultDistanceArea = -1;
+
+	
+	public ProjectPreferences() {
+		// 
+	}
+
+	/**
+	 * Sets the projection used when no projection is defined
+	 *
+	 * @param defaultProjection
+	 */
+	public void setDefaultProjection(IProjection defaultProjection) {
+		this.defaultProjection = defaultProjection;
+	}
+
+	public int getInt(String name, int defaultValue) {
+		if( name.equalsIgnoreCase("DefaultDistanceUnits")) {
+			return this.getDefaultDistanceUnits();
+		} else if( name.equalsIgnoreCase("DefaultDistanceArea")) {
+			return this.getDefaultDistanceArea();
+		} else if( name.equalsIgnoreCase("DefaultMapUnits")) {
+			return this.getDefaultMapUnits();
+		}
+		
+		return super.getInt(name, defaultValue);
+	}
+	
+	public IProjection getDefaultProjection() {
+		if (defaultProjection == null){
+			XMLEntity xml = PluginServices.getPluginServices("org.gvsig.app")
+			.getPersistentXML();
+
+			// Default Projection
+			String projCode = null;
+			if (xml.contains("DefaultProjection")) {
+				projCode = xml.getStringProperty("DefaultProjection");
+				setDefaultProjection(CRSFactory.getCRS(projCode));
+			} else {
+				setDefaultProjection(defaultFactoryProjection);
+			}
+
+		}
+		return defaultProjection;
+	}
+
+	/**
+	 * Sets the default selection color that will be used in subsequent
+	 * projects.
+	 *
+	 * @param color
+	 */
+	public void setDefaultSelectionColor(Color color) {
+		defaultSelectionColor = color;
+	}
+
+	/**
+	 * Returns the current default selection color defined which is the color
+	 * defined when the user does not define any other one
+	 *
+	 * @return java.awt.Color
+	 */
+	public Color getDefaultSelectionColor() {
+		XMLEntity xml = PluginServices.getPluginServices("org.gvsig.app")
+				.getPersistentXML();
+		if (xml.contains("DefaultSelectionColor")) {
+			defaultSelectionColor = StringUtilities.string2Color(xml
+					.getStringProperty("DefaultSelectionColor"));
+		}
+		return defaultSelectionColor;
+	}
+
+	public Color getDefaultViewBackColor() {
+		XMLEntity xml = PluginServices.getPluginServices("org.gvsig.app").getPersistentXML();
+		if (xml.contains("DefaultViewBackColor")) {
+			defaultViewBackColor = StringUtilities.
+				string2Color(xml.getStringProperty("DefaultViewBackColor"));
+		}
+		return defaultViewBackColor;
+	}
+
+	public void setDefaultViewBackColor(Color color) {
+		defaultViewBackColor = color;
+	}
+
+	public Color getDefaultOverviewBackColor() {
+		XMLEntity xml = PluginServices.getPluginServices("org.gvsig.app")
+				.getPersistentXML();
+		if (xml.contains("defaultOverviewBackColor")) {
+			defaultOverviewBackColor = StringUtilities.string2Color(xml
+					.getStringProperty("defaultOverviewBackColor"));
+		}
+		return defaultOverviewBackColor;
+
+	}
+
+	public void setDefaultOverviewBackColor(Color color) {
+		defaultOverviewBackColor = color;
+	}
+
+	/**
+	 * Returns the user's default map units. This is the cartography data
+	 * distance units.
+	 *
+	 * @return int (index of the <b>Attributes.NAMES array</b>)
+	 */
+	public int getDefaultMapUnits() {
+		if (defaultMapUnits == -1) {
+			XMLEntity xml = PluginServices.getPluginServices(
+					"org.gvsig.app").getPersistentXML();
+			if (xml.contains("DefaultMapUnits")) {
+				defaultMapUnits = xml.getIntProperty("DefaultMapUnits");
+			} else {
+				// first app run case
+				String[] unitNames = MapContext.getDistanceNames();
+				for (int i = 0; i < unitNames.length; i++) {
+					// meter is the factory default's map unit
+					if (unitNames[i].equals("Metros")) {
+						defaultMapUnits = i;
+						break;
+					}
+				}
+			}
+			if (defaultMapUnits == -1 || defaultMapUnits >= MapContext.getDistanceNames().length){
+				defaultMapUnits = MapContext.getDistancePosition("Metros");
+			}
+		}
+		return defaultMapUnits;
+	}
+
+	/**
+	 * Returns the user's default view units for measuring distances. This is
+	 * the units that the user will see in the status bar of the view.
+	 *
+	 * @return int (index of the <b>Attributes.NAMES array</b>)
+	 */
+	public int getDefaultDistanceUnits() {
+		if (defaultDistanceUnits == -1) {
+			XMLEntity xml = PluginServices.getPluginServices(
+					"org.gvsig.app").getPersistentXML();
+			if (xml.contains("DefaultDistanceUnits")) {
+				defaultDistanceUnits = xml
+						.getIntProperty("DefaultDistanceUnits");
+			} else {
+				// first app run case
+				String[] unitNames = MapContext.getDistanceNames();
+				for (int i = 0; i < unitNames.length; i++) {
+					// meter is the factory default's distance unit
+					if (unitNames[i].equals("Metros")) {
+						defaultDistanceUnits = i;
+						break;
+					}
+				}
+			}
+			if (defaultDistanceUnits == -1 || defaultDistanceUnits >= MapContext.getDistanceNames().length){
+				defaultDistanceUnits = MapContext.getDistancePosition("Metros");
+			}
+		}
+		return defaultDistanceUnits;
+	}
+	/**
+	 * Returns the user's default view units for measuring areas. This is
+	 * the units that the user will see in the status bar of the view.
+	 *
+	 * @return int (index of the <b>Attributes.NAMES array</b>)
+	 */
+	public int getDefaultDistanceArea() {
+		if (defaultDistanceArea == -1) {
+			XMLEntity xml = PluginServices.getPluginServices(
+					"org.gvsig.app").getPersistentXML();
+			if (xml.contains("DefaultDistanceArea")) {
+				defaultDistanceArea = xml
+						.getIntProperty("DefaultDistanceArea");
+			} else {
+				// first app run case
+				String[] unitNames = MapContext.getAreaNames();
+				for (int i = 0; i < unitNames.length; i++) {
+					// meter is the factory default's distance unit
+					if (unitNames[i].equals("Metros")) {
+						defaultDistanceArea = i;
+						break;
+					}
+				}
+			}
+			if (defaultDistanceArea == -1 || defaultDistanceArea >= MapContext.getAreaNames().length){
+				defaultDistanceArea=getDefaultDistanceUnits();
+			}
+		}
+		return defaultDistanceArea;
+	}
+	/**
+	 * Sets the default map unit (the units used by the data).
+	 *
+	 * @param mapUnits
+	 */
+	public void setDefaultMapUnits(int mapUnits) {
+		defaultMapUnits = mapUnits;
+	}
+
+	/**
+	 * Sets the default distance units (the units shown in the status bar)
+	 *
+	 * @param distanceUnits
+	 */
+	public void setDefaultDistanceUnits(int distanceUnits) {
+		defaultDistanceUnits = distanceUnits;
+	}
+	/**
+	 * Sets the default distance area (the units shown in the status bar)
+	 *
+	 * @param distanceUnits
+	 */
+	public void setDefaultDistanceArea(int distanceArea) {
+		defaultDistanceArea = distanceArea;
+	}
+
+}

Property changes on: tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/app/project/ProjectPreferences.java
___________________________________________________________________
Added: svn:mime-type
   + text/plain

Index: tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/app/ApplicationLocator.java
===================================================================
--- tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/app/ApplicationLocator.java	(revision 0)
+++ tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/app/ApplicationLocator.java	(revision 38653)
@@ -0,0 +1,91 @@
+/* gvSIG. Geographic Information System of the Valencian Government
+*
+* Copyright (C) 2007-2008 Infrastructures and Transports Department
+* of the Valencian Government (CIT)
+*
+* This program is free software; you can redistribute it and/or
+* modify it under the terms of the GNU General Public License
+* as published by the Free Software Foundation; either version 2
+* of the License, or (at your option) any later version.
+*
+* This program is distributed in the hope that it will be useful,
+* but WITHOUT ANY WARRANTY; without even the implied warranty of
+* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
+* GNU General Public License for more details.
+*
+* You should have received a copy of the GNU General Public License
+* along with this program; if not, write to the Free Software
+* Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston,
+* MA  02110-1301, USA.
+*
+*/
+
+/*
+* AUTHORS (In addition to CIT):
+* 2009 IVER T.I   {{Task}}
+*/
+
+package org.gvsig.app;
+
+import org.gvsig.tools.locator.BaseLocator;
+import org.gvsig.tools.locator.Locator;
+import org.gvsig.tools.locator.LocatorException;
+
+public class ApplicationLocator extends BaseLocator {
+
+	private static final String LOCATOR_NAME = "appgsigLocator";
+
+	public static final String APPGVSIG_MANAGER_NAME = "appgsigLocator.manager.persistence";
+
+	private static final String APPGVSIG_MANAGER_DESCRIPTION = "Manager of appgvSIG";
+	
+	/**
+	 * Unique instance.
+	 */
+	private static final ApplicationLocator instance = new ApplicationLocator();
+
+	/**
+	 * Return the singleton instance.
+	 *
+	 * @return the singleton instance
+	 */
+	public static ApplicationLocator getInstance() {
+		return instance;
+	}
+
+	public String getLocatorName() {
+		return LOCATOR_NAME;
+	}
+
+	/**
+	 * Return a reference to PersistenceManager.
+	 *
+	 * @return a reference to PersistenceManager
+	 * @throws LocatorException
+	 *             if there is no access to the class or the class cannot be
+	 *             instantiated
+	 * @see Locator#get(String)
+	 */
+	public static ApplicationManager getManager()
+			throws LocatorException {
+		return (ApplicationManager) getInstance().get(APPGVSIG_MANAGER_NAME);
+	}
+
+	/**
+	 * Registers the Class implementing the PersistenceManager interface.
+	 *
+	 * @param clazz
+	 *            implementing the PersistenceManager interface
+	 */
+	@SuppressWarnings("unchecked")
+	public static void registerAppgvSIGManager(Class clazz) {
+		getInstance().register(APPGVSIG_MANAGER_NAME,
+				APPGVSIG_MANAGER_DESCRIPTION, clazz);
+	}
+
+	@SuppressWarnings("unchecked")
+	public static void registerDefaultAppgvSIGManager(Class clazz) {
+		getInstance().registerDefault(APPGVSIG_MANAGER_NAME,
+				APPGVSIG_MANAGER_DESCRIPTION, clazz);
+	}		
+}

Property changes on: tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/app/ApplicationLocator.java
___________________________________________________________________
Added: svn:mime-type
   + text/plain

Index: tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/app/PreferencesNode.java
===================================================================
--- tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/app/PreferencesNode.java	(revision 0)
+++ tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/app/PreferencesNode.java	(revision 38653)
@@ -0,0 +1,54 @@
+package org.gvsig.app;
+
+import java.awt.Color;
+
+
+public interface PreferencesNode {
+
+	public String name() ;
+
+	public void clear() throws Exception ;
+	
+	public void flush() throws Exception;
+
+	public String[] keys() throws Exception ;
+
+	public String get(String arg0, String arg1) ;
+
+	public void remove(String arg0) ;
+
+	public void sync() throws Exception ;
+
+	
+	
+	public Color getColor(String name, Color value) ;
+
+	public boolean getBoolean(String name, boolean value) ;
+
+	public byte[] getByteArray(String name, byte[] value) ;
+
+	public double getDouble(String name, double value) ;
+
+	public float getFloat(String name, float value) ;
+
+	public int getInt(String name, int value) ;
+
+	public long getLong(String name, long value) ;
+
+
+	public void put(String name, String value) ;
+
+	public void putBoolean(String name, boolean value) ;
+
+	public void putByteArray(String name, byte[] value) ;
+
+	public void putDouble(String name, double value) ;
+
+	public void putFloat(String name, float value) ;
+
+	public void putInt(String name, int value) ;
+
+	public void putLong(String name, long value) ;
+
+
+}

Property changes on: tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/app/PreferencesNode.java
___________________________________________________________________
Added: svn:mime-type
   + text/plain

Index: tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/fmap/dal/serverexplorer/filesystem/swing/FilesystemExplorerWizardPanel.java
===================================================================
--- tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/fmap/dal/serverexplorer/filesystem/swing/FilesystemExplorerWizardPanel.java	(revision 0)
+++ tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/fmap/dal/serverexplorer/filesystem/swing/FilesystemExplorerWizardPanel.java	(revision 38653)
@@ -0,0 +1,657 @@
+/* gvSIG. Geographic Information System of the Valencian Government
+ *
+ * Copyright (C) 2007-2008 Infrastructures and Transports Department
+ * of the Valencian Government (CIT)
+ *
+ * This program is free software; you can redistribute it and/or
+ * modify it under the terms of the GNU General Public License
+ * as published by the Free Software Foundation; either version 2
+ * of the License, or (at your option) any later version.
+ *
+ * This program is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
+ * GNU General Public License for more details.
+ *
+ * You should have received a copy of the GNU General Public License
+ * along with this program; if not, write to the Free Software
+ * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston,
+ * MA  02110-1301, USA.
+ *
+ */
+
+/*
+ * AUTHORS (In addition to CIT):
+ * 2008 IVER T.I. S.A.   {{Task}}
+ */
+package org.gvsig.fmap.dal.serverexplorer.filesystem.swing;
+
+import java.awt.Component;
+import java.awt.GridBagConstraints;
+import java.awt.GridBagLayout;
+import java.awt.Insets;
+import java.awt.event.ActionEvent;
+import java.awt.event.ActionListener;
+import java.io.File;
+import java.util.ArrayList;
+import java.util.Iterator;
+import java.util.List;
+import java.util.prefs.Preferences;
+
+import javax.swing.AbstractListModel;
+import javax.swing.JButton;
+import javax.swing.JList;
+import javax.swing.JPanel;
+import javax.swing.JScrollPane;
+import javax.swing.ScrollPaneConstants;
+import javax.swing.event.ListSelectionEvent;
+import javax.swing.event.ListSelectionListener;
+import javax.swing.filechooser.FileFilter;
+
+import org.slf4j.Logger;
+import org.slf4j.LoggerFactory;
+
+import org.gvsig.andami.PluginServices;
+import org.gvsig.andami.messages.Messages;
+import org.gvsig.andami.messages.NotificationManager;
+import org.gvsig.app.ApplicationLocator;
+import org.gvsig.app.ApplicationManager;
+import org.gvsig.app.gui.WizardPanel;
+import org.gvsig.app.prepareAction.PrepareContext;
+import org.gvsig.fmap.dal.DALLocator;
+import org.gvsig.fmap.dal.DataManager;
+import org.gvsig.fmap.dal.DataStoreParameters;
+import org.gvsig.fmap.dal.exception.DataException;
+import org.gvsig.fmap.dal.exception.FileNotFoundException;
+import org.gvsig.fmap.dal.serverexplorer.filesystem.FilesystemFileFilter;
+import org.gvsig.fmap.dal.serverexplorer.filesystem.FilesystemServerExplorer;
+import org.gvsig.fmap.dal.serverexplorer.filesystem.FilesystemServerExplorerParameters;
+import org.gvsig.fmap.dal.serverexplorer.filesystem.FilesystemStoreParameters;
+import org.gvsig.fmap.mapcontrol.swing.dynobject.DynObjectEditor;
+import org.gvsig.fmap.mapcontrol.swing.dynobject.DynObjectViewer;
+import org.gvsig.gui.beans.swing.JFileChooser;
+import org.gvsig.tools.dynobject.DynObject;
+import org.gvsig.tools.service.ServiceException;
+import org.gvsig.tools.swing.api.ToolsSwingLocator;
+
+/**
+ * @author jmvivo
+ * 
+ */
+public abstract class FilesystemExplorerWizardPanel extends WizardPanel
+    implements ActionListener, ListSelectionListener {
+
+    /**
+	 *
+	 */
+    private static final long serialVersionUID = -3371957786521876903L;
+
+    private static final Logger LOG = LoggerFactory
+        .getLogger(FilesystemExplorerWizardPanel.class);
+
+    public static final String OPEN_LAYER_FILE_CHOOSER_ID =
+        "OPEN_LAYER_FILE_CHOOSER_ID";
+
+    protected static final String ADD_COMMAND = "ADD";
+    protected static final String EDIT_COMMAND = "PROPERTIES";
+    protected static final String REMOVE_COMMAND = "REMOVE";
+    protected static final String UP_COMMAND = "UP";
+    protected static final String DOWN_COMMAND = "DOWN";
+
+    private static String lastPath = null;
+    private static MyFileFilter lastFilter = null;
+    private static final String DEFAULT_FILTER = "All_supported";
+
+    private JList fileList;
+    private JScrollPane fileListScroll;
+    private JPanel buttonsPanel;
+    private JButton addButton;
+    private JButton propertiesButton;
+    private JButton removeButton;
+    private JButton upButton;
+    private JButton downButton;
+
+    protected FilesystemServerExplorer explorer;
+    private ArrayList<MyFileFilter> filters;
+
+    public void setTabName(String name) {
+        super.setTabName(name);
+    }
+
+    /*
+     * (non-Javadoc)
+     * 
+     * @see com.iver.cit.gvsig.gui.WizardPanel#getParameters()
+     */
+    @Override
+    public DataStoreParameters[] getParameters() {
+        return ((FilesystemStoreListModel) getFileList().getModel())
+            .getParameters();
+    }
+
+    /*
+     * (non-Javadoc)
+     * 
+     * @see com.iver.cit.gvsig.gui.WizardPanel#initWizard()
+     */
+    @Override
+    public void initWizard() {
+        setTabName(PluginServices.getText(this, "Fichero"));
+        if (lastPath == null) {
+            Preferences prefs = Preferences.userRoot().node("gvsig.foldering");
+            lastPath = prefs.get("DataFolder", null);
+        }
+
+        DataManager dm = DALLocator.getDataManager();
+        FilesystemServerExplorerParameters param;
+        try {
+            param =
+                (FilesystemServerExplorerParameters) dm
+                    .createServerExplorerParameters(FilesystemServerExplorer.NAME);
+            param.setInitialpath(lastPath);
+            explorer =
+                (FilesystemServerExplorer) dm.openServerExplorer(
+                    FilesystemServerExplorer.NAME, param);
+        } catch (Exception e) {
+            throw new RuntimeException(e);
+        }
+
+        int mode = FilesystemServerExplorer.MODE_ALL;
+        this.filters = new ArrayList<MyFileFilter>();
+        if (this.getMapCtrl() == null) {
+            mode = FilesystemServerExplorer.MODE_FEATURE;
+        } else {
+            mode =
+                FilesystemServerExplorer.MODE_GEOMETRY
+                    | FilesystemServerExplorer.MODE_RASTER;
+        }
+        @SuppressWarnings("unchecked")
+        Iterator<FilesystemFileFilter> iter = explorer.getFilters(mode);
+        while (iter.hasNext()) {
+            this.filters.add(new MyFileFilter(iter.next()));
+        }
+        this.filters.add(new MyFileFilter(explorer.getFilter(mode,
+            Messages.get(DEFAULT_FILTER))));
+        initUI();
+    }
+
+    private void initUI() {
+        this.setLayout(new GridBagLayout());
+        GridBagConstraints constr = new GridBagConstraints();
+
+        constr.gridwidth = GridBagConstraints.RELATIVE;
+        constr.gridheight = GridBagConstraints.RELATIVE;
+        constr.fill = GridBagConstraints.BOTH;
+        constr.anchor = GridBagConstraints.FIRST_LINE_START;
+        constr.weightx = 1;
+        constr.weighty = 1;
+        constr.ipadx = 3;
+        constr.ipady = 3;
+
+        this.add(getFileListScroll(), constr);
+
+        constr.gridwidth = GridBagConstraints.REMAINDER;
+        constr.gridheight = GridBagConstraints.RELATIVE;
+        constr.fill = GridBagConstraints.NONE;
+        constr.anchor = GridBagConstraints.FIRST_LINE_END;
+        constr.weightx = 0;
+        constr.weighty = 0;
+        this.add(getButtonsPanel(), constr);
+
+        this.updateButtons();
+        this.updateContainingWizardAcceptButton();
+
+    }
+
+    protected class FilesystemStoreListModel extends AbstractListModel {
+
+        private static final long serialVersionUID = -726119349962990665L;
+        private ArrayList<FilesystemStoreParameters> theList;
+
+        public FilesystemStoreListModel() {
+            theList = new ArrayList<FilesystemStoreParameters>();
+        }
+
+        public DataStoreParameters[] getParameters() {
+            return theList.toArray(new DataStoreParameters[0]);
+        }
+
+        public Object getElementAt(int index) {
+            return theList.get(index).getFile().getName();
+        }
+
+        public FilesystemStoreParameters getStoreParameterAt(int index) {
+            return theList.get(index);
+        }
+
+        public int getSize() {
+            return theList.size();
+        }
+
+        public DynObject getDynObjectAt(int index) {
+            return (DynObject) theList.get(index);
+        }
+
+        public void add(DynObject dynObject) {
+            this.theList.add((FilesystemStoreParameters) dynObject);
+            this.fireIntervalAdded(this, this.theList.size() - 1,
+                this.theList.size() - 1);
+        }
+
+        public void addAll(List<FilesystemStoreParameters> toAdd) {
+            int index0 = this.getSize() - 1;
+            if (index0 < 0) {
+                index0 = 0;
+            }
+            this.theList.addAll(toAdd);
+            this.fireIntervalAdded(this, index0, this.theList.size() - 1);
+        }
+
+        public void remove(int i) {
+            this.theList.remove(i);
+            this.fireIntervalRemoved(this, i, i);
+
+        }
+
+        public void up(FilesystemStoreParameters item) {
+            int curIndex = this.theList.indexOf(item);
+            if (curIndex < 1) {
+                return;
+            }
+            this.theList.remove(item);
+            this.theList.add(curIndex - 1, item);
+            this.fireContentsChanged(this, curIndex, curIndex - 1);
+        }
+
+        public void down(FilesystemStoreParameters item) {
+            int curIndex = this.theList.indexOf(item);
+            if (curIndex < 0) {
+                return;
+            } else
+                if (curIndex == this.theList.size() - 1) {
+                    return;
+                }
+            this.theList.remove(item);
+            this.theList.add(curIndex + 1, item);
+            this.fireContentsChanged(this, curIndex, curIndex + 1);
+        }
+
+    }
+
+    protected JList getFileList() {
+        if (fileList == null) {
+            fileList = new JList(new FilesystemStoreListModel());
+
+            fileList.addListSelectionListener(this);
+        }
+        return fileList;
+    }
+
+    private JScrollPane getFileListScroll() {
+        if (fileListScroll == null) {
+            fileListScroll = new JScrollPane();
+            fileListScroll.setViewportView(getFileList());
+            fileListScroll
+                .setVerticalScrollBarPolicy(ScrollPaneConstants.VERTICAL_SCROLLBAR_AS_NEEDED);
+            fileListScroll
+                .setHorizontalScrollBarPolicy(ScrollPaneConstants.HORIZONTAL_SCROLLBAR_AS_NEEDED);
+
+        }
+        return fileListScroll;
+    }
+
+    private Component getButtonsPanel() {
+        if (buttonsPanel == null) {
+            buttonsPanel = new JPanel();
+
+            buttonsPanel.setLayout(new GridBagLayout());
+
+            GridBagConstraints constr = new GridBagConstraints();
+
+            constr.anchor = GridBagConstraints.CENTER;
+            constr.fill = GridBagConstraints.NONE;
+            constr.ipadx = 3;
+            constr.ipady = 3;
+            constr.insets = new Insets(3, 3, 3, 3);
+            constr.gridwidth = GridBagConstraints.REMAINDER;
+
+            buttonsPanel.add(getAddButton(), constr);
+            buttonsPanel.add(getPropertiesButton(), constr);
+            buttonsPanel.add(getRemoveButton(), constr);
+            buttonsPanel.add(getUpButton(), constr);
+            buttonsPanel.add(getDownButton(), constr);
+            // buttonsPanel.add(new JLabel(), constrLbl);
+        }
+        return buttonsPanel;
+    }
+
+    private JButton getAddButton() {
+        if (addButton == null) {
+            addButton =
+                ToolsSwingLocator.getUsabilitySwingManager().createJButton();
+            addButton.setText(getLocalizedText("add"));
+            addButton.setMargin(new java.awt.Insets(2, 2, 2, 2));
+            addButton.setActionCommand(ADD_COMMAND);
+            addButton.addActionListener(this);
+        }
+        return addButton;
+    }
+
+    private JButton getPropertiesButton() {
+        if (propertiesButton == null) {
+            propertiesButton =
+                ToolsSwingLocator.getUsabilitySwingManager().createJButton();
+            propertiesButton.setText(getLocalizedText("properties"));
+            propertiesButton.setMargin(new java.awt.Insets(2, 2, 2, 2));
+            propertiesButton.setActionCommand(EDIT_COMMAND);
+            propertiesButton.addActionListener(this);
+        }
+        return propertiesButton;
+    }
+
+    private JButton getRemoveButton() {
+        if (removeButton == null) {
+            removeButton =
+                ToolsSwingLocator.getUsabilitySwingManager().createJButton();
+            removeButton.setText(getLocalizedText("remove"));
+            removeButton.setMargin(new java.awt.Insets(2, 2, 2, 2));
+            removeButton.setActionCommand(REMOVE_COMMAND);
+            removeButton.addActionListener(this);
+        }
+        return removeButton;
+    }
+
+    private JButton getUpButton() {
+        if (upButton == null) {
+            upButton =
+                ToolsSwingLocator.getUsabilitySwingManager().createJButton();
+            upButton.setText(getLocalizedText("up"));
+            upButton.setMargin(new java.awt.Insets(2, 2, 2, 2));
+            upButton.setActionCommand(UP_COMMAND);
+            upButton.addActionListener(this);
+        }
+        return upButton;
+    }
+
+    private JButton getDownButton() {
+        if (downButton == null) {
+            downButton =
+                ToolsSwingLocator.getUsabilitySwingManager().createJButton();
+            downButton.setText(getLocalizedText("down"));
+            downButton.setMargin(new java.awt.Insets(2, 2, 2, 2));
+            downButton.setActionCommand(DOWN_COMMAND);
+            downButton.addActionListener(this);
+        }
+        return downButton;
+    }
+
+    private String getLocalizedText(String txt) {
+        try {
+            return PluginServices.getText(this, txt);
+        } catch (Exception e) {
+            return txt;
+        }
+    }
+
+    public void actionPerformed(ActionEvent e) {
+        String command = e.getActionCommand();
+        FilesystemStoreListModel model =
+            (FilesystemStoreListModel) getFileList().getModel();
+
+        if (command == ADD_COMMAND) {
+            List<FilesystemStoreParameters> toAdd = this.addFiles();
+            if (toAdd.isEmpty()) {
+                return;
+            }
+            model.addAll(toAdd);
+
+            getFileList().setModel(model);
+            
+            this.updateContainingWizardAcceptButton();
+
+        } else
+            if (command == EDIT_COMMAND) {
+                DynObject dynObject =
+                    model.getDynObjectAt(getFileList().getSelectedIndex());
+
+                try {
+                    DynObjectEditor editor = new DynObjectEditor(dynObject);
+                    editor.editObject(true);
+                } catch (ServiceException ex) {
+                    LOG.error(
+                        "Error creating a Swing component for the DynObject: "
+                            + dynObject, ex);
+                }
+
+            } else
+                if (command == REMOVE_COMMAND) {
+                    int[] selecteds = getFileList().getSelectedIndices();
+                    for (int i = selecteds.length - 1; i > -1; i--) {
+                        model.remove(selecteds[i]);
+                    }
+                    getFileList().setSelectedIndex(-1);
+                    
+                    this.updateContainingWizardAcceptButton();
+
+                } else
+                    if (command == UP_COMMAND) {
+                        List<FilesystemStoreParameters> items =
+                            new ArrayList<FilesystemStoreParameters>();
+                        int[] selecteds = getFileList().getSelectedIndices();
+                        if (selecteds.length == 0 || selecteds[0] == 0) {
+                            return;
+                        }
+                        for (int i = 0; i < selecteds.length; i++) {
+                            items.add(model.getStoreParameterAt(selecteds[i]));
+                            selecteds[i]--;
+                        }
+                        Iterator<FilesystemStoreParameters> iter =
+                            items.iterator();
+                        while (iter.hasNext()) {
+                            model.up(iter.next());
+                        }
+                        getFileList().setSelectedIndices(selecteds);
+
+                    } else
+                        if (command == DOWN_COMMAND) {
+                            List<FilesystemStoreParameters> items =
+                                new ArrayList<FilesystemStoreParameters>();
+                            int[] selecteds =
+                                getFileList().getSelectedIndices();
+                            if (selecteds.length == 0
+                                || selecteds[selecteds.length - 1] == model
+                                    .getSize() - 1) {
+                                return;
+                            }
+                            for (int i = selecteds.length - 1; i > -1; i--) {
+                                items.add(model
+                                    .getStoreParameterAt(selecteds[i]));
+                                selecteds[i]++;
+                            }
+                            Iterator<FilesystemStoreParameters> iter =
+                                items.iterator();
+                            while (iter.hasNext()) {
+                                model.down(iter.next());
+                            }
+                            getFileList().setSelectedIndices(selecteds);
+
+                        } else {
+                            throw new IllegalArgumentException(command);
+                        }
+
+    }
+
+    /**
+     * check number of files already selected for adding
+     */
+    private void updateContainingWizardAcceptButton() {
+        int curr_add_file_count = getFileList().getModel().getSize();
+        this.callStateChanged(curr_add_file_count > 0);
+    }
+
+    
+    public boolean areSettingsValid() {
+        int curr_add_file_count = getFileList().getModel().getSize();
+        return (curr_add_file_count > 0);
+    }
+
+    public List<DynObject> getSelecteds() {
+        ArrayList<DynObject> list = new ArrayList<DynObject>();
+        JList fList = this.getFileList();
+        int[] selecteds = fList.getSelectedIndices();
+        FilesystemStoreListModel model =
+            (FilesystemStoreListModel) fList.getModel();
+
+        for (int index : selecteds) {
+            list.add((DynObject) model.getStoreParameterAt(index));
+        }
+        return list;
+    }
+
+    public void valueChanged(ListSelectionEvent e) {
+        this.updateButtons();
+    }
+
+    public class MyFileFilter extends FileFilter {
+
+        public FilesystemFileFilter filter = null;
+
+        public MyFileFilter(FilesystemFileFilter params) {
+            this.filter = params;
+        }
+
+        /**
+         * @see javax.swing.filechooser.FileFilter#accept(java.io.File)
+         */
+        public boolean accept(File f) {
+            if (f.isDirectory()) {
+                return true;
+            }
+            return filter.accept(f);
+
+        }
+
+        /**
+         * @see javax.swing.filechooser.FileFilter#getDescription()
+         */
+        public String getDescription() {
+            return filter.getDescription();
+        }
+
+        public String getName() {
+            return filter.getDataStoreProviderName();
+        }
+    }
+
+    private List<FilesystemStoreParameters> addFiles() {
+        
+        // this.callStateChanged(true);
+        
+        JFileChooser fileChooser =
+            new JFileChooser(OPEN_LAYER_FILE_CHOOSER_ID,
+                explorer.getCurrentPath());
+        fileChooser.setMultiSelectionEnabled(true);
+        fileChooser.setAcceptAllFileFilterUsed(false);
+
+        Iterator<MyFileFilter> iter = this.filters.iterator();
+        while (iter.hasNext()) {
+            fileChooser.addChoosableFileFilter(iter.next());
+        }
+
+        if (lastFilter != null && filters.contains(lastFilter)) {
+            fileChooser.setFileFilter(lastFilter);
+        }
+
+        int result = fileChooser.showOpenDialog(this);
+
+        List<FilesystemStoreParameters> toAdd =
+            new ArrayList<FilesystemStoreParameters>();
+
+        if (result == JFileChooser.APPROVE_OPTION) {
+            lastPath = fileChooser.getCurrentDirectory().getAbsolutePath();
+            try {
+                explorer.setCurrentPath(fileChooser.getCurrentDirectory());
+            } catch (FileNotFoundException e) {
+                NotificationManager.addError(e);
+            }
+            lastFilter = (MyFileFilter) fileChooser.getFileFilter();
+            ApplicationManager appGvSIGMan = ApplicationLocator.getManager();
+            PrepareContext context = this.getPrepareDataStoreContext();
+            List<DataStoreParameters> paramList = new ArrayList<DataStoreParameters>();
+            List<DataStoreParameters> toAddParamList = null;
+            for (File aFile : fileChooser.getSelectedFiles()) {
+                try {
+                	DataStoreParameters param =
+                        explorer.createStoreParameters(aFile, lastFilter
+                            .getDescription().compareTo(DEFAULT_FILTER) == 0
+                            ? null : lastFilter.getName());
+                    if (param == null) {
+                        // TODO show warning
+                        continue;
+                    }
+
+                    paramList.add(param);
+                   
+                } catch (DataException e) {
+                    NotificationManager.addError(e);
+                    return null;
+                }
+            }
+            
+            try {
+                toAddParamList =
+                    appGvSIGMan.prepareOpenDataStoreParameters(paramList, context);
+            } catch (Exception e) {
+                NotificationManager.addError(e);
+            }
+            
+            for (int i = 0; i < toAddParamList.size(); i++) {
+				toAdd.add((FilesystemStoreParameters)toAddParamList.get(i));
+			}
+        }
+        return toAdd;
+    }
+
+    protected abstract PrepareContext getPrepareDataStoreContext();
+
+    /**
+     * Refers to up/down/remove buttons etc. Called when selection changes
+     */
+    private void updateButtons() {
+        int selectedIndex = this.getFileList().getSelectedIndex();
+        int size = this.getFileList().getModel().getSize();
+        int[] selecteds = this.getFileList().getSelectedIndices();
+        if (size < 1) {
+            this.getPropertiesButton().setEnabled(false);
+            this.getRemoveButton().setEnabled(false);
+            this.getUpButton().setEnabled(false);
+            this.getDownButton().setEnabled(false);
+            return;
+        } else
+            if (size == 1) {
+                this.getUpButton().setEnabled(false);
+                this.getDownButton().setEnabled(false);
+            } else {
+                this.getUpButton().setEnabled(selectedIndex > 0);
+
+                this.getDownButton().setEnabled(
+                    selectedIndex > -1
+                        && selecteds[selecteds.length - 1] < size - 1);
+            }
+        this.getPropertiesButton().setEnabled(
+            selectedIndex > -1
+                && this.getFileList().getSelectedIndices().length == 1);
+        this.getRemoveButton().setEnabled(selectedIndex > -1);
+    }
+
+    public void close() {
+        if (explorer != null) {
+            explorer.dispose();
+            explorer = null;
+        }
+        if (filters != null) {
+            filters.clear();
+            filters = null;
+        }
+    }
+}

Property changes on: tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/fmap/dal/serverexplorer/filesystem/swing/FilesystemExplorerWizardPanel.java
___________________________________________________________________
Added: svn:mime-type
   + text/plain

Index: tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/fmap/dal/serverexplorer/filesystem/swing/FilesystemExplorerAddLayerWizardPanel.java
===================================================================
--- tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/fmap/dal/serverexplorer/filesystem/swing/FilesystemExplorerAddLayerWizardPanel.java	(revision 0)
+++ tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/fmap/dal/serverexplorer/filesystem/swing/FilesystemExplorerAddLayerWizardPanel.java	(revision 38653)
@@ -0,0 +1,194 @@
+/* gvSIG. Geographic Information System of the Valencian Government
+ *
+ * Copyright (C) 2007-2008 Infrastructures and Transports Department
+ * of the Valencian Government (CIT)
+ *
+ * This program is free software; you can redistribute it and/or
+ * modify it under the terms of the GNU General Public License
+ * as published by the Free Software Foundation; either version 2
+ * of the License, or (at your option) any later version.
+ *
+ * This program is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
+ * GNU General Public License for more details.
+ *
+ * You should have received a copy of the GNU General Public License
+ * along with this program; if not, write to the Free Software
+ * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston,
+ * MA  02110-1301, USA.
+ *
+ */
+
+/*
+ * AUTHORS (In addition to CIT):
+ * 2008 IVER T.I. S.A.   {{Task}}
+ */
+package org.gvsig.fmap.dal.serverexplorer.filesystem.swing;
+
+import java.awt.BorderLayout;
+import java.awt.Window;
+import java.awt.event.ActionEvent;
+
+import javax.swing.JFrame;
+
+import org.cresques.cts.IProjection;
+import org.slf4j.Logger;
+import org.slf4j.LoggerFactory;
+
+import org.gvsig.app.addlayer.AddLayerDialog;
+import org.gvsig.app.prepareAction.PrepareContext;
+import org.gvsig.app.prepareAction.PrepareContextView;
+import org.gvsig.fmap.dal.DataStoreParameters;
+import org.gvsig.fmap.dal.DataTypes;
+import org.gvsig.fmap.dal.serverexplorer.filesystem.FilesystemStoreParameters;
+import org.gvsig.fmap.mapcontrol.MapControl;
+import org.gvsig.fmap.mapcontrol.swing.dynobject.DynObjectEditor;
+import org.gvsig.tools.dynobject.DynField;
+import org.gvsig.tools.dynobject.DynObject;
+import org.gvsig.tools.dynobject.exception.DynFieldNotFoundException;
+import org.gvsig.tools.library.impl.DefaultLibrariesInitializer;
+import org.gvsig.tools.service.ServiceException;
+
+/**
+ * @author jmvivo
+ * 
+ */
+public class FilesystemExplorerAddLayerWizardPanel extends
+    FilesystemExplorerWizardPanel {
+
+    private static final long serialVersionUID = -5054057255129168139L;
+
+    private static final Logger LOG = LoggerFactory
+        .getLogger(FilesystemExplorerAddLayerWizardPanel.class);
+
+    private PrepareContext prepareContext;
+
+    @Override
+    public void execute() {
+        if (this.getMapCtrl() == null) {
+            throw new IllegalArgumentException("MapControl need");
+        }
+        String layerName;
+
+        for (DataStoreParameters params : this.getParameters()) {
+            IProjection proj = null;
+
+            proj = this.getMapCtrl().getProjection();
+
+            // Buscamos por el parametro de la proyeccion
+            // que sean obligatorios y est�n a null
+            // y le ponemos la proyeccion de la vista
+            DynField[] fields = params.getDynClass().getDynFields();
+            for (DynField field : fields) {
+                if (field.getType() == DataTypes.CRS && field.isMandatory()) {
+                    if (params.getDynValue(field.getName()) == null) {
+                        params.setDynValue(field.getName(), proj);
+                    }
+                }
+            }
+
+            layerName =
+                ((FilesystemStoreParameters) params).getFile().getName();
+
+            this.doAddLayer(this.getMapCtrl(), layerName, params);
+        }
+    }
+
+    @Override
+    public void actionPerformed(ActionEvent e) {
+
+        String command = e.getActionCommand();
+        FilesystemStoreListModel model =
+            (FilesystemStoreListModel) getFileList().getModel();
+
+        if (command == EDIT_COMMAND) {
+            DynObject dynObject =
+                model.getDynObjectAt(getFileList().getSelectedIndex());
+
+            // For store parameters with a CRS field, add the current view
+            // CRS as default value when null.
+            try {
+                IProjection projection =
+                    (IProjection) dynObject.getDynValue("CRS");
+                if (projection == null) {
+                    projection = getDefaultProjection();
+                    dynObject.setDynValue("CRS", projection);
+                }
+            } catch (DynFieldNotFoundException e1) {
+                LOG.debug("Loading a store whose parameters "
+                    + "don't have a CRS field");
+            }
+
+            try {
+                DynObjectEditor editor = new DynObjectEditor(dynObject);
+                editor.editObject(true);
+            } catch (ServiceException ex) {
+                LOG.error(
+                    "Error creating a Swing component for the DynObject: "
+                        + dynObject, ex);
+            }
+
+        } else {
+            super.actionPerformed(e);
+        }
+    }
+
+    /**
+     * @return
+     */
+    private IProjection getDefaultProjection() {
+        return getMapCtrl().getViewPort().getProjection();
+    }
+
+    public static void main(String[] args) {
+        try {
+            new DefaultLibrariesInitializer().fullInitialize();
+
+            JFrame frame = new JFrame();
+
+            AddLayerDialog addLayerDlg = new AddLayerDialog();
+
+            FilesystemExplorerAddLayerWizardPanel wizardPanel =
+                new FilesystemExplorerAddLayerWizardPanel();
+            addLayerDlg.addWizardTab("File", wizardPanel);
+            wizardPanel.initWizard();
+
+            frame.setLayout(new BorderLayout());
+            frame.add(addLayerDlg);
+
+            frame.setDefaultCloseOperation(JFrame.EXIT_ON_CLOSE);
+            frame.setBounds(10, 10, 400, 400);
+            frame.setVisible(true);
+
+        } catch (Exception e) {
+            e.printStackTrace();
+            System.exit(-1);
+            return;
+        }
+    }
+
+    @Override
+    protected PrepareContext getPrepareDataStoreContext() {
+        if (this.prepareContext == null) {
+            this.prepareContext = new PrepareContextView() {
+
+                public Window getOwnerWindow() {
+                    return null;
+                }
+
+                public MapControl getMapControl() {
+                    return FilesystemExplorerAddLayerWizardPanel.this
+                        .getMapCtrl();
+                }
+
+				public IProjection getViewProjection() {
+					return getMapControl().getProjection();
+				}
+
+            };
+        }
+        return this.prepareContext;
+    }
+
+}

Property changes on: tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig/fmap/dal/serverexplorer/filesystem/swing/FilesystemExplorerAddLayerWizardPanel.java
___________________________________________________________________
Added: svn:mime-type
   + text/plain


Property changes on: tags/v2_0_0_Build_2050/applications/appgvSIG/src/org/gvsig
___________________________________________________________________
Added: svn:ignore
   + MyGeoprocess.java


Index: tags/v2_0_0_Build_2050/applications/appgvSIG/src/log4j.properties
===================================================================
--- tags/v2_0_0_Build_2050/applications/appgvSIG/src/log4j.properties	(revision 0)
+++ tags/v2_0_0_Build_2050/applications/appgvSIG/src/log4j.properties	(revision 38653)
@@ -0,0 +1,18 @@
+log4j.rootLogger=info, stdout
+
+log4j.appender.stdout=org.apache.log4j.ConsoleAppender
+log4j.appender.stdout.layout=org.apache.log4j.PatternLayout
+
+# Pattern to output the caller's file name and line number.
+log4j.appender.stdout.layout.ConversionPattern=%5p [%t] (%F:%L) - %m%n
+
+log4j.appender.R=org.apache.log4j.RollingFileAppender
+log4j.appender.R.File=application.log
+
+log4j.appender.R.MaxFileSize=100KB
+# Keep one backup file
+log4j.appender.R.MaxBackupIndex=1
+
+log4j.appender.R.layout=org.apache.log4j.PatternLayout
+log4j.appender.R.layout.ConversionPattern=%p %t %c - %m%n
+

Property changes on: tags/v2_0_0_Build_2050/applications/appgvSIG/src/log4j.properties
___________________________________________________________________
Added: svn:eol-style
   + native
Added: svn:keywords
   + Author Date Id Revision

Index: tags/v2_0_0_Build_2050/applications/appgvSIG/pom.xml
===================================================================
--- tags/v2_0_0_Build_2050/applications/appgvSIG/pom.xml	(revision 0)
+++ tags/v2_0_0_Build_2050/applications/appgvSIG/pom.xml	(revision 38653)
@@ -0,0 +1,412 @@
+<?xml version="1.0" encoding="UTF-8"?>
+
+<project xmlns="http://maven.apache.org/POM/4.0.0" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
+    xsi:schemaLocation="http://maven.apache.org/POM/4.0.0
+                      http://maven.apache.org/xsd/maven-4.0.0.xsd">
+
+    <modelVersion>4.0.0</modelVersion>
+    <artifactId>org.gvsig.app</artifactId>
+    <packaging>jar</packaging>
+    <version>2.0-SNAPSHOT</version>
+    <name>Application gvSIG</name>
+    <description>gvSIG basic extensions</description>
+    <parent>
+        <groupId>org.gvsig</groupId>
+        <artifactId>gvsig-base-extension-pom</artifactId>
+        <version>2.0-SNAPSHOT</version>
+    </parent>
+    <dependencies>
+        <dependency>
+            <groupId>org.slf4j</groupId>
+            <artifactId>slf4j-api</artifactId>
+            <scope>compile</scope>
+        </dependency>
+        <dependency>
+            <groupId>org.gvsig</groupId>
+            <artifactId>org.gvsig.andami</artifactId>
+            <scope>compile</scope>
+        </dependency>
+        <dependency>
+            <groupId>org.gvsig</groupId>
+            <artifactId>org.gvsig.i18n</artifactId>
+            <scope>compile</scope>
+        </dependency>
+        <dependency>
+            <groupId>org.gvsig</groupId>
+            <artifactId>org.gvsig.utils</artifactId>
+            <scope>compile</scope>
+        </dependency>
+        <dependency>
+            <groupId>org.gvsig</groupId>
+            <artifactId>org.gvsig.coreplugin</artifactId>
+            <version>2.0-SNAPSHOT</version>
+            <scope>compile</scope>
+        </dependency>
+        <dependency>
+            <groupId>org.gvsig</groupId>
+            <artifactId>org.gvsig.ui</artifactId>
+            <scope>compile</scope>
+        </dependency>
+        <dependency>
+            <groupId>org.gvsig</groupId>
+            <artifactId>org.gvsig.fmap.control</artifactId>
+            <scope>compile</scope>
+        </dependency>
+        <dependency>
+            <groupId>org.gvsig</groupId>
+            <artifactId>org.gvsig.fmap.mapcontext</artifactId>
+            <scope>compile</scope>
+        </dependency>
+        <dependency>
+            <groupId>org.gvsig</groupId>
+            <artifactId>org.gvsig.fmap.mapcontext</artifactId>
+            <classifier>impl</classifier>
+        </dependency>
+        <dependency>
+            <groupId>org.gvsig</groupId>
+            <artifactId>org.gvsig.fmap.mapcontext</artifactId>
+            <classifier>operation</classifier>
+            <scope>compile</scope>
+        </dependency>
+        <dependency>
+            <groupId>org.gvsig</groupId>
+            <artifactId>org.gvsig.fmap.dal</artifactId>
+            <scope>compile</scope>
+        </dependency>
+        <dependency>
+            <groupId>org.gvsig</groupId>
+            <artifactId>org.gvsig.fmap.dal</artifactId>
+            <classifier>spi</classifier>
+            <scope>compile</scope>
+        </dependency>
+        <dependency>
+            <groupId>org.gvsig</groupId>
+            <artifactId>org.gvsig.fmap.dal</artifactId>
+            <classifier>impl</classifier>
+            <scope>compile</scope>
+        </dependency>
+        <dependency>
+            <groupId>org.gvsig</groupId>
+            <artifactId>org.gvsig.fmap.dal.index.spatial</artifactId>
+            <classifier>gt2</classifier>
+        </dependency>
+        <dependency>
+            <groupId>org.gvsig</groupId>
+            <artifactId>org.gvsig.fmap.dal.index.spatial</artifactId>
+            <classifier>jts</classifier>
+        </dependency>
+        <dependency>
+            <groupId>org.gvsig</groupId>
+            <artifactId>org.gvsig.fmap.dal.index.spatial</artifactId>
+            <classifier>jsi</classifier>
+        </dependency>
+        <dependency>
+            <groupId>org.gvsig</groupId>
+            <artifactId>org.gvsig.fmap.dal.file</artifactId>
+            <scope>compile</scope>
+        </dependency>
+        <dependency>
+            <groupId>org.gvsig</groupId>
+            <artifactId>org.gvsig.fmap.dal.file</artifactId>
+            <classifier>store.dbf</classifier>
+            <scope>compile</scope>
+        </dependency>
+        <dependency>
+            <groupId>org.gvsig</groupId>
+            <artifactId>org.gvsig.fmap.dal.file</artifactId>
+            <classifier>store.dxf</classifier>
+            <scope>compile</scope>
+        </dependency>
+        <dependency>
+            <groupId>org.gvsig</groupId>
+            <artifactId>org.gvsig.fmap.dal.file</artifactId>
+            <classifier>store.dxf.legend</classifier>
+        </dependency>
+        <dependency>
+            <groupId>org.gvsig</groupId>
+            <artifactId>org.gvsig.fmap.dal.file</artifactId>
+            <classifier>store.dgn</classifier>
+            <scope>compile</scope>
+        </dependency>
+        <dependency>
+            <groupId>org.gvsig</groupId>
+            <artifactId>org.gvsig.fmap.dal.file</artifactId>
+            <classifier>store.dgn.legend</classifier>
+        </dependency>
+        <dependency>
+            <groupId>org.gvsig</groupId>
+            <artifactId>org.gvsig.fmap.dal.file</artifactId>
+            <classifier>store.shp</classifier>
+            <scope>compile</scope>
+        </dependency>
+        <dependency>
+            <groupId>org.gvsig</groupId>
+            <artifactId>org.gvsig.symbology.lib.api</artifactId>
+            <scope>compile</scope>
+        </dependency>
+        <dependency>
+            <groupId>org.gvsig</groupId>
+            <artifactId>org.gvsig.symbology.lib.impl</artifactId>
+            <scope>compile</scope>
+        </dependency>
+        <dependency>
+            <groupId>org.gvsig</groupId>
+            <artifactId>org.gvsig.symbology.swing.api</artifactId>
+            <scope>compile</scope>
+        </dependency>
+        <dependency>
+            <groupId>org.gvsig</groupId>
+            <artifactId>org.gvsig.symbology.swing.impl</artifactId>
+            <scope>compile</scope>
+        </dependency>
+        <dependency>
+            <groupId>org.gvsig</groupId>
+            <artifactId>org.gvsig.fmap.geometry</artifactId>
+            <scope>compile</scope>
+        </dependency>
+        <dependency>
+            <groupId>org.gvsig</groupId>
+            <artifactId>org.gvsig.fmap.geometry</artifactId>
+            <classifier>impl</classifier>
+        </dependency>
+        <dependency>
+            <groupId>org.gvsig</groupId>
+            <artifactId>org.gvsig.fmap.geometry</artifactId>
+            <classifier>operation</classifier>
+            <scope>compile</scope>
+        </dependency>
+        <dependency>
+            <groupId>org.gvsig</groupId>
+            <artifactId>org.gvsig.tools.lib</artifactId>
+            <scope>compile</scope>
+        </dependency>
+        <dependency>
+            <groupId>org.gvsig</groupId>
+            <artifactId>org.gvsig.tools.lib</artifactId>
+            <type>test-jar</type>
+            <scope>test</scope>
+        </dependency>
+        <dependency>
+            <groupId>org.gvsig</groupId>
+            <artifactId>org.gvsig.tools.swing.api</artifactId>
+            <scope>compile</scope>
+        </dependency>
+        <dependency>
+            <groupId>org.gvsig</groupId>
+            <artifactId>org.gvsig.tools.swing.spi</artifactId>
+            <scope>compile</scope>
+        </dependency>
+        <dependency>
+            <groupId>org.gvsig</groupId>
+            <artifactId>org.gvsig.tools.swing.serv.field</artifactId>
+            <scope>compile</scope>
+        </dependency>
+        <dependency>
+            <groupId>org.gvsig</groupId>
+            <artifactId>org.gvsig.tools.evaluator.sqljep</artifactId>
+            <scope>compile</scope>
+        </dependency>
+        <dependency>
+            <groupId>org.gvsig</groupId>
+            <artifactId>org.gvsig.metadata.lib.basic.api</artifactId>
+            <scope>compile</scope>
+        </dependency>
+        <dependency>
+            <groupId>org.gvsig</groupId>
+            <artifactId>org.gvsig.metadata.lib.basic.impl</artifactId>
+        </dependency>
+        <dependency>
+            <groupId>org.gvsig</groupId>
+            <artifactId>org.gvsig.metadata.swing.basic.api</artifactId>
+            <scope>compile</scope>
+        </dependency>
+        <dependency>
+            <groupId>org.gvsig</groupId>
+            <artifactId>org.gvsig.metadata.swing.basic.impl</artifactId>
+        </dependency>
+        <dependency>
+            <groupId>org.gvsig</groupId>
+            <artifactId>org.gvsig.projection</artifactId>
+            <scope>compile</scope>
+        </dependency>
+        <dependency>
+            <groupId>org.gvsig</groupId>
+            <artifactId>org.gvsig.projection</artifactId>
+            <classifier>cresques-impl</classifier>
+        </dependency>
+        <dependency>
+            <groupId>org.gvsig</groupId>
+            <artifactId>org.gvsig.projection</artifactId>
+            <classifier>cresques-ui</classifier>
+            <scope>compile</scope>
+        </dependency>
+        <dependency>
+            <groupId>org.gvsig</groupId>
+            <artifactId>org.gvsig.compat</artifactId>
+            <scope>compile</scope>
+        </dependency>
+        <dependency>
+            <groupId>org.gvsig</groupId>
+            <artifactId>org.gvsig.compat</artifactId>
+            <classifier>se</classifier>
+        </dependency>
+        <dependency>
+            <groupId>org.gvsig</groupId>
+            <artifactId>org.gvsig.about.api</artifactId>
+            <scope>compile</scope>
+        </dependency>
+        <dependency>
+            <groupId>org.gvsig</groupId>
+            <artifactId>org.gvsig.about.impl</artifactId>
+        </dependency>
+        <dependency>
+            <groupId>org.gvsig</groupId>
+            <artifactId>org.gvsig.timesupport.lib.api</artifactId>
+            <scope>compile</scope>
+        </dependency>
+         <dependency>
+            <groupId>org.gvsig</groupId>
+            <artifactId>org.gvsig.timesupport.lib.impl</artifactId>
+            <scope>runtime</scope>
+        </dependency>
+        <dependency>
+            <groupId>org.opengis</groupId>
+            <artifactId>geoapi</artifactId>
+        </dependency>
+        <dependency>
+            <groupId>com.sun</groupId>
+            <artifactId>jimi</artifactId>
+            <scope>compile</scope>
+        </dependency>
+        <dependency>
+            <groupId>org.jpedal</groupId>
+            <artifactId>jpedal_lgpl</artifactId>
+            <scope>compile</scope>
+        </dependency>
+        <dependency>
+            <groupId>com.vividsolutions</groupId>
+            <artifactId>jts</artifactId>
+            <scope>compile</scope>
+        </dependency>
+        <dependency>
+            <groupId>zql</groupId>
+            <artifactId>zql</artifactId>
+            <scope>compile</scope>
+        </dependency>
+        <dependency>
+            <groupId>xml-apis</groupId>
+            <artifactId>xml-apis-ext</artifactId>
+            <scope>compile</scope>
+        </dependency>
+        <dependency>
+            <groupId>org.geotools</groupId>
+            <artifactId>gt2-main</artifactId>
+        </dependency>
+        <dependency>
+            <groupId>hsqldb</groupId>
+            <artifactId>hsqldb</artifactId>
+        </dependency>
+        <dependency>
+            <groupId>java3d</groupId>
+            <artifactId>vecmath</artifactId>
+            <scope>compile</scope>
+        </dependency>
+        <dependency>
+            <groupId>javax.media</groupId>
+            <artifactId>jai_core</artifactId>
+        </dependency>
+        <dependency>
+            <groupId>javax.media</groupId>
+            <artifactId>jai_codec</artifactId>
+        </dependency>
+        <!-- org.gvsig.projection dependencies to copy to the extension -->
+         <dependency>
+            <groupId>joda-time</groupId>
+            <artifactId>joda-time</artifactId>              
+        </dependency>
+        <dependency>
+            <groupId>geojava</groupId>
+            <artifactId>geojava</artifactId>
+        </dependency>
+        <dependency>
+            <groupId>org.gvsig</groupId>
+            <artifactId>org.gvsig.remoteclient</artifactId>
+            <scope>compile</scope>
+        </dependency>
+        <dependency>
+            <groupId>org.gvsig</groupId>
+            <artifactId>org.gvsig.installer.lib.api</artifactId>
+            <scope>compile</scope>
+        </dependency>
+        <dependency>
+            <groupId>javax.help</groupId>
+            <artifactId>javahelp</artifactId>
+            <scope>compile</scope>
+        </dependency>
+        <dependency>
+            <groupId>jwizardcomponent</groupId>
+            <artifactId>jwizardcomponent</artifactId>
+            <scope>compile</scope>
+        </dependency>
+        <dependency>
+            <groupId>castor</groupId>
+            <artifactId>castor</artifactId>
+            <scope>compile</scope>
+        </dependency>
+        <dependency>
+            <groupId>jfree</groupId>
+            <artifactId>jcommon</artifactId>
+            <scope>compile</scope>
+        </dependency>
+        <dependency>
+            <groupId>net.sf</groupId>
+            <artifactId>flib-jcalendar</artifactId>
+            <scope>compile</scope>
+        </dependency>
+        
+    </dependencies>
+    <properties>
+        <build-dir>${basedir}/../build</build-dir>
+        <eclipse.project.name>appgvSIG</eclipse.project.name>
+        <package.info.state>devel</package.info.state>
+        
+        <!-- alpha-devel -->
+
+        <!-- Just in case, those are some available package info property values -->
+        <!-- <package.info.state>alpha3</package.info.state> <package.info.official>true</package.info.official> 
+            <package.info.operatingSystem>all</package.info.operatingSystem> <package.info.architecture>all</package.info.architecture> 
+            <package.info.javaVM>j1_5</package.info.javaVM> <package.info.gvSIGVersion>2.0.0</package.info.gvSIGVersion> 
+            <package.info.baseDownloadURL> http://gvsig-desktop.forge.osor.eu/gvSIG-desktop/pool/${project.artifactId} 
+            </package.info.baseDownloadURL> -->
+    </properties>
+    <build>
+        <sourceDirectory>src</sourceDirectory>
+        <testSourceDirectory>src-test</testSourceDirectory>
+        <resources>
+            <resource>
+                <directory>resources</directory>
+                <filtering>true</filtering>
+                <includes>
+                    <include>**/andami-theme.xml</include>
+                </includes>
+            </resource>
+            <resource>
+                <directory>resources</directory>
+                <filtering>false</filtering>
+                <excludes>
+                    <exclude>**/andami-theme.xml</exclude>
+                </excludes>
+            </resource>
+        </resources>
+        <!-- TODO: MAKE TESTS WORK AND REMOVE THIS OPTION -->
+        <plugins>
+            <plugin>
+                <groupId>org.apache.maven.plugins</groupId>
+                <artifactId>maven-surefire-plugin</artifactId>
+                <configuration>
+                    <skipTests>true</skipTests>
+                </configuration>
+            </plugin>
+        </plugins>
+    </build>
+</project>
Index: tags/v2_0_0_Build_2050/applications/appgvSIG/resources/plugin-persistence.def
===================================================================
--- tags/v2_0_0_Build_2050/applications/appgvSIG/resources/plugin-persistence.def	(revision 0)
+++ tags/v2_0_0_Build_2050/applications/appgvSIG/resources/plugin-persistence.def	(revision 38653)
@@ -0,0 +1,32 @@
+<?xml version="1.0"?>
+<!--
+Definitions of plugin persistence org.gvsig.editing.  
+ -->
+<definitions>
+  <version>1.0.0</version>
+  <classes>
+    <class name="org.gvsig.app">
+      <description>Persistence for the gvSIG plugin</description>
+      <fields>
+        <field name="defaultSymbolLibraryPath" type="String" classOfValue="" mandatory="false">
+          <description>Default symbol library path</description>
+        </field>
+        <field name="defaultSymbolFillColorAleatory" type="Boolean" classOfValue="" mandatory="false">
+          <description></description>
+        </field>
+        <field name="defaultSymbolFillColor" type="OBJECT" classOfValue="java.awt.Color" mandatory="false">
+          <description></description>
+        </field>
+        <field name="defaultSymbolColor" type="OBJECT" classOfValue="java.awt.Color" mandatory="false">
+          <description></description>
+        </field>
+        <field name="defaultSymbolFont" type="OBJECT" classOfValue="java.awt.Font" mandatory="false">
+          <description></description>
+        </field>
+        <field name="symbolLibraryPath" type="String" classOfValue="" mandatory="false">
+          <description></description>
+        </field>
+      </fields>
+    </class>
+  </classes>
+</definitions>  
Index: tags/v2_0_0_Build_2050/applications/appgvSIG/resources/META-INF/services/org.gvsig.tools.library.Library
===================================================================
--- tags/v2_0_0_Build_2050/applications/appgvSIG/resources/META-INF/services/org.gvsig.tools.library.Library	(revision 0)
+++ tags/v2_0_0_Build_2050/applications/appgvSIG/resources/META-INF/services/org.gvsig.tools.library.Library	(revision 38653)
@@ -0,0 +1,2 @@
+org.gvsig.app.ApplicationLibrary
+org.gvsig.app.imp.AppgvSIGDefaultImplLibrary
\ No newline at end of file
Index: tags/v2_0_0_Build_2050/applications/appgvSIG/resources/theme/andami-theme.xml
===================================================================
--- tags/v2_0_0_Build_2050/applications/appgvSIG/resources/theme/andami-theme.xml	(revision 0)
+++ tags/v2_0_0_Build_2050/applications/appgvSIG/resources/theme/andami-theme.xml	(revision 38653)
@@ -0,0 +1,18 @@
+<AndamiProperties>
+	<ApplicationImages>
+		<SplashImages>
+			<Splash
+				path="splash.png"
+				timer="10000"
+				x="300" y="50"
+				fontsize="16" color="80,170,240"
+				version="${package.info.gvSIGVersion}.${buildNumber}"/>
+		</SplashImages>		
+		<!-- 
+		<BackgroundImage path="gvsig-icon16x16.png"/>
+		 -->
+		<WallpaperType value="CENTERED"/>
+		<Icon path="gvsig-icon16x16.png"/>
+	</ApplicationImages>
+	<ApplicationName value="gvSIG ${package.info.gvSIGVersion}.${buildNumber}"/>
+</AndamiProperties>
\ No newline at end of file
Index: tags/v2_0_0_Build_2050/applications/appgvSIG/resources/theme/gvsig-proj-black-wallpaper.png
===================================================================
Cannot display: file marked as a binary type.
svn:mime-type = application/octet-stream

Property changes on: tags/v2_0_0_Build_2050/applications/appgvSIG/resources/theme/gvsig-proj-black-wallpaper.png
___________________________________________________________________
Added: svn:mime-type
   + application/octet-stream

Index: tags/v2_0_0_Build_2050/applications/appgvSIG/resources/theme/splash.png
===================================================================
Cannot display: file marked as a binary type.
svn:mime-type = application/octet-stream

Property changes on: tags/v2_0_0_Build_2050/applications/appgvSIG/resources/theme/splash.png
___________________________________________________________________
Added: svn:mime-type
   + application/octet-stream

Index: tags/v2_0_0_Build_2050/applications/appgvSIG/resources/theme/gvsig-icon16x16.png
===================================================================
Cannot display: file marked as a binary type.
svn:mime-type = application/octet-stream

Property changes on: tags/v2_0_0_Build_2050/applications/appgvSIG/resources/theme/gvsig-icon16x16.png
___________________________________________________________________
Added: svn:mime-type
   + application/octet-stream

Index: tags/v2_0_0_Build_2050/applications/appgvSIG/resources/images/layer/layer-icon-dxf.png
===================================================================
Cannot display: file marked as a binary type.
svn:mime-type = application/octet-stream

Property changes on: tags/v2_0_0_Build_2050/applications/appgvSIG/resources/images/layer/layer-icon-dxf.png
___________________________________________________________________
Added: svn:mime-type
   + application/octet-stream

Index: tags/v2_0_0_Build_2050/applications/appgvSIG/resources/images/layer/layer-icon-jdbc.png
===================================================================
Cannot display: file marked as a binary type.
svn:mime-type = application/octet-stream

Property changes on: tags/v2_0_0_Build_2050/applications/appgvSIG/resources/images/layer/layer-icon-jdbc.png
___________________________________________________________________
Added: svn:mime-type
   + application/octet-stream

Index: tags/v2_0_0_Build_2050/applications/appgvSIG/resources/images/layer/layer-icon.png
===================================================================
Cannot display: file marked as a binary type.
svn:mime-type = application/octet-stream

Property changes on: tags/v2_0_0_Build_2050/applications/appgvSIG/resources/images/layer/layer-icon.png
___________________________________________________________________
Added: svn:mime-type
   + application/octet-stream

Index: tags/v2_0_0_Build_2050/applications/appgvSIG/resources/images/layer/layer-icon-postgresql.png
===================================================================
Cannot display: file marked as a binary type.
svn:mime-type = application/octet-stream

Property changes on: tags/v2_0_0_Build_2050/applications/appgvSIG/resources/images/layer/layer-icon-postgresql.png
___________________________________________________________________
Added: svn:mime-type
   + application/octet-stream

Index: tags/v2_0_0_Build_2050/applications/appgvSIG/resources/images/layer/layer-icon-mysql.png
===================================================================
Cannot display: file marked as a binary type.
svn:mime-type = application/octet-stream

Property changes on: tags/v2_0_0_Build_2050/applications/appgvSIG/resources/images/layer/layer-icon-mysql.png
___________________________________________________________________
Added: svn:mime-type
   + application/octet-stream

Index: tags/v2_0_0_Build_2050/applications/appgvSIG/resources/images/layer/layer-icon-dgn.png
===================================================================
Cannot display: file marked as a binary type.
svn:mime-type = application/octet-stream

Property changes on: tags/v2_0_0_Build_2050/applications/appgvSIG/resources/images/layer/layer-icon-dgn.png
___________________________________________________________________
Added: svn:mime-type
   + application/octet-stream

Index: tags/v2_0_0_Build_2050/applications/appgvSIG/resources/images/layer/layer-icon-vectorial.png
===================================================================
Cannot display: file marked as a binary type.
svn:mime-type = application/octet-stream

Property changes on: tags/v2_0_0_Build_2050/applications/appgvSIG/resources/images/layer/layer-icon-vectorial.png
___________________________________________________________________
Added: svn:mime-type
   + application/octet-stream

Index: tags/v2_0_0_Build_2050/applications/appgvSIG/resources/images/layer/layer-icon-group.png
===================================================================
Cannot display: file marked as a binary type.
svn:mime-type = application/octet-stream

Property changes on: tags/v2_0_0_Build_2050/applications/appgvSIG/resources/images/layer/layer-icon-group.png
___________________________________________________________________
Added: svn:mime-type
   + application/octet-stream

Index: tags/v2_0_0_Build_2050/applications/appgvSIG/resources/images/action/edit-copy.png
===================================================================
Cannot display: file marked as a binary type.
svn:mime-type = application/octet-stream

Property changes on: tags/v2_0_0_Build_2050/applications/appgvSIG/resources/images/action/edit-copy.png
___________________________________________________________________
Added: svn:mime-type
   + application/octet-stream

Index: tags/v2_0_0_Build_2050/applications/appgvSIG/resources/images/action/application-project-new.png
===================================================================
Cannot display: file marked as a binary type.
svn:mime-type = application/octet-stream

Property changes on: tags/v2_0_0_Build_2050/applications/appgvSIG/resources/images/action/application-project-new.png
___________________________________________________________________
Added: svn:mime-type
   + application/octet-stream

Index: tags/v2_0_0_Build_2050/applications/appgvSIG/resources/images/action/layer-filter.png
===================================================================
Cannot display: file marked as a binary type.
svn:mime-type = application/octet-stream

Property changes on: tags/v2_0_0_Build_2050/applications/appgvSIG/resources/images/action/layer-filter.png
___________________________________________________________________
Added: svn:mime-type
   + application/octet-stream

Index: tags/v2_0_0_Build_2050/applications/appgvSIG/resources/images/action/selection-select-by-polygon.png
===================================================================
Cannot display: file marked as a binary type.
svn:mime-type = application/octet-stream

Property changes on: tags/v2_0_0_Build_2050/applications/appgvSIG/resources/images/action/selection-select-by-polygon.png
___________________________________________________________________
Added: svn:mime-type
   + application/octet-stream

Index: tags/v2_0_0_Build_2050/applications/appgvSIG/resources/images/action/edit-find.png
===================================================================
Cannot display: file marked as a binary type.
svn:mime-type = application/octet-stream

Property changes on: tags/v2_0_0_Build_2050/applications/appgvSIG/resources/images/action/edit-find.png
___________________________________________________________________
Added: svn:mime-type
   + application/octet-stream

Index: tags/v2_0_0_Build_2050/applications/appgvSIG/resources/images/action/application-project-open.png
===================================================================
Cannot display: file marked as a binary type.
svn:mime-type = application/octet-stream

Property changes on: tags/v2_0_0_Build_2050/applications/appgvSIG/resources/images/action/application-project-open.png
___________________________________________________________________
Added: svn:mime-type
   + application/octet-stream

Index: tags/v2_0_0_Build_2050/applications/appgvSIG/resources/images/action/document-print.png
===================================================================
Cannot display: file marked as a binary type.
svn:mime-type = application/octet-stream

Property changes on: tags/v2_0_0_Build_2050/applications/appgvSIG/resources/images/action/document-print.png
___________________________________________________________________
Added: svn:mime-type
   + application/octet-stream

Index: tags/v2_0_0_Build_2050/applications/appgvSIG/resources/images/action/edit-clear.png
===================================================================
Cannot display: file marked as a binary type.
svn:mime-type = application/octet-stream

Property changes on: tags/v2_0_0_Build_2050/applications/appgvSIG/resources/images/action/edit-clear.png
___________________________________________________________________
Added: svn:mime-type
   + application/octet-stream

Index: tags/v2_0_0_Build_2050/applications/appgvSIG/resources/images/action/edit-redo.png
===================================================================
Cannot display: file marked as a binary type.
svn:mime-type = application/octet-stream

Property changes on: tags/v2_0_0_Build_2050/applications/appgvSIG/resources/images/action/edit-redo.png
___________________________________________________________________
Added: svn:mime-type
   + application/octet-stream

Index: tags/v2_0_0_Build_2050/applications/appgvSIG/resources/images/action/view-navigation-zoom-out-center.png
===================================================================
Cannot display: file marked as a binary type.
svn:mime-type = application/octet-stream

Property changes on: tags/v2_0_0_Build_2050/applications/appgvSIG/resources/images/action/view-navigation-zoom-out-center.png
___________________________________________________________________
Added: svn:mime-type
   + application/octet-stream

Index: tags/v2_0_0_Build_2050/applications/appgvSIG/resources/images/action/edit-undo-redo-actions.png
===================================================================
Cannot display: file marked as a binary type.
svn:mime-type = application/octet-stream

Property changes on: tags/v2_0_0_Build_2050/applications/appgvSIG/resources/images/action/edit-undo-redo-actions.png
___________________________________________________________________
Added: svn:mime-type
   + application/octet-stream

Index: tags/v2_0_0_Build_2050/applications/appgvSIG/resources/images/action/edit-cut.png
===================================================================
Cannot display: file marked as a binary type.
svn:mime-type = application/octet-stream

Property changes on: tags/v2_0_0_Build_2050/applications/appgvSIG/resources/images/action/edit-cut.png
___________________________________________________________________
Added: svn:mime-type
   + application/octet-stream

Index: tags/v2_0_0_Build_2050/applications/appgvSIG/resources/images/action/view-navigation-pan.png
===================================================================
Cannot display: file marked as a binary type.
svn:mime-type = application/octet-stream

Property changes on: tags/v2_0_0_Build_2050/applications/appgvSIG/resources/images/action/view-navigation-pan.png
___________________________________________________________________
Added: svn:mime-type
   + application/octet-stream

Index: tags/v2_0_0_Build_2050/applications/appgvSIG/resources/images/action/view-query-area.png
===================================================================
Cannot display: file marked as a binary type.
svn:mime-type = application/octet-stream

Property changes on: tags/v2_0_0_Build_2050/applications/appgvSIG/resources/images/action/view-query-area.png
___________________________________________________________________
Added: svn:mime-type
   + application/octet-stream

Index: tags/v2_0_0_Build_2050/applications/appgvSIG/resources/images/action/edit-delete.png
===================================================================
Cannot display: file marked as a binary type.
svn:mime-type = application/octet-stream

Property changes on: tags/v2_0_0_Build_2050/applications/appgvSIG/resources/images/action/edit-delete.png
___________________________________________________________________
Added: svn:mime-type
   + application/octet-stream

Index: tags/v2_0_0_Build_2050/applications/appgvSIG/resources/images/action/view-navigation-zoom-back.png
===================================================================
Cannot display: file marked as a binary type.
svn:mime-type = application/octet-stream

Property changes on: tags/v2_0_0_Build_2050/applications/appgvSIG/resources/images/action/view-navigation-zoom-back.png
___________________________________________________________________
Added: svn:mime-type
   + application/octet-stream

Index: tags/v2_0_0_Build_2050/applications/appgvSIG/resources/images/action/selection-reverse.png
===================================================================
Cannot display: file marked as a binary type.
svn:mime-type = application/octet-stream

Property changes on: tags/v2_0_0_Build_2050/applications/appgvSIG/resources/images/action/selection-reverse.png
___________________________________________________________________
Added: svn:mime-type
   + application/octet-stream

Index: tags/v2_0_0_Build_2050/applications/appgvSIG/resources/images/action/view-navigation-zoom-all.png
===================================================================
Cannot display: file marked as a binary type.
svn:mime-type = application/octet-stream

Property changes on: tags/v2_0_0_Build_2050/applications/appgvSIG/resources/images/action/view-navigation-zoom-all.png
___________________________________________________________________
Added: svn:mime-type
   + application/octet-stream

Index: tags/v2_0_0_Build_2050/applications/appgvSIG/resources/images/action/edit-paste.png
===================================================================
Cannot display: file marked as a binary type.
svn:mime-type = application/octet-stream

Property changes on: tags/v2_0_0_Build_2050/applications/appgvSIG/resources/images/action/edit-paste.png
___________________________________________________________________
Added: svn:mime-type
   + application/octet-stream

Index: tags/v2_0_0_Build_2050/applications/appgvSIG/resources/images/action/application-project-save.png
===================================================================
Cannot display: file marked as a binary type.
svn:mime-type = application/octet-stream

Property changes on: tags/v2_0_0_Build_2050/applications/appgvSIG/resources/images/action/application-project-save.png
___________________________________________________________________
Added: svn:mime-type
   + application/octet-stream

Index: tags/v2_0_0_Build_2050/applications/appgvSIG/resources/images/action/layer-info-by-point.png
===================================================================
Cannot display: file marked as a binary type.
svn:mime-type = application/octet-stream

Property changes on: tags/v2_0_0_Build_2050/applications/appgvSIG/resources/images/action/layer-info-by-point.png
___________________________________________________________________
Added: svn:mime-type
   + application/octet-stream

Index: tags/v2_0_0_Build_2050/applications/appgvSIG/resources/images/action/application-project-save-as.png
===================================================================
Cannot display: file marked as a binary type.
svn:mime-type = application/octet-stream

Property changes on: tags/v2_0_0_Build_2050/applications/appgvSIG/resources/images/action/application-project-save-as.png
___________________________________________________________________
Added: svn:mime-type
   + application/octet-stream

Index: tags/v2_0_0_Build_2050/applications/appgvSIG/resources/images/action/view-query-distance.png
===================================================================
Cannot display: file marked as a binary type.
svn:mime-type = application/octet-stream

Property changes on: tags/v2_0_0_Build_2050/applications/appgvSIG/resources/images/action/view-query-distance.png
___________________________________________________________________
Added: svn:mime-type
   + application/octet-stream

Index: tags/v2_0_0_Build_2050/applications/appgvSIG/resources/images/action/view-navigation-frame-manager.png
===================================================================
Cannot display: file marked as a binary type.
svn:mime-type = application/octet-stream

Property changes on: tags/v2_0_0_Build_2050/applications/appgvSIG/resources/images/action/view-navigation-frame-manager.png
___________________________________________________________________
Added: svn:mime-type
   + application/octet-stream

Index: tags/v2_0_0_Build_2050/applications/appgvSIG/resources/images/action/edit-select-all.png
===================================================================
Cannot display: file marked as a binary type.
svn:mime-type = application/octet-stream

Property changes on: tags/v2_0_0_Build_2050/applications/appgvSIG/resources/images/action/edit-select-all.png
___________________________________________________________________
Added: svn:mime-type
   + application/octet-stream

Index: tags/v2_0_0_Build_2050/applications/appgvSIG/resources/images/action/selection-clear.png
===================================================================
Cannot display: file marked as a binary type.
svn:mime-type = application/octet-stream

Property changes on: tags/v2_0_0_Build_2050/applications/appgvSIG/resources/images/action/selection-clear.png
___________________________________________________________________
Added: svn:mime-type
   + application/octet-stream

Index: tags/v2_0_0_Build_2050/applications/appgvSIG/resources/images/action/view-layer-add.png
===================================================================
Cannot display: file marked as a binary type.
svn:mime-type = application/octet-stream

Property changes on: tags/v2_0_0_Build_2050/applications/appgvSIG/resources/images/action/view-layer-add.png
___________________________________________________________________
Added: svn:mime-type
   + application/octet-stream

Index: tags/v2_0_0_Build_2050/applications/appgvSIG/resources/images/action/application-exit.png
===================================================================
Cannot display: file marked as a binary type.
svn:mime-type = application/octet-stream

Property changes on: tags/v2_0_0_Build_2050/applications/appgvSIG/resources/images/action/application-exit.png
___________________________________________________________________
Added: svn:mime-type
   + application/octet-stream

Index: tags/v2_0_0_Build_2050/applications/appgvSIG/resources/images/action/view-navigation-zoom-in-center.png
===================================================================
Cannot display: file marked as a binary type.
svn:mime-type = application/octet-stream

Property changes on: tags/v2_0_0_Build_2050/applications/appgvSIG/resources/images/action/view-navigation-zoom-in-center.png
___________________________________________________________________
Added: svn:mime-type
   + application/octet-stream

Index: tags/v2_0_0_Build_2050/applications/appgvSIG/resources/images/action/edit-find-replace.png
===================================================================
Cannot display: file marked as a binary type.
svn:mime-type = application/octet-stream

Property changes on: tags/v2_0_0_Build_2050/applications/appgvSIG/resources/images/action/edit-find-replace.png
___________________________________________________________________
Added: svn:mime-type
   + application/octet-stream

Index: tags/v2_0_0_Build_2050/applications/appgvSIG/resources/images/action/selection-select-by-rectangle.png
===================================================================
Cannot display: file marked as a binary type.
svn:mime-type = application/octet-stream

Property changes on: tags/v2_0_0_Build_2050/applications/appgvSIG/resources/images/action/selection-select-by-rectangle.png
___________________________________________________________________
Added: svn:mime-type
   + application/octet-stream

Index: tags/v2_0_0_Build_2050/applications/appgvSIG/resources/images/action/view-navigation-zoom-in-topoint.png
===================================================================
Cannot display: file marked as a binary type.
svn:mime-type = application/octet-stream

Property changes on: tags/v2_0_0_Build_2050/applications/appgvSIG/resources/images/action/view-navigation-zoom-in-topoint.png
___________________________________________________________________
Added: svn:mime-type
   + application/octet-stream

Index: tags/v2_0_0_Build_2050/applications/appgvSIG/resources/images/action/view-navigation-zoom-out-topoint.png
===================================================================
Cannot display: file marked as a binary type.
svn:mime-type = application/octet-stream

Property changes on: tags/v2_0_0_Build_2050/applications/appgvSIG/resources/images/action/view-navigation-zoom-out-topoint.png
___________________________________________________________________
Added: svn:mime-type
   + application/octet-stream

Index: tags/v2_0_0_Build_2050/applications/appgvSIG/resources/images/action/edit-undo.png
===================================================================
Cannot display: file marked as a binary type.
svn:mime-type = application/octet-stream

Property changes on: tags/v2_0_0_Build_2050/applications/appgvSIG/resources/images/action/edit-undo.png
___________________________________________________________________
Added: svn:mime-type
   + application/octet-stream

Index: tags/v2_0_0_Build_2050/applications/appgvSIG/resources/images/action/selection-simple-select.png
===================================================================
Cannot display: file marked as a binary type.
svn:mime-type = application/octet-stream

Property changes on: tags/v2_0_0_Build_2050/applications/appgvSIG/resources/images/action/selection-simple-select.png
___________________________________________________________________
Added: svn:mime-type
   + application/octet-stream

Index: tags/v2_0_0_Build_2050/applications/appgvSIG/resources/images/action/view-navigation-zoom-to-selection.png
===================================================================
Cannot display: file marked as a binary type.
svn:mime-type = application/octet-stream

Property changes on: tags/v2_0_0_Build_2050/applications/appgvSIG/resources/images/action/view-navigation-zoom-to-selection.png
___________________________________________________________________
Added: svn:mime-type
   + application/octet-stream

Index: tags/v2_0_0_Build_2050/applications/appgvSIG/resources/images/cursor/cursor-zoom-in.png
===================================================================
Cannot display: file marked as a binary type.
svn:mime-type = application/octet-stream

Property changes on: tags/v2_0_0_Build_2050/applications/appgvSIG/resources/images/cursor/cursor-zoom-in.png
___________________________________________________________________
Added: svn:mime-type
   + application/octet-stream

Index: tags/v2_0_0_Build_2050/applications/appgvSIG/resources/images/cursor/cursor-zoom-out.png
===================================================================
Cannot display: file marked as a binary type.
svn:mime-type = application/octet-stream

Property changes on: tags/v2_0_0_Build_2050/applications/appgvSIG/resources/images/cursor/cursor-zoom-out.png
___________________________________________________________________
Added: svn:mime-type
   + application/octet-stream

Index: tags/v2_0_0_Build_2050/applications/appgvSIG/resources/images/cursor/cursor-info-by-point.png
===================================================================
Cannot display: file marked as a binary type.
svn:mime-type = application/octet-stream

Property changes on: tags/v2_0_0_Build_2050/applications/appgvSIG/resources/images/cursor/cursor-info-by-point.png
___________________________________________________________________
Added: svn:mime-type
   + application/octet-stream

Index: tags/v2_0_0_Build_2050/applications/appgvSIG/resources/images/cursor/cursor-query-area.png
===================================================================
Cannot display: file marked as a binary type.
svn:mime-type = application/octet-stream

Property changes on: tags/v2_0_0_Build_2050/applications/appgvSIG/resources/images/cursor/cursor-query-area.png
___________________________________________________________________
Added: svn:mime-type
   + application/octet-stream

Index: tags/v2_0_0_Build_2050/applications/appgvSIG/resources/images/cursor/cursor-select-by-polygon.png
===================================================================
Cannot display: file marked as a binary type.
svn:mime-type = application/octet-stream

Property changes on: tags/v2_0_0_Build_2050/applications/appgvSIG/resources/images/cursor/cursor-select-by-polygon.png
___________________________________________________________________
Added: svn:mime-type
   + application/octet-stream

Index: tags/v2_0_0_Build_2050/applications/appgvSIG/resources/images/cursor/cursor-query-distance.png
===================================================================
Cannot display: file marked as a binary type.
svn:mime-type = application/octet-stream

Property changes on: tags/v2_0_0_Build_2050/applications/appgvSIG/resources/images/cursor/cursor-query-distance.png
___________________________________________________________________
Added: svn:mime-type
   + application/octet-stream

Index: tags/v2_0_0_Build_2050/applications/appgvSIG/resources/images/cursor/cursor-pan.png
===================================================================
Cannot display: file marked as a binary type.
svn:mime-type = application/octet-stream

Property changes on: tags/v2_0_0_Build_2050/applications/appgvSIG/resources/images/cursor/cursor-pan.png
___________________________________________________________________
Added: svn:mime-type
   + application/octet-stream

Index: tags/v2_0_0_Build_2050/applications/appgvSIG/resources/images/cursor/cursor-select-by-point.png
===================================================================
Cannot display: file marked as a binary type.
svn:mime-type = application/octet-stream

Property changes on: tags/v2_0_0_Build_2050/applications/appgvSIG/resources/images/cursor/cursor-select-by-point.png
___________________________________________________________________
Added: svn:mime-type
   + application/octet-stream

Index: tags/v2_0_0_Build_2050/applications/appgvSIG/resources/images/cursor/cursor-crux.png
===================================================================
Cannot display: file marked as a binary type.
svn:mime-type = application/octet-stream

Property changes on: tags/v2_0_0_Build_2050/applications/appgvSIG/resources/images/cursor/cursor-crux.png
___________________________________________________________________
Added: svn:mime-type
   + application/octet-stream

Index: tags/v2_0_0_Build_2050/applications/appgvSIG/resources/images/document/document-view-icon.png
===================================================================
Cannot display: file marked as a binary type.
svn:mime-type = application/octet-stream

Property changes on: tags/v2_0_0_Build_2050/applications/appgvSIG/resources/images/document/document-view-icon.png
___________________________________________________________________
Added: svn:mime-type
   + application/octet-stream

Index: tags/v2_0_0_Build_2050/applications/appgvSIG/resources/images/document/document-view-icon-sel.png
===================================================================
Cannot display: file marked as a binary type.
svn:mime-type = application/octet-stream

Property changes on: tags/v2_0_0_Build_2050/applications/appgvSIG/resources/images/document/document-view-icon-sel.png
___________________________________________________________________
Added: svn:mime-type
   + application/octet-stream

Index: tags/v2_0_0_Build_2050/applications/appgvSIG/resources/images/legend/legend-overview-single-symbol.png
===================================================================
Cannot display: file marked as a binary type.
svn:mime-type = application/octet-stream

Property changes on: tags/v2_0_0_Build_2050/applications/appgvSIG/resources/images/legend/legend-overview-single-symbol.png
___________________________________________________________________
Added: svn:mime-type
   + application/octet-stream

Index: tags/v2_0_0_Build_2050/applications/appgvSIG/resources/images/legend/legend-overview-vectorial-unique-value.png
===================================================================
Cannot display: file marked as a binary type.
svn:mime-type = application/octet-stream

Property changes on: tags/v2_0_0_Build_2050/applications/appgvSIG/resources/images/legend/legend-overview-vectorial-unique-value.png
___________________________________________________________________
Added: svn:mime-type
   + application/octet-stream

Index: tags/v2_0_0_Build_2050/applications/appgvSIG/resources/images/legend/legend-overview-vectorial-interval.png
===================================================================
Cannot display: file marked as a binary type.
svn:mime-type = application/octet-stream

Property changes on: tags/v2_0_0_Build_2050/applications/appgvSIG/resources/images/legend/legend-overview-vectorial-interval.png
___________________________________________________________________
Added: svn:mime-type
   + application/octet-stream

Index: tags/v2_0_0_Build_2050/applications/appgvSIG/resources/images/toolbar-go/go-first.png
===================================================================
Cannot display: file marked as a binary type.
svn:mime-type = application/octet-stream

Property changes on: tags/v2_0_0_Build_2050/applications/appgvSIG/resources/images/toolbar-go/go-first.png
___________________________________________________________________
Added: svn:mime-type
   + application/octet-stream

Index: tags/v2_0_0_Build_2050/applications/appgvSIG/resources/images/toolbar-go/go-previous-fast.png
===================================================================
Cannot display: file marked as a binary type.
svn:mime-type = application/octet-stream

Property changes on: tags/v2_0_0_Build_2050/applications/appgvSIG/resources/images/toolbar-go/go-previous-fast.png
___________________________________________________________________
Added: svn:mime-type
   + application/octet-stream

Index: tags/v2_0_0_Build_2050/applications/appgvSIG/resources/images/toolbar-go/go-next-fast.png
===================================================================
Cannot display: file marked as a binary type.
svn:mime-type = application/octet-stream

Property changes on: tags/v2_0_0_Build_2050/applications/appgvSIG/resources/images/toolbar-go/go-next-fast.png
___________________________________________________________________
Added: svn:mime-type
   + application/octet-stream

Index: tags/v2_0_0_Build_2050/applications/appgvSIG/resources/images/toolbar-go/go-previous.png
===================================================================
Cannot display: file marked as a binary type.
svn:mime-type = application/octet-stream

Property changes on: tags/v2_0_0_Build_2050/applications/appgvSIG/resources/images/toolbar-go/go-previous.png
___________________________________________________________________
Added: svn:mime-type
   + application/octet-stream

Index: tags/v2_0_0_Build_2050/applications/appgvSIG/resources/images/toolbar-go/go-next.png
===================================================================
Cannot display: file marked as a binary type.
svn:mime-type = application/octet-stream

Property changes on: tags/v2_0_0_Build_2050/applications/appgvSIG/resources/images/toolbar-go/go-next.png
___________________________________________________________________
Added: svn:mime-type
   + application/octet-stream

Index: tags/v2_0_0_Build_2050/applications/appgvSIG/resources/images/toolbar-go/go-last.png
===================================================================
Cannot display: file marked as a binary type.
svn:mime-type = application/octet-stream

Property changes on: tags/v2_0_0_Build_2050/applications/appgvSIG/resources/images/toolbar-go/go-last.png
___________________________________________________________________
Added: svn:mime-type
   + application/octet-stream

Index: tags/v2_0_0_Build_2050/applications/appgvSIG/dist_resources/gvSIG.bat
===================================================================
--- tags/v2_0_0_Build_2050/applications/appgvSIG/dist_resources/gvSIG.bat	(revision 0)
+++ tags/v2_0_0_Build_2050/applications/appgvSIG/dist_resources/gvSIG.bat	(revision 38653)
@@ -0,0 +1,35 @@
+@echo off
+rem set gvSIG_JRE_HOME=
+rem set this_path=
+set error=N
+IF DEFINED gvSIG_JRE_HOME goto check_this_path
+ECHO No se ha establecido la variable 'gvSIG_JRE_HOME'
+ECHO . 
+set error=S
+:check_this_path
+IF DEFINED this_path goto check_errors
+ECHO No se ha establecido la variable 'this_path'
+set error=S
+:check_errors
+IF "%error%" == "N" goto run
+Echo . 
+ECHO Para que funcione este arranque de gvSIG debe editar este fichero
+ECHO y modificar las siguentes lineas:
+ECHO . 
+ECHO rem set gvSIG_JRE_HOME=
+ECHO rem set this_path=
+ECHO . 
+ECHO Dejandolas asi:
+ECHO . 
+ECHO set gvSIG_JRE_HOME={ruta a la jre preparada para gvsig}
+ECHO set this_path={ruta en la que se encuentra este archivo}
+ECHO .  
+ECHO Ejecucion cancelada
+pause
+goto end
+
+:run
+cd "%this_path%"
+"%gvSIG_JRE_HOME%\bin\java.exe" -cp ##Andami_classpath## -Xmx500M com.iver.andami.Launcher gvSIG gvSIG/extensiones %1
+
+:end
\ No newline at end of file

Property changes on: tags/v2_0_0_Build_2050/applications/appgvSIG/dist_resources/gvSIG.bat
___________________________________________________________________
Added: svn:eol-style
   + CRLF

Index: tags/v2_0_0_Build_2050/applications/appgvSIG/dist_resources/gvSIG.sh
===================================================================
--- tags/v2_0_0_Build_2050/applications/appgvSIG/dist_resources/gvSIG.sh	(revision 0)
+++ tags/v2_0_0_Build_2050/applications/appgvSIG/dist_resources/gvSIG.sh	(revision 38653)
@@ -0,0 +1,32 @@
+#!/bin/sh
+# gvSIG.sh
+
+GVSIG_SH_FILE=`readlink -f $0`
+GVSIG_BIN=`dirname $GVSIG_SH_FILE`
+#GVSIG_JRE_HOME=$HOME/gvSIG/jre/1.5.0_12
+GVSIG_JRE_HOME=$HOME/gvSIG/jre/1.5.0_12
+# Comporbar la JRE
+if [ ! -f "$GVSIG_JRE_HOME/bin/java" ] 
+then 
+{
+	echo No se ha encontrado el ejecutalble de la JRE en $GVSIG_JRE_HOME/bin/java
+	echo 
+	echo "Edite este fichero ($0) y modifique la variable GVSIG_JRE_HOME"
+	echo para que tenga una ruta al JAVA_HOME preparado para gvSIG
+	exit 1
+}
+fi
+
+export JAVA_HOME="$GVSIG_JRE_HOME"
+export LD_LIBRARY_PATH=$LD_LIBRARY_PATH:"$GVSIG_LIBS"
+cd "$GVSIG_BIN"
+
+
+for i in $GVSIG_BIN/lib/*.jar ; do
+  LIBRARIES=$LIBRARIES:"$i"
+done
+for i in $GVSIG_BIN/lib/*.zip ; do
+  LIBRARIES=$LIBRARIES:"$i"
+done
+
+"$JAVA_HOME"/bin/java -cp $GVSIG_BIN/bin:$LIBRARIES  -Xmx500M com.iver.andami.Launcher gvSIG gvSIG/extensiones "$@"
\ No newline at end of file

Property changes on: tags/v2_0_0_Build_2050/applications/appgvSIG/dist_resources/gvSIG.sh
___________________________________________________________________
Added: svn:eol-style
   + LF

Index: tags/v2_0_0_Build_2050/applications/appgvSIG/A.txt
===================================================================
--- tags/v2_0_0_Build_2050/applications/appgvSIG/A.txt	(revision 0)
+++ tags/v2_0_0_Build_2050/applications/appgvSIG/A.txt	(revision 38653)
@@ -0,0 +1,45 @@
+ ============================================================================
+                   The Apache Software License, Version 1.1
+ ============================================================================
+ 
+ Copyright (C) 2000 The Apache Software Foundation. All rights reserved.
+ 
+ Redistribution and use in source and binary forms, with or without modifica-
+ tion, are permitted provided that the following conditions are met:
+ 
+ 1. Redistributions of  source code must  retain the above copyright  notice,
+    this list of conditions and the following disclaimer.
+ 
+ 2. Redistributions in binary form must reproduce the above copyright notice,
+    this list of conditions and the following disclaimer in the documentation
+    and/or other materials provided with the distribution.
+ 
+ 3. The end-user documentation included with the redistribution, if any, must
+    include  the following  acknowledgment:  "This product includes  software
+    developed  by the  Apache Software Foundation  (http://www.apache.org/)."
+    Alternately, this  acknowledgment may  appear in the software itself,  if
+    and wherever such third-party acknowledgments normally appear.
+ 
+ 4. The names "Batik" and  "Apache Software Foundation"  must not be  used to
+    endorse  or promote  products derived  from this  software without  prior
+    written permission. For written permission, please contact
+    apache@apache.org.
+ 
+ 5. Products  derived from this software may not  be called "Apache", nor may
+    "Apache" appear  in their name,  without prior written permission  of the
+    Apache Software Foundation.
+ 
+ THIS SOFTWARE IS PROVIDED ``AS IS'' AND ANY EXPRESSED OR IMPLIED WARRANTIES,
+ INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND
+ FITNESS  FOR A PARTICULAR  PURPOSE ARE  DISCLAIMED.  IN NO  EVENT SHALL  THE
+ APACHE SOFTWARE  FOUNDATION  OR ITS CONTRIBUTORS  BE LIABLE FOR  ANY DIRECT,
+ INDIRECT, INCIDENTAL, SPECIAL,  EXEMPLARY, OR CONSEQUENTIAL  DAMAGES (INCLU-
+ DING, BUT NOT LIMITED TO, PROCUREMENT  OF SUBSTITUTE GOODS OR SERVICES; LOSS
+ OF USE, DATA, OR  PROFITS; OR BUSINESS  INTERRUPTION)  HOWEVER CAUSED AND ON
+ ANY  THEORY OF LIABILITY,  WHETHER  IN CONTRACT,  STRICT LIABILITY,  OR TORT
+ (INCLUDING  NEGLIGENCE OR  OTHERWISE) ARISING IN  ANY WAY OUT OF THE  USE OF
+ THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
+ 
+ This software  consists of voluntary contributions made  by many individuals
+ on  behalf  of the Apache Software  Foundation. For more  information on the
+ Apache Software Foundation, please see <http://www.apache.org/>.

Property changes on: tags/v2_0_0_Build_2050/applications/appgvSIG/A.txt
___________________________________________________________________
Added: svn:keywords
   + Author Date Id Revision
Added: svn:eol-style
   + native

Index: tags/v2_0_0_Build_2050/applications/appgvSIG/distribution/distribution.xml
===================================================================
--- tags/v2_0_0_Build_2050/applications/appgvSIG/distribution/distribution.xml	(revision 0)
+++ tags/v2_0_0_Build_2050/applications/appgvSIG/distribution/distribution.xml	(revision 38653)
@@ -0,0 +1,144 @@
+<assembly>
+	<id>distribution</id>
+	<formats>
+		<format>dir</format>
+	</formats>
+	<fileSets>
+	<!-- Extructure for the extension -->
+		<fileSet>
+			<directory>config</directory>
+			<outputDirectory>${extension.install.dir.name}
+			</outputDirectory>
+		</fileSet>
+        <!-- Copy all resources but the theme ones, as they are handled
+        through resource filtering -->
+		<fileSet>
+			<directory>resources</directory>
+			<outputDirectory>${extension.install.dir.name}
+			</outputDirectory>
+            <excludes>
+                <exclude>**/theme/**</exclude>
+            </excludes>
+		</fileSet>
+        <!-- Copy the theme files from the target folder as they have been
+        filtered there, to set the gvSIG version for example. -->
+        <fileSet>
+            <directory>target/classes/theme</directory>
+            <outputDirectory>${extension.install.dir.name}/theme
+            </outputDirectory>
+        </fileSet>
+	</fileSets>
+    <files>
+        <file>
+            <source>package.info</source>
+            <outputDirectory>${extension.install.dir.name}
+            </outputDirectory>
+        </file>
+    </files>
+	<!--
+		***********************************************************************
+	-->
+  <!-- *													   *-->
+	<!--
+		***********************************************************************
+	-->
+	<dependencySets>
+		<dependencySet>
+			<outputDirectory>${extension.install.dir.name}/${library-dir}
+			</outputDirectory>
+			<includes>
+
+				<!-- org.gvsig.i18n -->
+				<include>org.gvsig:org.gvsig.i18n</include>
+				
+				<!-- org.gvsig.metadata -->
+				<include>org.gvsig:org.gvsig.metadata.lib.basic.api</include>
+				<include>org.gvsig:org.gvsig.metadata.lib.basic.impl</include>
+				<include>org.gvsig:org.gvsig.metadata.swing.basic.api</include>
+				<include>org.gvsig:org.gvsig.metadata.swing.basic.impl</include>
+				
+				<!--  org.gvsig.timesupport -->
+				<include>org.gvsig:org.gvsig.timesupport.lib.api</include>
+                <include>org.gvsig:org.gvsig.timesupport.lib.impl</include>
+                <include>joda-time:joda-time</include>			
+				
+				<!-- org.gvsig.compat -->
+				<include>org.gvsig:org.gvsig.compat</include>
+				<include>org.gvsig:org.gvsig.compat:jar:se</include>
+
+				<!-- org.gvsig.projection -->
+				<include>org.gvsig:org.gvsig.projection</include>
+				<include>org.gvsig:org.gvsig.projection:jar:cresques-impl</include>
+				<include>org.opengis:geoapi</include>
+				<include>javax.units:jsr108</include>
+                <include>org.geotools:gt2-legacy</include>
+                <include>org.geotools:gt2-main</include>
+                <include>org.geotools:gt2-referencing</include>
+				<include>geojava:geojava</include>
+                <!-- geotools dependencies -->
+                <include>org.geotools:gt2-api</include>
+                <include>org.opengis:geoapi-legacy</include>
+                <include>org.geotools:gt2-referencing</include>
+                <include>org.geotools:gt2-coverage</include>
+                <include>org.geotools:gt2-render</include>
+                <include>java3d:vecmath</include>
+                
+				<!-- org.gvsig.fmap.* -->
+				<include>org.gvsig:org.gvsig.fmap*</include>
+				<include>org.gvsig:org.gvsig.dxf</include>
+				<include>org.gvsig:org.gvsig.tools.evaluator.sqljep</include>
+				<include>net.sf:sqljep</include>	
+				<include>org.gvsig:org.gvsig.jdk.v1_6</include>							
+
+				<!-- org.gvsig.fmap.dal.index -->
+				<!-- 
+				<include>org.gvsig:org.gvsig.fmap.dal.index.spatial:jar:jsi</include>
+				<include>org.gvsig:org.gvsig.fmap.dal.index.spatial:jar:gt2</include>
+				<include>org.gvsig:org.gvsig.fmap.dal.index.spatial:jar:jts</include>
+				<include>org.gvsig:org.gvsig.fmap.dal.index.spatial:jar:spatialindex</include>
+				 -->
+				<include>net.sf:jsi</include>
+				<include>gnu.trove:trove</include>
+				<include>spatialindex:spatialindex</include>
+
+				<!-- org.gvsig.symbology -->
+				<!-- 
+				TODO: remove this entry when the basic symbology 
+				becomes an extension. 
+				-->
+				<include>org.gvsig:org.gvsig.symbology.lib.api</include>
+				<include>org.gvsig:org.gvsig.symbology.lib.impl</include>
+				<include>org.gvsig:org.gvsig.symbology.swing.api</include>
+				<include>org.gvsig:org.gvsig.symbology.swing.impl</include>
+
+				<include>org.apache.xmlgraphics:batik-anim</include>
+				<include>org.apache.xmlgraphics:batik-awt-util</include>
+				<include>org.apache.xmlgraphics:batik-bridge</include>
+				<include>org.apache.xmlgraphics:batik-css</include>
+				<include>org.apache.xmlgraphics:batik-dom</include>
+				<include>org.apache.xmlgraphics:batik-gvt</include>
+				<include>org.apache.xmlgraphics:batik-js</include>
+				<include>org.apache.xmlgraphics:batik-parser</include>
+				<include>org.apache.xmlgraphics:batik-script</include>
+				<include>org.apache.xmlgraphics:batik-svg-dom</include>
+				 
+				<include>xml-apis:xml-apis-ext</include>
+				<include>org.gvsig:batik-ext-gvsig-custom</include>
+							
+				<!-- org.gvsig.app -->
+				<include>org.gvsig:org.gvsig.app</include>
+				<include>com.sun:jimi</include>
+				<include>org.jpedal:jpedal_lgpl</include>
+				<include>zql:zql</include>
+				<include>*:jai_*</include>
+				
+				<!-- org.gvsig.remoteclient -->
+				<include>org.gvsig:org.gvsig.remoteclient</include>
+
+                <!-- About support -->                
+                <include>org.gvsig:org.gvsig.about*</include>
+
+			</includes>
+		</dependencySet>
+	</dependencySets>
+</assembly>
Index: tags/v2_0_0_Build_2050/applications/appgvSIG/test/cities.shp
===================================================================
Cannot display: file marked as a binary type.
svn:mime-type = application/octet-stream

Property changes on: tags/v2_0_0_Build_2050/applications/appgvSIG/test/cities.shp
___________________________________________________________________
Added: svn:mime-type
   + application/octet-stream

Index: tags/v2_0_0_Build_2050/applications/appgvSIG/test/cities.dbf
===================================================================
Cannot display: file marked as a binary type.
svn:mime-type = application/octet-stream

Property changes on: tags/v2_0_0_Build_2050/applications/appgvSIG/test/cities.dbf
___________________________________________________________________
Added: svn:mime-type
   + application/octet-stream

Index: tags/v2_0_0_Build_2050/applications/appgvSIG/test/praro.shp
===================================================================
Cannot display: file marked as a binary type.
svn:mime-type = application/octet-stream

Property changes on: tags/v2_0_0_Build_2050/applications/appgvSIG/test/praro.shp
___________________________________________________________________
Added: svn:mime-type
   + application/octet-stream

Index: tags/v2_0_0_Build_2050/applications/appgvSIG/test/praro.dbf
===================================================================
Cannot display: file marked as a binary type.
svn:mime-type = application/octet-stream

Property changes on: tags/v2_0_0_Build_2050/applications/appgvSIG/test/praro.dbf
___________________________________________________________________
Added: svn:mime-type
   + application/octet-stream

Index: tags/v2_0_0_Build_2050/applications/appgvSIG/test/cities.shx
===================================================================
Cannot display: file marked as a binary type.
svn:mime-type = application/octet-stream

Property changes on: tags/v2_0_0_Build_2050/applications/appgvSIG/test/cities.shx
___________________________________________________________________
Added: svn:mime-type
   + application/octet-stream

Index: tags/v2_0_0_Build_2050/applications/appgvSIG/test/praro.shx
===================================================================
Cannot display: file marked as a binary type.
svn:mime-type = application/octet-stream

Property changes on: tags/v2_0_0_Build_2050/applications/appgvSIG/test/praro.shx
___________________________________________________________________
Added: svn:mime-type
   + application/octet-stream


Property changes on: tags/v2_0_0_Build_2050/applications/appgvSIG
___________________________________________________________________
Added: svn:ignore
   + .classpath 
.project 
.settings 
maven-eclipse.xml
target
bin
hs_err_pid*
.externalToolBuilders
.settings
.classpath
.project
package.info


