Re: [Haskell-cafe] [ANNOUNCE] Fmark markup language

2012-09-19 Thread Mario Blažević

On 12-09-18 07:37 PM, Richard O'Keefe wrote:


On 19/09/2012, at 1:43 AM, Stefan Monnier wrote:


The problem with that is that some people DO end some headings with
a full stop; for them your special syntax is not natural.


Markdown/ReST is already using the no syntax idea (e.g. compared to
pre-wiki markup such a LaTeX or Texinfo), so he's simply trying to push
this idea further.


Markdown is very heavy on syntax,
what it is *light* on is specification of what the
syntax actually is.  As a result,
I'm aware of three different dialects,
and someone told me about having to reverse
engineer the syntax from a Perl implementation.
As a further result, I cannot write a program to
reliably *generate* Markdown.


	Very true. Sadly, this is the case with almost all other Wiki-like 
markup schemes out there. They are all implementation-specified. The 
only exception I'm aware of is Creole, for which an EBNF grammar exists, 
even if it's pretty nasty-looking. A look at that specification makes 
one appreciate how badly specified natural syntax is.


	In my opinion, there is no single natural syntax that can be imposed on 
ASCII strings and serve majority of uses. There are many different 
syntaxes that feel  natural for different uses and different users, and 
the best we can hope to achieve would be a way to provide a formal and 
readable specification for each of those syntaxes. I've been playing 
with one approach in this direction with the concrete-relaxng-parser 
package, but it's still early days.





I suspect it'll be difficult.


Oh, more power to him for trying.
I just don't think it can be pushed very far.

Oh, there is a really *filthy* hack that could be pulled
for italics, bold face, and so on.  Contrary to its original
principles, Unicode includes several copies of ASCII
(see http://unicode.org/charts/PDF/U1D400.pdf):
Mathematical bold,
Mathematical italic,
Mathematical bold italic,
Mathematical script,
Mathematical bold script,
Mathematical fraktur,
Mathematical double struck (blackboard-bold),
Mathematical bold fraktur,
Mathematical sans-serif,
Mathematical sans-serif bold,
Mathematical sans-serif italic,
Mathematical sans-serif bold italic,
Mathematical monospace,
and some similar sets of Greek.


Thank you for sharing this hack. It's very amusing.




--
Mario Blazevic
mblaze...@stilo.com
Stilo International

This message, including any attachments, is for the sole use of the
intended recipient(s) and may contain confidential and privileged
information. Any unauthorized review, use, disclosure, copying, or
distribution is strictly prohibited. If you are not the intended
recipient(s) please contact the sender by reply email and destroy
all copies of the original message and any attachments.

___
Haskell-Cafe mailing list
Haskell-Cafe@haskell.org
http://www.haskell.org/mailman/listinfo/haskell-cafe


Re: [Haskell-cafe] [ANNOUNCE] Fmark markup language

2012-09-18 Thread José Lopes

Hello Ivan,

I agree with your point: if you want a heading that ends with a punctuation
sign then you cannot do it in Fmark (for now). That gives me something to
think about. However, I will still look for a way that avoids (as much as
possible) special syntax. Do you have any suggestion?

I also agree with you on the natural conventions. I want to find a good
tradeoff between syntax and expressiveness. In other words, I want to
avoid as much those odd choices you mentioned. For example, I have
been thinking seriously about emphasis and what would be a good way
to do it. So far I could only come up with quotes (either  or '). What do
you think?

Cheers,
José

On 18-09-2012 06:05, Ivan Lazar Miljenovic wrote:

On 18 September 2012 13:57, José Lopes jose.lo...@ist.utl.pt wrote:

Hello Kris,

Thank you for your email.

At this moment, Fmark is not as powerful as Markdown, also because Fmark
just started.
Markdown offers things such as Blockquotes, Lists, Code blocks, links,
emphasis, images, etc.
Fmark does not offer as many features: for now, there are only paragraphs,
headings,
subsections (endless nesting) and footnotes. In the near future, I want to
bolds/italics,
ordered and unordered lists, links, and later on as many elements as
possible :)

The problem with Fmark is also its greatest feature. While other markup
languages
introduce special syntactic characters to give meaning to the document's
elements,
I would like to take a different approach: I want to use characters that
people already
use in document writing to achieve the same result. For example, in
Mediawiki a
heading is some text surrounded by equal signs. But in Fmark a heading is
simply some
text that does not end in a punctuation character, such as period or an
exclamation mark.
I argue that this is a more natural approach.

Is it possible to override this?  What happens if I want a heading of
This is the greatest Heading Ever! ?

Natural conventions seem to be to be rather hacky and with lots of
corner cases; I think it's better to define a specific syntax for
markup (e.g. what is the natural way of emphasising text?) and stick
to it (though I agree that Markdown has some odd choices; in
particular, the ability to use both _ and * for italics whilst
requiring ** for bold).


I want to find a natural way of not burdening the user with the task of
having to learn
some special syntax in order to write a document. Instead I want to find
natural ways
of writing and use those ways to reconstruct the elements in a document. Of
course,
what is natural is subjective and that is why I want to find a good tradeoff
between
expressiveness and simplicity in the syntax. For example, in Fmark a
footnote is some
text surrounded by square brackets. Maybe you find this natural, maybe you
don't. If a
handful of people defend a more natural way of writing footnotes I want to
implement
the way they say. If there is a more natural way of doing this I want to
find it. But for now
I think square brackets are better than the equal signs or any other strange
syntactic
character such as exclamation marks and so on...

Another thing about Fmark is styles. I want to use fmark personally to write
papers, using
Latex as backend. While experimenting with previous versions of Fmark I
realized that I
could not specify the title, the author, the date, and the abstract. which
are essential in a
paper. I came up with an idea which I think is quite interesting. I wrote
another document
also using Fmark which only had the words Title, Author, Date, and
Abstract. And
then I combined these two documents together, such that, Fmark associated
title, author,
date and abstract, with the corresponding content. I thought the idea was
interesting
because the content and style documents have both the same structure and are
both
written in Fmark. Of course, there is still a long way to go, in order to be
able to fully
customize a document.

But styles are a good and simple approach, similar to document classes in
Latex: the idea is
to write one document (content) and then use multiple (predefined, user
defined) styles, such
as, article, report, etc, to stylize your document. Another interesting
thing I have been thinking
about (but not implemented yet) is recursion in document styling. In a way,
weaving a style
with content can be compared to matching a regular expression.

Anyway, these are just some key ideas. I see Fmark as a work in progress and
in a way as a
research project, trying to find a natural way of writing documents while
escaping as much
as possible from the syntax of a programming language. I also have a
metagoal with this
project: if my father (the non programming guy) could use it to write his
PhD dissertation,
I would be quite happy :)

