Re: [Zope-dev] Structured Text Plus

2001-06-12 Thread Michel Pelletier

On Tue, 12 Jun 2001, Ian Clatworthy wrote:

 Andreas Jung wrote:
 
  - Original Message -
  From: Ian Clatworthy [EMAIL PROTECTED]
  To: [EMAIL PROTECTED]
  Sent: Sunday, June 10, 2001 9:52 PM
  Subject: [Zope-dev] Structured Text Plus
 
   I've put together the design for an extended version of
   Structured Text which I'd like some feedback on before
   I go too much further. At this stage, the design is
   explained via a series of user-level How-To's, e.g.
   Writing Documents Using Structured Text Plus.
 
  Could you please summarize the benefits compared to
  STXNG ?

 As I understand things from reading the STXNG Wiki stuff,
 it's largely an internal rewrite which adds 2 or 3 new
 features, namely images and tables.

This is only a small feature compared to what STXNG really adds to
structured text.  STXNG turns structured text into cross-format Document
Object Model (DOM) in two stages and then into a final format.  The first
stage turns it into a simple DOM that reflects the paragraph structure,
but not the markup (italics, bold, links, etc.).

The second stage uses the first stage DOM to create an even more elaborate
DOM based on markup or colorized text found in the first DOM's
paragraphs.

The second stage DOM can then be fed to a final outputter stage that
renders the DOM in any format you want, currently we support HTML,
DocBook, and MML (Framemaker or something like that) and it would be easy
to add any other XML format or PDF.  Here's an example that will work for
you:

 print text
Title

  o *one*

  o **two**

  o 'three'

#
# Create the basic DOM structure

 Basic(text)
StructuredTextDocument([
StructuredTextParagraph(Title, [
 StructuredTextParagraph(  o *one*, [
 ])
 StructuredTextParagraph(  o **two**, [
 ])
 StructuredTextParagraph(  o 'three', [
 ])
]),
])

#
# Create the Colorized DOM structure

 Document(Basic(text))
StructuredTextDocument([
StructuredTextSection(StructuredTextSectionTitle(Title, [
]), [
 StructuredTextBullet(StructuredTextEmphasis('one'), [
 ])
 StructuredTextBullet(StructuredTextStrong('two'), [
 ])
 StructuredTextBullet(StructuredTextLiteral('three'), [
 ])
]),
])

#
# Generate HTML from the DOM

 print HTML(Document(Basic(text)))
html
head
titleTitle/title
/head
body
h0Title/h0

ul
liemone/em/li
listrongtwo/strong/li
licodethree/code/li

/ul
/body
/html

#
# Generate DocBook from the DOM

 print DocBookChapter(Document(Basic(text)))
chapter
titleTitle/title
itemizedlist
listitemparaemphasisone/emphasis /para/listitem
listitemparaemphasistwo/emphasis/para/listitem
listitemparaliteralthree/literal/para/listitem
/itemizedlist
/chapter



You should really work from STXNG because we designed it to be extended,
just like you want to do.  You can subclass and customize the colorizer
in the second stage to recognize your own customized markup and do what
you will with it.  Amos and I did this to support images in the book.
You can also customize outputers as I explained.

  You are targeting also the single-source approach
  for documents with STPlus - what are the benefits
  compared to working solution like Docbook ?

 Upwards compatibility with STX, i.e. something more
 readable than XML.

Amen to that!

-Michel


