[mapguide-commits] r6382 - in trunk/MgDev/Doc/samples: . javasamples javasamples/common javasamples/hello_map javasamples/hello_viewer javasamples/images javasamples/interacting_with_layers javasamples/styles

svn_mapguide at osgeo.org svn_mapguide at osgeo.org
Thu Dec 29 08:47:30 EST 2011


Author: jng
Date: 2011-12-29 05:47:30 -0800 (Thu, 29 Dec 2011)
New Revision: 6382

Added:
   trunk/MgDev/Doc/samples/javasamples/
   trunk/MgDev/Doc/samples/javasamples/common/
   trunk/MgDev/Doc/samples/javasamples/common/common.jsp
   trunk/MgDev/Doc/samples/javasamples/common/pageLoadFunctions.js
   trunk/MgDev/Doc/samples/javasamples/common/title.jsp
   trunk/MgDev/Doc/samples/javasamples/common/viewsource.php
   trunk/MgDev/Doc/samples/javasamples/hello_map/
   trunk/MgDev/Doc/samples/javasamples/hello_map/display_spatial_reference.jsp
   trunk/MgDev/Doc/samples/javasamples/hello_map/task_pane.jsp
   trunk/MgDev/Doc/samples/javasamples/hello_viewer/
   trunk/MgDev/Doc/samples/javasamples/hello_viewer/gotopoint.jsp
   trunk/MgDev/Doc/samples/javasamples/hello_viewer/task_pane.jsp
   trunk/MgDev/Doc/samples/javasamples/images/
   trunk/MgDev/Doc/samples/javasamples/images/banner.jpg
   trunk/MgDev/Doc/samples/javasamples/index.jsp
   trunk/MgDev/Doc/samples/javasamples/interacting_with_layers/
   trunk/MgDev/Doc/samples/javasamples/interacting_with_layers/layer_visibility.jsp
   trunk/MgDev/Doc/samples/javasamples/interacting_with_layers/task_pane.jsp
   trunk/MgDev/Doc/samples/javasamples/interacting_with_layers/toggle_roads_label.jsp
   trunk/MgDev/Doc/samples/javasamples/main.jsp
   trunk/MgDev/Doc/samples/javasamples/styles/
   trunk/MgDev/Doc/samples/javasamples/styles/globalStyles.css
   trunk/MgDev/Doc/samples/javasamples/styles/otherStyles.css
Log:
Dev Guide: Add java devguide samples. This was sourced from the Autodesk Infrastructure Map Server 2012 installation media. Before anyone cries copyright infringement, the source for theses samples is licensed under LGPL and every one of these source files includes the LGPL header at the top, explicitly stating permission to modify and redistribute these sources.

Added: trunk/MgDev/Doc/samples/javasamples/common/common.jsp
===================================================================
--- trunk/MgDev/Doc/samples/javasamples/common/common.jsp	                        (rev 0)
+++ trunk/MgDev/Doc/samples/javasamples/common/common.jsp	2011-12-29 13:47:30 UTC (rev 6382)
@@ -0,0 +1,57 @@
+<%
+//  Copyright (C) 2004-2006  Autodesk, Inc.
+//
+//  This library is free software; you can redistribute it and/or
+//  modify it under the terms of version 2.1 of the GNU Lesser
+//  General Public License as published by the Free Software Foundation.
+//
+//  This library 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
+//  Lesser General Public License for more details.
+//
+//  You should have received a copy of the GNU Lesser General Public
+//  License along with this library; if not, write to the Free Software
+//  Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA  02110-1301  USA
+
+// Define some commonly used directories and files
+
+// -----------------------------------------------------------------------------------
+// Use the following for Windows installations
+// -----------------------------------------------------------------------------------
+String webExtensionsDirectory = "C:\\Program Files\\Autodesk\\MapGuideEnterprise2011\\WebServerExtensions\\";
+  
+String MapGuideServerDirectory = "C:\\Program Files\\Autodesk\\MapGuideEnterprise2011\\Server\\";
+  
+String viewerFilesDirectory = webExtensionsDirectory + "www\\viewerfiles\\";
+  
+String schemaDirectory = MapGuideServerDirectory + "Schema\\";
+  
+String webconfigDirectory = webExtensionsDirectory + "www\\";
+
+String webconfigFilePath = webconfigDirectory + "webconfig.ini";
+// -----------------------------------------------------------------------------------
+// End of Windows configuration
+// -----------------------------------------------------------------------------------
+
+// -----------------------------------------------------------------------------------
+// Use the following for Linux installations
+// -----------------------------------------------------------------------------------
+/************************************************************************************* 
+String webExtensionsDirectory = "/opt/Autodesk/mapguideenterprise2011/webserverextensions/";
+  
+String MapGuideServerDirectory = "/opt/Autodesk/mapguideenterprise2011/server/";
+  
+String viewerFilesDirectory = webExtensionsDirectory + "www/viewerfiles/";
+  
+String schemaDirectory = MapGuideServerDirectory + "Schema/";
+  
+String webconfigDirectory = webExtensionsDirectory + "www/";
+
+String webconfigFilePath = webconfigDirectory + "webconfig.ini";
+*************************************************************************************/
+// -----------------------------------------------------------------------------------
+// End of Linux configuration
+// -----------------------------------------------------------------------------------
+
+%>
\ No newline at end of file