If you have any more questions I would be happy to answer.
But if you're interested in using markup languages for blogs perhaps a HTML
backend
in Fmark would be more interesting for you. Although, XML + JavaScript + CSS
is also 

Re: [Haskell-cafe] [ANNOUNCE] Fmark markup language

2012-09-18 Thread José Lopes

Hello Richard,

When you say (for) some people (...) you special syntax is not natural
that's a good thing. I want these people involved in the project. I want
to understand what they find natural in order to weigh the options and
make a proper decision.

On the README file in the github page you will find a brief explanation
of the markup elements. I need to elaborate you that though because
I feel I explain it too fast.
https://github.com/jabolopes/fmark

Let me answer your questions about sections. The amount of indentation
is not fixed. You can use whatever you want. There is also no nesting limit
in Fmark, however, there is a nesting limit in the Latex backend. For now,
quotations, block quotes, source code embedding, etc, are not implemented.
Those will be added in the future.

About embedding a Fmark document in another document. That seems to
be a very cool feature. I will definitely think about it! Maybe you can come
up with a natural way of doing it?

Cheers,
José


On 18-09-2012 06:19, Richard O'Keefe wrote:

On 18/09/2012, at 3:57 PM, José Lopes wrote:

The problem with Fmark is also its greatest feature. While other markup 
languages
introduce special syntactic characters to give meaning to the document's 
elements,
I would like to take a different approach: I want to use characters that people 
already
use in document writing to achieve the same result. For example, in Mediawiki a
heading is some text surrounded by equal signs. But in Fmark a heading is 
simply some
text that does not end in a punctuation character, such as period or an 
exclamation mark.
I argue that this is a more natural approach.

The problem with that is that some people DO end some headings with
a full stop; for them your special syntax is not natural.

I want to find a natural way of not burdening the user with the task of having 
to learn
some special syntax in order to write a document.

You haven't found it.  What you *have* is very special syntax expressed using
several methods, AND IT IS NOT DOCUMENTED.  I have read the examples, and I can
find nothing explaining what the syntax is.

For example, I find indenting subsections rather unnatural and error-prone.
(For example, moving a paragraph from a deep location to a shallow one would
create a new subsection unintentionally.)
Is the amount of indentation fixed?  How many levels of subsections are
supported?  What if I want to use indentation to express quotation instead?
How do I embed source code?  How can you get an example of Fmark in an
Fmark document without having it acted on?  I could go on and on with
questions about syntax.




--
José António Branquinho de Oliveira Lopes
Instituto Superior Técnico
Technical University of Lisbon

___
Haskell-Cafe mailing list
Haskell-Cafe@haskell.org
http://www.haskell.org/mailman/listinfo/haskell-cafe


Re: [Haskell-cafe] [ANNOUNCE] Fmark markup language

2012-09-18 Thread Ivan Lazar Miljenovic
On 18 September 2012 21:53, José Lopes jose.lo...@ist.utl.pt wrote:
 Hello Ivan,

 I agree with your point: if you want a heading that ends with a punctuation
 sign then you cannot do it in Fmark (for now). That gives me something to
 think about. However, I will still look for a way that avoids (as much as
 possible) special syntax. Do you have any suggestion?

 I also agree with you on the natural conventions. I want to find a good
 tradeoff between syntax and expressiveness. In other words, I want to
 avoid as much those odd choices you mentioned. For example, I have
 been thinking seriously about emphasis and what would be a good way
 to do it. So far I could only come up with quotes (either  or '). What do
 you think?

I think that _emphasis_ is pretty natural, as is *bold* and possibly
-strikethrough-.

But you _are_ adding in some aspects of markup now.

Using quotes is bad because what happens if you're actually quoting someone? ;-)


 Cheers,
 José


 On 18-09-2012 06:05, Ivan Lazar Miljenovic wrote:

 On 18 September 2012 13:57, José Lopes jose.lo...@ist.utl.pt wrote:

 Hello Kris,

 Thank you for your email.

 At this moment, Fmark is not as powerful as Markdown, also because Fmark
 just started.
 Markdown offers things such as Blockquotes, Lists, Code blocks, links,
 emphasis, images, etc.
 Fmark does not offer as many features: for now, there are only
 paragraphs,
 headings,
 subsections (endless nesting) and footnotes. In the near future, I want
 to
 bolds/italics,
 ordered and unordered lists, links, and later on as many elements as
 possible :)

 The problem with Fmark is also its greatest feature. While other markup
 languages
 introduce special syntactic characters to give meaning to the document's
 elements,
 I would like to take a different approach: I want to use characters that
 people already
 use in document writing to achieve the same result. For example, in
 Mediawiki a
 heading is some text surrounded by equal signs. But in Fmark a heading is
 simply some
 text that does not end in a punctuation character, such as period or an
 exclamation mark.
 I argue that this is a more natural approach.

 Is it possible to override this?  What happens if I want a heading of
 This is the greatest Heading Ever! ?

 Natural conventions seem to be to be rather hacky and with lots of
 corner cases; I think it's better to define a specific syntax for
 markup (e.g. what is the natural way of emphasising text?) and stick
 to it (though I agree that Markdown has some odd choices; in
 particular, the ability to use both _ and * for italics whilst
 requiring ** for bold).

 I want to find a natural way of not burdening the user with the task of
 having to learn
 some special syntax in order to write a document. Instead I want to find
 natural ways
 of writing and use those ways to reconstruct the elements in a document.
 Of
 course,
 what is natural is subjective and that is why I want to find a good
 tradeoff
 between
 expressiveness and simplicity in the syntax. For example, in Fmark a
 footnote is some
 text surrounded by square brackets. Maybe you find this natural, maybe
 you
 don't. If a
 handful of people defend a more natural way of writing footnotes I want
 to
 implement
 the way they say. If there is a more natural way of doing this I want to
 find it. But for now
 I think square brackets are better than the equal signs or any other
 strange
 syntactic
 character such as exclamation marks and so on...

 Another thing about Fmark is styles. I want to use fmark personally to
 write
 papers, using
 Latex as backend. While experimenting with previous versions of Fmark I
 realized that I
 could not specify the title, the author, the date, and the abstract.
 which
 are essential in a
 paper. I came up with an idea which I think is quite interesting. I wrote
 another document
 also using Fmark which only had the words Title, Author, Date, and
 Abstract. And
 then I combined these two documents together, such that, Fmark associated
 title, author,
 date and abstract, with the corresponding content. I thought the idea was
 interesting
 because the content and style documents have both the same structure and
 are
 both
 written in Fmark. Of course, there is still a long way to go, in order to
 be
 able to fully
 customize a document.

 But styles are a good and simple approach, similar to document classes in
 Latex: the idea is
 to write one document (content) and then use multiple (predefined, user
 defined) styles, such
 as, article, report, etc, to stylize your document. Another interesting
 thing I have been thinking
 about (but not implemented yet) is recursion in document styling. In a
 way,
 weaving a style
 with content can be compared to matching a regular expression.

 Anyway, these are just some key ideas. I see Fmark as a work in progress
 and
 in a way as a
 research project, trying to find a natural way of writing documents while
 escaping as much
 as possible from the syntax of a 

