You are viewing a plain text version of this content. The canonical link for it is here.
Posted to svn@forrest.apache.org by tw...@apache.org on 2005/09/08 06:40:52 UTC

svn commit: r279511 - /forrest/trunk/whiteboard/plugins/org.apache.forrest.plugin.internal.xhtml2/resources/stylesheets/xhtml2_to_html.xsl

Author: twilliams
Date: Wed Sep  7 21:40:42 2005
New Revision: 279511

URL: http://svn.apache.org/viewcvs?rev=279511&view=rev
Log:
can't return all the html, head, stuff for insertion in the pipeline.  temporary solution to get on with pipeline testing

Modified:
    forrest/trunk/whiteboard/plugins/org.apache.forrest.plugin.internal.xhtml2/resources/stylesheets/xhtml2_to_html.xsl

Modified: forrest/trunk/whiteboard/plugins/org.apache.forrest.plugin.internal.xhtml2/resources/stylesheets/xhtml2_to_html.xsl
URL: http://svn.apache.org/viewcvs/forrest/trunk/whiteboard/plugins/org.apache.forrest.plugin.internal.xhtml2/resources/stylesheets/xhtml2_to_html.xsl?rev=279511&r1=279510&r2=279511&view=diff
==============================================================================
--- forrest/trunk/whiteboard/plugins/org.apache.forrest.plugin.internal.xhtml2/resources/stylesheets/xhtml2_to_html.xsl (original)
+++ forrest/trunk/whiteboard/plugins/org.apache.forrest.plugin.internal.xhtml2/resources/stylesheets/xhtml2_to_html.xsl Wed Sep  7 21:40:42 2005
@@ -38,11 +38,11 @@
     -  depth to be configured -->
   <xsl:param name="xhtml-heading" select="1"/>
 
-  <!-- Use XHTML 1.0 as the output schema -->
+  <!-- Use XHTML 1.0 as the output schema 
   <xsl:output method="html" version="1.0" encoding="utf-8"
     omit-xml-declaration="yes" media-type="text/html"
     doctype-public="-//W3C//DTD HTML 4.01//EN"
-    doctype-system="http://www.w3.org/TR/html4/strict.dtd"/>
+    doctype-system="http://www.w3.org/TR/html4/strict.dtd"/>-->
 
   <!-- Copy elements by default -->
   <xsl:template match="comment()">
@@ -755,18 +755,33 @@
     -->
   <!-- Add our Subversion/CVS Id to the root element -->
   <xsl:template match="html:html">
-   <xsl:comment> $Id: xhtml2html.xslt 127 2004-11-14 03:06:21Z etherealwake $ </xsl:comment>
-   <html>
+  <!-- most of this template is placeholder stuff to get it to look like 
+      the resultant document2html so that I can see if I'm going down
+      the correct path
+      -->
+   <tocitems>
+     <tocitem level="1" href="#welcome" title="Welcome"></tocitem>
+    </tocitems>
+   <meta-data></meta-data>
+   <div id="content">
+    <div id="skinconf-printlink"></div>
+    <div id="skinconf-xmllink"></div>
+    <div id="skinconf-podlink"></div>
+    <div id="skinconf-txtlink"></div>
+    <div id="skinconf-pdflink"></div>
+    <div id="disable-font-script"></div>
+
     <xsl:apply-templates select="@*"/>
     <xsl:apply-templates/>
-   </html>
+   
+   </div>
   </xsl:template>
   <!-- Specify namespace for metadata (if not using schema.X links) -->
   <xsl:template match="html:html/@profile">
    <xsl:attribute name="profile"><xsl:value-of select="."/></xsl:attribute>
   </xsl:template>
   <!-- Add a generator tag to the head section -->
-  <xsl:template match="html:head">
+  <xsl:template match="html:headDISABLED">
    <head>
     <xsl:apply-templates select="@*"/>
     <meta http-equiv="Content-Type" content="text/html; charset=utf-8"/>