___
Zope-Dev maillist  -  [EMAIL PROTECTED]
http://lists.zope.org/mailman/listinfo/zope-dev
**  No cross posts or HTML encoding!  **
(Related lists - 
 http://lists.zope.org/mailman/listinfo/zope-announce
 http://lists.zope.org/mailman/listinfo/zope )



Re: [Zope-dev] Structured Text Plus

2001-06-12 Thread Ian Clatworthy



Michel Pelletier wrote:

  As I understand things from reading the STXNG Wiki stuff,
  it's largely an internal rewrite which adds 2 or 3 new
  features, namely images and tables.
 
 This is only a small feature compared to what STXNG really adds to
 structured text.  STXNG turns structured text into cross-format Document
 Object Model (DOM) in two stages and then into a final format.  The first
 stage turns it into a simple DOM that reflects the paragraph structure,
 but not the markup (italics, bold, links, etc.).

Yes, the new processing architecture is great and I fully intend
to leverage it as much as possible. I'm not sure if I'll
need to make some additional changes to the core classes as well?
If I do, I don't expect them to be large.

Ian C.


-- 
This transmission is  for the intended  addressee only and is confidential
information.  If you  have  received  this  transmission in error,  please 
delete  it and  notify  the sender.  The contents of this  e-mail are  the 
opinion of the writer only and are not endorsed by Mincom Limited unless
expressly stated otherwise.

___
Zope-Dev maillist  -  [EMAIL PROTECTED]
http://lists.zope.org/mailman/listinfo/zope-dev
**  No cross posts or HTML encoding!  **
(Related lists - 
 http://lists.zope.org/mailman/listinfo/zope-announce
 http://lists.zope.org/mailman/listinfo/zope )



Re: [Zope-dev] Structured Text Plus

2001-06-11 Thread Chris Withers

Have you checked out StructuredTextNG?

cheers,

Chris

Ian Clatworthy wrote:
 
 I've put together the design for an extended version of
 Structured Text which I'd like some feedback on before
 I go too much further. At this stage, the design is
 explained via a series of user-level How-To's, e.g.
 Writing Documents Using Structured Text Plus.
 The home page is:
 
   http://www.zope.org/Members/ianc/StructuredTextPlus/home
 
 Ian C.
 
 --
 This transmission is  for the intended  addressee only and is confidential
 information.  If you  have  received  this  transmission in error,  please
 delete  it and  notify  the sender.  The contents of this  e-mail are  the
 opinion of the writer only and are not endorsed by Mincom Limited unless
 expressly stated otherwise.
 
 ___
 Zope-Dev maillist  -  [EMAIL PROTECTED]
 http://lists.zope.org/mailman/listinfo/zope-dev
 **  No cross posts or HTML encoding!  **
 (Related lists -
  http://lists.zope.org/mailman/listinfo/zope-announce
  http://lists.zope.org/mailman/listinfo/zope )

___
Zope-Dev maillist  -  [EMAIL PROTECTED]
http://lists.zope.org/mailman/listinfo/zope-dev
**  No cross posts or HTML encoding!  **
(Related lists - 
 http://lists.zope.org/mailman/listinfo/zope-announce
 http://lists.zope.org/mailman/listinfo/zope )



Re: [Zope-dev] Structured Text Plus

2001-06-11 Thread Andreas Jung


- Original Message - 
From: Ian Clatworthy [EMAIL PROTECTED]
To: [EMAIL PROTECTED]
Sent: Sunday, June 10, 2001 9:52 PM
Subject: [Zope-dev] Structured Text Plus


 I've put together the design for an extended version of
 Structured Text which I'd like some feedback on before
 I go too much further. At this stage, the design is
 explained via a series of user-level How-To's, e.g.
 Writing Documents Using Structured Text Plus.

Could you please summarize the benefits compared to 
STXNG ? 

You are targeting also the single-source approach
for documents with STPlus - what are the benefits
compared to working solution like Docbook ?

Andreas


___
Zope-Dev maillist  -  [EMAIL PROTECTED]
http://lists.zope.org/mailman/listinfo/zope-dev
**  No cross posts or HTML encoding!  **
(Related lists - 
 http://lists.zope.org/mailman/listinfo/zope-announce
 http://lists.zope.org/mailman/listinfo/zope )



Re: [Zope-dev] Structured Text Plus

2001-06-11 Thread Ian Clatworthy



Andreas Jung wrote:
 
 - Original Message -
 From: Ian Clatworthy [EMAIL PROTECTED]
 To: [EMAIL PROTECTED]
 Sent: Sunday, June 10, 2001 9:52 PM
 Subject: [Zope-dev] Structured Text Plus
 
  I've put together the design for an extended version of
  Structured Text which I'd like some feedback on before
  I go too much further. At this stage, the design is
  explained via a series of user-level How-To's, e.g.
  Writing Documents Using Structured Text Plus.
 
 Could you please summarize the benefits compared to
 STXNG ?

As I understand things from reading the STXNG Wiki stuff,
it's largely an internal rewrite which adds 2 or 3 new
features, namely images and tables. STXPlus is a lot more
ambitious than that wrt new features, i.e.

* there are 3 levels of features above'Classic', namely
  Topic, Document and Book
* each level adds half a dozen new features.

 You are targeting also the single-source approach
 for documents with STPlus - what are the benefits
 compared to working solution like Docbook ?

Upwards compatibility with STX, i.e. something more
readable than XML.

Ian C.


-- 
This transmission is  for the intended  addressee only and is confidential
information.  If you  have  received  this  transmission in error,  please 
delete  it and  notify  the sender.  The contents of this  e-mail are  the 
opinion of the writer only and are not endorsed by Mincom Limited unless
expressly stated otherwise.

___
Zope-Dev maillist  -  [EMAIL PROTECTED]
http://lists.zope.org/mailman/listinfo/zope-dev
**  No cross posts or HTML encoding!  **
(Related lists - 
 http://lists.zope.org/mailman/listinfo/zope-announce
 http://lists.zope.org/mailman/listinfo/zope )