Re: [Haskell-cafe] [ANNOUNCE] Fmark markup language

2012-09-18 Thread José Lopes

Hi,

Like I said it's a tradeoff. I will try to use this philosophy as much as
possible. But it's also important not to be fundamentalist. We'll see
as it goes.

I like that strikethrough. You are right about the quotes, but we can
leave  for quoting and use the ' for something else.

Cheers,
José

On 18-09-2012 13:18, Ivan Lazar Miljenovic wrote:

On 18 September 2012 21:53, José Lopes jose.lo...@ist.utl.pt wrote:

Hello Ivan,

I agree with your point: if you want a heading that ends with a punctuation
sign then you cannot do it in Fmark (for now). That gives me something to
think about. However, I will still look for a way that avoids (as much as
possible) special syntax. Do you have any suggestion?

I also agree with you on the natural conventions. I want to find a good
tradeoff between syntax and expressiveness. In other words, I want to
avoid as much those odd choices you mentioned. For example, I have
been thinking seriously about emphasis and what would be a good way
to do it. So far I could only come up with quotes (either  or '). What do
you think?

I think that _emphasis_ is pretty natural, as is *bold* and possibly
-strikethrough-.

But you _are_ adding in some aspects of markup now.

Using quotes is bad because what happens if you're actually quoting someone? ;-)


Cheers,
José


On 18-09-2012 06:05, Ivan Lazar Miljenovic wrote:

On 18 September 2012 13:57, José Lopes jose.lo...@ist.utl.pt wrote:

Hello Kris,

Thank you for your email.

At this moment, Fmark is not as powerful as Markdown, also because Fmark
just started.
Markdown offers things such as Blockquotes, Lists, Code blocks, links,
emphasis, images, etc.
Fmark does not offer as many features: for now, there are only
paragraphs,
headings,
subsections (endless nesting) and footnotes. In the near future, I want
to
bolds/italics,
ordered and unordered lists, links, and later on as many elements as
possible :)

The problem with Fmark is also its greatest feature. While other markup
languages
introduce special syntactic characters to give meaning to the document's
elements,
I would like to take a different approach: I want to use characters that
people already
use in document writing to achieve the same result. For example, in
Mediawiki a
heading is some text surrounded by equal signs. But in Fmark a heading is
simply some
text that does not end in a punctuation character, such as period or an
exclamation mark.
I argue that this is a more natural approach.

Is it possible to override this?  What happens if I want a heading of
This is the greatest Heading Ever! ?

Natural conventions seem to be to be rather hacky and with lots of
corner cases; I think it's better to define a specific syntax for
markup (e.g. what is the natural way of emphasising text?) and stick
to it (though I agree that Markdown has some odd choices; in
particular, the ability to use both _ and * for italics whilst
requiring ** for bold).


I want to find a natural way of not burdening the user with the task of
having to learn
some special syntax in order to write a document. Instead I want to find
natural ways
of writing and use those ways to reconstruct the elements in a document.
Of
course,
what is natural is subjective and that is why I want to find a good
tradeoff
between
expressiveness and simplicity in the syntax. For example, in Fmark a
footnote is some
text surrounded by square brackets. Maybe you find this natural, maybe
you
don't. If a
handful of people defend a more natural way of writing footnotes I want
to
implement
the way they say. If there is a more natural way of doing this I want to
find it. But for now
I think square brackets are better than the equal signs or any other
strange
syntactic
character such as exclamation marks and so on...

Another thing about Fmark is styles. I want to use fmark personally to
write
papers, using
Latex as backend. While experimenting with previous versions of Fmark I
realized that I
could not specify the title, the author, the date, and the abstract.
which
are essential in a
paper. I came up with an idea which I think is quite interesting. I wrote
another document
also using Fmark which only had the words Title, Author, Date, and
Abstract. And
then I combined these two documents together, such that, Fmark associated
title, author,
date and abstract, with the corresponding content. I thought the idea was
interesting
because the content and style documents have both the same structure and
are
both
written in Fmark. Of course, there is still a long way to go, in order to
be
able to fully
customize a document.

But styles are a good and simple approach, similar to document classes in
Latex: the idea is
to write one document (content) and then use multiple (predefined, user
defined) styles, such
as, article, report, etc, to stylize your document. Another interesting
thing I have been thinking
about (but not implemented yet) is recursion in document styling. In a
way,
weaving a style
with content can be compared to matching 

Re: [Haskell-cafe] [ANNOUNCE] Fmark markup language

2012-09-18 Thread Stefan Monnier
 The problem with that is that some people DO end some headings with
 a full stop; for them your special syntax is not natural.

Markdown/ReST is already using the no syntax idea (e.g. compared to
pre-wiki markup such a LaTeX or Texinfo), so he's simply trying to push
this idea further.

I suspect it'll be difficult.

 What if I want to use indentation to express quotation instead?

I think this one is solvable: a paragraph that's more indented than the
previous heading can be considered a quote.


Stefan


___
Haskell-Cafe mailing list
Haskell-Cafe@haskell.org
http://www.haskell.org/mailman/listinfo/haskell-cafe