Added: trunk/MgDev/Doc/samples/javasamples/common/pageLoadFunctions.js
===================================================================
--- trunk/MgDev/Doc/samples/javasamples/common/pageLoadFunctions.js	                        (rev 0)
+++ trunk/MgDev/Doc/samples/javasamples/common/pageLoadFunctions.js	2011-12-29 13:47:30 UTC (rev 6382)
@@ -0,0 +1,93 @@
+//  Copyright (C) 2007  Autodesk, Inc.
+//
+//  This library is free software; you can redistribute it and/or
+//  modify it under the terms of version 2.1 of the GNU Lesser
+//  General Public License as published by the Free Software Foundation.
+//
+//  This library 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
+//  Lesser General Public License for more details.
+//
+//  You should have received a copy of the GNU Lesser General Public
+//  License along with this library; if not, write to the Free Software
+//  Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA  02110-1301  USA
+//
+// JavaScript functions to run when the task pane loads.
+// These functions temporarily disable the task pane until the map frame
+// has been loaded. 
+
+var saveBodyNodes = document.createElement('body');
+window.onload = function()
+{
+  // If the map has initialized, no need to do anything else.
+  
+  if (parent.parent.mapFrame.mapInit)
+  return;
+
+  // Replace the OnMapLoaded function from the main frame. We can use this
+  // method to perform any custom functions that depend
+  // on the map being initialized. In this case, use it to activate the
+  // task pane. Also set mapFrame.mapInit. The DWF Viewer does not use
+  // this variable, but we need it for both AJAX and DWF Viewers as a
+  // check for when to run this window.onload() function.
+  //
+  // Be sure to run the original OnMapLoaded() function; parts
+  // of the Viewer depend on it.
+  
+  original_OnMapLoaded = parent.parent.OnMapLoaded;
+  parent.parent.OnMapLoaded = function()
+  {
+    restoreBody();
+    replaceMapName();
+    parent.parent.mapFrame.mapInit = true;
+    original_OnMapLoaded();
+  }
+
+  // Temporarily replace the task pane with holder text while we wait
+  // for initialization to complete. It will be restored when the 
+  // OnMapLoaded() function is called.
+  
+  replaceBody();
+  
+  return;
+
+  // Functions ----------------------------------------------------
+  
+  function replaceBody()
+  {
+    // Replace the body of the task pane with inactive holder text.
+    while (document.body.hasChildNodes())
+    {
+      saveBodyNodes.appendChild(document.body.firstChild);
+    }
+    var tempPara = document.createElement('p');
+    var tempText = document.createTextNode('Loading...');
+    tempPara.appendChild(tempText);
+    document.body.appendChild(tempPara);
+  }
+  function restoreBody()
+  {
+    // Remove the holder text and restore the task pane.
+    while (document.body.hasChildNodes())
+    {
+      document.body.removeChild(document.body.firstChild);
+    }
+    while (saveBodyNodes.hasChildNodes())
+    {
+      document.body.appendChild(saveBodyNodes.firstChild);
+    }
+  }
+  function replaceMapName()
+  {
+    // Check document links for empty map name. Replace with the 
+    // map name used in this layout.
+    docLinks = document.links;
+    mapName = parent.parent.mapFrame.GetMapName();
+    for (i = 0; i < docLinks.length; i++)
+    {
+      newHref = docLinks[i].href.replace("MAPNAME=unknown", "MAPNAME=" + mapName);
+      docLinks[i].href = newHref;
+    }
+  }
+}

Added: trunk/MgDev/Doc/samples/javasamples/common/title.jsp
===================================================================
--- trunk/MgDev/Doc/samples/javasamples/common/title.jsp	                        (rev 0)
+++ trunk/MgDev/Doc/samples/javasamples/common/title.jsp	2011-12-29 13:47:30 UTC (rev 6382)
@@ -0,0 +1,39 @@
+<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN" "http://www.w3.org/TR/html4/loose.dtd">
+<!--
+//  Copyright (C) 2004-2006  Autodesk, Inc.
+//
+//  This library is free software; you can redistribute it and/or
+//  modify it under the terms of version 2.1 of the GNU Lesser
+//  General Public License as published by the Free Software Foundation.
+//
+//  This library 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
+//  Lesser General Public License for more details.
+//
+//  You should have received a copy of the GNU Lesser General Public
+//  License along with this library; if not, write to the Free Software
+//  Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA  02110-1301  USA
+-->
+<html>
+	<head>
+		<title>Title Frame</title>
+		<meta content="text/html; charset=utf-8" http-equiv="Content-Type">
+		<meta http-equiv="content-script-type" content="text/javascript">
+		<meta http-equiv="content-style-type" content="text/css">
+		<link href="../styles/globalStyles.css" rel="stylesheet" type="text/css">
+		<link href="../styles/otherStyles.css" rel="stylesheet" type="text/css">
+	</head>
+	<body class="TitleFrame">
+		<table width="100%" border="0" cellpadding="0" cellspacing="0">
+			<tr>				
+				<td class="TitleText">MapGuide Developer's Guide</td>
+				<td class="TitleText" width="100%" align="right"><%= request.getParameter("TitleText") %></td>
+			</tr>
+			<tr>
+				<td width="100%" bgcolor="#004282"></td>
+				<td align="right"><img src="../images/banner.jpg"></td>
+			</tr>
+		</table>
+	</body>
+</html>

Added: trunk/MgDev/Doc/samples/javasamples/common/viewsource.php
===================================================================
--- trunk/MgDev/Doc/samples/javasamples/common/viewsource.php	                        (rev 0)
+++ trunk/MgDev/Doc/samples/javasamples/common/viewsource.php	2011-12-29 13:47:30 UTC (rev 6382)
@@ -0,0 +1,43 @@
+<?php
+//  Copyright (C) 2004-2006  Autodesk, Inc.
+//
+//  This library is free software; you can redistribute it and/or
+//  modify it under the terms of version 2.1 of the GNU Lesser
+//  General Public License as published by the Free Software Foundation.
+//
+//  This library 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
+//  Lesser General Public License for more details.
+//
+//  You should have received a copy of the GNU Lesser General Public
+//  License along with this library; if not, write to the Free Software
+//  Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA  02110-1301  USA
+
+	$sourceFile = ($_SERVER['REQUEST_METHOD'] == "POST")? $_POST['FILENAME']: $_GET['FILENAME'];
+	
+	if (DIRECTORY_SEPARATOR == '/')
+		$sourceFile = str_replace('\\', '/', $sourceFile);
+	else
+		$sourceFile = str_replace('/', '\\', $sourceFile);
+	
+	$testForUtf = pack("ccc", 0xEF, 0xBB, 0xBF);
+	$fileContents = file_get_contents($sourceFile);
+	if (substr($fileContents, 0, 3) == $testForUtf)
+		$fileContents = htmlentities(utf8_decode(substr($fileContents, 3)));
+	else
+		$fileContents = htmlentities($fileContents);
+?>
+<html>
+	<head>
+		<title>Source of <?= basename($sourceFile) ?></title>
+	</head>
+	
+	<body>
+		<p><strong><?= $sourceFile ?></strong></p>
+		<pre style="background-color: #f8f8f8; padding: 10px; border: 2px solid black">
+<code><?= $fileContents ?>
+</code>
+		</pre>
+	</body>
+</html>
\ No newline at end of file