@@ -777,7 +792,7 @@
    </head>
   </xsl:template>
   <!-- <title> and <body> are pretty much copied as is -->
-  <xsl:template match="html:title|html:body">
+  <xsl:template match="html:title|html:bodyDISABLE">
    <xsl:element name="{local-name()}">
     <xsl:apply-templates select="@*"/>
     <xsl:apply-templates/>
@@ -814,7 +829,7 @@
    </xsl:choose>
   </xsl:template>
   <!-- We will treat sections as simple <div>s of class section -->
-  <xsl:template match="html:section">
+  <xsl:template match="html:section|html:body">
    <xsl:call-template name="block">
     <xsl:with-param name="element" select="'div'"/>
     <xsl:with-param name="class" select="'section'"/>



Re: svn commit: r279511

Posted by Thorsten Scherler <th...@apache.org>.
On Fri, 2005-09-09 at 09:47 -0400, Tim Williams wrote:
> I've reverted my changes as requested.  

Hmm.

> I'll lay low until I see where
> you're going with this.  Perhaps I don't understand views as well as I
> thought, 

Actually I am quite convinced that you actually *do* understand views
and where they are heading to. I am watching your commits and they are
the way I would do it given the current situation. 

The mails you have wrote about views are describing them really well and
you took the time (which was a lot I guess) to follow and describe the
view processing. We really appreciate this work and I reckon you learned
a lot while doing it (because we learned a lot reading it carefully)!
Maybe more people should follow this example if they are curious about
getting into views and their refactoring.

> but I don't see that the output side of them works on xdoc,
> but rather the resultant html of document2html.

Like I stated in *a lot* of mails: views *are* *just* replacing
site2xhtml.xsl of leather-dev. Which means for the current
implementation of views (that we have now) *you* *are* *100%* *right*!!!

Everything else is a modification/personal interpretation of views which
should go in a refactored version of them rather then in the XHTML2
plugin!

> Either way, I'm deleting my local changes and svn up occasionally to
> see where you're going.

Hmm, I am really concerned what is going on ATM. Please do not get
frustrated about comments on your work. Remember each person on this
list is speaking for themselves and each of us have their own point of
view on things. Always assume that the comments are intended to help you
rather then criticize.

Having said this I can understand that sometimes it is better to lay low
and watch what is going on, to better cope with the situation (I as well
reached this point on certain parts of our code base and discussions). 

There are many areas in forrest that need enhancement and maybe it is
time for you to bring up your ideas how to improve views:
On Thu, 2005-09-08 at 18:24 -0400, Tim Williams wrote:
> For example, in this process so far, I've been notetaking my own ideas
> of how we might improve views

I am really keen to hear this ideas. Please tell us more.

salu2
-- 
thorsten

"Together we stand, divided we fall!" 
Hey you (Pink Floyd)


Re: svn commit: r279511 - /forrest/trunk/whiteboard/plugins/org.apache.forrest.plugin.internal.xhtml2/resources/stylesheets/xhtml2_to_html.xsl

Posted by Ross Gardler <rg...@apache.org>.
Tim Williams wrote:
> I've reverted my changes as requested.