Re: [Haskell-cafe] [ANNOUNCE] Fmark markup language

2012-09-18 Thread José Lopes

Hello Stefan,

Thank you for the input.

Cheers,
José

On 18-09-2012 14:43, Stefan Monnier wrote:

The problem with that is that some people DO end some headings with
a full stop; for them your special syntax is not natural.

Markdown/ReST is already using the no syntax idea (e.g. compared to
pre-wiki markup such a LaTeX or Texinfo), so he's simply trying to push
this idea further.

I suspect it'll be difficult.


What if I want to use indentation to express quotation instead?

I think this one is solvable: a paragraph that's more indented than the
previous heading can be considered a quote.


 Stefan


___
Haskell-Cafe mailing list
Haskell-Cafe@haskell.org
http://www.haskell.org/mailman/listinfo/haskell-cafe


--
José António Branquinho de Oliveira Lopes
Instituto Superior Técnico
Technical University of Lisbon


___
Haskell-Cafe mailing list
Haskell-Cafe@haskell.org
http://www.haskell.org/mailman/listinfo/haskell-cafe


Re: [Haskell-cafe] [ANNOUNCE] Fmark markup language

2012-09-18 Thread Brandon Allbery
On Tue, Sep 18, 2012 at 1:05 AM, Ivan Lazar Miljenovic 
ivan.miljeno...@gmail.com wrote:

 to it (though I agree that Markdown has some odd choices; in
 particular, the ability to use both _ and * for italics whilst
 requiring ** for bold).


The odd thing is, I've found that I use those constructs naturally (i.e.
when simply writing text in a text-only medium) in pretty much exactly the
way Markdown uses them.  _italics_ and *italics* are semantically different
(I tend to use the former for titles and such) but are both usually italics
in my normal usage.  (There's also /italics/ but that is not very
widespread.)  I do tend to use # instead of = for headings but that's kinda
stolen (and mutated) from a different variety of non-natural markup.

I suspect that when the dust has settled, it'll turn out that Markdown is
pretty much right.  Maybe with some tweaking, but largely it represents
(and IIRC was derived from) actual in-the-wild textual usage.

-- 
brandon s allbery  allber...@gmail.com
wandering unix systems administrator (available) (412) 475-9364 vm/sms
___
Haskell-Cafe mailing list
Haskell-Cafe@haskell.org
http://www.haskell.org/mailman/listinfo/haskell-cafe


Re: [Haskell-cafe] [ANNOUNCE] Fmark markup language

2012-09-18 Thread José Lopes

Hey,

Why do you say that _italics_ and *italics* are semantically different?
What do you mean?

Cheers,
José

On 18-09-2012 15:30, Brandon Allbery wrote:
On Tue, Sep 18, 2012 at 1:05 AM, Ivan Lazar Miljenovic 
ivan.miljeno...@gmail.com mailto:ivan.miljeno...@gmail.com wrote:


to it (though I agree that Markdown has some odd choices; in
particular, the ability to use both _ and * for italics whilst
requiring ** for bold).


The odd thing is, I've found that I use those constructs naturally 
(i.e. when simply writing text in a text-only medium) in pretty much 
exactly the way Markdown uses them.  _italics_ and *italics* are 
semantically different (I tend to use the former for titles and such) 
but are both usually italics in my normal usage.  (There's also 
/italics/ but that is not very widespread.)  I do tend to use # 
instead of = for headings but that's kinda stolen (and mutated) from a 
different variety of non-natural markup.


I suspect that when the dust has settled, it'll turn out that Markdown 
is pretty much right.  Maybe with some tweaking, but largely it 
represents (and IIRC was derived from) actual in-the-wild textual usage.


--
brandon s allbery allber...@gmail.com mailto:allber...@gmail.com
wandering unix systems administrator (available) (412) 475-9364 vm/sms



--
José António Branquinho de Oliveira Lopes
Instituto Superior Técnico
Technical University of Lisbon

___
Haskell-Cafe mailing list
Haskell-Cafe@haskell.org
http://www.haskell.org/mailman/listinfo/haskell-cafe


Re: [Haskell-cafe] [ANNOUNCE] Fmark markup language

2012-09-18 Thread Brandon Allbery
On Tue, Sep 18, 2012 at 10:34 AM, José Lopes jose.lo...@ist.utl.pt wrote:

 Why do you say that _italics_ and *italics* are semantically different?
 What do you mean?


The parenthetical hinted at it:

(I tend to use the former for titles and such)

 There's a convention at work here, namely that italicized book titles and
similar are often underlined in plain text — and in plain text without
backspaces this is represented as leading and trailing _.  So there's a
semantic (i.e. content) difference even though the generated markup is the
same.

-- 
brandon s allbery  allber...@gmail.com
wandering unix systems administrator (available) (412) 475-9364 vm/sms
___
Haskell-Cafe mailing list
Haskell-Cafe@haskell.org
http://www.haskell.org/mailman/listinfo/haskell-cafe


Re: [Haskell-cafe] [ANNOUNCE] Fmark markup language

2012-09-18 Thread Tillmann Rendel

Hi,

José Lopes wrote in an earlier email:

I want to find a natural way of not burdening the user with the task of having 
to learn
some special syntax in order to write a document.


And then:

[...] we can leave  for quoting and use the ' for something else.


That sounds like 'some special syntax' to me. Or should it be some 
special syntax? I can't remember which was for quoting and which was 
for something else. Maybe I need to look that up in the Fmark 
documentation, again.


  Tillmann

___
Haskell-Cafe mailing list
Haskell-Cafe@haskell.org
http://www.haskell.org/mailman/listinfo/haskell-cafe


Re: [Haskell-cafe] [ANNOUNCE] Fmark markup language

2012-09-18 Thread José Lopes

Hey Tillmann,

That is a good point. What would you suggest for emphasis ?

Cheers,
José

On 18-09-2012 21:00, Tillmann Rendel wrote:

Hi,

José Lopes wrote in an earlier email:
I want to find a natural way of not burdening the user with the task 
of having to learn

some special syntax in order to write a document.


And then:

[...] we can leave  for quoting and use the ' for something else.


That sounds like 'some special syntax' to me. Or should it be some 
special syntax? I can't remember which was for quoting and which was 
for something else. Maybe I need to look that up in the Fmark 
documentation, again.


  Tillmann