Added: trunk/MgDev/Doc/samples/javasamples/hello_map/display_spatial_reference.jsp
===================================================================
--- trunk/MgDev/Doc/samples/javasamples/hello_map/display_spatial_reference.jsp	                        (rev 0)
+++ trunk/MgDev/Doc/samples/javasamples/hello_map/display_spatial_reference.jsp	2011-12-29 13:47:30 UTC (rev 6382)
@@ -0,0 +1,89 @@
+<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN" "http://www.w3.org/TR/html4/loose.dtd">
+<!--
+//  Copyright (C) 2004-2006  Autodesk, Inc.
+//
+//  This library is free software; you can redistribute it and/or
+//  modify it under the terms of version 2.1 of the GNU Lesser
+//  General Public License as published by the Free Software Foundation.
+//
+//  This library 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
+//  Lesser General Public License for more details.
+//
+//  You should have received a copy of the GNU Lesser General Public
+//  License along with this library; if not, write to the Free Software
+//  Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA  02110-1301  USA
+-->
+<html>
+<%@ page import="org.osgeo.mapguide.*" %>
+<%@ page import="java.util.*" %>
+<%@ page import="java.io.*" %>
+<%@ page import="java.text.*" %>
+<%@ page import="javax.servlet.jsp.*" %>
+<%@ page import="javax.servlet.http.*" %>
+<%@ include file="../common/common.jsp" %>
+  <head>
+    <title>Hello, map</title>
+    <meta content="text/html; charset=utf-8" http-equiv="Content-Type">
+    <meta http-equiv="content-script-type" content="text/javascript">
+    <meta http-equiv="content-style-type" content="text/css">
+    <link href="../styles/globalStyles.css" rel="stylesheet"  type="text/css">
+    <link href="../styles/otherStyles.css" rel="stylesheet" type="text/css">
+  </head>
+  <body class="AppFrame">
+    <h1 class="AppHeading">Spatial Reference</h1>
+    <%
+      String sessionId = request.getParameter("SESSION");
+      String mapName = request.getParameter("MAPNAME");
+
+    try
+    {
+      // --------------------------------------------------//
+      // Basic initialization needs to be done every time.
+      
+      MapGuideJavaApi.MgInitializeWebTier(webconfigFilePath);
+
+      // Get the user information using the session id,
+      // and set up a connection to the site server.
+      
+      MgUserInformation userInfo = new MgUserInformation(sessionId);
+      MgSiteConnection siteConnection = new MgSiteConnection();
+      siteConnection.Open(userInfo);
+
+      // Get an instance of the required service(s).
+      
+      MgResourceService resourceService = (MgResourceService) siteConnection.CreateService(MgServiceType.ResourceService);
+
+      // Finished basic initialization.
+      // --------------------------------------------------//
+      
+      // Query the spatial reference system used for the map.
+      
+      MgMap map = new MgMap();
+      map.Open(resourceService, mapName);
+      String srs = map.GetMapSRS();
+      
+      // Format it and display it in the task pane.
+      
+      out.println("<p>Map <strong>" + map.GetName() + "</strong> uses this reference system: </p>");
+      Integer lineLength = 30;
+      out.println("<pre style=\"padding: 2px; border: 1px solid black; background-color: #eee\">");
+      while (srs.length() > lineLength)
+      {
+        out.println(srs.substring(0, lineLength));
+        srs = srs.substring(lineLength);
+      }
+      out.println(srs);
+      out.println("</pre>");
+    }
+    catch (MgException e)
+    {
+    out.println("<p><strong>Error:</strong> ");
+    out.println(e.GetDetails());
+    out.println("</p>");
+    }
+  %>
+
+</body>
+</html>
\ No newline at end of file

Added: trunk/MgDev/Doc/samples/javasamples/hello_map/task_pane.jsp
===================================================================
--- trunk/MgDev/Doc/samples/javasamples/hello_map/task_pane.jsp	                        (rev 0)
+++ trunk/MgDev/Doc/samples/javasamples/hello_map/task_pane.jsp	2011-12-29 13:47:30 UTC (rev 6382)
@@ -0,0 +1,65 @@
+<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN" "http://www.w3.org/TR/html4/loose.dtd">
+<!--
+//  Copyright (C) 2004-2007  Autodesk, Inc.
+//
+//  This library is free software; you can redistribute it and/or
+//  modify it under the terms of version 2.1 of the GNU Lesser
+//  General Public License as published by the Free Software Foundation.
+//
+//  This library 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
+//  Lesser General Public License for more details.
+//
+//  You should have received a copy of the GNU Lesser General Public
+//  License along with this library; if not, write to the Free Software
+//  Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA  02110-1301  USA
+-->
+<%@ page import="java.net.*" %>
+<%@ page import="java.io.*" %>
+<html>
+  <head>
+    <meta content="text/html; charset=utf-8" http-equiv="Content-Type">
+    <title>Task Pane</title>
+    <meta http-equiv="content-style-type" content="text/css">
+    <link href="../styles/globalStyles.css" rel="stylesheet" type="text/css">
+    <link href="../styles/otherStyles.css" rel="stylesheet" type="text/css">
+    <meta http-equiv="content-script-type" content="text/javascript">
+  </head>
+  <body class="AppFrame">
+    <h1 class="AppHeading">Hello Map</h1>
+    <%
+      String sessionId = request.getParameter("SESSION");
+      String mapName = request.getParameter("MAPNAME");
+    %>
+    <p>This sample shows the most basic interaction with a map. It connects to a session
+    	and queries information about the map.
+    </p>
+    <ul>
+      <li>
+        <a href="display_spatial_reference.jsp?SESSION=<%= sessionId %>&MAPNAME=<%= mapName %>">Display Spatial Reference</a>
+        <br/>Connect to MapGuide session and display basic information.
+        <br/>
+        <%
+        String fileName = "display_spatial_reference.jsp";
+        ServletContext context = session.getServletContext();
+        File currentPath = new File(context.getRealPath(request.getServletPath()));
+        String dir = currentPath.getParent();
+        String fullPath = java.net.URLEncoder.encode(dir + "/" + fileName);
+        %>
+        <!-- Not implemented yet
+        <a target="_blank" href="../common/viewsource.php?FILENAME=<%= fullPath %>" >View source</a>
+        -->
+      </li>
+    </ul>
+
+	<!-- Not implemented yet
+    <p>View source for support files:</p>
+    <ul>
+      <li><a target="_blank" href="../common/viewsource.php?FILENAME=<%= dir %>/../main.jsp">main.jsp</a> (wrapper for Viewer frames)</li>
+      <li><a target="_blank" href="../common/viewsource.php?FILENAME=<%= dir %>/task_pane.jsp">task_pane.jsp</a> (this task pane page)</li>
+      <li><a target="_blank" href="../common/viewsource.php?FILENAME=<%= dir %>/../common/common.jsp">common.jsp</a> (directory paths)</li>
+    </ul>
+    -->
+  </body>
+</html>

Added: trunk/MgDev/Doc/samples/javasamples/hello_viewer/gotopoint.jsp
===================================================================
--- trunk/MgDev/Doc/samples/javasamples/hello_viewer/gotopoint.jsp	                        (rev 0)
+++ trunk/MgDev/Doc/samples/javasamples/hello_viewer/gotopoint.jsp	2011-12-29 13:47:30 UTC (rev 6382)
@@ -0,0 +1,54 @@
+<?php
+
+//
+//  Copyright (C) 2004-2006  Autodesk, Inc.
+//
+//  This library is free software; you can redistribute it and/or
+//  modify it under the terms of version 2.1 of the GNU Lesser
+//  General Public License as published by the Free Software Foundation.
+//
+//  This library 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
+//  Lesser General Public License for more details.
+//
+//  You should have received a copy of the GNU Lesser General Public
+//  License along with this library; if not, write to the Free Software
+//  Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA  02110-1301  USA
+//
+
+?>
+
+<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN" "http://www.w3.org/TR/html4/loose.dtd">
+<html>
+
+<head>
+    <title>Viewer Sample Application- Goto Point</title>
+    <meta content="text/html; charset=utf-8" http-equiv="Content-Type">
+    <meta http-equiv="content-script-type" content="text/javascript">
+</head>
+<%
+  String x = request.getParameter("X");
+  String y = request.getParameter("Y");
+  String scale = request.getParameter("Scale");
+%>
+<!-- Emit this function and assocate it with the onLoad event for the -->
+<!-- page so that it gets executed when this page loads in the        -->
+<!-- browser. The function calls the ZoomToView method on the         -->
+<!-- Viewer frame forcing the Viewer to navigate to the specified     -->
+<!-- point and scale.                                                 -->
+
+<script language="javascript">
+
+function OnPageLoad()
+{
+    parent.ZoomToView(<%= x %>, <%= y %>, <%= scale %>, true);
+}
+
+</script>
+
+<body onLoad="OnPageLoad()">
+
+</body>
+
+</html>