I never requested that :-((

I was trying to understand why this change was necessary.

>  I'll lay low until I see where
> you're going with this.  Perhaps I don't understand views as well as I
> thought, but I don't see that the output side of them works on xdoc,
> but rather the resultant html of document2html.

Did I say that output was XDoc? I didn't mean to, what I meant was the 
outpur of document2html is not XHTML2 (its not even html), therefore if 
we continue to work with that format we are not using XHTML2 in our 
internals.

> Either way, I'm deleting my local changes and svn up occasionally to
> see where you're going.

No, please don't do that. I never said this change should be reverted, I 
asked why it was necessary.

I have vision in my own mind as to where this is going, but that doesn't 
mean it is right. Both you and Thorsten are expressing similar concerns, 
but I don't understand them. I'm trying to understand.

This commit, in isolation, makes no sense whatsoever. However, I am 
aware it is part of a larger set of changes you made locally. I need to 
understand what your approach is and if it is in line with Thorstens, 
because if it is then it is likely that my approach is wrong.

Ross

> --tim
> 
> On 9/9/05, Ross Gardler <rg...@apache.org> wrote:
> 
>>Tim Williams wrote:
>>
>>>On 9/9/05, Ross Gardler <rg...@apache.org> wrote:
>>>
>>>
>>>>twilliams@apache.org wrote:
>>>>
>>>>
>>>>>Author: twilliams
>>>>>Date: Wed Sep  7 21:40:42 2005
>>>>>New Revision: 279511
>>>>>
>>>>>URL: http://svn.apache.org/viewcvs?rev=279511&view=rev
>>>>>Log:
>>>>>can't return all the html, head, stuff for insertion in the pipeline.  temporary solution to get on with pipeline testing
>>>>
>>>>Why do you want the output to look like document2html output and then be
>>>>passed into the existing pipelines?
>>>
>>>
>>>Because that's how views work right now.  I didn't have this grand
>>>redesign scheme in my mind at the time.  I thought we were getting
>>>XHTML2 to work with the current views and replacing the **body-*.html
>>>aggregation "part" in the **page pipeline with an xthml2tohtml
>>>equivalent was how I did it.
>>
>>Views as they are now, work with XDoc. The goal is to make core work
>>with XHTML2 not XDoc. It is not possible to include views in this work
>>*and* not do a level of redesign in views (or the old skin system).
>>
>>
>>>>Don't we just want XHTML2 -> output plugin = desired output
>>>
>>>
>>>That's what it is, but views operate on html structured like the
>>>output of document2html.  I wasn't redesigning views, just getting
>>>xhtml2 to work with them.
>>
>>So here you are saying the same as Thorsten.
>>
>>
>>>>Meaning we only need an XHTML2_to_HTML stylesheet>
>>>>
>>>>(I recall a conversation Tim and I had on IRC in which he asked me why
>>>>we need the XHTML2HTML stylesheet. I seem to remember the answer I gave
>>>>was misleading to say the least. Hopefully recent discussions about the
>>>>new pipeline will have clarified - if not I'll try agian when I
>>>>understand the intent of this commit, I may be missing something)
>>>>
>>>>Ross
>>>
>>>
>>>I could very well be missing something but like I tried to explain in
>>>the other thread, to get xhtml2 to work with views (or the current
>>>skins for that matter) we need two things:
>>>1) a xslt that outputs html with the same structure of document2html
>>>2) a change in the **page pipeline to call that instead of **body-*.html
>>
>>Well this is where the "division" needs to be called. In my view it is a
>>waste of effort refactoring the current skinning system to use XHTML2
>>and then converting views to get rid of the body-** templates.
>>
>>In my opinion we should skip the conversion of skins and work directly
>>on views.
>>
>>If you revert this commit and do svn up, you will see that the body-*
>>part of the pipeline is working. All we need to do now is get views to
>>work with site.xml source files to create the navigation (this is, a
>>small step).
>>
>>[NOTE] this work happens in the contracts *not* in the structurer
>>sitemap so it does not prevent work proceeding with the refactoring of
>>views.
>>
>>
>>>Even when we do what you suggest and use contracts for everything
>>>instead of aggregation, the implementation of that contract will still
>>>need something similar to this.
>>
>>Why? I don't think this is the case (see my summary mails on return from
>>  Apachecon and Thorsten expansion of that summary)
>>
>>Ross
>>
> 
> 
> 


Re: svn commit: r279511 - /forrest/trunk/whiteboard/plugins/org.apache.forrest.plugin.internal.xhtml2/resources/stylesheets/xhtml2_to_html.xsl

Posted by Tim Williams <wi...@gmail.com>.
I've reverted my changes as requested.  I'll lay low until I see where
you're going with this.  Perhaps I don't understand views as well as I
thought, but I don't see that the output side of them works on xdoc,
but rather the resultant html of document2html.

Either way, I'm deleting my local changes and svn up occasionally to
see where you're going.
--tim