--
José António Branquinho de Oliveira Lopes
Instituto Superior Técnico
Technical University of Lisbon


___
Haskell-Cafe mailing list
Haskell-Cafe@haskell.org
http://www.haskell.org/mailman/listinfo/haskell-cafe


Re: [Haskell-cafe] [ANNOUNCE] Fmark markup language

2012-09-18 Thread Richard O'Keefe

On 19/09/2012, at 12:04 AM, José Lopes wrote:

 Hello Richard,
 
 When you say (for) some people (...) you special syntax is not natural
 that's a good thing. I want these people involved in the project. I want
 to understand what they find natural in order to weigh the options and
 make a proper decision.

One important question is how many *scripts* you want to support.
Do you, for example, want to support Greek?  There is a Unicode
character for Greek question mark U+037E, some documentation I've
seen says that the preferred character is U+003F.  So does ;
terminate a sentence or not?
How many *languages* do you want to support?
Are you going to support Armenian, where the question mark that
ends a sentence goes not _after the last letter_ of the last
word but _over the last vowel_?

(As someone who only writes in English, I have no trouble with the
answer only the Latin script, only the English language.)

I don't actually believe that there _is_ a natural convention for
italics, boldface, superscripts, etc.  Even _this_ is an artificial
convention going back to mechanical typewriters that could underline
but not change font.
 
 On the README file in the github page you will find a brief explanation
 of the markup elements. I need to elaborate you that though because
 I feel I explain it too fast.
 https://github.com/jabolopes/fmark

I did read the README.md.  I disagree that there exists any problem
of manual removal of special characters.  If I want to remove XML markup,
I just do unxml foobar.xml foobar.txt.  If I want to convert from one
kind of markup to another, there is pandoc, which is admittedly a touch
buggy, ...

The problem is that the README.md does not in fact explain what any
of the 'markup elements' are.

Let's take one little example, a letter of the kind I used to write
by hand.

123 Copper Road,
   Gemstone,
  Dunedin,
 New Zealand .
31 February 2016.

Dear Schnorer,
   I am writing to you because I am tired of frobulating.

Yours without wax,
   Dr Strabismus of Utrecht
  (whom God preserve!)

How do I tell Fmark about this structure?
How do I get this layout?  (The '1' and 'Y' should be in the centre.)

 Let me answer your questions about sections. The amount of indentation
 is not fixed. You can use whatever you want. There is also no nesting limit
 in Fmark, however, there is a nesting limit in the Latex backend. For now,
 quotations, block quotes, source code embedding, etc, are not implemented.
 Those will be added in the future.

These answers belong in the README.me.
 
 About embedding a Fmark document in another document. That seems to
 be a very cool feature. I will definitely think about it! Maybe you can come
 up with a natural way of doing it?

The last time I thought I had a natural way to do anything like that
I found that the SGML design was worse broken than I would have believed 
possible.

___
Haskell-Cafe mailing list
Haskell-Cafe@haskell.org
http://www.haskell.org/mailman/listinfo/haskell-cafe


Re: [Haskell-cafe] [ANNOUNCE] Fmark markup language

2012-09-18 Thread Richard O'Keefe

On 19/09/2012, at 1:43 AM, Stefan Monnier wrote:

 The problem with that is that some people DO end some headings with
 a full stop; for them your special syntax is not natural.
 
 Markdown/ReST is already using the no syntax idea (e.g. compared to
 pre-wiki markup such a LaTeX or Texinfo), so he's simply trying to push
 this idea further.

Markdown is very heavy on syntax,
what it is *light* on is specification of what the
syntax actually is.  As a result,
I'm aware of three different dialects,
and someone told me about having to reverse
engineer the syntax from a Perl implementation.
As a further result, I cannot write a program to
reliably *generate* Markdown.
 
 I suspect it'll be difficult.

Oh, more power to him for trying.
I just don't think it can be pushed very far.