Added: trunk/MgDev/Doc/samples/javasamples/hello_viewer/task_pane.jsp
===================================================================
--- trunk/MgDev/Doc/samples/javasamples/hello_viewer/task_pane.jsp	                        (rev 0)
+++ trunk/MgDev/Doc/samples/javasamples/hello_viewer/task_pane.jsp	2011-12-29 13:47:30 UTC (rev 6382)
@@ -0,0 +1,87 @@
+<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN" "http://www.w3.org/TR/html4/loose.dtd">
+<!--
+//  Copyright (C) 2004-2006  Autodesk, Inc.
+//
+//  This library is free software; you can redistribute it and/or
+//  modify it under the terms of version 2.1 of the GNU Lesser
+//  General Public License as published by the Free Software Foundation.
+//
+//  This library 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
+//  Lesser General Public License for more details.
+//
+//  You should have received a copy of the GNU Lesser General Public
+//  License along with this library; if not, write to the Free Software
+//  Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA  02110-1301  USA
+-->
+<%@ page import="java.net.*" %>
+<%@ page import="java.io.*" %>
+<html>
+  <head>
+    <meta content="text/html; charset=utf-8" http-equiv="Content-Type">
+    <title>Task Pane</title>
+    <meta http-equiv="content-style-type" content="text/css">
+    <link href="../styles/globalStyles.css" rel="stylesheet" type="text/css">
+    <link href="../styles/otherStyles.css" rel="stylesheet" type="text/css">
+    <meta http-equiv="content-script-type" content="text/javascript">
+  </head>
+  <body class="AppFrame">
+    <h1 class="AppHeading">Hello Viewer</h1>
+    <%
+      String sessionId = request.getParameter("SESSION");
+      String mapName = request.getParameter("MAPNAME");
+    %>
+    <p>This sample shows different ways of calling MapGuide Viewer API functions.</p>
+    <p><strong>1.</strong> The web layout contains a custom Invoke Script command 
+    	that calls the <code>ZoomToView()</code> function. Click the <img src="../../stdicons/icon_invokescript.gif" width="16" height="16" /> 
+    	button in the tool bar, task list, or context menu
+    	to reposition the map view. The Invoke Script command
+    	is defined in the web layout for the sample. It contains the following:
+    </p>
+    <pre><code>ZoomToView(-87.732492, 
+43.743934, 5000, true);</code></pre>
+
+    <p><strong>2.</strong> Click <a href="gotopoint.jsp?X=-87.724520&Y=43.768387&Scale=5000" target="scriptFrame">this link</a>
+    to display a different location. This loads a page into the hidden script frame.</p>
+    <%
+    ServletContext context = session.getServletContext();
+    File currentPath = new File(context.getRealPath(request.getServletPath()));
+    String dir = currentPath.getParent();
+    String fullPath = java.net.URLEncoder.encode(dir);
+    %>
+    <!-- Not implemented yet
+    <p>View source for support file:</p>
+    <ul>
+      <li><a target="_blank" href="../common/viewsource.php?FILENAME=<%= fullPath %>/gotopoint.jsp">gotopoint.jsp</a></li>
+    </ul>
+    -->
+
+    <p><strong>3.</strong> Click <a href="#" onclick="parent.parent.ZoomToView(-87.707416, 43.747860, 5000, true);">this link</a>
+    to display a third location. This uses <code>onclick</code> to call JavaScript directly from the task pane.</p>
+    	
+    <!-- Not implemented yet
+    <p>View source for this file:</p>
+    <ul>
+      <li><a target="_blank" href="../common/viewsource.php?FILENAME=<%= fullPath %>/task_pane.jsp">task_pane.jsp</a></li>
+    </ul>
+    -->
+    
+    <p><strong>4.</strong> The home task pane loads JavaScript from an external file. The script runs when the map first loads. It disables 
+    	the task pane and waits until the map has completed loading before enabling the pane. It does this by hooking into 
+    	the <code>OnMapLoaded()</code> function of the main frame.</p>
+    		
+    <!-- Not implemented yet
+    <p>View files:</p>
+    <ul>
+      <li>
+        <a target="_blank" href="../common/viewsource.php?FILENAME=<%= fullPath %>/../index.jsp" >index.jsp</a>
+      </li>
+      <li>
+        <a target="_blank" href="../common/viewsource.php?FILENAME=<%= fullPath %>/../common/pageLoadFunctions.js" >pageLoadFunctions.js</a>
+      </li>
+    </ul>
+    -->
+
+  </body>
+</html>

Added: trunk/MgDev/Doc/samples/javasamples/images/banner.jpg
===================================================================
(Binary files differ)


Property changes on: trunk/MgDev/Doc/samples/javasamples/images/banner.jpg
___________________________________________________________________
Added: svn:mime-type
   + application/octet-stream