On 9/9/05, Ross Gardler <rg...@apache.org> wrote:
> Tim Williams wrote:
> > On 9/9/05, Ross Gardler <rg...@apache.org> wrote:
> >
> >>twilliams@apache.org wrote:
> >>
> >>>Author: twilliams
> >>>Date: Wed Sep  7 21:40:42 2005
> >>>New Revision: 279511
> >>>
> >>>URL: http://svn.apache.org/viewcvs?rev=279511&view=rev
> >>>Log:
> >>>can't return all the html, head, stuff for insertion in the pipeline.  temporary solution to get on with pipeline testing
> >>
> >>Why do you want the output to look like document2html output and then be
> >>passed into the existing pipelines?
> >
> >
> > Because that's how views work right now.  I didn't have this grand
> > redesign scheme in my mind at the time.  I thought we were getting
> > XHTML2 to work with the current views and replacing the **body-*.html
> > aggregation "part" in the **page pipeline with an xthml2tohtml
> > equivalent was how I did it.
> 
> Views as they are now, work with XDoc. The goal is to make core work
> with XHTML2 not XDoc. It is not possible to include views in this work
> *and* not do a level of redesign in views (or the old skin system).
> 
> >>Don't we just want XHTML2 -> output plugin = desired output
> >
> >
> > That's what it is, but views operate on html structured like the
> > output of document2html.  I wasn't redesigning views, just getting
> > xhtml2 to work with them.
> 
> So here you are saying the same as Thorsten.
> 
> >>Meaning we only need an XHTML2_to_HTML stylesheet>
> >>
> >>(I recall a conversation Tim and I had on IRC in which he asked me why
> >>we need the XHTML2HTML stylesheet. I seem to remember the answer I gave
> >>was misleading to say the least. Hopefully recent discussions about the
> >>new pipeline will have clarified - if not I'll try agian when I
> >>understand the intent of this commit, I may be missing something)
> >>
> >>Ross
> >
> >
> > I could very well be missing something but like I tried to explain in
> > the other thread, to get xhtml2 to work with views (or the current
> > skins for that matter) we need two things:
> > 1) a xslt that outputs html with the same structure of document2html
> > 2) a change in the **page pipeline to call that instead of **body-*.html
> 
> Well this is where the "division" needs to be called. In my view it is a
> waste of effort refactoring the current skinning system to use XHTML2
> and then converting views to get rid of the body-** templates.
> 
> In my opinion we should skip the conversion of skins and work directly
> on views.
> 
> If you revert this commit and do svn up, you will see that the body-*
> part of the pipeline is working. All we need to do now is get views to
> work with site.xml source files to create the navigation (this is, a
> small step).
> 
> [NOTE] this work happens in the contracts *not* in the structurer
> sitemap so it does not prevent work proceeding with the refactoring of
> views.
> 
> > Even when we do what you suggest and use contracts for everything
> > instead of aggregation, the implementation of that contract will still
> > need something similar to this.
> 
> Why? I don't think this is the case (see my summary mails on return from
>   Apachecon and Thorsten expansion of that summary)
> 
> Ross
>

Re: svn commit: r279511 - /forrest/trunk/whiteboard/plugins/org.apache.forrest.plugin.internal.xhtml2/resources/stylesheets/xhtml2_to_html.xsl

Posted by Ross Gardler <rg...@apache.org>.
Tim Williams wrote:
> On 9/9/05, Ross Gardler <rg...@apache.org> wrote:
> 
>>twilliams@apache.org wrote:
>>
>>>Author: twilliams
>>>Date: Wed Sep  7 21:40:42 2005
>>>New Revision: 279511
>>>
>>>URL: http://svn.apache.org/viewcvs?rev=279511&view=rev
>>>Log:
>>>can't return all the html, head, stuff for insertion in the pipeline.  temporary solution to get on with pipeline testing
>>
>>Why do you want the output to look like document2html output and then be
>>passed into the existing pipelines?
> 
> 
> Because that's how views work right now.  I didn't have this grand
> redesign scheme in my mind at the time.  I thought we were getting
> XHTML2 to work with the current views and replacing the **body-*.html
> aggregation "part" in the **page pipeline with an xthml2tohtml
> equivalent was how I did it.