Oh, there is a really *filthy* hack that could be pulled
for italics, bold face, and so on.  Contrary to its original
principles, Unicode includes several copies of ASCII
(see http://unicode.org/charts/PDF/U1D400.pdf):
Mathematical bold,
Mathematical italic,
Mathematical bold italic,
Mathematical script,
Mathematical bold script,
Mathematical fraktur,
Mathematical double struck (blackboard-bold),
Mathematical bold fraktur,
Mathematical sans-serif,
Mathematical sans-serif bold,
Mathematical sans-serif italic,
Mathematical sans-serif bold italic,
Mathematical monospace,
and some similar sets of Greek.
So as long as you don't want strike-through or underlying,
and as long as you don't want italic Cyrillic c, ...
Too bad if you want a bold italic capital Thorn...

 
 What if I want to use indentation to express quotation instead?
 
 I think this one is solvable: a paragraph that's more indented than the
 previous heading can be considered a quote.

Ah, but the quotation might not end with a sentence terminator,
so that would be considered a new heading.


___
Haskell-Cafe mailing list
Haskell-Cafe@haskell.org
http://www.haskell.org/mailman/listinfo/haskell-cafe


Re: [Haskell-cafe] [ANNOUNCE] Fmark markup language

2012-09-18 Thread José Lopes

Hey Richard,

Regarding the languages, I think it is better to start with English
and see how successful Fmark is. There's no point in trying to tackle
lots of languages if we cannot solve the problem for one of them.
But then again, keeping everything Unicode.

In fact, in this matter, I think with Haskell we have an advantage
because things like 'isSpace' and 'isPuncuation' work with Unicode.

I now understand that the README.md is rather incomplete. I will
add some more information about the markup. Although, things
like bold, italics and so on are not implemented yet.

I will also take a look at your letter example. I think the real
challenge here is center alignment. I will think about a
way to solve it in Fmark so we can discuss it later on.

Thank you for the feedback.

Cheers,
José

On 19-09-2012 00:37, Richard O'Keefe wrote:

On 19/09/2012, at 1:43 AM, Stefan Monnier wrote:


The problem with that is that some people DO end some headings with
a full stop; for them your special syntax is not natural.

Markdown/ReST is already using the no syntax idea (e.g. compared to
pre-wiki markup such a LaTeX or Texinfo), so he's simply trying to push
this idea further.

Markdown is very heavy on syntax,
what it is *light* on is specification of what the
syntax actually is.  As a result,
I'm aware of three different dialects,
and someone told me about having to reverse
engineer the syntax from a Perl implementation.
As a further result, I cannot write a program to
reliably *generate* Markdown.

I suspect it'll be difficult.

Oh, more power to him for trying.
I just don't think it can be pushed very far.

Oh, there is a really *filthy* hack that could be pulled
for italics, bold face, and so on.  Contrary to its original
principles, Unicode includes several copies of ASCII
(see http://unicode.org/charts/PDF/U1D400.pdf):
Mathematical bold,
Mathematical italic,
Mathematical bold italic,
Mathematical script,
Mathematical bold script,
Mathematical fraktur,
Mathematical double struck (blackboard-bold),
Mathematical bold fraktur,
Mathematical sans-serif,
Mathematical sans-serif bold,
Mathematical sans-serif italic,
Mathematical sans-serif bold italic,
Mathematical monospace,
and some similar sets of Greek.
So as long as you don't want strike-through or underlying,
and as long as you don't want italic Cyrillic c, ...
Too bad if you want a bold italic capital Thorn...


What if I want to use indentation to express quotation instead?

I think this one is solvable: a paragraph that's more indented than the
previous heading can be considered a quote.

Ah, but the quotation might not end with a sentence terminator,
so that would be considered a new heading.


___
Haskell-Cafe mailing list
Haskell-Cafe@haskell.org
http://www.haskell.org/mailman/listinfo/haskell-cafe


--
José António Branquinho de Oliveira Lopes
Instituto Superior Técnico
Technical University of Lisbon


___
Haskell-Cafe mailing list
Haskell-Cafe@haskell.org
http://www.haskell.org/mailman/listinfo/haskell-cafe


Re: [Haskell-cafe] [ANNOUNCE] Fmark markup language

2012-09-18 Thread José Lopes

Hello Richard,

I made a first draft of your letter example.
It is not exactly as you had written but I think you might like it.
It is the combination of a content document (letter) and a style
document (letter.style). You can see the results in the PDF, which
was created using the Latex backend and the letter document
class.

Cheers,
José

On 19-09-2012 01:21, José Lopes wrote:

Hey Richard,

Regarding the languages, I think it is better to start with English
and see how successful Fmark is. There's no point in trying to tackle
lots of languages if we cannot solve the problem for one of them.
But then again, keeping everything Unicode.

In fact, in this matter, I think with Haskell we have an advantage
because things like 'isSpace' and 'isPuncuation' work with Unicode.

I now understand that the README.md is rather incomplete. I will
add some more information about the markup. Although, things
like bold, italics and so on are not implemented yet.

I will also take a look at your letter example. I think the real
challenge here is center alignment. I will think about a
way to solve it in Fmark so we can discuss it later on.

Thank you for the feedback.

Cheers,
José

On 19-09-2012 00:37, Richard O'Keefe wrote:

On 19/09/2012, at 1:43 AM, Stefan Monnier wrote:


The problem with that is that some people DO end some headings with
a full stop; for them your special syntax is not natural.

Markdown/ReST is already using the no syntax idea (e.g. compared to
pre-wiki markup such a LaTeX or Texinfo), so he's simply trying to push
this idea further.

Markdown is very heavy on syntax,
what it is *light* on is specification of what the
syntax actually is.  As a result,
I'm aware of three different dialects,
and someone told me about having to reverse
engineer the syntax from a Perl implementation.
As a further result, I cannot write a program to
reliably *generate* Markdown.

I suspect it'll be difficult.

Oh, more power to him for trying.
I just don't think it can be pushed very far.

Oh, there is a really *filthy* hack that could be pulled
for italics, bold face, and so on.  Contrary to its original
principles, Unicode includes several copies of ASCII
(see http://unicode.org/charts/PDF/U1D400.pdf):
Mathematical bold,
Mathematical italic,
Mathematical bold italic,
Mathematical script,
Mathematical bold script,
Mathematical fraktur,
Mathematical double struck (blackboard-bold),
Mathematical bold fraktur,
Mathematical sans-serif,
Mathematical sans-serif bold,
Mathematical sans-serif italic,
Mathematical sans-serif bold italic,
Mathematical monospace,
and some similar sets of Greek.
So as long as you don't want strike-through or underlying,
and as long as you don't want italic Cyrillic c, ...
Too bad if you want a bold italic capital Thorn...


What if I want to use indentation to express quotation instead?

I think this one is solvable: a paragraph that's more indented than the
previous heading can be considered a quote.

Ah, but the quotation might not end with a sentence terminator,
so that would be considered a new heading.


___
Haskell-Cafe mailing list
Haskell-Cafe@haskell.org
http://www.haskell.org/mailman/listinfo/haskell-cafe




--
José António Branquinho de Oliveira Lopes
Instituto Superior Técnico
Technical University of Lisbon

123 Copper Road,
Gemstone,
Dunedin,
New Zealand 

31 February 2016

Dear Schnorer,
   I am writing to you because I am tired of frobulating.
   I am also tired of this and that.

Yours without wax,

Dr Strabismus of Utrecht
(whom God preserve!)


letter.pdf
Description: Adobe PDF document
Address

Date

Opening,
  Letter.

Closing,

Signature___
Haskell-Cafe mailing list
Haskell-Cafe@haskell.org
http://www.haskell.org/mailman/listinfo/haskell-cafe


[Haskell-cafe] [ANNOUNCE] Fmark markup language

2012-09-17 Thread José Lopes

Hello everyone,

I just wanted to share a package I created called Fmark, now available
on HackageDB.

Feedback both on the project and on the code is greatly appreciated :)

Fmark (Friendly Markup) is a very simple markup language without
syntax and simple but sophisticated document styling, capable of
producing PDF and XML files.

The key philosophy behind this markup language is to eliminate the
strange syntactic characters seen in most markup languages, but
at the same time try to maintain a high level of expressiveness, using
only document reconstruction.

Check it out
http://hackage.haskell.org/package/fmark
https://github.com/jabolopes/fmark

Best regards,
José

--
José António Branquinho de Oliveira Lopes
58612 - MEIC-A
Instituto Superior Técnico (IST), Universidade Técnica de Lisboa (UTL)
jose.lo...@ist.utl.pt


___
Haskell-Cafe mailing list
Haskell-Cafe@haskell.org
http://www.haskell.org/mailman/listinfo/haskell-cafe


Re: [Haskell-cafe] [ANNOUNCE] Fmark markup language

2012-09-17 Thread Kristopher Micinski
Jose,

So I'm interested to hear you opinion on this as well...

I use Pandoc with Markdown through Hakyll, which allows you to do a
fair amount of cute things that are just really helpful for
maintaining a blog (for example..).  But I didn't get this from
reading your github readme: what makes your markup language special?
Could you give an example of how the language is more expressive than
(say) markdown processed through Pandoc (I only mention because it
lets you process LaTeX, very helpful, right...) or something
comparable?

kris

On Mon, Sep 17, 2012 at 11:09 PM, José Lopes jose.lo...@ist.utl.pt wrote:
 Hello everyone,

 I just wanted to share a package I created called Fmark, now available
 on HackageDB.

 Feedback both on the project and on the code is greatly appreciated :)

 Fmark (Friendly Markup) is a very simple markup language without
 syntax and simple but sophisticated document styling, capable of
 producing PDF and XML files.

 The key philosophy behind this markup language is to eliminate the
 strange syntactic characters seen in most markup languages, but
 at the same time try to maintain a high level of expressiveness, using
 only document reconstruction.

 Check it out
 http://hackage.haskell.org/package/fmark
 https://github.com/jabolopes/fmark

 Best regards,
 José

 --
 José António Branquinho de Oliveira Lopes
 58612 - MEIC-A
 Instituto Superior Técnico (IST), Universidade Técnica de Lisboa (UTL)
 jose.lo...@ist.utl.pt


 ___
 Haskell-Cafe mailing list
 Haskell-Cafe@haskell.org
 http://www.haskell.org/mailman/listinfo/haskell-cafe

___
Haskell-Cafe mailing list
Haskell-Cafe@haskell.org
http://www.haskell.org/mailman/listinfo/haskell-cafe


Re: [Haskell-cafe] [ANNOUNCE] Fmark markup language

2012-09-17 Thread José Lopes

Hello Kris,

Thank you for your email.

At this moment, Fmark is not as powerful as Markdown, also because Fmark 
just started.
Markdown offers things such as Blockquotes, Lists, Code blocks, links, 
emphasis, images, etc.
Fmark does not offer as many features: for now, there are only 
paragraphs, headings,
subsections (endless nesting) and footnotes. In the near future, I want 
to bolds/italics,
ordered and unordered lists, links, and later on as many elements as 
possible :)