Added: trunk/MgDev/Doc/samples/javasamples/index.jsp
===================================================================
--- trunk/MgDev/Doc/samples/javasamples/index.jsp	                        (rev 0)
+++ trunk/MgDev/Doc/samples/javasamples/index.jsp	2011-12-29 13:47:30 UTC (rev 6382)
@@ -0,0 +1,97 @@
+<%--
+  -Copyright (C) 2004-2007  Autodesk, Inc.
+  -This library is free software; you can redistribute it and/or
+  -modify it under the terms of version 2.1 of the GNU Lesser
+  -General Public License as published by the Free Software Foundation.
+
+  -This library 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
+  -Lesser General Public License for more details.
+
+  -You should have received a copy of the GNU Lesser General Public
+  -License along with this library; if not, write to the Free Software
+  -Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA  02110-1301  USA
+--%>
+
+<%@ page import="org.osgeo.mapguide.*" %>
+<%@ page import="java.util.*" %>
+<%@ page import="java.io.*" %>
+<%@ page import="java.text.*" %>
+<%@ page import="javax.servlet.jsp.*" %>
+<%@ page import="javax.servlet.http.*" %>
+<%@ include file="common/common.jsp" %>
+<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01//EN" "http://www.w3.org/TR/html4/strict.dtd">
+<html>
+  <head>
+    <meta http-equiv="Content-Type" content="text/html; charset=iso-8859-1">
+    <title>MapGuide Developer Guide Samples</title>
+    <meta http-equiv="content-style-type" content="text/css">
+    <link href="styles/globalStyles.css" rel="stylesheet"  type="text/css">
+    <link href="styles/otherStyles.css" rel="stylesheet" type="text/css">
+    <script src="common/pageLoadFunctions.js" type="text/javascript" language="JavaScript">
+    </script>
+  </head>
+  <body class="AppFrame">
+    <%
+      String sessionId = request.getParameter("SESSION");
+      String mapName = request.getParameter("MAPNAME");
+      if (mapName == null) mapName = "unknown";
+    %>
+    
+    <p>At any time, click <img src="../stdicons/icon_home.gif" width="16" height="16" /> 
+    in the task bar to return to this list of samples.</p>
+    <h1>
+      Basic Samples
+    </h1>
+      <ul>
+        <li><a href="hello_map/task_pane.jsp?SESSION=<%= sessionId %>&MAPNAME=<%= mapName %>">Hello Map</a></li>
+        <li><a href="hello_viewer/task_pane.jsp?SESSION=<%= sessionId %>&MAPNAME=<%= mapName %>">Hello Viewer</a></li>
+        <li><a href="interacting_with_layers/task_pane.jsp?SESSION=<%= sessionId %>&MAPNAME=<%= mapName %>">Interacting With Layers</a></li>
+        
+        <!-- Not implemented yet
+        <li><a href="working_with_feature_data/task_pane.jsp?SESSION=<%= sessionId %>&MAPNAME=<%= mapName %>">Working With Feature Data</a></li>
+        <li><a href="modifying_maps_and_layers/task_pane.jsp?SESSION=<%= sessionId %>&MAPNAME=<%= mapName %>">Modifying Maps and Layers</a></li>
+        <li><a href="analyzing_features/task_pane.jsp?SESSION=<%= sessionId %>&MAPNAME=<%= mapName %>">Analyzing Features</a></li>
+        <li><a href="digitizing_features/task_pane.jsp?SESSION=<%= sessionId %>&MAPNAME=<%= mapName %>">Digitizing and Redlining</a></li>
+        <li><a href="custom_output/task_pane.jsp?SESSION=<%= sessionId %>&MAPNAME=<%= mapName %>">Custom Output</a></li>
+        -->
+      </ul>
+    <h1>
+      Viewer Samples
+    </h1>
+      <ul>
+        <li><a href="../javaviewersample/dwfviewersample.jsp?SESSION=<?= $sessionId ?>&MAPNAME=<?= $mapName ?>" target="_blank">Using DWF Viewer</a></li>
+        <li><a href="../javaviewersample/ajaxviewersample.jsp?SESSION=<?= $sessionId ?>&MAPNAME=<?= $mapName ?>" target="_blank">Using Ajax Viewer</a></li>
+        <li><a href="../javaviewersample/ajaxtiledviewersample.jsp?SESSION=<?= $sessionId ?>&MAPNAME=<?= $mapName ?>" target="_blank">Using Tiled Ajax Viewer</a></li>
+      </ul>
+    <%
+    String helpDir = webExtensionsDirectory + "www/Help/";
+    String helpUrl = "/mapguide/Help/";
+    String devGuide = helpDir + "DevGuide.pdf";
+    String apiRef = helpDir + "index.htm";
+    String viewerApi = helpDir + "viewerapi.html";
+    File f_devGuide = new File(devGuide);
+    File f_apiRef = new File(apiRef);
+    File f_viewerApi = new File(viewerApi);
+    if (f_devGuide.exists() || f_apiRef.exists() || f_viewerApi.exists())
+    {
+    	out.println("<hr><h1>Documentation</h1>");
+    	out.println("<p>Opens in a new window</p><ul>");
+    	if (f_devGuide.exists())
+    	{
+    		out.println("<li><a href=\"" + helpUrl + "DevGuide.pdf\" target=\"_blank\">Developer's Guide (PDF)</a></li>"); 
+    	}
+    	if (f_apiRef.exists())
+    	{
+    		out.println("<li><a href=\"" + helpUrl + "index.htm\" target=\"_blank\">Web Server Extensions API Reference</a></li>"); 
+    	}
+    	if (f_viewerApi.exists())
+    	{
+    		out.println("<li><a href=\"" + helpUrl + "viewerapi.html\" target=\"_blank\">Viewer API Reference</a></li>"); 
+    	}
+    	out.println("</ul>");
+    }
+    %>
+  </body>
+</html>

Added: trunk/MgDev/Doc/samples/javasamples/interacting_with_layers/layer_visibility.jsp
===================================================================
--- trunk/MgDev/Doc/samples/javasamples/interacting_with_layers/layer_visibility.jsp	                        (rev 0)
+++ trunk/MgDev/Doc/samples/javasamples/interacting_with_layers/layer_visibility.jsp	2011-12-29 13:47:30 UTC (rev 6382)
@@ -0,0 +1,83 @@
+<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN" "http://www.w3.org/TR/html4/loose.dtd">
+<!--
+//  Copyright (C) 2004-2006  Autodesk, Inc.
+//
+//  This library is free software; you can redistribute it and/or
+//  modify it under the terms of version 2.1 of the GNU Lesser
+//  General Public License as published by the Free Software Foundation.
+//
+//  This library 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
+//  Lesser General Public License for more details.
+//
+//  You should have received a copy of the GNU Lesser General Public
+//  License along with this library; if not, write to the Free Software
+//  Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA  02110-1301  USA
+-->
+<html>
+<%@ page import="org.osgeo.mapguide.*" %>
+<%@ page import="java.util.*" %>
+<%@ page import="java.io.*" %>
+<%@ page import="java.text.*" %>
+<%@ page import="javax.servlet.jsp.*" %>
+<%@ page import="javax.servlet.http.*" %>
+<%@ include file="../common/common.jsp" %>
+  <head>
+    <title>Layer Visibility</title>
+    <meta content="text/html; charset=utf-8" http-equiv="Content-Type">
+    <meta http-equiv="content-script-type" content="text/javascript">
+    <meta http-equiv="content-style-type" content="text/css">
+    <link href="../styles/globalStyles.css" rel="stylesheet"  type="text/css">
+    <link href="../styles/otherStyles.css" rel="stylesheet" type="text/css">
+  </head>
+  <body class="AppFrame">
+    <h1 class="AppHeading">Layer Visibility</h1>
+    <%
+      String sessionId = request.getParameter("SESSION");
+      String mapName = request.getParameter("MAPNAME");
+
+    try
+    {
+      MapGuideJavaApi.MgInitializeWebTier(webconfigFilePath);
+
+      // Get the user information using the session id,
+      // and set up a connection to the site server.
+      
+      MgUserInformation userInfo = new MgUserInformation(sessionId);
+      MgSiteConnection siteConnection = new MgSiteConnection();
+      siteConnection.Open(userInfo);
+  
+      // Get an instance of the required service(s).
+      
+      MgResourceService resourceService = (MgResourceService) siteConnection.CreateService(MgServiceType.ResourceService);
+  
+      MgMap map = new MgMap();
+      map.Open(resourceService, mapName);
+
+      MgLayerCollection layers = map.GetLayers(); // Get layer collection
+      out.println("<p>Layers, in draw order:</p>");
+      out.println("<table class=\"taskPane\" cellspacing=\"0\">");
+      out.println("<tr><th class=\"rowHead\">Layer</th><th>GetVisible()</th><th>IsVisible()</th></tr>");
+      Integer count = layers.GetCount(); 
+      for (Integer i = 0; i < count; i++)
+      {
+        MgLayer layer = (MgLayer) layers.GetItem(i);
+        out.println("<tr><td class=\"rowHead\">" + layer.GetName() + 
+        "</td><td>" + (layer.GetVisible() ? "on" : "off") + "</td><td>" + (layer.IsVisible() ? "on" : "off") + "</td></tr>\n");
+      }
+      out.println("</table>");
+    }
+    catch (MgException e)
+    {
+      out.println("<p><strong>Error:</strong> ");
+      out.println(e.GetDetails());
+      out.println("</p>");
+    }
+    %>
+    <p><code>GetVisible()</code> returns the state of the visibility flag for a given layer (the check box in the
+      Layers pane). <code>IsVisible()</code> returns the actual visibility of a layer, based on its visibility flag, 
+      the visibility flag of any groups that include the layer, and whether the layer has a defined style for the 
+    current view scale.</p>
+</body>
+</html>
\ No newline at end of file

