[richfaces-svn-commits] JBoss Rich Faces SVN: r2522 - in trunk: samples/richfaces-demo/src/main/webapp/richfaces and 3 other directories.
richfaces-svn-commits at lists.jboss.org
richfaces-svn-commits at lists.jboss.org
Mon Aug 27 23:41:43 EDT 2007
Author: SergeySmirnov
Date: 2007-08-27 23:41:43 -0400 (Mon, 27 Aug 2007)
New Revision: 2522
Added:
trunk/samples/richfaces-demo/src/main/webapp/richfaces/insert/examples/groovy.xhtml
trunk/samples/richfaces-demo/src/main/webapp/richfaces/insert/snippets/sample.groovy
Removed:
trunk/samples/richfaces-demo/src/main/webapp/richfaces/insert/examples/ajaxSubmit.xhtml
trunk/samples/richfaces-demo/src/main/webapp/richfaces/insert/snippets/commandLinkProblem.xhtml
Modified:
trunk/docs/taglibxsl/
trunk/samples/richfaces-demo/src/main/webapp/richfaces/insert/usage.xhtml
trunk/samples/richfaces-demo/src/main/webapp/richfaces/support.xhtml
Log:
demo. insert is added
Property changes on: trunk/docs/taglibxsl
___________________________________________________________________
Name: svn:ignore
+ target
Deleted: trunk/samples/richfaces-demo/src/main/webapp/richfaces/insert/examples/ajaxSubmit.xhtml
===================================================================
--- trunk/samples/richfaces-demo/src/main/webapp/richfaces/insert/examples/ajaxSubmit.xhtml 2007-08-27 18:41:07 UTC (rev 2521)
+++ trunk/samples/richfaces-demo/src/main/webapp/richfaces/insert/examples/ajaxSubmit.xhtml 2007-08-28 03:41:43 UTC (rev 2522)
@@ -1,37 +0,0 @@
-<ui:composition xmlns="http://www.w3.org/1999/xhtml"
- xmlns:ui="http://java.sun.com/jsf/facelets"
- xmlns:h="http://java.sun.com/jsf/html"
- xmlns:f="http://java.sun.com/jsf/core"
- xmlns:a4j="http://richfaces.org/a4j"
- xmlns:rich="http://richfaces.org/rich">
-
- <h:panelGrid columns="2">
- <rich:panel>
- <f:facet name="header">
- <h:outputText value="Form with ajaxSubmit equals true"/>
- </f:facet>
-
- <a4j:form ajaxSubmit="true" reRender="name">
- <h:panelGrid>
- <h:commandButton value="Set Local Name to John (Ajax)" action="#{userBean.nameItJohn}" />
- <h:outputText id="name" value="Name:#{userBean.name}" />
- </h:panelGrid>
- </a4j:form>
- </rich:panel>
-
- <rich:panel>
- <f:facet name="header">
- <h:outputText value="Form with ajaxSubmit equals false"/>
- </f:facet>
-
- <a4j:form>
- <h:panelGrid>
- <h:commandButton value="Set Both Name to Mark (non-Ajax)" action="#{userBean.nameItMark}" />
- <h:outputText id="name" value="Name:#{userBean.name}" />
- </h:panelGrid>
- </a4j:form>
-
- </rich:panel>
-
- </h:panelGrid>
-</ui:composition>
\ No newline at end of file
Copied: trunk/samples/richfaces-demo/src/main/webapp/richfaces/insert/examples/groovy.xhtml (from rev 2513, trunk/samples/richfaces-demo/src/main/webapp/richfaces/insert/examples/ajaxSubmit.xhtml)
===================================================================
--- trunk/samples/richfaces-demo/src/main/webapp/richfaces/insert/examples/groovy.xhtml (rev 0)
+++ trunk/samples/richfaces-demo/src/main/webapp/richfaces/insert/examples/groovy.xhtml 2007-08-28 03:41:43 UTC (rev 2522)
@@ -0,0 +1,13 @@
+<ui:composition xmlns="http://www.w3.org/1999/xhtml"
+ xmlns:ui="http://java.sun.com/jsf/facelets"
+ xmlns:h="http://java.sun.com/jsf/html"
+ xmlns:f="http://java.sun.com/jsf/core"
+ xmlns:a4j="http://richfaces.org/a4j"
+ xmlns:rich="http://richfaces.org/rich">
+
+
+
+ <rich:insert src="/richfaces/insert/snippets/sample.groovy" highlight="groovy" />
+
+
+</ui:composition>
\ No newline at end of file
Deleted: trunk/samples/richfaces-demo/src/main/webapp/richfaces/insert/snippets/commandLinkProblem.xhtml
===================================================================
--- trunk/samples/richfaces-demo/src/main/webapp/richfaces/insert/snippets/commandLinkProblem.xhtml 2007-08-27 18:41:07 UTC (rev 2521)
+++ trunk/samples/richfaces-demo/src/main/webapp/richfaces/insert/snippets/commandLinkProblem.xhtml 2007-08-28 03:41:43 UTC (rev 2522)
@@ -1,13 +0,0 @@
- ....
- <-- This code does not work correctly after the link is re-rendered -->
- <h:form>
- ....
- <a4j:commandButton value="Update Non-Ajax Link" reRender="panel" />
- ....
- <h:panelGrid id="panel">
- ....
- <h:commandLink value="Non-Ajax Submit" action="foo" />
- ....
- </h:panelGrid>
- ....
- </h:form>
\ No newline at end of file
Added: trunk/samples/richfaces-demo/src/main/webapp/richfaces/insert/snippets/sample.groovy
===================================================================
--- trunk/samples/richfaces-demo/src/main/webapp/richfaces/insert/snippets/sample.groovy (rev 0)
+++ trunk/samples/richfaces-demo/src/main/webapp/richfaces/insert/snippets/sample.groovy 2007-08-28 03:41:43 UTC (rev 2522)
@@ -0,0 +1,9 @@
+double[] values = new double[8]
+
+i = 0
+[1, 2, 3, 4, 5, 6, 7, 8].each {
+ println it
+ values[i++] = it
+ // uncomment the next line and it works fine!!
+ //println it
+}
\ No newline at end of file
Modified: trunk/samples/richfaces-demo/src/main/webapp/richfaces/insert/usage.xhtml
===================================================================
--- trunk/samples/richfaces-demo/src/main/webapp/richfaces/insert/usage.xhtml 2007-08-27 18:41:07 UTC (rev 2521)
+++ trunk/samples/richfaces-demo/src/main/webapp/richfaces/insert/usage.xhtml 2007-08-28 03:41:43 UTC (rev 2522)
@@ -7,7 +7,26 @@
xmlns:rich="http://richfaces.org/rich">
<ui:composition template="/templates/component-sample.xhtml">
<ui:define name="sample">
- <p>placeholder</p>
+ <p>rich:insert component allows to insert and, optionally, format the file from the appication
+ context to the page. The context relative path to the file is specified with <b>src</b>
+ attribute.
+ </p>
+ <p>
+ <b>highlight</b> attribute defined the type of syntax highlighting. If this attribute is
+ specified, the inserting text is formated and the keywords are colorized using
+ <a href="https://jhighlight.dev.java.net/" target="_blank">jhighlight
+ open source</a> library. You need to have jhighlight.jar in the classpath to have this feature
+ enabled. The following example shows the groovy code snippet inserted and highlighted:
+ </p>
+
+
+ <div class="sample-container">
+ <ui:include src="/richfaces/insert/examples/groovy.xhtml"/>
+ <ui:include src="/templates/include/sourceview.xhtml">
+ <ui:param name="sourcepath" value="/richfaces/insert/examples/groovy.xhtml"/>
+ <ui:param name="openlabel" value="View Page Source" />
+ </ui:include>
+ </div>
</ui:define>
</ui:composition>
Modified: trunk/samples/richfaces-demo/src/main/webapp/richfaces/support.xhtml
===================================================================
--- trunk/samples/richfaces-demo/src/main/webapp/richfaces/support.xhtml 2007-08-27 18:41:07 UTC (rev 2521)
+++ trunk/samples/richfaces-demo/src/main/webapp/richfaces/support.xhtml 2007-08-28 03:41:43 UTC (rev 2522)
@@ -7,14 +7,15 @@
<ui:composition template="/templates/main.xhtml">
<ui:define name="title">RichFaces - Open Source Rich JSF Components - Ajax Support</ui:define>
<ui:define name="body">
- <ui:remove>
+
<rich:tabPanel switchType="server" styleClass="top_tab" contentClass="content_tab" headerClass="header_tabs_class" inactiveTabClass="inactive_tab" activeTabClass="active_tab">
<rich:tab label="Usage">
<ui:include src="/richfaces/support/usage.xhtml"/>
</rich:tab>
+ <rich:tab label="Documentation">
+ <rich:insert src="/doc/support/tagInfo.html"/>
+ </rich:tab>
</rich:tabPanel>
- </ui:remove>
- <ui:include src="/richfaces/support/usage.xhtml"/>
</ui:define>
-</ui:composition>
+ </ui:composition>
</html>
More information about the richfaces-svn-commits
mailing list