The problem with Fmark is also its greatest feature. While other markup 
languages
introduce special syntactic characters to give meaning to the document's 
elements,
I would like to take a different approach: I want to use characters that 
people already
use in document writing to achieve the same result. For example, in 
Mediawiki a
heading is some text surrounded by equal signs. But in Fmark a heading 
is simply some
text that does not end in a punctuation character, such as period or an 
exclamation mark.

I argue that this is a more natural approach.

I want to find a natural way of not burdening the user with the task of 
having to learn
some special syntax in order to write a document. Instead I want to find 
natural ways
of writing and use those ways to reconstruct the elements in a document. 
Of course,
what is natural is subjective and that is why I want to find a good 
tradeoff between
expressiveness and simplicity in the syntax. For example, in Fmark a 
footnote is some
text surrounded by square brackets. Maybe you find this natural, maybe 
you don't. If a
handful of people defend a more natural way of writing footnotes I want 
to implement
the way they say. If there is a more natural way of doing this I want to 
find it. But for now
I think square brackets are better than the equal signs or any other 
strange syntactic

character such as exclamation marks and so on...

Another thing about Fmark is styles. I want to use fmark personally to 
write papers, using
Latex as backend. While experimenting with previous versions of Fmark I 
realized that I
could not specify the title, the author, the date, and the abstract. 
which are essential in a
paper. I came up with an idea which I think is quite interesting. I 
wrote another document
also using Fmark which only had the words Title, Author, Date, and 
Abstract. And
then I combined these two documents together, such that, Fmark 
associated title, author,
date and abstract, with the corresponding content. I thought the idea 
was interesting
because the content and style documents have both the same structure and 
are both
written in Fmark. Of course, there is still a long way to go, in order 
to be able to fully

customize a document.

But styles are a good and simple approach, similar to document classes 
in Latex: the idea is
to write one document (content) and then use multiple (predefined, user 
defined) styles, such
as, article, report, etc, to stylize your document. Another interesting 
thing I have been thinking
about (but not implemented yet) is recursion in document styling. In a 
way, weaving a style

with content can be compared to matching a regular expression.

Anyway, these are just some key ideas. I see Fmark as a work in progress 
and in a way as a
research project, trying to find a natural way of writing documents 
while escaping as much
as possible from the syntax of a programming language. I also have a 
metagoal with this
project: if my father (the non programming guy) could use it to write 
his PhD dissertation,

I would be quite happy :)

If you have any more questions I would be happy to answer.
But if you're interested in using markup languages for blogs perhaps a 
HTML backend
in Fmark would be more interesting for you. Although, XML + JavaScript + 
CSS is also possible.


Best regards,
José

On 18-09-2012 04:25, Kristopher Micinski wrote:

Jose,

So I'm interested to hear you opinion on this as well...

I use Pandoc with Markdown through Hakyll, which allows you to do a
fair amount of cute things that are just really helpful for
maintaining a blog (for example..).  But I didn't get this from
reading your github readme: what makes your markup language special?
Could you give an example of how the language is more expressive than
(say) markdown processed through Pandoc (I only mention because it
lets you process LaTeX, very helpful, right...) or something
comparable?

kris

On Mon, Sep 17, 2012 at 11:09 PM, José Lopes jose.lo...@ist.utl.pt wrote:

Hello everyone,

I just wanted to share a package I created called Fmark, now available
on HackageDB.

Feedback both on the project and on the code is greatly appreciated :)

Fmark (Friendly Markup) is a very simple markup language without
syntax and simple but sophisticated document styling, capable of
producing PDF and XML files.

The key philosophy behind this markup language is to eliminate the
strange syntactic characters seen in most markup languages, but
at the same time try to maintain a high level 

Re: [Haskell-cafe] [ANNOUNCE] Fmark markup language

2012-09-17 Thread Richard O'Keefe

On 18/09/2012, at 3:09 PM, José Lopes wrote:
 Fmark (Friendly Markup) is a very simple markup language without
 syntax and simple but sophisticated document styling, capable of
 producing PDF and XML files.

Do you _really_ mean without syntax?