Added: trunk/MgDev/Doc/samples/javasamples/interacting_with_layers/task_pane.jsp
===================================================================
--- trunk/MgDev/Doc/samples/javasamples/interacting_with_layers/task_pane.jsp	                        (rev 0)
+++ trunk/MgDev/Doc/samples/javasamples/interacting_with_layers/task_pane.jsp	2011-12-29 13:47:30 UTC (rev 6382)
@@ -0,0 +1,62 @@
+<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN" "http://www.w3.org/TR/html4/loose.dtd">
+<!--
+//  Copyright (C) 2004-2006  Autodesk, Inc.
+//
+//  This library is free software; you can redistribute it and/or
+//  modify it under the terms of version 2.1 of the GNU Lesser
+//  General Public License as published by the Free Software Foundation.
+//
+//  This library 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
+//  Lesser General Public License for more details.
+//
+//  You should have received a copy of the GNU Lesser General Public
+//  License along with this library; if not, write to the Free Software
+//  Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA  02110-1301  USA
+-->
+<%@ page import="java.net.*" %>
+<%@ page import="java.io.*" %>
+<html>
+	<head>
+		<meta content="text/html; charset=utf-8" http-equiv="Content-Type">
+		<title>Task Pane</title>
+		<meta http-equiv="content-style-type" content="text/css">
+		<link href="../styles/globalStyles.css" rel="stylesheet" type="text/css">
+		<link href="../styles/otherStyles.css" rel="stylesheet" type="text/css">
+		<meta http-equiv="content-script-type" content="text/javascript">
+	</head>
+  <body class="AppFrame">
+    <h1 class="AppHeading">Map Layers</h1>
+    <%
+      String sessionId = request.getParameter("SESSION");
+      String mapName = request.getParameter("MAPNAME");
+    %>
+    <ul>
+      <li>
+      	<a href="layer_visibility.jsp?SESSION=<%= sessionId %>&MAPNAME=<%= mapName %>">Layer Visibility</a>
+		    <br/>List layers and visibility status
+		    <br/>
+        <%
+        ServletContext context = session.getServletContext();
+        File currentPath = new File(context.getRealPath(request.getServletPath()));
+        String dir = currentPath.getParent();
+        String fullPath = java.net.URLEncoder.encode(dir);
+        %>
+        
+        <!-- Not implemented yet
+		    <a target="_blank" href="../common/viewsource.php?FILENAME=<%= fullPath %>/layer_visibility.jsp" >view source</a>
+		-->
+      </li>
+      <li>
+      	<a href="toggle_roads_label.jsp?SESSION=<%= sessionId %>&MAPNAME=<%= mapName %>">Rename Roads Layer</a>
+		    <br/>Toggle the name of the Roads layer
+		    <br/>
+		    <!-- Not implemented yet
+		    <a target="_blank" href="../common/viewsource.php?FILENAME=<%= fullPath %>/toggle_roads_label.jsp" >View source</a>
+		    -->
+      </li>
+    </ul>
+
+  </body>
+</html>

Added: trunk/MgDev/Doc/samples/javasamples/interacting_with_layers/toggle_roads_label.jsp
===================================================================
--- trunk/MgDev/Doc/samples/javasamples/interacting_with_layers/toggle_roads_label.jsp	                        (rev 0)
+++ trunk/MgDev/Doc/samples/javasamples/interacting_with_layers/toggle_roads_label.jsp	2011-12-29 13:47:30 UTC (rev 6382)
@@ -0,0 +1,109 @@
+<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN" "http://www.w3.org/TR/html4/loose.dtd">
+<!--
+//  Copyright (C) 2004-2006  Autodesk, Inc.
+//
+//  This library is free software; you can redistribute it and/or
+//  modify it under the terms of version 2.1 of the GNU Lesser
+//  General Public License as published by the Free Software Foundation.
+//
+//  This library 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
+//  Lesser General Public License for more details.
+//
+//  You should have received a copy of the GNU Lesser General Public
+//  License along with this library; if not, write to the Free Software
+//  Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA  02110-1301  USA
+-->
+<html>
+<%@ page import="org.osgeo.mapguide.*" %>
+<%@ page import="java.util.*" %>
+<%@ page import="java.io.*" %>
+<%@ page import="java.text.*" %>
+<%@ page import="javax.servlet.jsp.*" %>
+<%@ page import="javax.servlet.http.*" %>
+<%@ include file="../common/common.jsp" %>
+  <head>
+    <title>Rename layer</title>
+    <meta content="text/html; charset=utf-8" http-equiv="Content-Type">
+    <meta http-equiv="content-script-type" content="text/javascript">
+    <meta http-equiv="content-style-type" content="text/css">
+    <link href="../styles/globalStyles.css" rel="stylesheet"  type="text/css">
+    <link href="../styles/otherStyles.css" rel="stylesheet" type="text/css">
+
+    <script language="javascript" type="text/javascript">
+      function OnPageLoad()
+      {
+        parent.parent.mapFrame.Refresh();
+        parent.parent.mapFrame.ZoomToScale(12000);
+      }
+    </script>
+  </head>
+  <body class="AppFrame" onLoad="OnPageLoad();">
+    <h1 class="AppHeading">Rename Roads Layer</h1>
+    <%
+      String sessionId = request.getParameter("SESSION");
+      String mapName = request.getParameter("MAPNAME");
+
+    try
+    {
+      // Initialize the Web Extensions and connect to the Server using
+      // the Web Extensions session identifier stored in PHP
+      // session state.
+
+      MapGuideJavaApi.MgInitializeWebTier(webconfigFilePath);
+
+      // Get the user information using the session id,
+      // and set up a connection to the site server.
+      
+      MgUserInformation userInfo = new MgUserInformation(sessionId);
+      MgSiteConnection siteConnection = new MgSiteConnection();
+      siteConnection.Open(userInfo);
+  
+      // Get an instance of the required service(s).
+      
+      MgResourceService resourceService = (MgResourceService) siteConnection.CreateService(MgServiceType.ResourceService);
+
+      MgMap map = new MgMap(); 
+      map.Open(resourceService, mapName);
+
+      MgLayerCollection layers = map.GetLayers(); // Get layer collection
+
+      MgLayer roadLayer = (MgLayer) layers.GetItem("Roads");
+      String roadLabel = roadLayer.GetLegendLabel();
+      String newLabel;
+      if (roadLabel.equals("Roads"))
+        newLabel = "Streets";
+      else
+        newLabel = "Roads";
+
+      roadLayer.SetLegendLabel(newLabel);
+
+      // You must save the updated map or the
+      // changes will not be applied
+      // Also be sure to refresh the map on page load.
+      map.Save(resourceService);
+
+      out.println("<p>Layer label has been changed to " + newLabel + ".</p>");
+
+      out.println("<p><a href=\"toggle_roads_label.jsp?SESSION=" + sessionId +
+      "&MAPNAME=" + mapName + "\">Run again</a></p>");
+
+    }
+    catch (MgLayerNotFoundException e)
+    {
+      out.println("<p>Layer not found</p>");
+    }
+    catch (MgObjectNotFoundException e)
+    {
+      out.println("<p>Layer not found</p>");
+    }
+    catch (MgException e)
+    {
+      out.println(e.GetExceptionMessage());
+      out.println(e.GetDetails());
+    }
+  %>
+
+</body>
+</html>
\ No newline at end of file

