-
15. Re: XHTML files and content assist with custom tags
campi Jul 29, 2008 9:17 AM (in response to kragoth)"campi" wrote:
I needed the attribute-type and the attribute ...
The attribute wasn't displayed in my previous post. -
16. Re: XHTML files and content assist with custom tags
kragoth Jul 29, 2008 8:26 PM (in response to kragoth)Adding "JSF Capabilities" most certainly does make changes to a project.
It adds a WEB-INF/lib folder and a bunch of other things.
We do not have our project set up in the standard
WEB-INF/lib way. Our ant build is what sets up the web app structure.
At a source level we have a config directory that contains the files like web.xml and faces-config.xml etc. Our libs are in a lib folder with libraries seperated into their own folders. Like ../lib/richfaces/*.jar
This structure does not seem to work when you do the "Add JSF Capabilities"
Campi - regards your post: I actually tried just copying the richfaces tld file and giving it a different prefix and uri. Then adding that to my plugin.xml and I still didn't get the new components that I would have expected to get.
Would you mind posting your plugin.xml and tld file completely so I can try them myself.
That would be a big help thanks. -
17. Re: XHTML files and content assist with custom tags
campi Jul 30, 2008 4:23 AM (in response to kragoth)Here my plugin.xml :
<?xml version="1.0" encoding="UTF-8"?> <?eclipse version="3.0"?> <plugin> <extension-point id="tldResource" name="KB TLD Resource" schema="schema/tldResource.exsd"/> <extension point="org.jboss.tools.common.kb.tldResource"> <tld jsf="true" name="JSF Core" schema-location="schemas/tld/JsfCore1_2.xml" uri="http://java.sun.com/jsf/core"/> <tld jsf="true" name="JSF HTML Basic" schema-location="schemas/tld/JsfHtmlBasic1_1.xml" uri="http://java.sun.com/jsf/html" version="1.0"/> <tld jsf="true" name="JSF HTML Basic" schema-location="schemas/tld/JsfHtmlBasic1_2.xml" uri="http://java.sun.com/jsf/html"/> <tld jsf="true" name="JBoss Seam" schema-location="schemas/tld/JBossSeam1_2.xml" uri="http://jboss.com/products/seam/taglib" version="1.1"/> <tld jsf="true" name="JBoss Seam" schema-location="schemas/tld/JBossSeam1_2.xml" uri="http://jboss.com/products/seam/taglib" version="1.2"/> <tld jsf="true" name="JBoss Seam" schema-location="schemas/tld/JBossSeam2_0.xml" uri="http://jboss.com/products/seam/taglib"/> <tld jsf="true" name="JBoss Rich Faces" schema-location="schemas/tld/Vcp.xml" uri="http://richfaces.ajax4jsf.org/rich"/> <tld jsf="true" name="JBoss Rich Faces 3.1" schema-location="schemas/tld/Richfaces3_1.xml" uri="http://richfaces.org/rich" version="1.2"/> <tld jsf="true" name="JBoss Rich Faces 3.2" schema-location="schemas/tld/Richfaces3_2.xml" uri="http://richfaces.org/rich"/> <tld jsf="true" name="Rich Faces Ajax" schema-location="schemas/tld/VcpAjax.xml" uri="http://www.redhat.com/vcp/components/ajax"/> <tld jsf="true" name="JBoss Ajax4jsf" schema-location="schemas/tld/ajax4jsf.xml" uri="https://ajax4jsf.dev.java.net/ajax"/> <tld jsf="true" name="JBoss Ajax4jsf 3.1" schema-location="schemas/tld/Ajax4jsf3_1.xml" uri="http://richfaces.org/a4j" version="1.2"/> <tld jsf="true" name="JBoss Ajax4jsf 3.2" schema-location="schemas/tld/Ajax4jsf3_2.xml" uri="http://richfaces.org/a4j"/> <tld jsf="true" name="My Faces Extension" schema-location="schemas/tld/MyFacesExt.xml" uri="http://myfaces.apache.org/extensions"/> <tld jsf="true" name="My Faces Sandbox" schema-location="schemas/tld/MyFacesSandbox.xml" uri="http://myfaces.apache.org/sandbox"/> <tld jsf="true" name="My Faces Tomahawk" schema-location="schemas/tld/MyFacesTomahawk.xml" uri="http://myfaces.apache.org/tomahawk"/> <tld jsf="true" name="Facelets" schema-location="schemas/tld/Facelets.xml" uri="http://java.sun.com/jsf/facelets"/> <tld jsf="true" name="Facelets Html" schema-location="schemas/tld/FaceletsHtml.xml" uri="http://www.w3.org/1999/xhtml/facelets"/> <tld jsf="true" name="ADF Faces Core" schema-location="schemas/tld/ADFFacesCore.xml" uri="http://xmlns.oracle.com/adf/faces"/> <tld jsf="true" name="ADF Faces HTML" schema-location="schemas/tld/ADFFacesHtml.xml" uri="http://xmlns.oracle.com/adf/faces/html"/> <tld name="JSTL Core 1.0" schema-location="schemas/tld/JstlCore1_0.xml" uri="http://java.sun.com/jstl/core"/> <tld name="JSTL Format 1.0" schema-location="schemas/tld/JstlFmt1_0.xml" uri="http://java.sun.com/jstl/fmt"/> <tld name="JSTL SQL 1.0" schema-location="schemas/tld/JstlSql1_0.xml" uri="http://java.sun.com/jstl/sql"/> <tld name="JSTL XML 1.0" schema-location="schemas/tld/JstlXml1_0.xml" uri="http://java.sun.com/jstl/xml"/> <tld name="Struts HTML" schema-location="schemas/tld/StrutsHtml.xml" uri="http://struts.apache.org/tags-html"/> <tld name="Struts Bean" schema-location="schemas/tld/StrutsBean.xml" uri="http://struts.apache.org/tags-bean"/> <tld name="Struts Tiles" schema-location="schemas/tld/StrutsTiles.xml" uri="http://struts.apache.org/tags-tiles"/> <tld name="Struts Tiles 1.1" schema-location="schemas/tld/StrutsTiles11.xml" uri="http://jakarta.apache.org/struts/tags-tiles-1.1"/> <tld name="JSP" schema-location="schemas/tld/Jsp.xml" uri="http://java.sun.com/JSP/Page"/> <tld jsf="true" name="AtexoCommonsPages" schema-location="schemas/tld/AtexoCommonsPages.xml" uri="http://www.atexo.com/commons-pages"/> <tld jsf="true" name="AtexoCommons" schema-location="schemas/tld/AtexoCommons.xml" uri="http://www.atexo.com/jsf"/> <tld jsf="true" name="AtexoSub" schema-location="schemas/tld/AtexoSub.xml" uri="http://www.atexo.com/sub"/> </extension> </plugin>
My Three tld that I will be using are the last three.
Here my AtexoCommonsPages.xml :<?xml version="1.0" encoding="UTF-8"?> <!DOCTYPE kb-schema PUBLIC "-//Red Hat, Inc//DTD Knowledge Base 1.0//EN" "http://www.redhat.com/dtds/kb-schema_1_0.dtd"> <schema prefix="commons-pages"> <element-type body-content="allowed" content="mixed" name="referentielAddOrUpdate" start-tag="required"> <description>Renders the referentiel add or update form page.</description> <attribute-type name="title" required="true" value="java.lang.String"> <proposal type="beanProperty"/> <proposal type="bundleProperty"/> <proposal type="jsfVariables"/> </attribute-type> <attribute type="title"/> </element-type> <element-type body-content="allowed" content="mixed" name="referentielDelete" start-tag="required"> <description>Renders the referentiel delete form page.</description> </element-type> </schema>
I haven't rewrite all my tad (someday I'll have the time for, I hope), but this exemple is working.
Here some screenshots after an eclipse -clean :
http://champion.louis.free.fr/screenshot/eclipse/completion-custom-tag.png
http://champion.louis.free.fr/screenshot/eclipse/completion-attribute.png -
18. Re: XHTML files and content assist with custom tags
kragoth Jul 30, 2008 7:19 PM (in response to kragoth)Thanks heaps campi!
I copied and paste your plugin.xml entry and tld file and it works. So obviously there was something else I was doing wrong!
I'll look around and hopefully I can find it.
Thanks again! -
19. Re: XHTML files and content assist with custom tags
kragoth Jul 30, 2008 7:38 PM (in response to kragoth)I think that the BIG step missing from the instructions is telling people to start eclipse with the -clean argument. Without that argument the modifications will never appear. (I know most people probably know to do this but.... I had completely forgotten about it :P) So, if the instructions could be updated to include that, it would be much better.
-
20. Re: XHTML files and content assist with custom tags
campi Jul 31, 2008 3:12 AM (in response to kragoth)"Kragoth" wrote:
I think that the BIG step missing from the instructions is telling people to start eclipse with the -clean argument. Without that argument the modifications will never appear. (I know most people probably know to do this but.... I had completely forgotten about it :P) So, if the instructions could be updated to include that, it would be much better.
I always launch eclipse with the -clean argument ^^ -
21. Re: XHTML files and content assist with custom tags
kragoth Jul 31, 2008 3:50 AM (in response to kragoth)I was also able to solve the problem of having the tld file checked into my codebase by adding a hardlink from the schemas/tld/xxxx.tld to my codebase.
this was done with the 'fsutil hardlink create' tool in windows xp command prompt. Just in case anyone else wants that functionality -
22. Re: XHTML files and content assist with custom tags
maxandersen Jul 31, 2008 11:56 AM (in response to kragoth)it is a major bug if adding jsf capabilities adds things to your project!
I've never seen that, so please report that in jira.