Views as they are now, work with XDoc. The goal is to make core work 
with XHTML2 not XDoc. It is not possible to include views in this work 
*and* not do a level of redesign in views (or the old skin system).

>>Don't we just want XHTML2 -> output plugin = desired output
> 
> 
> That's what it is, but views operate on html structured like the
> output of document2html.  I wasn't redesigning views, just getting
> xhtml2 to work with them.

So here you are saying the same as Thorsten.

>>Meaning we only need an XHTML2_to_HTML stylesheet>
>>
>>(I recall a conversation Tim and I had on IRC in which he asked me why
>>we need the XHTML2HTML stylesheet. I seem to remember the answer I gave
>>was misleading to say the least. Hopefully recent discussions about the
>>new pipeline will have clarified - if not I'll try agian when I
>>understand the intent of this commit, I may be missing something)
>>
>>Ross
> 
> 
> I could very well be missing something but like I tried to explain in
> the other thread, to get xhtml2 to work with views (or the current
> skins for that matter) we need two things:
> 1) a xslt that outputs html with the same structure of document2html
> 2) a change in the **page pipeline to call that instead of **body-*.html

Well this is where the "division" needs to be called. In my view it is a 
waste of effort refactoring the current skinning system to use XHTML2 
and then converting views to get rid of the body-** templates.

In my opinion we should skip the conversion of skins and work directly 
on views.

If you revert this commit and do svn up, you will see that the body-* 
part of the pipeline is working. All we need to do now is get views to 
work with site.xml source files to create the navigation (this is, a 
small step).

[NOTE] this work happens in the contracts *not* in the structurer 
sitemap so it does not prevent work proceeding with the refactoring of 
views.

> Even when we do what you suggest and use contracts for everything
> instead of aggregation, the implementation of that contract will still
> need something similar to this.

Why? I don't think this is the case (see my summary mails on return from 
  Apachecon and Thorsten expansion of that summary)

Ross

Re: svn commit: r279511 - /forrest/trunk/whiteboard/plugins/org.apache.forrest.plugin.internal.xhtml2/resources/stylesheets/xhtml2_to_html.xsl

Posted by Ross Gardler <rg...@apache.org>.
David Crossley wrote:
> Tim Williams wrote:
> 
>>Ross Gardler wrote:
>>
>>>Why do you want the output to look like document2html output and then be
>>>passed into the existing pipelines?
>>
>>Because that's how views work right now.  I didn't have this grand
>>redesign scheme in my mind at the time.  I thought we were getting
>>XHTML2 to work with the current views and replacing the **body-*.html
>>aggregation "part" in the **page pipeline with an xthml2tohtml
>>equivalent was how I did it.
>> 
>>
>>>Don't we just want XHTML2 -> output plugin = desired output
>>
>>That's what it is, but views operate on html structured like the
>>output of document2html.  I wasn't redesigning views, just getting
>>xhtml2 to work with them.
> 
> 
> Now i see. Tim is aiming to do the work in stages.
> Get part of the XHTML2 working with the existing views
> and skinning.
> 
> Others are leaving the existing skins and views systems
> in place to continue operating as they do, while building
> a parallel plugin (plugins) that do XHTML2 all the way
> through.
> 
> Is that where the mismatch is occuring?

Certainly, that is the case with this commit. I'm not sure if this is a 
good approach or not, only experimentation will show. So, please Tim, 
don't delete your local changes. We are still asking questions and 
learning from one anothers experiments.

Ross

Re: svn commit: r279511 - /forrest/trunk/whiteboard/plugins/org.apache.forrest.plugin.internal.xhtml2/resources/stylesheets/xhtml2_to_html.xsl