Added: trunk/MgDev/Doc/samples/javasamples/main.jsp
===================================================================
--- trunk/MgDev/Doc/samples/javasamples/main.jsp	                        (rev 0)
+++ trunk/MgDev/Doc/samples/javasamples/main.jsp	2011-12-29 13:47:30 UTC (rev 6382)
@@ -0,0 +1,59 @@
+<%--
+  -Copyright (C) 2004-2007  Autodesk, Inc.
+  -This library is free software; you can redistribute it and/or
+  -modify it under the terms of version 2.1 of the GNU Lesser
+  -General Public License as published by the Free Software Foundation.
+
+  -This library 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
+  -Lesser General Public License for more details.
+
+  -You should have received a copy of the GNU Lesser General Public
+  -License along with this library; if not, write to the Free Software
+  -Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA  02110-1301  USA
+--%>
+
+<%@ page import="org.osgeo.mapguide.*" %>
+<%@ page import="java.util.*" %>
+<%@ page import="java.io.*" %>
+<%@ page import="java.text.*" %>
+<%@ page import="javax.servlet.jsp.*" %>
+<%@ page import="javax.servlet.http.*" %>
+<%@ include file="common/common.jsp" %>
+<%
+    // Initialize a JSP session and register a variable to hold the
+    // session id, then initialize the Web Extensions, and connect
+    // to the site, and create a session.
+
+    String realpath = getServletContext().getRealPath("/");
+    // Initialize web tier with the site configuration file.  The config
+    // file should be in the same folder as this script.
+    String configPath =  realpath + "webconfig.ini";
+    MapGuideJavaApi.MgInitializeWebTier( configPath );
+
+    MgUserInformation userInfo = new MgUserInformation("Anonymous", "");
+    MgSite site = new MgSite();
+
+    site.Open(userInfo);
+
+    String sessionId = site.CreateSession();
+    String title = "JSP Samples";
+    String webLayout = "Library://Samples/Layouts/JavaSamples.WebLayout";
+%>
+<html>
+  <head>
+    <title><%= title %>
+    </title>
+    <meta content="text/html; charset=utf-8" http-equiv="Content-Type" />
+    <meta http-equiv="content-script-type" content="text/javascript" />
+    <meta http-equiv="content-style-type" content="text/css">
+    <link href="styles/globalStyles.css" rel="stylesheet" type="text/css" />
+    <link href="styles/globalStyles.css" rel="stylesheet" type="text/css" />
+  </head>
+
+  <frameset rows="110,*" frameborder="NO" border="0" framespacing="0">
+    <frame src="common/title.jsp?TitleText=<%= title %>" name="TitleFrame" scrolling="NO" noresize />
+    <frame src="/mapguide2011/mapviewerajax/?SESSION=<%= sessionId %>&WEBLAYOUT=<%= webLayout %>" name="ViewerFrame" />
+  </frameset>
+</html>