Nope, thought not:

Fmark relies merely on spacing, indentation,
and common punctuation (e.g., periods, exclamation
and interrogation marks) to reconstruct the structure
of your document.

That's SYNTAX.

A markup language without syntax is like a meal without food.


___
Haskell-Cafe mailing list
Haskell-Cafe@haskell.org
http://www.haskell.org/mailman/listinfo/haskell-cafe


Re: [Haskell-cafe] [ANNOUNCE] Fmark markup language

2012-09-17 Thread Ivan Lazar Miljenovic
On 18 September 2012 13:57, José Lopes jose.lo...@ist.utl.pt wrote:
 Hello Kris,

 Thank you for your email.

 At this moment, Fmark is not as powerful as Markdown, also because Fmark
 just started.
 Markdown offers things such as Blockquotes, Lists, Code blocks, links,
 emphasis, images, etc.
 Fmark does not offer as many features: for now, there are only paragraphs,
 headings,
 subsections (endless nesting) and footnotes. In the near future, I want to
 bolds/italics,
 ordered and unordered lists, links, and later on as many elements as
 possible :)

 The problem with Fmark is also its greatest feature. While other markup
 languages
 introduce special syntactic characters to give meaning to the document's
 elements,
 I would like to take a different approach: I want to use characters that
 people already
 use in document writing to achieve the same result. For example, in
 Mediawiki a
 heading is some text surrounded by equal signs. But in Fmark a heading is
 simply some
 text that does not end in a punctuation character, such as period or an
 exclamation mark.
 I argue that this is a more natural approach.

Is it possible to override this?  What happens if I want a heading of
This is the greatest Heading Ever! ?

Natural conventions seem to be to be rather hacky and with lots of
corner cases; I think it's better to define a specific syntax for
markup (e.g. what is the natural way of emphasising text?) and stick
to it (though I agree that Markdown has some odd choices; in
particular, the ability to use both _ and * for italics whilst
requiring ** for bold).


 I want to find a natural way of not burdening the user with the task of
 having to learn
 some special syntax in order to write a document. Instead I want to find
 natural ways
 of writing and use those ways to reconstruct the elements in a document. Of
 course,
 what is natural is subjective and that is why I want to find a good tradeoff
 between
 expressiveness and simplicity in the syntax. For example, in Fmark a
 footnote is some
 text surrounded by square brackets. Maybe you find this natural, maybe you
 don't. If a
 handful of people defend a more natural way of writing footnotes I want to
 implement
 the way they say. If there is a more natural way of doing this I want to
 find it. But for now
 I think square brackets are better than the equal signs or any other strange
 syntactic
 character such as exclamation marks and so on...

 Another thing about Fmark is styles. I want to use fmark personally to write
 papers, using
 Latex as backend. While experimenting with previous versions of Fmark I
 realized that I
 could not specify the title, the author, the date, and the abstract. which
 are essential in a
 paper. I came up with an idea which I think is quite interesting. I wrote
 another document
 also using Fmark which only had the words Title, Author, Date, and
 Abstract. And
 then I combined these two documents together, such that, Fmark associated
 title, author,
 date and abstract, with the corresponding content. I thought the idea was
 interesting
 because the content and style documents have both the same structure and are
 both
 written in Fmark. Of course, there is still a long way to go, in order to be
 able to fully
 customize a document.

 But styles are a good and simple approach, similar to document classes in
 Latex: the idea is
 to write one document (content) and then use multiple (predefined, user
 defined) styles, such
 as, article, report, etc, to stylize your document. Another interesting
 thing I have been thinking
 about (but not implemented yet) is recursion in document styling. In a way,
 weaving a style
 with content can be compared to matching a regular expression.

 Anyway, these are just some key ideas. I see Fmark as a work in progress and
 in a way as a
 research project, trying to find a natural way of writing documents while
 escaping as much
 as possible from the syntax of a programming language. I also have a
 metagoal with this
 project: if my father (the non programming guy) could use it to write his
 PhD dissertation,
 I would be quite happy :)

 If you have any more questions I would be happy to answer.
 But if you're interested in using markup languages for blogs perhaps a HTML
 backend
 in Fmark would be more interesting for you. Although, XML + JavaScript + CSS
 is also possible.

 Best regards,
 José


 On 18-09-2012 04:25, Kristopher Micinski wrote:

 Jose,

 So I'm interested to hear you opinion on this as well...

 I use Pandoc with Markdown through Hakyll, which allows you to do a
 fair amount of cute things that are just really helpful for
 maintaining a blog (for example..).  But I didn't get this from
 reading your github readme: what makes your markup language special?
 Could you give an example of how the language is more expressive than
 (say) markdown processed through Pandoc (I only mention because it
 lets you process LaTeX, very helpful, right...) or something
 comparable?

 kris

 

Re: [Haskell-cafe] [ANNOUNCE] Fmark markup language

2012-09-17 Thread Richard O'Keefe

On 18/09/2012, at 3:57 PM, José Lopes wrote:
 The problem with Fmark is also its greatest feature. While other markup 
 languages
 introduce special syntactic characters to give meaning to the document's 
 elements,
 I would like to take a different approach: I want to use characters that 
 people already
 use in document writing to achieve the same result. For example, in Mediawiki 
 a
 heading is some text surrounded by equal signs. But in Fmark a heading is 
 simply some
 text that does not end in a punctuation character, such as period or an 
 exclamation mark.
 I argue that this is a more natural approach.

The problem with that is that some people DO end some headings with
a full stop; for them your special syntax is not natural.
 
 I want to find a natural way of not burdening the user with the task of 
 having to learn
 some special syntax in order to write a document.

You haven't found it.  What you *have* is very special syntax expressed using
several methods, AND IT IS NOT DOCUMENTED.  I have read the examples, and I can
find nothing explaining what the syntax is.

For example, I find indenting subsections rather unnatural and error-prone.
(For example, moving a paragraph from a deep location to a shallow one would
create a new subsection unintentionally.)
Is the amount of indentation fixed?  How many levels of subsections are
supported?  What if I want to use indentation to express quotation instead?
How do I embed source code?  How can you get an example of Fmark in an
Fmark document without having it acted on?  I could go on and on with
questions about syntax.



___
Haskell-Cafe mailing list
Haskell-Cafe@haskell.org
http://www.haskell.org/mailman/listinfo/haskell-cafe