Posted by David Crossley <cr...@apache.org>.
Tim Williams wrote:
> Ross Gardler wrote:
> > 
> > Why do you want the output to look like document2html output and then be
> > passed into the existing pipelines?
> 
> Because that's how views work right now.  I didn't have this grand
> redesign scheme in my mind at the time.  I thought we were getting
> XHTML2 to work with the current views and replacing the **body-*.html
> aggregation "part" in the **page pipeline with an xthml2tohtml
> equivalent was how I did it.
>  
> > Don't we just want XHTML2 -> output plugin = desired output
> 
> That's what it is, but views operate on html structured like the
> output of document2html.  I wasn't redesigning views, just getting
> xhtml2 to work with them.

Now i see. Tim is aiming to do the work in stages.
Get part of the XHTML2 working with the existing views
and skinning.

Others are leaving the existing skins and views systems
in place to continue operating as they do, while building
a parallel plugin (plugins) that do XHTML2 all the way
through.

Is that where the mismatch is occuring?

-David

Re: svn commit: r279511 - /forrest/trunk/whiteboard/plugins/org.apache.forrest.plugin.internal.xhtml2/resources/stylesheets/xhtml2_to_html.xsl

Posted by Tim Williams <wi...@gmail.com>.
On 9/9/05, Ross Gardler <rg...@apache.org> wrote:
> twilliams@apache.org wrote:
> > Author: twilliams
> > Date: Wed Sep  7 21:40:42 2005
> > New Revision: 279511
> >
> > URL: http://svn.apache.org/viewcvs?rev=279511&view=rev
> > Log:
> > can't return all the html, head, stuff for insertion in the pipeline.  temporary solution to get on with pipeline testing
> 
> Why do you want the output to look like document2html output and then be
> passed into the existing pipelines?

Because that's how views work right now.  I didn't have this grand
redesign scheme in my mind at the time.  I thought we were getting
XHTML2 to work with the current views and replacing the **body-*.html
aggregation "part" in the **page pipeline with an xthml2tohtml
equivalent was how I did it.
 
> Don't we just want XHTML2 -> output plugin = desired output

That's what it is, but views operate on html structured like the
output of document2html.  I wasn't redesigning views, just getting
xhtml2 to work with them.
 
> Meaning we only need an XHTML2_to_HTML stylesheet>
>
> (I recall a conversation Tim and I had on IRC in which he asked me why
> we need the XHTML2HTML stylesheet. I seem to remember the answer I gave
> was misleading to say the least. Hopefully recent discussions about the
> new pipeline will have clarified - if not I'll try agian when I
> understand the intent of this commit, I may be missing something)
> 
> Ross

I could very well be missing something but like I tried to explain in
the other thread, to get xhtml2 to work with views (or the current
skins for that matter) we need two things:
1) a xslt that outputs html with the same structure of document2html
2) a change in the **page pipeline to call that instead of **body-*.html

Even when we do what you suggest and use contracts for everything
instead of aggregation, the implementation of that contract will still
need something similar to this.

--tim

Re: svn commit: r279511 - /forrest/trunk/whiteboard/plugins/org.apache.forrest.plugin.internal.xhtml2/resources/stylesheets/xhtml2_to_html.xsl

Posted by Ross Gardler <rg...@apache.org>.
twilliams@apache.org wrote:
> Author: twilliams
> Date: Wed Sep  7 21:40:42 2005
> New Revision: 279511
> 
> URL: http://svn.apache.org/viewcvs?rev=279511&view=rev
> Log:
> can't return all the html, head, stuff for insertion in the pipeline.  temporary solution to get on with pipeline testing

Why do you want the output to look like document2html output and then be 
passed into the existing pipelines?

Don't we just want XHTML2 -> output plugin = desired output

Meaning we only need an XHTML2_to_HTML stylesheet>

(I recall a conversation Tim and I had on IRC in which he asked me why 
we need the XHTML2HTML stylesheet. I seem to remember the answer I gave 
was misleading to say the least. Hopefully recent discussions about the 
new pipeline will have clarified - if not I'll try agian when I 
understand the intent of this commit, I may be missing something)

Ross