Added: trunk/MgDev/Doc/samples/javasamples/styles/globalStyles.css
===================================================================
--- trunk/MgDev/Doc/samples/javasamples/styles/globalStyles.css	                        (rev 0)
+++ trunk/MgDev/Doc/samples/javasamples/styles/globalStyles.css	2011-12-29 13:47:30 UTC (rev 6382)
@@ -0,0 +1,217 @@
+/*
+Copyright (C) 2004-2006  Autodesk, Inc.
+
+This library is free software; you can redistribute it and/or
+modify it under the terms of version 2.1 of the GNU Lesser
+General Public License as published by the Free Software Foundation.
+
+This library 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
+Lesser General Public License for more details.
+
+You should have received a copy of the GNU Lesser General Public
+License along with this library; if not, write to the Free Software
+Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA  02110-1301  USA
+*/
+
+/*
+----------------------------------------------------------
+autodesk masthead base styles for screen media
+FileName: ad_mh.css
+Version: 2003.01.10
+2-10-05: Updated with values from global.css for new
+         Corp look.
+----------------------------------------------------------
+*/
+
+
+/* General Elements */
+/* ----------------------------------------------------- */
+body {
+    margin: 0px 0px 0px 0px;
+    color: #000000;
+    font-family: arial,verdana,helvetica,sans-serif;
+    background: #f2f2f2;
+    font-size: 11px; /*global font size, thus 11px = 1em if not redefined elsewhere*/
+    height: 100%;
+}
+td {
+    font-family: Arial,Helvetica,Verdana,Geneva,sans-serif;
+    color: #000000;
+    font-size: 13px;
+}
+
+/*global link settings*/
+a {
+    color:#0082b4;
+    text-decoration:none;
+}
+
+a:visited {
+    color:#46a9de;
+}
+a:hover,
+a:active {
+    text-decoration:underline;
+}
+
+input, select, textarea {
+    font-family: Arial,Helvetica,Verdana,Geneva,sans-serif;
+    font-size: 13px;
+}
+
+hr {
+    color: #CCCCCC;
+    height: 1px;
+    margin: 0px 0px 5px 0px;
+}
+
+/* Formatting Structure */
+/* ----------------------------------------------------- */
+
+table.main {
+    width: 774px;
+    height: 100%;
+    background: #FFFFFF;
+}
+td.sitename {
+    height: 81px;
+    vertical-align: bottom;
+}
+table.sitename {
+    margin: 0px 11px 0px 11px;
+    width: 752px;
+    height: 81px;
+}
+
+td.logo { text-align: right; vertical-align: bottom; }
+
+td.vertnav {
+    height: 20px;
+    border-bottom: solid 1px #999999;
+    padding-left: 11px;
+    vertical-align : middle;
+    color: #000000;
+    font-size: 11px;
+    text-decoration: none;
+}
+
+td.content {
+    padding: 27px 11px 11px 11px;
+    width: 572px;
+    height: 82%;
+    vertical-align: top;
+}
+td.lhsash {
+    background-color: #F2F2F2;
+    padding: 27px 11px 11px 10px; /* Ww */
+    width: 159px; /* Ww */
+    vertical-align: top;
+}
+td.lhnav, td.lhnavbld {
+    padding: 0px 0px 0px 1px; /* Ww */
+}
+
+td.footer {
+    padding: 16px 11px 11px 11px;
+    height: 26px;
+    vertical-align: top;
+    color: #666666;
+    font-size: 11px;
+}
+
+td.langsel { padding: 22px 0px 0px 0px; }
+td.promo { padding: 33px 0px 0px 0px; }
+.promobox  { margin-bottom: 11px; }/* 11px space after promo boxes */
+
+
+/* Navigation Links */
+/* ----------------------------------------------------- */
+.sitename, a.sitename, a.sitename:visited, a.sitename:hover  {
+    color: #000000;
+    font-size: 16px;
+    font-weight: bold;
+    line-height: 16px;
+    text-decoration: none;
+}
+.lhnav {
+    color: #000000;
+    font-size: 11px;
+    text-decoration: none;
+}
+a.lhnav, a.lhnav:visited {
+    color: #0082B4;
+    text-decoration: none;
+}
+a.lhnav:hover {
+    color: #0082B4;
+    text-decoration: underline;
+}
+.lhnavbld {
+    color: #000000;
+    font-size: 11px;
+    font-weight: bold;
+    text-decoration: none;
+}
+a.lhnavbld, a.lhnavbld:visited {
+    color: #0082B4;
+    text-decoration: none;
+}
+a.lhnavbld:hover {
+    color: #0082B4;
+    text-decoration: underline;
+}
+.ftnav, a.ftnav, a.ftnav:visited {
+    color: #0082B4;
+    font-size: 11px;
+    text-decoration: none;
+}
+a.ftnav:hover {
+    text-decoration: underline;
+}
+
+
+/* DIV */
+/* ----------------------------------------------------- */
+div.clear { clear: both; }
+div.lh-blue {
+    color: #0066CC;
+    padding: 0px 4px 0px 1px; /* Ww */
+    font-size: 11px;
+}/* blue '-' on the LHSash subnavigation */
+div.lh-black {
+    color: #000000;
+    padding: 0px 4px 0px 1px; /* Ww */
+    font-size: 11px;
+}/* black '-' on the LHSash subnavigation */
+
+
+/* Text Formatting */
+/* ----------------------------------------------------- */
+.title {
+    color: #000000;
+    font-weight: bold;
+    font-size: 14px;
+ }
+ .pdf {
+    color: #666666;
+    font-size: 8pt;
+    font-style : italic;
+    text-decoration: none;
+}
+.bold {
+    font-weight: bold;
+}
+
+/* Images */
+/* ----------------------------------------------------- */
+img  { border: 0px; }/* remove border from image */
+.img-left {
+    margin: 0px 11px 11px 0px;
+    float : left;
+}
+.img-right  {
+    margin: 0px 0px 11px 11px;
+    float: right;
+}

Added: trunk/MgDev/Doc/samples/javasamples/styles/otherStyles.css
===================================================================
--- trunk/MgDev/Doc/samples/javasamples/styles/otherStyles.css	                        (rev 0)
+++ trunk/MgDev/Doc/samples/javasamples/styles/otherStyles.css	2011-12-29 13:47:30 UTC (rev 6382)
@@ -0,0 +1,118 @@
+/*
+Copyright (C) 2004-2006  Autodesk, Inc.
+
+This library is free software; you can redistribute it and/or
+modify it under the terms of version 2.1 of the GNU Lesser
+General Public License as published by the Free Software Foundation.
+
+This library 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
+Lesser General Public License for more details.
+
+You should have received a copy of the GNU Lesser General Public
+License along with this library; if not, write to the Free Software
+Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA  02110-1301  USA
+*/
+
+body.TitleFrame {
+    background-color: #FFFFFF;
+    margin: 0px;
+    vertical-align: bottom;
+}
+
+td.TitleText {
+    margin: 0px;
+    font-size: 20px;
+    vertical-align: bottom;
+    padding: 5px;
+    font-weight: bold;
+    color: #000000;
+}
+
+table.taskPane
+{
+  border: 0;
+}
+table.taskPane td, th {
+    font-family: Arial,Helvetica,Verdana,Geneva,sans-serif;
+    color: #000000;
+    font-size: 13px;
+    text-align: right;
+    border: 0;
+    border-bottom: 1px solid black;
+    margin: 4px;
+    padding: 2px 4px 2px 4px;
+}
+table.taskPane th
+{
+  background-color: #eee;
+  font-weight: normal;
+  border-top: 1px solid black;
+}
+table.taskPane td.rowHead, th.rowHead
+{
+  text-align: left;
+}
+
+body.AppFrame {
+    margin: 5px 5px 5px 5px;
+    color: #000000;
+    font-family: arial,verdana,helvetica,sans-serif;
+    background: #FFFFFF;
+    font-size: 13px; /*global font size, thus 11px = 1em if not redefined elsewhere*/
+    width: auto;
+    height: auto;
+}
+
+h1 {
+font-size: 18px;
+}
+
+body.AppFrame h1 {
+    font-family: Arial, Helvetica, sans-serif;
+    font-size: 18px;
+    font-weight: bold;
+    margin: 15px 0 0 0;
+    padding-bottom: 0;
+}
+
+body.AppFrame ul
+{
+    margin-top: 5px;
+}
+
+body.AppFrame p
+{
+  margin: 5px;
+}
+
+body.AppFrame hr
+{
+  margin: 5px;
+}
+
+td.NavItem {
+    vertical-align: middle;
+    width: 100%;
+    margin-top: 2px;
+    margin-bottom: 2px;
+    margin-left: 4px;
+    height: 20px;
+    background-position: center;
+}
+
+a.NavLink {
+    vertical-align: middle;
+    line-height: 20px;
+    background-position: center;
+    margin: 0px;
+    padding: 0px;
+    height: 20px;
+}
+
+
+img.NavPic {
+    background-position: center;
+    vertical-align: middle;
+}



More information about the mapguide-commits mailing list