Re: [Pharo-users] Pillar in-image rendering as RichText

2019-10-21 Thread Kasper Østerbye
On 21 October 2019 at 21.44.49, Norbert Hartl (norb...@hartl.name) wrote:

I started to use Rubric as text editing component. With this I started to
add text attributes for wysiwyg editing. In a basic attempt I wrote a
converter from text attributes to pillar markup. The text with pillar
markup is stored in my model and the pillar to text reconstructs to
formatted text.
With spec we need to redo such a component. There is a text component. The
plan is to add a rich text component that can have styled text. Both things
together could be a good editor in wysiwyg fashion having pillar as
document model.
In your first post I thought I read you have the same plan. Maybe just
wishful thinking.

Got it.

When googling, it seems like the Cuis-StyledTextEditor (
https://github.com/Cuis-Smalltalk/StyledTextEditor) is the latest attempt,
but it is not Pharo.

As I understand it, it is the plan to get gtk and pharo to work together
somehow. Does gtk have a widget that allow for rich text wysiwyg? Its
underlying text model seems to be similar to smalltalk (attributes).

At the moment I am less interested in (developing) a wysiwyg editor. Also I
am not going to try and make a *full* pillar renderer (I am not a pillar
fan).

As Julien wrote, class comments (and perhaps even regular comments)
rendered in rich-text based on markup is my first goal.

I am still picking up Pharo and all it tooling, so it is slow progress atm.

Btw, in the comments for Rubric a project named TxText is mentioned. I
presume it is either integrated into the system and has lost its name, or
it stalled?

Best,

Kasper


Re: [Pharo-users] Pillar in-image rendering as RichText

2019-10-21 Thread tbrunz
Hi Norbert, Kasper,

I, for one, am /*very*/ interested in being able to edit Pillar documents in
a wysiwyg fashion.  And of course I then want to write out such a document
as a text file with Pillar markup, so that I can commit that document to a
Booklet repo, to be compiled into a PDF.

I was looking for a way to view a Pillar markup text file, as an aid to
composing/proofreading.  There is a plugin for Atom, but it appears to be so
old (and unmaintained) that it no longer renders correctly in the latest
versions of Atom.  So I have been making due with using Markdown preview,
but it's far from ideal.

You have something like this started?  Need help?  And if anyone else has a
suggestion..?

-Ted




--
Sent from: http://forum.world.st/Pharo-Smalltalk-Users-f1310670.html



Re: [Pharo-users] Pillar in-image rendering as RichText

2019-10-21 Thread Norbert Hartl


> Am 21.10.2019 um 19:20 schrieb Kasper Østerbye :
> 
> 
>> 
>> On 21 October 2019 at 18.53.24, Norbert Hartl (norb...@hartl.name) wrote:
>> Looking at the code it seems that there is just a pillar to text conversikn. 
> 
> Yes, I only go from pillar to Text (not just String).
> 
>> Do you have plans to go from text to pillar as well?
> 
> Your question confuses me :-)
> 
> What would be the source of an already formatted Text?
> Is there a “rich text editor”? I did not know there was one?
Well, I‘m in a constant fight with Esteban about it  I started to use Rubric 
as text editing component. With this I started to add text attributes for 
wysiwyg editing. In a basic attempt I wrote a converter from text attributes to 
pillar markup. The text with pillar markup is stored in my model and the pillar 
to text reconstructs to formatted text.
With spec we need to redo such a component. There is a text component. The plan 
is to add a rich text component that can have styled text. Both things together 
could be a good editor in wysiwyg fashion having pillar as document model. 
In your first post I thought I read you have the same plan. Maybe just wishful 
thinking.

Norbert

> Best,
> 
> Kasper


Re: [Pharo-users] Pillar in-image rendering as RichText

2019-10-21 Thread Kasper Østerbye
On 21 October 2019 at 18.53.24, Norbert Hartl (norb...@hartl.name) wrote:

Looking at the code it seems that there is just a pillar to text
conversikn.

Yes, I only go from pillar to Text (not just String).

Do you have plans to go from text to pillar as well?

Your question confuses me :-)

   - What would be the source of an already formatted Text?
   - Is there a “rich text editor”? I did not know there was one?

Best,

Kasper


Re: [Pharo-users] Pillar in-image rendering as RichText

2019-10-21 Thread Norbert Hartl
Looking at the code it seems that there is just a pillar to text conversikn. Do 
you have plans to go from text to pillar as well?

Norbert

> Am 21.10.2019 um 17:19 schrieb Kasper Østerbye :
> 
> 
> Cheers,
> 
> 
> Rendering the Pillar markup inside the Pharo image
> 
> This is work in (early) progress, but I think it is far enough for a 
> "technology preview".
> 
> Goal of the project
> 
> The goal of the project is to be able to do better in-image documentation. To 
> do this, I am working on several fronts:
> 
> Rendering more pillar, expecially I would like to get a solution for tables.
> Rendering github markdown in addition to pillar markdown. This will allow me 
> to pull markdown from git and display it in-image.
> Giving the "help-system" some love.
> In-image tools for writing markdown - a markdown editor
> A design for keeping the mark-down texts seamlessly outside of the image
> Reg. 1., I can only figure out how to transform a morphic table into an 
> image, and then add that image to the text (not included atm as I find it so 
> ugly a solution). Any other ideas are greatly appreciated.
> 
> Reg. 2. I am nearly done on this one, at least for the easy aspects (headers, 
> lists, emphasis, code-blocks).
> 
> Reg 3 and 4. Only loose ideas atm.
> 
> Trying it out
> 
> Load it using Metacello:
> 
> Metacello new
>baseline: 'PillarRichTextRender';
>repository: 'github://kasperosterbye/PillarRichTextRender';
>load.
> At the moment it will load the whole of Pillar, but I hope to fix that soon.
> 
> Once loaded, the class PRRichTextComposer has some examples on the class side.


Re: [Pharo-users] Pillar in-image rendering as RichText

2019-10-21 Thread Julien
Nice work Kasper!

I can’t wait to have a tab with rendered pillar when browsing class comment. :-)

Julien

---
Julien Delplanque
Doctorant à l’Université de Lille
http://juliendelplanque.be/phd.html
Equipe Rmod, Inria
Bâtiment B 40, Avenue Halley 59650 Villeneuve d'Ascq
Numéro de téléphone: +333 59 35 86 40

> Le 21 oct. 2019 à 16:10, Kasper Østerbye  a écrit :
> 
> Cheers,
> 
> 
> Rendering the Pillar markup inside the Pharo image
> 
> This is work in (early) progress, but I think it is far enough for a 
> "technology preview".
> 
>  
> Goal
>  of the project
> 
> The goal of the project is to be able to do better in-image documentation. To 
> do this, I am working on several fronts:
> 
> Rendering more pillar, expecially I would like to get a solution for tables.
> Rendering github markdown in addition to pillar markdown. This will allow me 
> to pull markdown from git and display it in-image.
> Giving the "help-system" some love.
> In-image tools for writing markdown - a markdown editor
> A design for keeping the mark-down texts seamlessly outside of the image
> Reg. 1., I can only figure out how to transform a morphic table into an 
> image, and then add that image to the text (not included atm as I find it so 
> ugly a solution). Any other ideas are greatly appreciated.
> 
> Reg. 2. I am nearly done on this one, at least for the easy aspects (headers, 
> lists, emphasis, code-blocks).
> 
> Reg 3 and 4. Only loose ideas atm.
> 
>  
> Trying
>  it out
> 
> Load it using Metacello:
> 
> Metacello new
>baseline: 'PillarRichTextRender';
>repository: 'github://kasperosterbye/PillarRichTextRender 
> ';
>load.
> At the moment it will load the whole of Pillar, but I hope to fix that soon.
> 
> Once loaded, the class PRRichTextComposer has some examples on the class side.



Re: [Pharo-users] Pillar in-image rendering (was: String concatenation vs. Stream)

2019-10-21 Thread Kasper Østerbye
On 21 October 2019 at 16.17.49, Guillermo Polito (guillermopol...@gmail.com)
wrote:

What if instead of putting tables into text you put text into tables ;).
In other words, think both text and tables as renderable elements (cof cof
morphs).
Then, since we can make a morph from a text, and a table morph, then both
can be combined.

Out of the table thinking :-)

So by putting a table on the outside, I can make the normal paragraphs
individual rows of one column?

To make an actual table, it would be some rows with more columns than one?

Do the tables morphs allow for merged  cells?

I will look into it, but I am not too optimistic that I will be able to get
anything that looks nice.

Best,

Kasper


Re: [Pharo-users] Pillar in-image rendering (was: String concatenation vs. Stream)

2019-10-21 Thread Guillermo Polito
On Sat, Oct 19, 2019 at 1:40 PM Kasper Østerbye 
wrote:

> My main *remaining issue is to do tables* somehow. Any hints on how to
> render tables inside a text?
>

Hi Kasper, some intuition from my part for this.
What if instead of putting tables into text you put text into tables ;).
In other words, think both text and tables as renderable elements (cof cof
morphs).
Then, since we can make a morph from a text, and a table morph, then both
can be combined.

Cheers,
Guille


[Pharo-users] Pillar in-image rendering as RichText

2019-10-21 Thread Kasper Østerbye
Cheers,


Rendering the Pillar markup inside the Pharo image

This is work in (early) progress, but I think it is far enough for a
"technology preview".
Goal
of the project

The goal of the project is to be able to do better in-image documentation.
To do this, I am working on several fronts:

   1. Rendering more pillar, expecially I would like to get a solution for
   tables.
   2. Rendering github markdown in addition to pillar markdown. This will
   allow me to pull markdown from git and display it in-image.
   3. Giving the "help-system" some love.
   4. In-image tools for writing markdown - a markdown editor
   5. A design for keeping the mark-down texts seamlessly outside of the
   image

Reg. 1., I can only figure out how to transform a morphic table into an
image, and then add that image to the text (not included atm as I find it
so ugly a solution). Any other ideas are greatly appreciated.

Reg. 2. I am nearly done on this one, at least for the easy aspects
(headers, lists, emphasis, code-blocks).

Reg 3 and 4. Only loose ideas atm.
Trying
it out

Load it using Metacello:

Metacello new
   baseline: 'PillarRichTextRender';
   repository: 'github://kasperosterbye/PillarRichTextRender';
   load.

At the moment it will load the whole of Pillar, but I hope to fix that soon.

Once loaded, the class PRRichTextComposer has some examples on the class
side.


Re: [Pharo-users] Pillar in-image rendering (was: String concatenation vs. Stream)

2019-10-20 Thread Kasper Østerbye
On 20 October 2019 at 09.11.06, Pierce Ng (pie...@samadhiweb.com) wrote:

On Sat, Oct 19, 2019 at 04:39:21AM -0700, Kasper Østerbye wrote:
> I am currently working on a github markdown -> pillar tree (the internal
> rep of pillar). I estimate I am a few days out from that one.

Are you doing this in pure Pharo?

Yes. I want to be able to render it inside the image windows.

I have wrapped libhoedown, a Markdown to HTML library. libhoedown uses
callbacks to invoke its renderer and I started constructing a Markdown
to Pillar (string, not object tree) renderer by having libhoedown call
back into Pharo.

Pierce

I do understand you not wanting to write your own parser, it is a pest!
However, I want a simple distribution model with no external dependencies.

At the moment I have a working github-markdown parser (written in Pharo)
which recognises:

Blocks: headers, paragraphs, ordered and unorderd (nested) lists, block,
code-blocs.

Inline: bold, italics, overstrike, inline-code.

I want links and images before releasing it as version 1.

It is restrictive and is a bit peculiar regarding indentation and a few
other things.

— Kasper


Re: [Pharo-users] Pillar in-image rendering (was: String concatenation vs. Stream)

2019-10-20 Thread Pierce Ng
On Sat, Oct 19, 2019 at 04:39:21AM -0700, Kasper Østerbye wrote:
> I am currently working on a github markdown -> pillar tree (the internal
> rep of pillar). I estimate I am a few days out from that one.

Are you doing this in pure Pharo?

I have wrapped libhoedown, a Markdown to HTML library. libhoedown uses
callbacks to invoke its renderer and I started constructing a Markdown
to Pillar (string, not object tree) renderer by having libhoedown call
back into Pharo.

Pierce




[Pharo-users] Pillar in-image rendering (was: String concatenation vs. Stream)

2019-10-19 Thread Kasper Østerbye
On 19 October 2019 at 10.51.53, Norbert Hartl (norb...@hartl.name) wrote:

Am 18.10.2019 um 11:33 schrieb Kasper Østerbye :

I am working on a pillar to `Text` generator. Here I found concatenation to
be simpler to handle as I can add bold, italics, indentation, etc. in a
much simpler way. To use a streaming method I would have to introduce both
Canvas and Aggregate brushes. Doable indeed, but much less concise.

I started to do exactly the same. Well I started to do a converter between
pillar markup and text attributes, but I think you do the same. We probably
should talk. Is you code anywhere public?

Norbert

I have the basic pillar rendering done: headers, lists, bold, emphasis,
images, links (including a “open browser on method” link).

My main *remaining issue is to do tables* somehow. Any hints on how to
render tables inside a text?

It is not on github atm - I need a pull request to come through
 there before I can be a
modular extension.

I’ll try to get it up on my own github sometime Monday.

I am currently working on a github markdown -> pillar tree (the internal
rep of pillar). I estimate I am a few days out from that one.

Best,

Kasper


Re: [Pharo-users] Pillar Book Tester

2018-08-05 Thread Siemen Baader
Very cool, this should be very useful to keep documentation up-to-date.
Good job!

cheers
Siemen

On Tue, Jul 31, 2018 at 11:25 AM Quentin DUCASSE (CI_2020) <
quentin.duca...@ensta-bretagne.org> wrote:

> Hello everyone!
>
> I am currently in an internship within the RMoD team and would like to
> present my work. My internship subject was the following: “How to test
> documents (books, slides) written in Pillar?”. Let me first introduce
> Pillar then what I managed to implement and what is left to do.
>
>
>
> -*What is Pillar?*
>
>
>
> Pillar is a markup syntax and associated tools to write and generate
> documentation, books, slide-based presentations or websites. Pillar syntax
> is similar to Markdown’s one but its emphasis is stressed on publishing to
> different formats/languages (Markdown, html, LateX, pdf).
>
>
>
> -*What does it mean to ‘test a book’?*
>
>
> --  *Display code within the book*
>
> Pillar syntax allows you to write codeblocks, showing a part of code. The
> inside of a codeblock allows one to display any part of code you might
> want to. For example:
>
> [[[
>
> YourClass >> yourMethod
>
> ^ ‘bla’
>
> ]]]
>
> This codeblock presents a method definition, the other two possible
> codeblocks are the following:
>
>
>   Class definition
>
> [[[
>
> Object subclass: #YourClass
>
> instanceVariableNames: ''
>
> classVariableNames: ''
>
> package: YourPackage'
>
> ]]]
>
>
>   Example
>
> [[[
>
> 1+1
>
> >>> 2
>
> ]]]
>
>
>
> --  *How to test it?*
>
> The use of ‘>>>’ and parameters in the codeblock will help us to test the
> code within it. The BookTester will turn examples into tests.
>
>
>
> Testing examples:
>
> [[[testcase=true
>
> 3+4  becomes   self assert: (3+4) equals: 7
>
> >>>7
>
> ]]]
>
>
> Testing methodDefinitions and classDefinitions:
>
>
>
> Testing method or class definitions resumes is the same as testing if the
> compilation of the method does not raise any error. It can help make sure
> your book is up to date with the latest Pharo version. Those tests are done
> the same way as testing an example: stating methodDefinition=true or
> classDefinition=true as code block parameters will make them elible for
> tests. Now, we are adding more features to code block or Pillar to help
> book writers.
>
>
>
> -*Additional Features*
>
> In Pillar, several annotations can be used for different purposes like
> including columns/tables/citations/figures/links…
>
>
>
> -- *  Loading code:* loader
>
> ${loader:account=QDucasse|project=TestBook|tag=Chapter1}$
>
> allows you to load the github project as it was in the commit tagged
> Chapter1. This will help you test every chapter of your code with its
> current progression and also allow you to test the objects you are defining
> in your book.
>
>
> -   *Executing Tests:* run
>
> ${run:testClass=YourClassTest}$ runs the test defined in the class
> testClass. And of course this testClass can be
>
>
> Other annotations have been added to help you write your book:
>
>
> -  * Display a class definition:* showClass:
>
> ${showClass:className=YourClass}$ displays a codeblock with the class
> definition within it
>
> This helps you quickly include a class definition you want to display in
> your book. Combined with the loader it means that the code can be the
> source of your book.
>
>
>
> -  * Display a method definition:* showMethod:
>
> ${showMethod:className=YourClass|methodName=yourMethod}$ will display a
> codeblock with the method definition within it
>
> This helps you quickly include a method definition you want to display in
> your book.
>
>
>
> -  * Screenshot:*
>
>
> ${showMethod:packageName=yourPackage|className=YourClass|methodName=yourMethod|caption|width|label}$
>
> saves a screenshot of a Calypso browser open at the selected package,
> class and method and includes it in both your book (using the designated
> Pillar figure reference) and the figures subfolder in the pillar book
> folder (saved as PNG).
>
>
> -*Future objectives*
>
>
>
> One of the future improvements would be to make everyone able to write
> examples and test them in the comments of method definitions. It is already
> partially possible “3+4 >>> 7” will be highlighted differently and if
> printed will display “7->7”. However, an automation or UI improvement would
> be nice.
>
>
>
> I hope this gave you the will to write something you had in mind. Are
> there any books you want to try the tools on? Feel free to ask !
>
>
>
> Quentin Ducasse
>
>


[Pharo-users] Pillar Book Tester

2018-07-31 Thread Quentin DUCASSE (CI_2020)
Hello everyone!

I am currently in an internship within the RMoD team and would like to present 
my work. My internship subject was the following: “How to test documents 
(books, slides) written in Pillar?”. Let me first introduce Pillar then what I 
managed to implement and what is left to do.



-What is Pillar?



Pillar is a markup syntax and associated tools to write and generate 
documentation, books, slide-based presentations or websites. Pillar syntax is 
similar to Markdown’s one but its emphasis is stressed on publishing to 
different formats/languages (Markdown, html, LateX, pdf).



-What does it mean to ‘test a book’?


--  Display code within the book

Pillar syntax allows you to write codeblocks, showing a part of code. The 
inside of a codeblock allows one to display any part of code you might want to. 
For example:

[[[

YourClass >> yourMethod

^ ‘bla’

]]]

This codeblock presents a method definition, the other two possible codeblocks 
are the following:


  Class definition

[[[

Object subclass: #YourClass

instanceVariableNames: ''

classVariableNames: ''

package: YourPackage'

]]]


  Example

[[[

1+1

>>> 2

]]]



--  How to test it?

The use of ‘>>>’ and parameters in the codeblock will help us to test the code 
within it. The BookTester will turn examples into tests.



Testing examples:

[[[testcase=true

3+4  becomes   self assert: (3+4) equals: 7

>>>7

]]]


Testing methodDefinitions and classDefinitions:



Testing method or class definitions resumes is the same as testing if the 
compilation of the method does not raise any error. It can help make sure your 
book is up to date with the latest Pharo version. Those tests are done the same 
way as testing an example: stating methodDefinition=true or 
classDefinition=true as code block parameters will make them elible for tests. 
Now, we are adding more features to code block or Pillar to help book writers.



-Additional Features

In Pillar, several annotations can be used for different purposes like 
including columns/tables/citations/figures/links…



--   Loading code: loader

${loader:account=QDucasse|project=TestBook|tag=Chapter1}$

allows you to load the github project as it was in the commit tagged Chapter1. 
This will help you test every chapter of your code with its current progression 
and also allow you to test the objects you are defining in your book.


-   Executing Tests: run

${run:testClass=YourClassTest}$ runs the test defined in the class testClass. 
And of course this testClass can be


Other annotations have been added to help you write your book:


-   Display a class definition: showClass:

${showClass:className=YourClass}$ displays a codeblock with the class 
definition within it

This helps you quickly include a class definition you want to display in your 
book. Combined with the loader it means that the code can be the source of your 
book.



-   Display a method definition: showMethod:

${showMethod:className=YourClass|methodName=yourMethod}$ will display a 
codeblock with the method definition within it

This helps you quickly include a method definition you want to display in your 
book.



-   Screenshot:

${showMethod:packageName=yourPackage|className=YourClass|methodName=yourMethod|caption|width|label}$

saves a screenshot of a Calypso browser open at the selected package, class and 
method and includes it in both your book (using the designated Pillar figure 
reference) and the figures subfolder in the pillar book folder (saved as PNG).


-Future objectives



One of the future improvements would be to make everyone able to write examples 
and test them in the comments of method definitions. It is already partially 
possible “3+4 >>> 7” will be highlighted differently and if printed will 
display “7->7”. However, an automation or UI improvement would be nice.



I hope this gave you the will to write something you had in mind. Are there any 
books you want to try the tools on? Feel free to ask !



Quentin Ducasse



Re: [Pharo-users] Pillar questions

2018-02-13 Thread Stephane Ducasse
You have a booklet
https://github.com/SquareBracketAssociates/Booklet-PublishingAPillarBooklet
it is about Pillar 70 (mainly about book publishing) all the rest is
compatible with Pillar 50.

Stef


On Tue, Feb 13, 2018 at 6:34 PM, Arturo Zambrano
 wrote:
> Hi Stef
>
> On Tue, Feb 13, 2018 at 2:18 PM, Stephane Ducasse 
> wrote:
>>
>> Hi arturo
>>
>> Pillar is based on templates so you edit the template and add more
>> variables.
>
>
> got it
>
>>
>> In pillar 5 these variables are metadata so you should add a new one
>> in the metadata declaration.
>> Let me know if you need some screen sharing or some help.
>
>
> I will play a bit and come back with more questions.
>
> I assume that this is the main documentation source
> https://ci.inria.fr/pharo-contribution/job/EnterprisePharoBook/lastSuccessfulBuild/artifact/book-result/PillarChap/Pillar.html
>
> If there is more documentation to read, please let me know.
>
> Thanks.
> Best Regards
>
>
>
>>
>> stef
>>
>> On Tue, Feb 13, 2018 at 4:21 PM, Arturo Zambrano
>>  wrote:
>> > Hi All,
>> >  Q1
>> >   Is there a way of adding page headers/footers in pillar?
>> >   header = image + short legend.
>> >   footer = line  + section name +  page number.
>> >
>> >   Q2
>> >My plan is to use Pillar programmatically, are you aware of some
>> > projects
>> > that use Pillar in that way?  Most of the documentation I found is
>> > regarding
>> > Pillar syntax.
>> >  The testcases are good examples, but I would like to see something more
>> > complex if possible.
>> >
>> >  Thanks!
>> > Arturo
>>
>



Re: [Pharo-users] Pillar questions

2018-02-13 Thread Arturo Zambrano
Hi Stef

On Tue, Feb 13, 2018 at 2:18 PM, Stephane Ducasse 
wrote:

> Hi arturo
>
> Pillar is based on templates so you edit the template and add more
> variables.
>

got it


> In pillar 5 these variables are metadata so you should add a new one
> in the metadata declaration.
> Let me know if you need some screen sharing or some help.
>

I will play a bit and come back with more questions.

I assume that this is the main documentation source
https://ci.inria.fr/pharo-contribution/job/EnterprisePharoBook/lastSuccessfulBuild/artifact/book-result/PillarChap/Pillar.html

If there is more documentation to read, please let me know.

Thanks.
Best Regards




> stef
>
> On Tue, Feb 13, 2018 at 4:21 PM, Arturo Zambrano
>  wrote:
> > Hi All,
> >  Q1
> >   Is there a way of adding page headers/footers in pillar?
> >   header = image + short legend.
> >   footer = line  + section name +  page number.
> >
> >   Q2
> >My plan is to use Pillar programmatically, are you aware of some
> projects
> > that use Pillar in that way?  Most of the documentation I found is
> regarding
> > Pillar syntax.
> >  The testcases are good examples, but I would like to see something more
> > complex if possible.
> >
> >  Thanks!
> > Arturo
>
>


Re: [Pharo-users] Pillar questions

2018-02-13 Thread Arturo Zambrano
On Tue, Feb 13, 2018 at 12:25 PM, Guillermo Polito <
guillermopol...@gmail.com> wrote:

> Hi,
>
>
>
> On Tue, Feb 13, 2018 at 4:21 PM, Arturo Zambrano <
> arturo.zambr...@gmail.com> wrote:
>
>> Hi All,
>>  Q1
>>   Is there a way of adding page headers/footers in pillar?
>>   header = image + short legend.
>>   footer = line  + section name +  page number.
>>
>
> In html generation or pdf generation?
>

any format, as I consider them an intermediate format
somehow, at end I will need Word document :(


>
> Usually all this is handled by the latex/html templates.
>

great!  thanks!.


>
>>
>>   Q2
>>My plan is to use Pillar programmatically, are you aware of some
>> projects that use Pillar in that way?  Most of the documentation I found is
>> regarding Pillar syntax.
>>  The testcases are good examples, but I would like to see something more
>> complex if possible.
>>
>
> There is ecstatic that is a little project that uses pillar programatically
>
> https://github.com/guillep/ecstatic/
>
> Otherwise, I'd recommend to use the latest pillar version in this branch:
>
> https://github.com/pillar-markup/pillar/tree/newpipeline
>
>

Thanks again Guillermo!

>
>>  Thanks!
>> Arturo
>>
>
>
>
> --
>
>
>
> Guille Polito
>
> Research Engineer
>
> Centre de Recherche en Informatique, Signal et Automatique de Lille
>
> CRIStAL - UMR 9189
>
> French National Center for Scientific Research - *http://www.cnrs.fr
> *
>
>
> *Web:* *http://guillep.github.io* 
>
> *Phone: *+33 06 52 70 66 13
>


Re: [Pharo-users] Pillar questions

2018-02-13 Thread Stephane Ducasse
Hi arturo

Pillar is based on templates so you edit the template and add more variables.
In pillar 5 these variables are metadata so you should add a new one
in the metadata declaration.
Let me know if you need some screen sharing or some help.

stef

On Tue, Feb 13, 2018 at 4:21 PM, Arturo Zambrano
 wrote:
> Hi All,
>  Q1
>   Is there a way of adding page headers/footers in pillar?
>   header = image + short legend.
>   footer = line  + section name +  page number.
>
>   Q2
>My plan is to use Pillar programmatically, are you aware of some projects
> that use Pillar in that way?  Most of the documentation I found is regarding
> Pillar syntax.
>  The testcases are good examples, but I would like to see something more
> complex if possible.
>
>  Thanks!
> Arturo



Re: [Pharo-users] Pillar questions

2018-02-13 Thread Guillermo Polito
Hi,



On Tue, Feb 13, 2018 at 4:21 PM, Arturo Zambrano 
wrote:

> Hi All,
>  Q1
>   Is there a way of adding page headers/footers in pillar?
>   header = image + short legend.
>   footer = line  + section name +  page number.
>

In html generation or pdf generation?

Usually all this is handled by the latex/html templates.


>
>   Q2
>My plan is to use Pillar programmatically, are you aware of some
> projects that use Pillar in that way?  Most of the documentation I found is
> regarding Pillar syntax.
>  The testcases are good examples, but I would like to see something more
> complex if possible.
>

There is ecstatic that is a little project that uses pillar programatically

https://github.com/guillep/ecstatic/

Otherwise, I'd recommend to use the latest pillar version in this branch:

https://github.com/pillar-markup/pillar/tree/newpipeline


>
>  Thanks!
> Arturo
>



-- 



Guille Polito

Research Engineer

Centre de Recherche en Informatique, Signal et Automatique de Lille

CRIStAL - UMR 9189

French National Center for Scientific Research - *http://www.cnrs.fr
*


*Web:* *http://guillep.github.io* 

*Phone: *+33 06 52 70 66 13


[Pharo-users] Pillar questions

2018-02-13 Thread Arturo Zambrano
Hi All,
 Q1
  Is there a way of adding page headers/footers in pillar?
  header = image + short legend.
  footer = line  + section name +  page number.

  Q2
   My plan is to use Pillar programmatically, are you aware of some
projects that use Pillar in that way?  Most of the documentation I found is
regarding Pillar syntax.
 The testcases are good examples, but I would like to see something more
complex if possible.

 Thanks!
Arturo


Re: [Pharo-users] Pillar Re: Neural Network - Handwritten Digit Recognition

2018-02-09 Thread Stephane Ducasse
you can change the size of the image using |width=60| it is expression
is given in %
I fixed it. I will read it and give you feedback.
Now I just skimmed throw it and I would
- structure the text with some sections like setup, importing,
computing, rendering, conclusions
- then I would turn the large roassal script in a tiny and beautiful class

Stef

On Sat, Feb 10, 2018 at 2:35 AM, Pierce Ng  wrote:
> On Thu, Feb 08, 2018 at 07:42:09PM +0800, Pierce Ng wrote:
>> On Wed, Feb 07, 2018 at 08:24:29PM +0100, Stephane Ducasse wrote:
>> > Here is the link 
>> > https://github.com/SquareBracketAssociates/Booklet-IA-Neurons
>> > I can give you commit rights.
>>
>> My Github username is PierceNg. Thank you.
>
> Stef, thanks for adding me to the repo. I've plugged my blog post in as 
> chapter
> 1.
>
> On Pillar, I see that the generated PDF shows the array inspector screenshot 
> as
> an outsized image. What's the best practice on sizing images?
>
> Anyhow, I've set up Docker with the texlive:pillar image and just did a
> successful test run. I can now experiment with agility. :-)
>
> Pierce
>



[Pharo-users] Pillar Re: Neural Network - Handwritten Digit Recognition

2018-02-09 Thread Pierce Ng
On Thu, Feb 08, 2018 at 07:42:09PM +0800, Pierce Ng wrote:
> On Wed, Feb 07, 2018 at 08:24:29PM +0100, Stephane Ducasse wrote:
> > Here is the link 
> > https://github.com/SquareBracketAssociates/Booklet-IA-Neurons
> > I can give you commit rights.
> 
> My Github username is PierceNg. Thank you.

Stef, thanks for adding me to the repo. I've plugged my blog post in as chapter
1.

On Pillar, I see that the generated PDF shows the array inspector screenshot as
an outsized image. What's the best practice on sizing images?

Anyhow, I've set up Docker with the texlive:pillar image and just did a
successful test run. I can now experiment with agility. :-)

Pierce



Re: [Pharo-users] Pillar script evaluation generating a screenshot

2018-02-07 Thread Stephane Ducasse
Hi Juraj

I do not know it on top of my head.
I will check ...


For example you get a stream in which you can work
[[[eval=true
stream
nextPutAll: '__WfManagedObject comment:__ ' ;
nextPutAll: WfManagedObject comment; cr;
lf.
]]]

Now I would like to get automatically some png.



On Sat, Feb 3, 2018 at 2:46 PM, Juraj Kubelka  wrote:
> Hi,
>
> Pillar allows to evaluate a script and use its output instead of the script 
> itself, e.g.,
>
> -=-=-=-
> [[[eval=true
> DateAndTime now printString
> ]]]
> -=-=-=-
>
> How can I test it in a Pharo image? I tried:
>
> -=-=-=-
> document := PRPillarParser parse: '[[[eval=true
> DateAndTime now printString
> ]]]' readStream.
>
> PRHTMLWriter write: document.
> -=-=-=-
>
> It returns: DateAndTime now 
> printString
>
> Then I tried:
>
> -=-=-=-
> transformedDocument := (PRScriptEvaluator executeOn: (PRCompilationContext 
> withDocument: document withConfiguration: PRPillarConfiguration new)) input.
>
> PRHTMLWriter write: transformedDocument.
> -=-=-=-
>
> And it returns an empty string.
> What should I do to be able to obtain an HTML output with the output of 
> `DateAndTime now printString`?
>
>
> -=-=-=-
> documentWithImage := PRPillarParser parse: '[[[eval=true
> ByteArray streamContents: [ :writeStream |
> PNGReadWriter putForm: World submorphs atRandom imageForm onStream: 
> writeStream ]
> ]]]' readStream.
> -=-=-=-
>
> What is the best practice if the evaluated result should be a screenshot?
>
> Thanks!
> Juraj
>
>



[Pharo-users] Pillar script evaluation generating a screenshot

2018-02-03 Thread Juraj Kubelka
Hi,

Pillar allows to evaluate a script and use its output instead of the script 
itself, e.g.,

-=-=-=-
[[[eval=true
DateAndTime now printString
]]]
-=-=-=-

How can I test it in a Pharo image? I tried: 

-=-=-=-
document := PRPillarParser parse: '[[[eval=true
DateAndTime now printString
]]]' readStream.

PRHTMLWriter write: document.  
-=-=-=-

It returns: DateAndTime now 
printString

Then I tried:

-=-=-=-
transformedDocument := (PRScriptEvaluator executeOn: (PRCompilationContext 
withDocument: document withConfiguration: PRPillarConfiguration new)) input.

PRHTMLWriter write: transformedDocument.
-=-=-=-

And it returns an empty string.
What should I do to be able to obtain an HTML output with the output of 
`DateAndTime now printString`?


-=-=-=-
documentWithImage := PRPillarParser parse: '[[[eval=true
ByteArray streamContents: [ :writeStream |
PNGReadWriter putForm: World submorphs atRandom imageForm onStream: 
writeStream ]
]]]' readStream.
-=-=-=-

What is the best practice if the evaluated result should be a screenshot? 

Thanks!
Juraj




Re: [Pharo-users] Pillar (was Re: Behold Pharo: The Modern Smalltalk)

2017-10-13 Thread Stephane Ducasse
epub already works. Now it should be improved.

Doing an pandoc exporter should not be that difficult. If you do it I
will integrate it.

On Fri, Oct 13, 2017 at 12:03 PM, Gour  wrote:
> On Wed, 11 Oct 2017 17:18:54 +
> Dimitris Chloupis 
> wrote:
>
>> Well there is a move towards Pillar for class and method commands so
>> who knows maybe we will have that soon enough ;)
>
> Let me say that I'm very happy seeing that Pillar is moving forward (e.g.
> addition of support for footnotes) as well as plan for the future (*.epub
> support) since I'm considering whether it could serve as single-source markup
> for all of one's writings?
>
> After migrating from Python-powered static-site-generator (to Hugo) and rst
> markup I was considering to use AsciiDoc(tor) markup for all my content, but,
> so far, due to using Emacsm settled to use org-mode instead. Haven't tried 
> with
> slides (yet), but there is Pandoc support for it.
>
> Therefore, I'd rather see Pillar support in Pandoc which would buy us even 
> more
> import/export capabilities for free instead of focusing on single formats like
> *.odt, *.epub etc.
>
> Pillar with 1st class support in Pandoc would, imho, improve status of Pharo
> itself making it along with Pillar exceelent tool for development as well as
> for all writing needs - articles, books, documentation, slide-presentations.
>
> But it would be nice to make it more transparent where/how can one submit
> feature request for Pillar?
>
> Fogbugs issue trakcer is certainly not the ideal place these days...
>
>
> Sincerely,
> Gour
>
> --
> Everyone is forced to act helplessly according to the qualities
> he has acquired from the modes of material nature; therefore no
> one can refrain from doing something, not even for a moment.
>
>
>



Re: [Pharo-users] Pillar (was Re: Behold Pharo: The Modern Smalltalk)

2017-10-13 Thread Offray Vladimir Luna Cárdenas
Hi,

I have created a document in Grafoscopio. The source file is a single
Grafoscopio notebook in STON [1] (~600kb), the output is a single
Pandoc's Markdown file[2] (~500kb), and you can produce the output as a
PDF file like in [3] (~13Mb). Pandoc has a lot of maturity and a
community with a lot of momentum, dedicated mainly to light
documentation. If we have support for Pandoc's Markdown on Pharo, we can
leverage on that knowledge and tools without reinventing the wheel. Of
course using AST and a lot of infrastructure behind Pillar can be used,
without falling in love with its syntax.

[1] http://mutabit.com/repos.fossil/mapeda/doc/tip/mapeda.ston
[2] http://mutabit.com/repos.fossil/mapeda/doc/tip/mapeda.markdown
[3] http://mutabit.com/repos.fossil/mapeda/uv/mapeda.pdf

Cheers,

Offray

On 13/10/17 08:21, H. Hirzel wrote:
> Interoperability with pandoc is desirable
>
> Some people want MSWord documents and they provide input in the form
> of MSWord documents.
> Or LibreOffice ODT.
>
> pandoc handles that well for a subset of MSWord options.
>
> pandoc allows you as well to write a custom output format -- in this
> case Pillar.
>
> E.g. conversion from MSWord docx to Pillar is possible.
>
> It would need somebody to look into the issue of doing some Lua scripting.
> pandoc has Lua embedded for output generation.
>
>
> --Hannes
>
>
> P.S. I will have some time later for Pillar issues (not Lua), but the
> document model and generation of slides. Still open issue on my list
> is rendering Pillar on Morphic, in particular slide.
>
>
> On 10/13/17, Dimitris Chloupis  wrote:
>> Why exporting to latex, html and markdown is not enough for you ?
>>
>> On Fri, Oct 13, 2017 at 1:05 PM Gour  wrote:
>>
>>> On Wed, 11 Oct 2017 17:18:54 +
>>> Dimitris Chloupis 
>>> wrote:
>>>
 Well there is a move towards Pillar for class and method commands so
 who knows maybe we will have that soon enough ;)
>>> Let me say that I'm very happy seeing that Pillar is moving forward (e.g.
>>> addition of support for footnotes) as well as plan for the future (*.epub
>>> support) since I'm considering whether it could serve as single-source
>>> markup
>>> for all of one's writings?
>>>
>>> After migrating from Python-powered static-site-generator (to Hugo) and
>>> rst
>>> markup I was considering to use AsciiDoc(tor) markup for all my content,
>>> but,
>>> so far, due to using Emacsm settled to use org-mode instead. Haven't
>>> tried
>>> with
>>> slides (yet), but there is Pandoc support for it.
>>>
>>> Therefore, I'd rather see Pillar support in Pandoc which would buy us
>>> even
>>> more
>>> import/export capabilities for free instead of focusing on single formats
>>> like
>>> *.odt, *.epub etc.
>>>
>>> Pillar with 1st class support in Pandoc would, imho, improve status of
>>> Pharo
>>> itself making it along with Pillar exceelent tool for development as well
>>> as
>>> for all writing needs - articles, books, documentation,
>>> slide-presentations.
>>>
>>> But it would be nice to make it more transparent where/how can one submit
>>> feature request for Pillar?
>>>
>>> Fogbugs issue trakcer is certainly not the ideal place these days...
>>>
>>>
>>> Sincerely,
>>> Gour
>>>
>>> --
>>> Everyone is forced to act helplessly according to the qualities
>>> he has acquired from the modes of material nature; therefore no
>>> one can refrain from doing something, not even for a moment.
>>>
>>>
>>>
>>>
>





Re: [Pharo-users] Pillar (was Re: Behold Pharo: The Modern Smalltalk)

2017-10-13 Thread H. Hirzel
Interoperability with pandoc is desirable

Some people want MSWord documents and they provide input in the form
of MSWord documents.
Or LibreOffice ODT.

pandoc handles that well for a subset of MSWord options.

pandoc allows you as well to write a custom output format -- in this
case Pillar.

E.g. conversion from MSWord docx to Pillar is possible.

It would need somebody to look into the issue of doing some Lua scripting.
pandoc has Lua embedded for output generation.


--Hannes


P.S. I will have some time later for Pillar issues (not Lua), but the
document model and generation of slides. Still open issue on my list
is rendering Pillar on Morphic, in particular slide.


On 10/13/17, Dimitris Chloupis  wrote:
> Why exporting to latex, html and markdown is not enough for you ?
>
> On Fri, Oct 13, 2017 at 1:05 PM Gour  wrote:
>
>> On Wed, 11 Oct 2017 17:18:54 +
>> Dimitris Chloupis 
>> wrote:
>>
>> > Well there is a move towards Pillar for class and method commands so
>> > who knows maybe we will have that soon enough ;)
>>
>> Let me say that I'm very happy seeing that Pillar is moving forward (e.g.
>> addition of support for footnotes) as well as plan for the future (*.epub
>> support) since I'm considering whether it could serve as single-source
>> markup
>> for all of one's writings?
>>
>> After migrating from Python-powered static-site-generator (to Hugo) and
>> rst
>> markup I was considering to use AsciiDoc(tor) markup for all my content,
>> but,
>> so far, due to using Emacsm settled to use org-mode instead. Haven't
>> tried
>> with
>> slides (yet), but there is Pandoc support for it.
>>
>> Therefore, I'd rather see Pillar support in Pandoc which would buy us
>> even
>> more
>> import/export capabilities for free instead of focusing on single formats
>> like
>> *.odt, *.epub etc.
>>
>> Pillar with 1st class support in Pandoc would, imho, improve status of
>> Pharo
>> itself making it along with Pillar exceelent tool for development as well
>> as
>> for all writing needs - articles, books, documentation,
>> slide-presentations.
>>
>> But it would be nice to make it more transparent where/how can one submit
>> feature request for Pillar?
>>
>> Fogbugs issue trakcer is certainly not the ideal place these days...
>>
>>
>> Sincerely,
>> Gour
>>
>> --
>> Everyone is forced to act helplessly according to the qualities
>> he has acquired from the modes of material nature; therefore no
>> one can refrain from doing something, not even for a moment.
>>
>>
>>
>>
>



Re: [Pharo-users] Pillar

2017-10-13 Thread Gour
On Fri, 13 Oct 2017 10:43:27 +
Dimitris Chloupis 
wrote:

> Why exporting to latex, html and markdown is not enough for you ?

Well, I usuallyconsider latex/html as more suitable as output formats, while
standard markdown is semantically too poor for input format, but I'll test how
Pillar's outputs are suitable as Pandoc's inputs.


Sincerely,
Gour

-- 
It is far better to discharge one's prescribed duties, even though
faultily, than another's duties perfectly. Destruction in the course
of performing one's own duty is better than engaging in another's
duties, for to follow another's path is dangerous.





Re: [Pharo-users] Pillar (was Re: Behold Pharo: The Modern Smalltalk)

2017-10-13 Thread Dimitris Chloupis
Why exporting to latex, html and markdown is not enough for you ?

On Fri, Oct 13, 2017 at 1:05 PM Gour  wrote:

> On Wed, 11 Oct 2017 17:18:54 +
> Dimitris Chloupis 
> wrote:
>
> > Well there is a move towards Pillar for class and method commands so
> > who knows maybe we will have that soon enough ;)
>
> Let me say that I'm very happy seeing that Pillar is moving forward (e.g.
> addition of support for footnotes) as well as plan for the future (*.epub
> support) since I'm considering whether it could serve as single-source
> markup
> for all of one's writings?
>
> After migrating from Python-powered static-site-generator (to Hugo) and rst
> markup I was considering to use AsciiDoc(tor) markup for all my content,
> but,
> so far, due to using Emacsm settled to use org-mode instead. Haven't tried
> with
> slides (yet), but there is Pandoc support for it.
>
> Therefore, I'd rather see Pillar support in Pandoc which would buy us even
> more
> import/export capabilities for free instead of focusing on single formats
> like
> *.odt, *.epub etc.
>
> Pillar with 1st class support in Pandoc would, imho, improve status of
> Pharo
> itself making it along with Pillar exceelent tool for development as well
> as
> for all writing needs - articles, books, documentation,
> slide-presentations.
>
> But it would be nice to make it more transparent where/how can one submit
> feature request for Pillar?
>
> Fogbugs issue trakcer is certainly not the ideal place these days...
>
>
> Sincerely,
> Gour
>
> --
> Everyone is forced to act helplessly according to the qualities
> he has acquired from the modes of material nature; therefore no
> one can refrain from doing something, not even for a moment.
>
>
>
>


Re: [Pharo-users] Pillar (was Re: Behold Pharo: The Modern Smalltalk)

2017-10-13 Thread Cyril Ferlicot
On ven. 13 oct. 2017 at 12:05, Gour  wrote:

> On Wed, 11 Oct 2017 17:18:54 +
> Dimitris Chloupis 
> wrote:
>
> > Well there is a move towards Pillar for class and method commands so
> > who knows maybe we will have that soon enough ;)
>
> Let me say that I'm very happy seeing that Pillar is moving forward (e.g.
> addition of support for footnotes) as well as plan for the future (*.epub
> support) since I'm considering whether it could serve as single-source
> markup
> for all of one's writings?
>
> After migrating from Python-powered static-site-generator (to Hugo) and rst
> markup I was considering to use AsciiDoc(tor) markup for all my content,
> but,
> so far, due to using Emacsm settled to use org-mode instead. Haven't tried
> with
> slides (yet), but there is Pandoc support for it.
>
> Therefore, I'd rather see Pillar support in Pandoc which would buy us even
> more
> import/export capabilities for free instead of focusing on single formats
> like
> *.odt, *.epub etc.
>
> Pillar with 1st class support in Pandoc would, imho, improve status of
> Pharo
> itself making it along with Pillar exceelent tool for development as well
> as
> for all writing needs - articles, books, documentation,
> slide-presentations.
>
> But it would be nice to make it more transparent where/how can one submit
> feature request for Pillar?


Hi,


I don't have much time so, fast answer:
https://github.com/pillar-markup/pillar/issues



>
> Fogbugs issue trakcer is certainly not the ideal place these days...
>
>
> Sincerely,
> Gour
>
> --
> Everyone is forced to act helplessly according to the qualities
> he has acquired from the modes of material nature; therefore no
> one can refrain from doing something, not even for a moment.
>
>
>
> --
Cyril Ferlicot
https://ferlicot.fr

http://www.synectique.eu
2 rue Jacques Prévert 01,
59650 Villeneuve d'ascq France


[Pharo-users] Pillar (was Re: Behold Pharo: The Modern Smalltalk)

2017-10-13 Thread Gour
On Wed, 11 Oct 2017 17:18:54 +
Dimitris Chloupis 
wrote:

> Well there is a move towards Pillar for class and method commands so
> who knows maybe we will have that soon enough ;)

Let me say that I'm very happy seeing that Pillar is moving forward (e.g.
addition of support for footnotes) as well as plan for the future (*.epub
support) since I'm considering whether it could serve as single-source markup
for all of one's writings?

After migrating from Python-powered static-site-generator (to Hugo) and rst
markup I was considering to use AsciiDoc(tor) markup for all my content, but,
so far, due to using Emacsm settled to use org-mode instead. Haven't tried with
slides (yet), but there is Pandoc support for it.

Therefore, I'd rather see Pillar support in Pandoc which would buy us even more
import/export capabilities for free instead of focusing on single formats like
*.odt, *.epub etc.

Pillar with 1st class support in Pandoc would, imho, improve status of Pharo
itself making it along with Pillar exceelent tool for development as well as
for all writing needs - articles, books, documentation, slide-presentations.

But it would be nice to make it more transparent where/how can one submit
feature request for Pillar?

Fogbugs issue trakcer is certainly not the ideal place these days...


Sincerely,
Gour

-- 
Everyone is forced to act helplessly according to the qualities
he has acquired from the modes of material nature; therefore no
one can refrain from doing something, not even for a moment.





Re: [Pharo-users] [Pillar][editor][Pharo 6.1] How do I get to work 'Transform code snippets to new format'?

2017-09-01 Thread Tudor Girba
Hi,

Indeed, this depends on PetitIslands. But, anyway, this feature was a 
transformation for migrating old Pier line-based sources (starting with =) to 
newer Pillar-based one (with [[[ ]]]). I will remove this feature because it is 
not really needed anymore.

Cheers,
Doru


> On Sep 1, 2017, at 12:00 PM, H. Hirzel  wrote:
> 
> Hello
> 
> In a pristine Pharo 6.0/6.1 image I installed Pillar [1]. The editor
> for Pillar code works fine. It includes a menu entry
> 
> 'Transform code snippets to new format'
> 
> If I choose this entry a debug window appears [2]. It seems that I
> need to install an additional package.
> 
> Which one and how do I do that?
> 
> Thank you in advance
> 
> Hannes
> 
> 
> 
> 
> 
> 
> 
> 
> 
> [1] Not through the catalog but with
> 
>  Metacello new
>  smalltalkhubUser: 'Pier' project: 'Pillar';
>  configuration: 'Pillar';
>  version: #stable;
>  load.
> 
> This version comes with a Pillar editor.
> The version in the catalog seems to be older and does not contain a
> Pillar editor.
> 
> 
> 
> [2] PPActionParser(Object)>>doesNotUnderstand: #island
> GTOldCodeSnippet>>start
> [ :class :parser |
> parser setParser: (parser perform: parser children first name).
> parser productionNames
>   keysAndValuesDo:
>   [ :key :value | (parser instVarAt: key) setParser: (parser 
> perform:
> value) ] ] in GTOldCodeSnippet class(PPCompositeParser
> class)>>newStartingAt:
> [ :assoc | aBlock value: assoc key value: assoc value ] in
> IdentityDictionary(Dictionary)>>keysAndValuesDo:
> [ :each | each ifNotNil: [ aBlock value: each ] ] in
> IdentityDictionary(Dictionary)>>associationsDo:
> Array(SequenceableCollection)>>do:
> IdentityDictionary(Dictionary)>>associationsDo:
> IdentityDictionary(Dictionary)>>keysAndValuesDo:
> GTOldCodeSnippet class(PPCompositeParser class)>>newStartingAt:
> GTOldCodeSnippet class(PPCompositeParser class)>>new
> [ :rub |
> | newContents |
> newContents := GTOldCodeSnippet new parse: self contents.
> self
>   ensureDelete;
>   writeStreamDo: [ :s | s nextPutAll: newContents ].
> rub update ] in FileReference>>gtInspectorPillarIn:
> BlockClosure>>glamourValueWithArgs:
> GLMGenericAction(GLMAction)>>actOn:
> GLMGenericAction(GLMAction)>>morphicActOn:
> [ | selArgCount |
> "show cursor in case item opens a new MVC window"
> (selArgCount := selector numArgs) = 0
>   ifTrue: [ target perform: selector ]
>   ifFalse: [ selArgCount = arguments size
>   ifTrue: [ target perform: selector withArguments: 
> arguments ]
>   ifFalse: [ target perform: selector withArguments: 
> (arguments
> copyWith: evt) ].
>   self showShortcut ].
> self changed ] in ToggleMenuItemMorph(MenuItemMorph)>>invokeWithEvent:
> BlockClosure>>ensure:
> CursorWithMask(Cursor)>>showWhile:
> ToggleMenuItemMorph(MenuItemMorph)>>invokeWithEvent:
> ToggleMenuItemMorph(MenuItemMorph)>>mouseUp:
> ToggleMenuItemMorph(MenuItemMorph)>>handleMouseUp:
> 
> 

--
www.tudorgirba.com
www.feenk.com

"Innovation comes in the least expected form. 
That is, if it is expected, it already happened."




[Pharo-users] [Pillar][editor][Pharo 6.1] How do I get to work 'Transform code snippets to new format'?

2017-09-01 Thread H. Hirzel
Hello

In a pristine Pharo 6.0/6.1 image I installed Pillar [1]. The editor
for Pillar code works fine. It includes a menu entry

 'Transform code snippets to new format'

If I choose this entry a debug window appears [2]. It seems that I
need to install an additional package.

Which one and how do I do that?

Thank you in advance

Hannes









[1] Not through the catalog but with

  Metacello new
  smalltalkhubUser: 'Pier' project: 'Pillar';
  configuration: 'Pillar';
  version: #stable;
  load.

This version comes with a Pillar editor.
The version in the catalog seems to be older and does not contain a
Pillar editor.



[2] PPActionParser(Object)>>doesNotUnderstand: #island
GTOldCodeSnippet>>start
[ :class :parser |
parser setParser: (parser perform: parser children first name).
parser productionNames
keysAndValuesDo:
[ :key :value | (parser instVarAt: key) setParser: (parser 
perform:
value) ] ] in GTOldCodeSnippet class(PPCompositeParser
class)>>newStartingAt:
[ :assoc | aBlock value: assoc key value: assoc value ] in
IdentityDictionary(Dictionary)>>keysAndValuesDo:
[ :each | each ifNotNil: [ aBlock value: each ] ] in
IdentityDictionary(Dictionary)>>associationsDo:
Array(SequenceableCollection)>>do:
IdentityDictionary(Dictionary)>>associationsDo:
IdentityDictionary(Dictionary)>>keysAndValuesDo:
GTOldCodeSnippet class(PPCompositeParser class)>>newStartingAt:
GTOldCodeSnippet class(PPCompositeParser class)>>new
[ :rub |
| newContents |
newContents := GTOldCodeSnippet new parse: self contents.
self
ensureDelete;
writeStreamDo: [ :s | s nextPutAll: newContents ].
rub update ] in FileReference>>gtInspectorPillarIn:
BlockClosure>>glamourValueWithArgs:
GLMGenericAction(GLMAction)>>actOn:
GLMGenericAction(GLMAction)>>morphicActOn:
[ | selArgCount |
"show cursor in case item opens a new MVC window"
(selArgCount := selector numArgs) = 0
ifTrue: [ target perform: selector ]
ifFalse: [ selArgCount = arguments size
ifTrue: [ target perform: selector withArguments: 
arguments ]
ifFalse: [ target perform: selector withArguments: 
(arguments
copyWith: evt) ].
self showShortcut ].
self changed ] in ToggleMenuItemMorph(MenuItemMorph)>>invokeWithEvent:
BlockClosure>>ensure:
CursorWithMask(Cursor)>>showWhile:
ToggleMenuItemMorph(MenuItemMorph)>>invokeWithEvent:
ToggleMenuItemMorph(MenuItemMorph)>>mouseUp:
ToggleMenuItemMorph(MenuItemMorph)>>handleMouseUp:




Re: [Pharo-users] [Pillar] How do I include a picture which I get from aMorph imageFrom?

2017-08-31 Thread Henrik Nergaard

"There is no need to open the morph in the world and delete it. #imageForm uses 
its own form and renders the morph onto it."

| image |
image := AlignmentMorph newRow
hResizing: #shrinkWrap;
vResizing: #shrinkWrap;
color: Color gray;
addMorph: (EllipseMorph new color: Color red);
   addMorph: (EllipseMorph new color: Color yellow);
   addMorph: (EllipseMorph new color: Color green);
   imageForm.

image writePNGFileNamed: 'myImage.png'

"there are some export methods in morph which can be used instead of #imageForm 
and then #writePngFileNamed (#exportAsPNG), which will then prompt you for the 
file name and location".

Best regards,
Henrik











Fra: Pharo-users <pharo-users-boun...@lists.pharo.org> på vegne av Stephane 
Ducasse <stepharo.s...@gmail.com>
Sendt: 31. august 2017 20:23:24
Til: Any question about pharo is welcome
Emne: Re: [Pharo-users] [Pillar] How do I include a picture which I get from 
aMorph imageFrom?

I will keep your idea for a student lectures we will have in second semester

+Caption>file://image.png|width=50|label=label+
=>
+Caption>inMemory: [| myMorph myForm myPillarSource myPillarDOM |

myMorph := AlignmentMorph newRow
   addMorph: (EllipseMorph new color: Color red);
   addMorph: (EllipseMorph new color: Color yellow);
   addMorph: (EllipseMorph new color: Color green);
   openInWorld.

myForm := myMorph imageForm.
myMorph delete.

PNGReadWriter
putForm: myForm
onFileNamed: 'myImage.png'.
]|width=50|label=label+

On Mon, Aug 28, 2017 at 6:22 PM, H. Hirzel <hannes.hir...@gmail.com> wrote:
> The answer (second option by writing the image to disk) is
>
> | myMorph myForm myPillarSource myPillarDOM |
>
> myMorph := AlignmentMorph newRow
>addMorph: (EllipseMorph new color: Color red);
>addMorph: (EllipseMorph new color: Color yellow);
>addMorph: (EllipseMorph new color: Color green);
>openInWorld.
>
> myForm := myMorph imageForm.
> myMorph delete.
>
> PNGReadWriter
> putForm: myForm
> onFileNamed: 'myImage.png'.
>
>
>
> myPillarSource := '
>
> !The title
> Lorem ipsum dolor sit amet, consectetur adipiscing elit, sed do
> eiusmod tempor incididunt ut labore et dolore magna aliqua. Ut enim ad
> minim veniam, quis nostrud exercitation ullamco laboris nisi ut
> aliquip ex ea commodo consequat. Duis aute irure dolor in
> reprehenderit in voluptate velit esse cillum dolore eu fugiat nulla
> pariatur.
>
> +The caption of my image>file://myImage.png|label=myLabel+
>
> Excepteur sint occaecat cupidatat non proident, sunt in culpa qui
> officia deserunt mollit anim id est laborum.
> '.
>
>
> myPillarDOM :=   PRPillarParser parse: myPillarSource.
>
>
> (PRHTMLWriter write: myPillarDOM) contents inspect
>
>
>
>
>
> HH.
>
>
> On 8/28/17, H. Hirzel <hannes.hir...@gmail.com> wrote:
>> Hello
>>
>> Is it possible to include a in-image picture in Pillar which I get by
>> evaluating
>>
>> myMorph imageForm?
>>
>> Or do I need to write the instance of Form I get by evaluating the
>> expression above first as a PNG file to disk and get it from there.
>>
>>
>> PNGReadWriter
>>   putForm: myMorph imageForm
>>   onFileNamed: aString
>>
>> If yes what is the default directory where does Pillar expects pictures --
>>
>>
>> The Pillar cheat sheet [1] and the Pillar chapter in the Pharo
>> enterprise book no 3 [2] have an example
>>
>> +Caption>file://image.png|width=50|label=label+
>>
>>
>> Regards
>>
>> Hannes
>>
>>
>>
>> [1]
>> http://pillarhub.pharocloud.com/hub/pillarhub/pillarcheatsheet
>>
>> [2] Section 3.8 of
>> https://ci.inria.fr/pharo-contribution/job/EnterprisePharoBook/lastSuccessfulBuild/artifact/book-result/PillarChap/Pillar.html
>>
>



Re: [Pharo-users] pillar image in external link (or html a tag)

2017-08-31 Thread Stephane Ducasse
Right now I cannot concentrate on this.
- ESUG
- Lectures at Prague :)

Stef

On Sun, Aug 27, 2017 at 9:32 PM, Peter Uhnák  wrote:
> I did a pass on the Markdown exporter to align it with CommonMark
> specifications, so it is exporter properly if I instantiate the objects.
>
> But Pillar also needs to parse the string properly.
>
> On Sun, Aug 27, 2017 at 8:28 PM, Stephane Ducasse 
> wrote:
>>
>> Hi peter
>>
>> I do not think you can. I learned this features friday while writing
>> md text to point to travis.
>> This is something that we will able to add but for now my focus is not
>> there.
>> Stef
>>
>> On Sat, Aug 26, 2017 at 10:41 PM, Peter Uhnák  wrote:
>> > Hi,
>> >
>> > how can I embed an image into an anchor in Pillar?
>> >
>> > I've tried
>> >
>> > *+Pharo>https://pharo.org/web/files/pharo.png+>http://pharo.org/*
>> >
>> > I've also tried to create document by hand and export it, but every
>> > single
>> > exporter failed on it.
>> >
>> > doc := PRDocument new
>> > add: (PRExternalLink new
>> > reference: 'http://pharo.org/';
>> > add: (PRFigure new
>> > reference: 'https://pharo.org/web/files/pharo.png';
>> > add: (PRText content: 'Pharo');
>> > yourself
>> > );
>> > yourself
>> > );
>> > yourself
>> >
>> > Thanks,
>> > Peter
>>
>



Re: [Pharo-users] [Pillar] How do I include a picture which I get from aMorph imageFrom?

2017-08-31 Thread Stephane Ducasse
I will keep your idea for a student lectures we will have in second semester

+Caption>file://image.png|width=50|label=label+
=>
+Caption>inMemory: [| myMorph myForm myPillarSource myPillarDOM |

myMorph := AlignmentMorph newRow
   addMorph: (EllipseMorph new color: Color red);
   addMorph: (EllipseMorph new color: Color yellow);
   addMorph: (EllipseMorph new color: Color green);
   openInWorld.

myForm := myMorph imageForm.
myMorph delete.

PNGReadWriter
putForm: myForm
onFileNamed: 'myImage.png'.
]|width=50|label=label+

On Mon, Aug 28, 2017 at 6:22 PM, H. Hirzel  wrote:
> The answer (second option by writing the image to disk) is
>
> | myMorph myForm myPillarSource myPillarDOM |
>
> myMorph := AlignmentMorph newRow
>addMorph: (EllipseMorph new color: Color red);
>addMorph: (EllipseMorph new color: Color yellow);
>addMorph: (EllipseMorph new color: Color green);
>openInWorld.
>
> myForm := myMorph imageForm.
> myMorph delete.
>
> PNGReadWriter
> putForm: myForm
> onFileNamed: 'myImage.png'.
>
>
>
> myPillarSource := '
>
> !The title
> Lorem ipsum dolor sit amet, consectetur adipiscing elit, sed do
> eiusmod tempor incididunt ut labore et dolore magna aliqua. Ut enim ad
> minim veniam, quis nostrud exercitation ullamco laboris nisi ut
> aliquip ex ea commodo consequat. Duis aute irure dolor in
> reprehenderit in voluptate velit esse cillum dolore eu fugiat nulla
> pariatur.
>
> +The caption of my image>file://myImage.png|label=myLabel+
>
> Excepteur sint occaecat cupidatat non proident, sunt in culpa qui
> officia deserunt mollit anim id est laborum.
> '.
>
>
> myPillarDOM :=   PRPillarParser parse: myPillarSource.
>
>
> (PRHTMLWriter write: myPillarDOM) contents inspect
>
>
>
>
>
> HH.
>
>
> On 8/28/17, H. Hirzel  wrote:
>> Hello
>>
>> Is it possible to include a in-image picture in Pillar which I get by
>> evaluating
>>
>> myMorph imageForm?
>>
>> Or do I need to write the instance of Form I get by evaluating the
>> expression above first as a PNG file to disk and get it from there.
>>
>>
>> PNGReadWriter
>>   putForm: myMorph imageForm
>>   onFileNamed: aString
>>
>> If yes what is the default directory where does Pillar expects pictures --
>>
>>
>> The Pillar cheat sheet [1] and the Pillar chapter in the Pharo
>> enterprise book no 3 [2] have an example
>>
>> +Caption>file://image.png|width=50|label=label+
>>
>>
>> Regards
>>
>> Hannes
>>
>>
>>
>> [1]
>> http://pillarhub.pharocloud.com/hub/pillarhub/pillarcheatsheet
>>
>> [2] Section 3.8 of
>> https://ci.inria.fr/pharo-contribution/job/EnterprisePharoBook/lastSuccessfulBuild/artifact/book-result/PillarChap/Pillar.html
>>
>



Re: [Pharo-users] [Pillar] Pillar source code of ESUG 2015 presentation? Presentations done with Pillar?

2017-08-31 Thread H. Hirzel
Thank you, Stef

https://github.com/SquareBracketAssociates/PharoMooc/tree/master/support/beamer

On 8/31/17, Stephane Ducasse  wrote:
> Hannes
>
> the beamer templates manage the first page.
> Have a look in the support/ folder.
>
> Stef
>
> On Thu, Aug 31, 2017 at 4:12 PM, Cyril Ferlicot
>  wrote:
>> There is some doc in the section 3.12 of the documentation
>> https://ci.inria.fr/pharo-contribution/job/EnterprisePharoBook/lastSuccessfulBuild/artifact/book-result/PillarChap/Pillar.html
>>
>> I don't know if everything is here but there is some doc at least :)
>>
>> On Thu, Aug 31, 2017 at 4:08 PM, H. Hirzel 
>> wrote:
>>> On 8/31/17, H. Hirzel  wrote:
 A useful file which shows what is possible to do slides

 https://github.com/SquareBracketAssociates/PharoMooc/blob/master/Slides/1-Templates/Template.pillar
>>>
>>> Correction:
>>> This file shows how to do slides with Pillar
>>>
>>> https://github.com/SquareBracketAssociates/PharoMooc/blob/master/Slides/1-Templates/SlideExample.pillar
>>>
>>> My questions thus are specifically:
>>>
>>> 1. How do I do a title slide?
>>> 2. What do I do inside the ${}$ .
>>>Where do I find documentation on the options for these $ enclosed
>>> commands?
>>>
>>> --Hannes
>>>
>>
>>
>>
>> --
>> Cyril Ferlicot
>> https://ferlicot.fr
>>
>> http://www.synectique.eu
>> 2 rue Jacques Prévert 01,
>> 59650 Villeneuve d'ascq France
>>
>
>



Re: [Pharo-users] [Pillar] Pillar source code of ESUG 2015 presentation? Presentations done with Pillar?

2017-08-31 Thread Stephane Ducasse
Hannes

the beamer templates manage the first page.
Have a look in the support/ folder.

Stef

On Thu, Aug 31, 2017 at 4:12 PM, Cyril Ferlicot
 wrote:
> There is some doc in the section 3.12 of the documentation
> https://ci.inria.fr/pharo-contribution/job/EnterprisePharoBook/lastSuccessfulBuild/artifact/book-result/PillarChap/Pillar.html
>
> I don't know if everything is here but there is some doc at least :)
>
> On Thu, Aug 31, 2017 at 4:08 PM, H. Hirzel  wrote:
>> On 8/31/17, H. Hirzel  wrote:
>>> A useful file which shows what is possible to do slides
>>>
>>> https://github.com/SquareBracketAssociates/PharoMooc/blob/master/Slides/1-Templates/Template.pillar
>>
>> Correction:
>> This file shows how to do slides with Pillar
>>
>> https://github.com/SquareBracketAssociates/PharoMooc/blob/master/Slides/1-Templates/SlideExample.pillar
>>
>> My questions thus are specifically:
>>
>> 1. How do I do a title slide?
>> 2. What do I do inside the ${}$ .
>>Where do I find documentation on the options for these $ enclosed 
>> commands?
>>
>> --Hannes
>>
>
>
>
> --
> Cyril Ferlicot
> https://ferlicot.fr
>
> http://www.synectique.eu
> 2 rue Jacques Prévert 01,
> 59650 Villeneuve d'ascq France
>



Re: [Pharo-users] [Pillar] Pillar source code of ESUG 2015 presentation? Presentations done with Pillar?

2017-08-31 Thread Cyril Ferlicot
There is some doc in the section 3.12 of the documentation
https://ci.inria.fr/pharo-contribution/job/EnterprisePharoBook/lastSuccessfulBuild/artifact/book-result/PillarChap/Pillar.html

I don't know if everything is here but there is some doc at least :)

On Thu, Aug 31, 2017 at 4:08 PM, H. Hirzel  wrote:
> On 8/31/17, H. Hirzel  wrote:
>> A useful file which shows what is possible to do slides
>>
>> https://github.com/SquareBracketAssociates/PharoMooc/blob/master/Slides/1-Templates/Template.pillar
>
> Correction:
> This file shows how to do slides with Pillar
>
> https://github.com/SquareBracketAssociates/PharoMooc/blob/master/Slides/1-Templates/SlideExample.pillar
>
> My questions thus are specifically:
>
> 1. How do I do a title slide?
> 2. What do I do inside the ${}$ .
>Where do I find documentation on the options for these $ enclosed commands?
>
> --Hannes
>



-- 
Cyril Ferlicot
https://ferlicot.fr

http://www.synectique.eu
2 rue Jacques Prévert 01,
59650 Villeneuve d'ascq France



Re: [Pharo-users] [Pillar] Pillar source code of ESUG 2015 presentation? Presentations done with Pillar?

2017-08-31 Thread H. Hirzel
On 8/31/17, H. Hirzel  wrote:
> A useful file which shows what is possible to do slides
>
> https://github.com/SquareBracketAssociates/PharoMooc/blob/master/Slides/1-Templates/Template.pillar

Correction:
This file shows how to do slides with Pillar

https://github.com/SquareBracketAssociates/PharoMooc/blob/master/Slides/1-Templates/SlideExample.pillar

My questions thus are specifically:

1. How do I do a title slide?
2. What do I do inside the ${}$ .
   Where do I find documentation on the options for these $ enclosed commands?

--Hannes



Re: [Pharo-users] [Pillar] Pillar source code of ESUG 2015 presentation? Presentations done with Pillar?

2017-08-31 Thread H. Hirzel
A useful file which shows what is possible to do slides

https://github.com/SquareBracketAssociates/PharoMooc/blob/master/Slides/1-Templates/Template.pillar

But nothing about the first slide.




Another question:

${  ... something  }$

is used to tell Pillar that a new slide is defined and the title is set

${slide:title=Getting a Feel About Syntax}$

What are options to use within

   ${  ... something  }$

?

The pillar tutorial in the Enterprise book [1] does not mention this.

--Hannes


[1] 
https://ci.inria.fr/pharo-contribution/job/EnterprisePharoBook/lastSuccessfulBuild/artifact/book-result/PillarChap/Pillar.html#configParameters




On 8/31/17, Cyril Ferlicot  wrote:
> Hi,
>
> I did not check but the first slide is probably written in beamer
> direcly. It must be in the template of the slides.
>
> On Thu, Aug 31, 2017 at 2:53 PM, H. Hirzel  wrote:
>> Thank yous.
>>
>> I wonder how the image (or two images?) in the title slide were added.
>>
>> Example:
>> PDF
>>
>> http://rmod-pharo-mooc.lille.inria.fr/MOOC/Slides/Week1/C019-W1S05-PharoSyntaxInANutshell.pdf
>> Pillar source:
>> https://github.com/SquareBracketAssociates/PharoMooc/blob/master/Slides/Week1/C019-W1S04-PharoModelInaNushell.pillar
>>
>> The code of the first slide contains the meta information, i.e. there
>> must be a title template somewhere. Is the template defined within the
>> image or is it a separate file outside in the working directory? I did
>> not find it yet.
>>
>>
>> Below in { .. } is the definition of the title slide.
>> Then
>> ${slide:title=Getting a Feel About Syntax}$
>> starts a regular slide.
>>
>>
>>
>> {
>> "title":"Pharo Syntax in a Nutshell",
>> "slidesid":"W1S05"
>> }
>>
>>
>> ${slide:title=Getting a Feel About Syntax}$
>>
>> Give you the general feel to get started:
>> - Overview of syntactical elements and constructs
>> - Three kinds of messages to minimize parentheses
>> - Overview of block syntax
>> This lecture is an ""overview""
>> No stress if you do not get it right now!
>> We will repeat in future lectures
>> ${slide:title=The Complete Syntax on a Postcard}$
>> No need to understand everything!
>> But "everything" is on this screen :)
>>
>>
>> --Hannes
>>
>>
>
>
>
> --
> Cyril Ferlicot
> https://ferlicot.fr
>
> http://www.synectique.eu
> 2 rue Jacques Prévert 01,
> 59650 Villeneuve d'ascq France
>
>



Re: [Pharo-users] [Pillar] How do I open the Pillar editor in Pharo 6?

2017-08-31 Thread H. Hirzel
On 8/30/17, Offray Vladimir Luna Cárdenas  wrote:
> Works pretty well! See the screen below.

Confirmation that it works well. First it did not but in a pristine
image done with

curl get.pharo.org | bash

(Ubuntu 14.04)
then in a Pharo playground

Metacello new
smalltalkhubUser: 'Pier' project: 'Pillar';
configuration: 'Pillar';
version: #stable;
load.

The Pillar editor works fine, see screen shot.

Many thanks to Doru for the info about the Pillar installation invocation!
(Not sure about the status of the Pillar Pharo 6 catalog entry, two
weeks ago the Pillar editor did not work).

--Hannes


Re: [Pharo-users] [Pillar] How do I open the Pillar editor in Pharo 6?

2017-08-29 Thread Stephane Ducasse
I did not know it :) so this is cool.
Today we improved the makefile logic and I'm about to finish a hack to
give the possibility to the makefile to be fully generic.
After I will finally look at Luc makefile generator because we want to
move more logic to Pharo.

Stef

On Tue, Aug 29, 2017 at 2:20 PM, H. Hirzel  wrote:
> On 8/28/17, Norbert Hartl  wrote:
>>
>>> Am 26.08.2017 um 12:56 schrieb Tudor Girba :
>>>
>>> In an image having Pillar, inspect a Pillar file. Something like this:
>>>
>>> ‘path/to/file.pillar' asFileReference
>>>
>> I downloaded a 6.1 image, loaded pillar from catalog and inspected
>>
>> 'foo.pillar' asFileReference
>>
>> and I get
>>
>
> The same result here.
>
>>
>> Looks like there are additional steps needed.
>>
>> Norbert
>>
>
>
> If I do
>
>
> PRPillarParser parse:
> 'myExample.pillar' asFileReference contents
>
>
> I get a nice display of the Pillar Document Object Model and the
> results after using different exporter objects (HTML, DeckJS,
> Markdown, AsciiDoc, Beamer, LaTeX)
>
> But no Pillar editor.
>
> --Hannes



Re: [Pharo-users] [Pillar] Pillar source code of ESUG 2015 presentation? Presentations done with Pillar?

2017-08-29 Thread Stephane Ducasse
except the slides 2 and 3 of the first week :)
But else all the mooc: slides, exercises were made in Pillar

On Tue, Aug 29, 2017 at 3:39 PM, Peter Uhnák  wrote:
> All Pharo Mooc slides were made in pillar
>
> e.g.
>
> pillar:
> https://github.com/SquareBracketAssociates/PharoMooc/blob/master/Slides/Week3/C019-W3S03-Basic-Variables.pillar
>
> output:
> http://rmod-pharo-mooc.lille.inria.fr/MOOC/Slides/Week3/C019-W3S03-Basic-Variables.html#slide-2
>
> ( mooc.pharo.org )
>
> Peter
>
> On Tue, Aug 29, 2017 at 2:54 PM, H. Hirzel  wrote:
>>
>> Hello
>>
>> On the slide 14 of the Pillar presentation at ESUG 2015 [1] it says
>> that the presentation was made with Pillar. Is the Pillar source code
>> available somewhere?
>>
>> Other source code examples of presentations made with Pillar are fine as
>> well.
>>
>> Thank you
>>
>> Hannes Hirzel
>>
>>
>> [1]
>> http://esug.org/data/ESUG2015/4%20thursday/1600-1630%20Pilar/Pillar.pdf
>>
>



Re: [Pharo-users] [Pillar] Pillar source code of ESUG 2015 presentation? Presentations done with Pillar?

2017-08-29 Thread Peter Uhnák
All Pharo Mooc slides were made in pillar

e.g.

pillar:
https://github.com/SquareBracketAssociates/PharoMooc/blob/master/Slides/Week3/C019-W3S03-Basic-Variables.pillar

output:
http://rmod-pharo-mooc.lille.inria.fr/MOOC/Slides/Week3/C019-W3S03-Basic-Variables.html#slide-2

( mooc.pharo.org )

Peter

On Tue, Aug 29, 2017 at 2:54 PM, H. Hirzel  wrote:

> Hello
>
> On the slide 14 of the Pillar presentation at ESUG 2015 [1] it says
> that the presentation was made with Pillar. Is the Pillar source code
> available somewhere?
>
> Other source code examples of presentations made with Pillar are fine as
> well.
>
> Thank you
>
> Hannes Hirzel
>
>
> [1] http://esug.org/data/ESUG2015/4%20thursday/1600-1630%
> 20Pilar/Pillar.pdf
>
>


[Pharo-users] [Pillar] Pillar source code of ESUG 2015 presentation? Presentations done with Pillar?

2017-08-29 Thread H. Hirzel
Hello

On the slide 14 of the Pillar presentation at ESUG 2015 [1] it says
that the presentation was made with Pillar. Is the Pillar source code
available somewhere?

Other source code examples of presentations made with Pillar are fine as well.

Thank you

Hannes Hirzel


[1] http://esug.org/data/ESUG2015/4%20thursday/1600-1630%20Pilar/Pillar.pdf



Re: [Pharo-users] [Pillar] How do I open the Pillar editor in Pharo 6?

2017-08-29 Thread H. Hirzel
On 8/28/17, Norbert Hartl  wrote:
>
>> Am 26.08.2017 um 12:56 schrieb Tudor Girba :
>>
>> In an image having Pillar, inspect a Pillar file. Something like this:
>>
>> ‘path/to/file.pillar' asFileReference
>>
> I downloaded a 6.1 image, loaded pillar from catalog and inspected
>
> 'foo.pillar' asFileReference
>
> and I get
>

The same result here.

>
> Looks like there are additional steps needed.
>
> Norbert
>


If I do


PRPillarParser parse:
'myExample.pillar' asFileReference contents


I get a nice display of the Pillar Document Object Model and the
results after using different exporter objects (HTML, DeckJS,
Markdown, AsciiDoc, Beamer, LaTeX)

But no Pillar editor.

--Hannes


Re: [Pharo-users] [Pillar] How do I include a picture which I get from aMorph imageFrom?

2017-08-28 Thread H. Hirzel
The answer (second option by writing the image to disk) is

| myMorph myForm myPillarSource myPillarDOM |

myMorph := AlignmentMorph newRow
   addMorph: (EllipseMorph new color: Color red);
   addMorph: (EllipseMorph new color: Color yellow);
   addMorph: (EllipseMorph new color: Color green);
   openInWorld.

myForm := myMorph imageForm.
myMorph delete.

PNGReadWriter
putForm: myForm
onFileNamed: 'myImage.png'.



myPillarSource := '

!The title
Lorem ipsum dolor sit amet, consectetur adipiscing elit, sed do
eiusmod tempor incididunt ut labore et dolore magna aliqua. Ut enim ad
minim veniam, quis nostrud exercitation ullamco laboris nisi ut
aliquip ex ea commodo consequat. Duis aute irure dolor in
reprehenderit in voluptate velit esse cillum dolore eu fugiat nulla
pariatur.

+The caption of my image>file://myImage.png|label=myLabel+

Excepteur sint occaecat cupidatat non proident, sunt in culpa qui
officia deserunt mollit anim id est laborum.
'.


myPillarDOM :=   PRPillarParser parse: myPillarSource.


(PRHTMLWriter write: myPillarDOM) contents inspect





HH.


On 8/28/17, H. Hirzel  wrote:
> Hello
>
> Is it possible to include a in-image picture in Pillar which I get by
> evaluating
>
> myMorph imageForm?
>
> Or do I need to write the instance of Form I get by evaluating the
> expression above first as a PNG file to disk and get it from there.
>
>
> PNGReadWriter
>   putForm: myMorph imageForm
>   onFileNamed: aString
>
> If yes what is the default directory where does Pillar expects pictures --
>
>
> The Pillar cheat sheet [1] and the Pillar chapter in the Pharo
> enterprise book no 3 [2] have an example
>
> +Caption>file://image.png|width=50|label=label+
>
>
> Regards
>
> Hannes
>
>
>
> [1]
> http://pillarhub.pharocloud.com/hub/pillarhub/pillarcheatsheet
>
> [2] Section 3.8 of
> https://ci.inria.fr/pharo-contribution/job/EnterprisePharoBook/lastSuccessfulBuild/artifact/book-result/PillarChap/Pillar.html
>



[Pharo-users] [Pillar] How do I include a picture which I get from aMorph imageFrom?

2017-08-28 Thread H. Hirzel
Hello

Is it possible to include a in-image picture in Pillar which I get by evaluating

myMorph imageForm?

Or do I need to write the instance of Form I get by evaluating the
expression above first as a PNG file to disk and get it from there.


PNGReadWriter
putForm: myMorph imageForm
onFileNamed: aString

If yes what is the default directory where does Pillar expects pictures --


The Pillar cheat sheet [1] and the Pillar chapter in the Pharo
enterprise book no 3 [2] have an example

+Caption>file://image.png|width=50|label=label+


Regards

Hannes



[1]
http://pillarhub.pharocloud.com/hub/pillarhub/pillarcheatsheet

[2] Section 3.8 of
https://ci.inria.fr/pharo-contribution/job/EnterprisePharoBook/lastSuccessfulBuild/artifact/book-result/PillarChap/Pillar.html



Re: [Pharo-users] [Pillar] How do I open the Pillar editor in Pharo 6?

2017-08-28 Thread Norbert Hartl

> Am 26.08.2017 um 12:56 schrieb Tudor Girba :
> 
> In an image having Pillar, inspect a Pillar file. Something like this:
> 
> ‘path/to/file.pillar' asFileReference
> 
I downloaded a 6.1 image, loaded pillar from catalog and inspected

'foo.pillar' asFileReference

and I get



Looks like there are additional steps needed.

Norbert

> Cheers,
> Doru
> 
> 
>> On Aug 26, 2017, at 9:56 AM, H. Hirzel  wrote:
>> 
>> Hello Doru
>> 
>> On 8/26/17, Tudor Girba  wrote:
>>> Hi,
>>> 
>>> Just for information: Pillar already ships with a live editor with syntax
>>> highlighting that I built a couple of years ago.
>> 
>> Thank you for this information, Doru.
>> 
>> Earlier this week I was looking for a "Pillar tool" in Pharo 6 and was
>> told, that there is none.
>> I did not find a link in the help system nor a menu entry in the world menu.
>> 
>> How do I get at this live editor?
>> 
>>> And there are two inspector presentations available:
>>> - If you inspect a class, you will get a Pillar comment presentation with
>>> syntax highlighting
>>> - If you inspect a .pillar file, you will get a Pillar editor with syntax
>>> highlighting
>>> 
>>> Cheers,
>>> Doru
>>> 
>> 
>> 
>> Regards
>> Hannes
> 
> --
> www.tudorgirba.com
> www.feenk.com
> 
> "Quality cannot be an afterthought."



Re: [Pharo-users] pillar image in external link (or html a tag)

2017-08-27 Thread Peter Uhnák
I did a pass on the Markdown exporter to align it with CommonMark
specifications, so it is exporter properly if I instantiate the objects.

But Pillar also needs to parse the string properly.

On Sun, Aug 27, 2017 at 8:28 PM, Stephane Ducasse 
wrote:

> Hi peter
>
> I do not think you can. I learned this features friday while writing
> md text to point to travis.
> This is something that we will able to add but for now my focus is not
> there.
> Stef
>
> On Sat, Aug 26, 2017 at 10:41 PM, Peter Uhnák  wrote:
> > Hi,
> >
> > how can I embed an image into an anchor in Pillar?
> >
> > I've tried
> >
> > *+Pharo>https://pharo.org/web/files/pharo.png+>http://pharo.org/*
> >
> > I've also tried to create document by hand and export it, but every
> single
> > exporter failed on it.
> >
> > doc := PRDocument new
> > add: (PRExternalLink new
> > reference: 'http://pharo.org/';
> > add: (PRFigure new
> > reference: 'https://pharo.org/web/files/pharo.png';
> > add: (PRText content: 'Pharo');
> > yourself
> > );
> > yourself
> > );
> > yourself
> >
> > Thanks,
> > Peter
>
>


Re: [Pharo-users] pillar image in external link (or html a tag)

2017-08-27 Thread Stephane Ducasse
Hi peter

I do not think you can. I learned this features friday while writing
md text to point to travis.
This is something that we will able to add but for now my focus is not there.
Stef

On Sat, Aug 26, 2017 at 10:41 PM, Peter Uhnák  wrote:
> Hi,
>
> how can I embed an image into an anchor in Pillar?
>
> I've tried
>
> *+Pharo>https://pharo.org/web/files/pharo.png+>http://pharo.org/*
>
> I've also tried to create document by hand and export it, but every single
> exporter failed on it.
>
> doc := PRDocument new
> add: (PRExternalLink new
> reference: 'http://pharo.org/';
> add: (PRFigure new
> reference: 'https://pharo.org/web/files/pharo.png';
> add: (PRText content: 'Pharo');
> yourself
> );
> yourself
> );
> yourself
>
> Thanks,
> Peter



[Pharo-users] pillar image in external link (or html a tag)

2017-08-26 Thread Peter Uhnák
Hi,

how can I embed an image into an anchor in Pillar?

I've tried

*+Pharo>https://pharo.org/web/files/pharo.png+>http://pharo.org/*

I've also tried to create document by hand and export it, but every single
exporter failed on it.

doc := PRDocument new
add: (PRExternalLink new
reference: 'http://pharo.org/';
add: (PRFigure new
reference: 'https://pharo.org/web/files/pharo.png';
add: (PRText content: 'Pharo');
yourself
);
yourself
);
yourself

Thanks,
Peter


Re: [Pharo-users] [Pillar] How do I open the Pillar editor in Pharo 6?

2017-08-26 Thread Tudor Girba
In an image having Pillar, inspect a Pillar file. Something like this:

‘path/to/file.pillar' asFileReference

Cheers,
Doru


> On Aug 26, 2017, at 9:56 AM, H. Hirzel  wrote:
> 
> Hello Doru
> 
> On 8/26/17, Tudor Girba  wrote:
>> Hi,
>> 
>> Just for information: Pillar already ships with a live editor with syntax
>> highlighting that I built a couple of years ago.
> 
> Thank you for this information, Doru.
> 
> Earlier this week I was looking for a "Pillar tool" in Pharo 6 and was
> told, that there is none.
> I did not find a link in the help system nor a menu entry in the world menu.
> 
> How do I get at this live editor?
> 
>> And there are two inspector presentations available:
>> - If you inspect a class, you will get a Pillar comment presentation with
>> syntax highlighting
>> - If you inspect a .pillar file, you will get a Pillar editor with syntax
>> highlighting
>> 
>> Cheers,
>> Doru
>> 
> 
> 
> Regards
> Hannes

--
www.tudorgirba.com
www.feenk.com

"Quality cannot be an afterthought."




[Pharo-users] [Pillar] How do I open the Pillar editor in Pharo 6?

2017-08-26 Thread H. Hirzel
Hello Doru

On 8/26/17, Tudor Girba  wrote:
> Hi,
>
> Just for information: Pillar already ships with a live editor with syntax
> highlighting that I built a couple of years ago.

Thank you for this information, Doru.

Earlier this week I was looking for a "Pillar tool" in Pharo 6 and was
told, that there is none.
I did not find a link in the help system nor a menu entry in the world menu.

How do I get at this live editor?

> And there are two inspector presentations available:
> - If you inspect a class, you will get a Pillar comment presentation with
> syntax highlighting
> - If you inspect a .pillar file, you will get a Pillar editor with syntax
> highlighting
>
> Cheers,
> Doru
>


Regards
Hannes



Re: [Pharo-users] [Pillar] Installed the Pillar document preparation system into 6.1, how do I start using it?

2017-08-25 Thread Tudor Girba
On Aug 25, 2017, at 8:53 AM, Norbert Hartl  wrote:
> 
> 
>> Am 24.08.2017 um 22:34 schrieb Stephane Ducasse :
>> 
>> In Pharo 60 (and not in Pharo 50) I extracted the command line logic
>> into a specific object so that we do not have to be bound to use the
>> command line. You can have a look in the CLI package.
>> 
>> This is good that there is Section 7 this in the doc. We started to
>> build a simple Morphic renderer for Pillar.
>> We should continue. If someone wants to have fun. This would be nice
>> to have see it coming to live.
>> 
> A morphic renderer? Wouldn't it be fun to do one for bloc? I think we should 
> slowly collect some tools that use bloc in order to get the tension making it 
> the "default" thingie.

On its way :)

Doru


>> On my todo: I also want to use mustache inside Pharo and not
>> generating files on the disk.
>> 
> That should be doable by deleting some code.
> 
> Norbert
> 
>> Stef
>> 
>> On Fri, Aug 18, 2017 at 10:08 PM, H. Hirzel  wrote:
>>> Exactly.
>>> 
>>> Section 7 of
>>> https://ci.inria.fr/pharo-contribution/job/EnterprisePharoBook/lastSuccessfulBuild/artifact/book-result/PillarChap/Pillar.html
>>> 
>>> has an example
>>> 
>>> 
>>>   | wiki |
>>>   wiki := '!My Document'.
>>>   PRPillarParser parse: wiki
>>> 
>>> 
>>> Or
>>> 
>>>   PRPillarParser parse: (FileSystem workingDirectory / 'foo.pillar')
>>> readStream
>>> 
>>> 
>>> and then
>>> 
>>> 
>>>   PRHTMLWriter write: document
>>> 
>>> 
>>> This put together gives
>>> 
>>>   PRHTMLWriter write: (
>>>   PRPillarParser parse: (FileSystem workingDirectory / 'welcome.pillar')
>>>   )
>>> 
>>> 
>>> If I inspect the result of this expression I get the HTML string.
>>> 
>>> Thank you Cyril. This is what I was looking for.
>>> 
>>> --Hannes
>>> 
>>> 
>>> 
>>> 
>>> On 8/18/17, Cyril Ferlicot  wrote:
 On ven. 18 août 2017 at 21:43, H. Hirzel  wrote:
 
> Thank you Cyril for the link to the tutorial.
> 
> 
> https://ci.inria.fr/pharo-contribution/job/EnterprisePharoBook/lastSuccessfulBuild/artifact/book-result/PillarChap/Pillar.html
> 
> I see that Pillar is a command line tool. The welcome example taken
> from this tutorial is:
> 
>   Pharo.exe Pillar.image pillar export --to=html
> --outputFile=welcome welcome.pillar
> 
> How can I run a command like this from within Pharo in a "playground"
> (former workspace)?
> 
> Later on I plan to construct a simple GUI with text boxes for Pillar
> sources and have some buttons executing these commands.
> 
> --Hannes
> 
> 
 
 I remember writing a part "Pillar from Pharo" in this doc. I'm not sure it
 is still up to date but you can try to check part 7 of the doc I sent.
 --
 Cyril Ferlicot
 https://ferlicot.fr
 
 http://www.synectique.eu
 2 rue Jacques Prévert 01,
 59650 Villeneuve d'ascq France
 
>>> 
> 

--
www.tudorgirba.com
www.feenk.com

"Problem solving efficiency grows with the abstractness level of problem 
understanding."







Re: [Pharo-users] [Pillar] Installed the Pillar document preparation system into 6.1, how do I start using it?

2017-08-25 Thread Norbert Hartl

> Am 24.08.2017 um 22:34 schrieb Stephane Ducasse :
> 
> In Pharo 60 (and not in Pharo 50) I extracted the command line logic
> into a specific object so that we do not have to be bound to use the
> command line. You can have a look in the CLI package.
> 
> This is good that there is Section 7 this in the doc. We started to
> build a simple Morphic renderer for Pillar.
> We should continue. If someone wants to have fun. This would be nice
> to have see it coming to live.
> 
A morphic renderer? Wouldn't it be fun to do one for bloc? I think we should 
slowly collect some tools that use bloc in order to get the tension making it 
the "default" thingie.

> On my todo: I also want to use mustache inside Pharo and not
> generating files on the disk.
> 
That should be doable by deleting some code.

Norbert

> Stef
> 
> On Fri, Aug 18, 2017 at 10:08 PM, H. Hirzel  wrote:
>> Exactly.
>> 
>> Section 7 of
>> https://ci.inria.fr/pharo-contribution/job/EnterprisePharoBook/lastSuccessfulBuild/artifact/book-result/PillarChap/Pillar.html
>> 
>> has an example
>> 
>> 
>>| wiki |
>>wiki := '!My Document'.
>>PRPillarParser parse: wiki
>> 
>> 
>> Or
>> 
>>PRPillarParser parse: (FileSystem workingDirectory / 'foo.pillar')
>> readStream
>> 
>> 
>> and then
>> 
>> 
>>PRHTMLWriter write: document
>> 
>> 
>> This put together gives
>> 
>>PRHTMLWriter write: (
>>PRPillarParser parse: (FileSystem workingDirectory / 'welcome.pillar')
>>)
>> 
>> 
>> If I inspect the result of this expression I get the HTML string.
>> 
>> Thank you Cyril. This is what I was looking for.
>> 
>> --Hannes
>> 
>> 
>> 
>> 
>> On 8/18/17, Cyril Ferlicot  wrote:
>>> On ven. 18 août 2017 at 21:43, H. Hirzel  wrote:
>>> 
 Thank you Cyril for the link to the tutorial.
 
 
 https://ci.inria.fr/pharo-contribution/job/EnterprisePharoBook/lastSuccessfulBuild/artifact/book-result/PillarChap/Pillar.html
 
 I see that Pillar is a command line tool. The welcome example taken
 from this tutorial is:
 
Pharo.exe Pillar.image pillar export --to=html
 --outputFile=welcome welcome.pillar
 
 How can I run a command like this from within Pharo in a "playground"
 (former workspace)?
 
 Later on I plan to construct a simple GUI with text boxes for Pillar
 sources and have some buttons executing these commands.
 
 --Hannes
 
 
>>> 
>>> I remember writing a part "Pillar from Pharo" in this doc. I'm not sure it
>>> is still up to date but you can try to check part 7 of the doc I sent.
>>> --
>>> Cyril Ferlicot
>>> https://ferlicot.fr
>>> 
>>> http://www.synectique.eu
>>> 2 rue Jacques Prévert 01,
>>> 59650 Villeneuve d'ascq France
>>> 
>> 



Re: [Pharo-users] [Pillar] Installed the Pillar document preparation system into 6.1, how do I start using it?

2017-08-24 Thread Stephane Ducasse
In Pharo 60 (and not in Pharo 50) I extracted the command line logic
into a specific object so that we do not have to be bound to use the
command line. You can have a look in the CLI package.

This is good that there is Section 7 this in the doc. We started to
build a simple Morphic renderer for Pillar.
We should continue. If someone wants to have fun. This would be nice
to have see it coming to live.

On my todo: I also want to use mustache inside Pharo and not
generating files on the disk.

Stef

On Fri, Aug 18, 2017 at 10:08 PM, H. Hirzel  wrote:
> Exactly.
>
> Section 7 of
> https://ci.inria.fr/pharo-contribution/job/EnterprisePharoBook/lastSuccessfulBuild/artifact/book-result/PillarChap/Pillar.html
>
> has an example
>
>
> | wiki |
> wiki := '!My Document'.
> PRPillarParser parse: wiki
>
>
> Or
>
> PRPillarParser parse: (FileSystem workingDirectory / 'foo.pillar')
> readStream
>
>
> and then
>
>
> PRHTMLWriter write: document
>
>
> This put together gives
>
> PRHTMLWriter write: (
> PRPillarParser parse: (FileSystem workingDirectory / 'welcome.pillar')
> )
>
>
> If I inspect the result of this expression I get the HTML string.
>
> Thank you Cyril. This is what I was looking for.
>
> --Hannes
>
>
>
>
> On 8/18/17, Cyril Ferlicot  wrote:
>> On ven. 18 août 2017 at 21:43, H. Hirzel  wrote:
>>
>>> Thank you Cyril for the link to the tutorial.
>>>
>>>
>>> https://ci.inria.fr/pharo-contribution/job/EnterprisePharoBook/lastSuccessfulBuild/artifact/book-result/PillarChap/Pillar.html
>>>
>>> I see that Pillar is a command line tool. The welcome example taken
>>> from this tutorial is:
>>>
>>> Pharo.exe Pillar.image pillar export --to=html
>>> --outputFile=welcome welcome.pillar
>>>
>>> How can I run a command like this from within Pharo in a "playground"
>>> (former workspace)?
>>>
>>> Later on I plan to construct a simple GUI with text boxes for Pillar
>>> sources and have some buttons executing these commands.
>>>
>>> --Hannes
>>>
>>>
>>
>> I remember writing a part "Pillar from Pharo" in this doc. I'm not sure it
>> is still up to date but you can try to check part 7 of the doc I sent.
>> --
>> Cyril Ferlicot
>> https://ferlicot.fr
>>
>> http://www.synectique.eu
>> 2 rue Jacques Prévert 01,
>> 59650 Villeneuve d'ascq France
>>
>



Re: [Pharo-users] [Pillar] Installed the Pillar document preparation system into 6.1, how do I start using it?

2017-08-24 Thread H. Hirzel
Fine, thank you, Stephane.

I have Pillar now installed in 6.1. And a PetitParser version which
supports YAML, but in a different 6.1 image.

One issue is that I can have both in the same image -

1) Pillar loaded through the catalog
2) a good recent PetitParser version

See also my email to Tudor Girba this morning

--Hannes


On 8/22/17, Stephane Ducasse  wrote:
> Yes we need input (but most importantly time). I will allocate time
> because Pillar is important for me.
>
> On Fri, Aug 18, 2017 at 10:18 PM, Cyril Ferlicot
>  wrote:
>>
>> On ven. 18 août 2017 at 22:09, H. Hirzel  wrote:
>>>
>>> Exactly.
>>>
>>> Section 7 of
>>>
>>> https://ci.inria.fr/pharo-contribution/job/EnterprisePharoBook/lastSuccessfulBuild/artifact/book-result/PillarChap/Pillar.html
>>>
>>> has an example
>>>
>>>
>>> | wiki |
>>> wiki := '!My Document'.
>>> PRPillarParser parse: wiki
>>>
>>>
>>> Or
>>>
>>> PRPillarParser parse: (FileSystem workingDirectory / 'foo.pillar')
>>> readStream
>>>
>>>
>>> and then
>>>
>>>
>>> PRHTMLWriter write: document
>>>
>>>
>>> This put together gives
>>>
>>> PRHTMLWriter write: (
>>> PRPillarParser parse: (FileSystem workingDirectory /
>>> 'welcome.pillar')
>>> )
>>>
>>>
>>> If I inspect the result of this expression I get the HTML string.
>>>
>>> Thank you Cyril. This is what I was looking for.
>>>
>>> --Hannes
>>
>>
>>
>> Happy to see it still works :)
>>
>> I know there was work on Pillar after I wrote this. Maybe there is some
>> functionalities that will need more than those simple examples. By I am
>> not
>> sure and I know that Stephane want to simplify it further.
>> --
>> Cyril Ferlicot
>> https://ferlicot.fr
>>
>> http://www.synectique.eu
>> 2 rue Jacques Prévert 01,
>> 59650 Villeneuve d'ascq France
>
>



Re: [Pharo-users] [Pillar] Installed the Pillar document preparation system into 6.1, how do I start using it?

2017-08-22 Thread Stephane Ducasse
Yes we need input (but most importantly time). I will allocate time
because Pillar is important for me.

On Fri, Aug 18, 2017 at 10:18 PM, Cyril Ferlicot
 wrote:
>
> On ven. 18 août 2017 at 22:09, H. Hirzel  wrote:
>>
>> Exactly.
>>
>> Section 7 of
>>
>> https://ci.inria.fr/pharo-contribution/job/EnterprisePharoBook/lastSuccessfulBuild/artifact/book-result/PillarChap/Pillar.html
>>
>> has an example
>>
>>
>> | wiki |
>> wiki := '!My Document'.
>> PRPillarParser parse: wiki
>>
>>
>> Or
>>
>> PRPillarParser parse: (FileSystem workingDirectory / 'foo.pillar')
>> readStream
>>
>>
>> and then
>>
>>
>> PRHTMLWriter write: document
>>
>>
>> This put together gives
>>
>> PRHTMLWriter write: (
>> PRPillarParser parse: (FileSystem workingDirectory /
>> 'welcome.pillar')
>> )
>>
>>
>> If I inspect the result of this expression I get the HTML string.
>>
>> Thank you Cyril. This is what I was looking for.
>>
>> --Hannes
>
>
>
> Happy to see it still works :)
>
> I know there was work on Pillar after I wrote this. Maybe there is some
> functionalities that will need more than those simple examples. By I am not
> sure and I know that Stephane want to simplify it further.
> --
> Cyril Ferlicot
> https://ferlicot.fr
>
> http://www.synectique.eu
> 2 rue Jacques Prévert 01,
> 59650 Villeneuve d'ascq France



Re: [Pharo-users] [Pillar] Installed the Pillar document preparation system into 6.1, how do I start using it?

2017-08-18 Thread Cyril Ferlicot
On ven. 18 août 2017 at 22:09, H. Hirzel  wrote:

> Exactly.
>
> Section 7 of
>
> https://ci.inria.fr/pharo-contribution/job/EnterprisePharoBook/lastSuccessfulBuild/artifact/book-result/PillarChap/Pillar.html
>
> has an example
>
>
> | wiki |
> wiki := '!My Document'.
> PRPillarParser parse: wiki
>
>
> Or
>
> PRPillarParser parse: (FileSystem workingDirectory / 'foo.pillar')
> readStream
>
>
> and then
>
>
> PRHTMLWriter write: document
>
>
> This put together gives
>
> PRHTMLWriter write: (
> PRPillarParser parse: (FileSystem workingDirectory /
> 'welcome.pillar')
> )
>
>
> If I inspect the result of this expression I get the HTML string.
>
> Thank you Cyril. This is what I was looking for.
>
> --Hannes
>


Happy to see it still works :)

I know there was work on Pillar after I wrote this. Maybe there is some
functionalities that will need more than those simple examples. By I am not
sure and I know that Stephane want to simplify it further.
-- 
Cyril Ferlicot
https://ferlicot.fr

http://www.synectique.eu
2 rue Jacques Prévert 01,
59650 Villeneuve d'ascq France


Re: [Pharo-users] [Pillar] Installed the Pillar document preparation system into 6.1, how do I start using it?

2017-08-18 Thread H. Hirzel
Exactly.

Section 7 of
https://ci.inria.fr/pharo-contribution/job/EnterprisePharoBook/lastSuccessfulBuild/artifact/book-result/PillarChap/Pillar.html

has an example


| wiki |
wiki := '!My Document'.
PRPillarParser parse: wiki


Or

PRPillarParser parse: (FileSystem workingDirectory / 'foo.pillar')
readStream


and then


PRHTMLWriter write: document


This put together gives

PRHTMLWriter write: (
PRPillarParser parse: (FileSystem workingDirectory / 'welcome.pillar')
)


If I inspect the result of this expression I get the HTML string.

Thank you Cyril. This is what I was looking for.

--Hannes




On 8/18/17, Cyril Ferlicot  wrote:
> On ven. 18 août 2017 at 21:43, H. Hirzel  wrote:
>
>> Thank you Cyril for the link to the tutorial.
>>
>>
>> https://ci.inria.fr/pharo-contribution/job/EnterprisePharoBook/lastSuccessfulBuild/artifact/book-result/PillarChap/Pillar.html
>>
>> I see that Pillar is a command line tool. The welcome example taken
>> from this tutorial is:
>>
>> Pharo.exe Pillar.image pillar export --to=html
>> --outputFile=welcome welcome.pillar
>>
>> How can I run a command like this from within Pharo in a "playground"
>> (former workspace)?
>>
>> Later on I plan to construct a simple GUI with text boxes for Pillar
>> sources and have some buttons executing these commands.
>>
>> --Hannes
>>
>>
>
> I remember writing a part "Pillar from Pharo" in this doc. I'm not sure it
> is still up to date but you can try to check part 7 of the doc I sent.
> --
> Cyril Ferlicot
> https://ferlicot.fr
>
> http://www.synectique.eu
> 2 rue Jacques Prévert 01,
> 59650 Villeneuve d'ascq France
>



Re: [Pharo-users] [Pillar] Installed the Pillar document preparation system into 6.1, how do I start using it?

2017-08-18 Thread Cyril Ferlicot
On ven. 18 août 2017 at 21:43, H. Hirzel  wrote:

> Thank you Cyril for the link to the tutorial.
>
>
> https://ci.inria.fr/pharo-contribution/job/EnterprisePharoBook/lastSuccessfulBuild/artifact/book-result/PillarChap/Pillar.html
>
> I see that Pillar is a command line tool. The welcome example taken
> from this tutorial is:
>
> Pharo.exe Pillar.image pillar export --to=html
> --outputFile=welcome welcome.pillar
>
> How can I run a command like this from within Pharo in a "playground"
> (former workspace)?
>
> Later on I plan to construct a simple GUI with text boxes for Pillar
> sources and have some buttons executing these commands.
>
> --Hannes
>
>

I remember writing a part "Pillar from Pharo" in this doc. I'm not sure it
is still up to date but you can try to check part 7 of the doc I sent.
-- 
Cyril Ferlicot
https://ferlicot.fr

http://www.synectique.eu
2 rue Jacques Prévert 01,
59650 Villeneuve d'ascq France


Re: [Pharo-users] [Pillar] Installed the Pillar document preparation system into 6.1, how do I start using it?

2017-08-18 Thread H. Hirzel
Thank you Cyril for the link to the tutorial.


https://ci.inria.fr/pharo-contribution/job/EnterprisePharoBook/lastSuccessfulBuild/artifact/book-result/PillarChap/Pillar.html

I see that Pillar is a command line tool. The welcome example taken
from this tutorial is:

Pharo.exe Pillar.image pillar export --to=html
--outputFile=welcome welcome.pillar

How can I run a command like this from within Pharo in a "playground"
(former workspace)?

Later on I plan to construct a simple GUI with text boxes for Pillar
sources and have some buttons executing these commands.

--Hannes



On 8/18/17, Cyril Ferlicot  wrote:
> On ven. 18 août 2017 at 19:44, H. Hirzel  wrote:
>
>> Hello
>>
>> I installed Pillar through the catalog into Pharo 6.1, I assume.
>>
>> I had a look into the Help browser to find some documentation or a
>> link to the documentation.
>>
>> I did not find a menu entry in the world menu to open the tool.
>>
>> How do I start using the tool?
>>
>> --Hannes
>>
>> Hi,
>
> I did not check if it is up to date but there is a tutorial here:
>
> https://ci.inria.fr/pharo-contribution/job/EnterprisePharoBook/lastSuccessfulBuild/artifact/book-result/PillarChap/Pillar.html
>
> I hope this can help you to begin.
>
> There is no tool actually to use Pillar, you write your files and then
> there is command lines to generate the output wanted.
> --
> Cyril Ferlicot
> https://ferlicot.fr
>
> http://www.synectique.eu
> 2 rue Jacques Prévert 01,
> 59650 Villeneuve d'ascq France
>



Re: [Pharo-users] [Pillar] Installed the Pillar document preparation system into 6.1, how do I start using it?

2017-08-18 Thread Cyril Ferlicot
On ven. 18 août 2017 at 19:44, H. Hirzel  wrote:

> Hello
>
> I installed Pillar through the catalog into Pharo 6.1, I assume.
>
> I had a look into the Help browser to find some documentation or a
> link to the documentation.
>
> I did not find a menu entry in the world menu to open the tool.
>
> How do I start using the tool?
>
> --Hannes
>
> Hi,

I did not check if it is up to date but there is a tutorial here:

https://ci.inria.fr/pharo-contribution/job/EnterprisePharoBook/lastSuccessfulBuild/artifact/book-result/PillarChap/Pillar.html

I hope this can help you to begin.

There is no tool actually to use Pillar, you write your files and then
there is command lines to generate the output wanted.
-- 
Cyril Ferlicot
https://ferlicot.fr

http://www.synectique.eu
2 rue Jacques Prévert 01,
59650 Villeneuve d'ascq France


[Pharo-users] [Pillar] Installed the Pillar document preparation system into 6.1, how do I start using it?

2017-08-18 Thread H. Hirzel
Hello

I installed Pillar through the catalog into Pharo 6.1, I assume.

I had a look into the Help browser to find some documentation or a
link to the documentation.

I did not find a menu entry in the world menu to open the tool.

How do I start using the tool?

--Hannes



[Pharo-users] [Pillar dev news] cleaned commandline logic

2017-03-12 Thread stepharong

Hi

I started a new branch for Pharo 60.

Past actions for this branch are:

- clean and document the commandline logic and API in 4.0.11
- extract an object from the commandLine logic so that we can now invoke
the logic without having to do it from the image.

Next actions:
	- avoid as much as possible to use DNU trick combined with magritte  
description for CocoonConfigurations
	may be one idea is to have a configuration without Magritte and a  
subclass with.

Also a configuration does not have to have per se file support
	Should check in the future the stylesheet of artefact and extract a  
common property collection with lookup

little framework.

	- fix problem with some classes trashing printOn: (super cool for  
debugging) and testing.


- start to remove the metadata section (far too complex).

Stef



[Pharo-users] [Pillar] Free beginners guide to Latex

2017-02-24 Thread Dimitris Chloupis
Pillar is the official documentation system of Pharo. It uses syntax
similar to markdown which make it simple and easy to learn. However Pillars
power and flexibility goes far beyond that because it leverages Latex ,
epecially for generating PDFs ( every PDF you have seen read for Pharo uses
Latex and Pillar, except a few that use only Latex) or using advanced
features like math notations , more precise image locations etc.

However can be tricky to learn, Packt publishing is a website that sells
online ebooks and videos , they also offer a free ebook each day. Today
they offer a free beginner guide for Latex. Offer expires in 9 hours and 45
minutes, so get it now that is free.

https://www.packtpub.com/packt/offers/free-learning


Re: [Pharo-users] Pillar book makefile or template is broken.

2016-10-09 Thread Damien Pollet
On 9 October 2016 at 21:52, stepharo  wrote:

> I did a clean install. So I imagine that it should break on other machines
> too.


Might be that pillar archetype doesn't do a git clone but some kind of
archive extraction… I know github and zip files have limitations with that


Re: [Pharo-users] Pillar book makefile or template is broken.

2016-10-09 Thread stepharo

Ok thanks!

I will try tomorrow.


Stef


Le 9/10/16 à 21:29, Damien Pollet a écrit :


On 9 October 2016 at 20:03, stepharo > wrote:


I tried to add a title to a book

{
  "title":"Learning Programming with Pharo",


I think I tried with { "metadata": { "title": "bleb" } } in the 
book.pillar and that worked. No clue why the one from the conf is not 
inherited anymore.




Re: [Pharo-users] Pillar book makefile or template is broken.

2016-10-09 Thread stepharo



Le 9/10/16 à 21:23, Damien Pollet a écrit :


On 9 October 2016 at 19:47, stepharo > wrote:


- chmod +x support/latex/sbabook/gitinfo2.sh

Now I have no idea where I should add this command.


That should be versioned as part of sbabook. On my machine when I 
check it out it's executable, and apparently it's harder to make git 
ignore file modes than to have it follow them, so I don't know what's 
wrong.


no idea.
I did a clean install. So I imagine that it should break on other 
machines too.




Re: [Pharo-users] Pillar book makefile or template is broken.

2016-10-09 Thread Damien Pollet
On 9 October 2016 at 20:03, stepharo  wrote:

> I tried to add a title to a book
>
> {
>   "title":"Learning Programming with Pharo",
>

I think I tried with { "metadata": { "title": "bleb" } } in the book.pillar
and that worked. No clue why the one from the conf is not inherited anymore.


Re: [Pharo-users] Pillar book makefile or template is broken.

2016-10-09 Thread stepharo

Hi doru

Hi Stef,

I started from the Pharo image and now we have an editor that is working 
reasonably well inside Pharo. I will send more details shortly.

Cool

This means that I do not have to edit the book somewhere else, and this also 
means that I can run the generation from inside Pharo, too.

Nice.

So, the next step is to trigger the visitors to generate the book from within 
Pharo without relying on the command line. If we can manage that,
I think that we should extract the commandline code into a separated 
object.
I wanted to do that but I decided that I'm not allowed to start 
something new now.
I wanted to generated also all the magritte black magic accessors so 
that we do not rely on DNU.

  my guess is that the command line related logic will become simpler and more 
debuggable.
I wanted to replace some unix commands by some pharo code snippet 
(because I can debug FileReference)
but same reason as above (finish first three tasks before starting a new 
one).


Stef


Cheers,
Doru




On Oct 9, 2016, at 8:03 PM, stepharo  wrote:

I tried to add a title to a book

{
  "title":"Learning Programming with Pharo",
  "newLine":#unix,
  "configurations": {
"LaTeX" : {
  "outputType":#'latex:sbabook',
  "separateOutputFiles":true
},
"HTML" : {
  "outputType":#html,
  "separateOutputFiles":true
}
  }
}

did not work :(

{
  "title":"Learning Programming with Pharo"
}

!!Compilation

${inputFile:Chapters/Chapter1/chapter1.pillar}$

!!Edition and Templates

${inputFile:Chapters/Chapter2/chapter2.pillar}$

+>figures/pharo.png|width=30+
+>figures/rmod.png|width=30+

did not work :(

No idea how to debug i t sadly.

Stef


Le 9/10/16 à 19:42, stepharo a écrit :

Hi

Is there anybody maintaining Pillar?


I did

wget https://raw.githubusercontent.com/pillar-markup/pillar/master/download.sh

chmod +x download.sh

./download.sh

./pillar archetype book

ogrammingArchetype make pdf
git submodule update --init --recursive
mkdir -p ./build
ln -fs ../support ./build
support/latex/sbabook/gitinfo2.sh > build/gitHeadLocal.gin
/bin/sh: support/latex/sbabook/gitinfo2.sh: Permission denied
make: *** [build/gitHeadLocal.gin] Error 126


I have no idea how to fix it.

in the past I removed this git version script because it was going in my way.

Stef






--
www.tudorgirba.com
www.feenk.com

"Problem solving efficiency grows with the abstractness level of problem 
understanding."











Re: [Pharo-users] Pillar book makefile or template is broken.

2016-10-09 Thread Damien Pollet
On 9 October 2016 at 19:47, stepharo  wrote:

> - chmod +x support/latex/sbabook/gitinfo2.sh
>
> Now I have no idea where I should add this command.
>

That should be versioned as part of sbabook. On my machine when I check it
out it's executable, and apparently it's harder to make git ignore file
modes than to have it follow them, so I don't know what's wrong.


Re: [Pharo-users] Pillar book makefile or template is broken.

2016-10-09 Thread Tudor Girba
Hi Stef,

I started from the Pharo image and now we have an editor that is working 
reasonably well inside Pharo. I will send more details shortly.

This means that I do not have to edit the book somewhere else, and this also 
means that I can run the generation from inside Pharo, too. 

So, the next step is to trigger the visitors to generate the book from within 
Pharo without relying on the command line. If we can manage that, my guess is 
that the command line related logic will become simpler and more debuggable.

Cheers,
Doru



> On Oct 9, 2016, at 8:03 PM, stepharo  wrote:
> 
> I tried to add a title to a book
> 
> {
>  "title":"Learning Programming with Pharo",
>  "newLine":#unix,
>  "configurations": {
>"LaTeX" : {
>  "outputType":#'latex:sbabook',
>  "separateOutputFiles":true
>},
>"HTML" : {
>  "outputType":#html,
>  "separateOutputFiles":true
>}
>  }
> }
> 
> did not work :(
> 
> {
>  "title":"Learning Programming with Pharo"
> }
> 
> !!Compilation
> 
> ${inputFile:Chapters/Chapter1/chapter1.pillar}$
> 
> !!Edition and Templates
> 
> ${inputFile:Chapters/Chapter2/chapter2.pillar}$
> 
> +>figures/pharo.png|width=30+
> +>figures/rmod.png|width=30+
> 
> did not work :(
> 
> No idea how to debug i t sadly.
> 
> Stef
> 
> 
> Le 9/10/16 à 19:42, stepharo a écrit :
>> Hi
>> 
>> Is there anybody maintaining Pillar?
>> 
>> 
>> I did
>> 
>> wget 
>> https://raw.githubusercontent.com/pillar-markup/pillar/master/download.sh
>> 
>> chmod +x download.sh
>> 
>> ./download.sh
>> 
>> ./pillar archetype book
>> 
>> ogrammingArchetype make pdf
>> git submodule update --init --recursive
>> mkdir -p ./build
>> ln -fs ../support ./build
>> support/latex/sbabook/gitinfo2.sh > build/gitHeadLocal.gin
>> /bin/sh: support/latex/sbabook/gitinfo2.sh: Permission denied
>> make: *** [build/gitHeadLocal.gin] Error 126
>> 
>> 
>> I have no idea how to fix it.
>> 
>> in the past I removed this git version script because it was going in my way.
>> 
>> Stef
>> 
>> 
>> 
> 
> 

--
www.tudorgirba.com
www.feenk.com

"Problem solving efficiency grows with the abstractness level of problem 
understanding."







Re: [Pharo-users] Pillar book makefile or template is broken.

2016-10-09 Thread stepharo

I tried to add a title to a book

{
  "title":"Learning Programming with Pharo",
  "newLine":#unix,
  "configurations": {
"LaTeX" : {
  "outputType":#'latex:sbabook',
  "separateOutputFiles":true
},
"HTML" : {
  "outputType":#html,
  "separateOutputFiles":true
}
  }
}

did not work :(

{
  "title":"Learning Programming with Pharo"
}

!!Compilation

${inputFile:Chapters/Chapter1/chapter1.pillar}$

!!Edition and Templates

${inputFile:Chapters/Chapter2/chapter2.pillar}$

+>figures/pharo.png|width=30+
+>figures/rmod.png|width=30+

did not work :(

No idea how to debug i t sadly.

Stef


Le 9/10/16 à 19:42, stepharo a écrit :

Hi

Is there anybody maintaining Pillar?


I did

wget 
https://raw.githubusercontent.com/pillar-markup/pillar/master/download.sh


 chmod +x download.sh

./download.sh

./pillar archetype book

ogrammingArchetype make pdf
git submodule update --init --recursive
mkdir -p ./build
ln -fs ../support ./build
support/latex/sbabook/gitinfo2.sh > build/gitHeadLocal.gin
/bin/sh: support/latex/sbabook/gitinfo2.sh: Permission denied
make: *** [build/gitHeadLocal.gin] Error 126


I have no idea how to fix it.

in the past I removed this git version script because it was going in 
my way.


Stef








Re: [Pharo-users] Pillar book makefile or template is broken.

2016-10-09 Thread stepharo

Are the files in Chapters automatically added to the pillar.conf?

Because the pillar.conf

is just

{
  "title":"Book title",
  "newLine":#unix,
  "configurations": {
"LaTeX" : {
  "outputType":#'latex:sbabook',
  "separateOutputFiles":true
},
"HTML" : {
  "outputType":#html,
  "separateOutputFiles":true
}
  }
}

Does it mean that all the files should be always compiling?

Stef


Le 9/10/16 à 19:42, stepharo a écrit :

Hi

Is there anybody maintaining Pillar?


I did

wget 
https://raw.githubusercontent.com/pillar-markup/pillar/master/download.sh


 chmod +x download.sh

./download.sh

./pillar archetype book

ogrammingArchetype make pdf
git submodule update --init --recursive
mkdir -p ./build
ln -fs ../support ./build
support/latex/sbabook/gitinfo2.sh > build/gitHeadLocal.gin
/bin/sh: support/latex/sbabook/gitinfo2.sh: Permission denied
make: *** [build/gitHeadLocal.gin] Error 126


I have no idea how to fix it.

in the past I removed this git version script because it was going in 
my way.


Stef








Re: [Pharo-users] Pillar book makefile or template is broken.

2016-10-09 Thread stepharo


- chmod +x support/latex/sbabook/gitinfo2.sh

Now I have no idea where I should add this command.

Then how can I modify the makefile and version it in my version of the 
book ?


Should I just add Makefile to my git repo?

Stef


Le 9/10/16 à 19:42, stepharo a écrit :

Hi

Is there anybody maintaining Pillar?


I did

wget 
https://raw.githubusercontent.com/pillar-markup/pillar/master/download.sh


 chmod +x download.sh

./download.sh

./pillar archetype book

ogrammingArchetype make pdf
git submodule update --init --recursive
mkdir -p ./build
ln -fs ../support ./build
support/latex/sbabook/gitinfo2.sh > build/gitHeadLocal.gin
/bin/sh: support/latex/sbabook/gitinfo2.sh: Permission denied
make: *** [build/gitHeadLocal.gin] Error 126


I have no idea how to fix it.

in the past I removed this git version script because it was going in 
my way.


Stef








[Pharo-users] Pillar book makefile or template is broken.

2016-10-09 Thread stepharo

Hi

Is there anybody maintaining Pillar?


I did

wget 
https://raw.githubusercontent.com/pillar-markup/pillar/master/download.sh


 chmod +x download.sh

./download.sh

./pillar archetype book

ogrammingArchetype make pdf
git submodule update --init --recursive
mkdir -p ./build
ln -fs ../support ./build
support/latex/sbabook/gitinfo2.sh > build/gitHeadLocal.gin
/bin/sh: support/latex/sbabook/gitinfo2.sh: Permission denied
make: *** [build/gitHeadLocal.gin] Error 126


I have no idea how to fix it.

in the past I removed this git version script because it was going in my 
way.


Stef




Re: [Pharo-users] pillar: how to link to different parts?

2016-09-30 Thread Tudor Girba
Thanks!

Cheers,
Doru


> On Sep 30, 2016, at 8:54 PM, Johan Fabry  wrote:
> 
> 
> Yes, we do this in the Enterprise Pharo book.
> 
> For example there is a link to NeoJSON in the STON chapter 
> https://ci.inria.fr/pharo-contribution/job/EnterprisePharoBook/lastSuccessfulBuild/artifact/book-result/STON/STON.html
> 
> --
> Does this mail seem too brief? Sorry for that, I don’t mean to be rude! 
> Please see http://emailcharter.org .
> 
> Johan Fabry   -   http://pleiad.cl/~jfabry
> PLEIAD and RyCh labs  -  Computer Science Department (DCC)  -  University of 
> Chile
> 
>> On Sep 30, 2016, at 15:45, Tudor Girba  wrote:
>> 
>> Hi,
>> 
>> I am playing with Pillar, and I am now would like to link different chapters 
>> to one another. For example, in the old Pier book support, we could write 
>> something like:
>> 
>>  *ref:../anotherchapter/section*
>> 
>> and this would result in a rendering like:
>>  
>>   Section 15.3 (with a link)
>> 
>> Is there a support already in place for this in Pillar?
>> 
>> Cheers,
>> Doru
>> 
>> 
>> --
>> www.tudorgirba.com
>> www.feenk.com
>> 
>> "Every successful trip needs a suitable vehicle."
>> 
>> 
>> 
>> 
>> 
>> 
>> 
> 
> 

--
www.tudorgirba.com
www.feenk.com

"Yesterday is a fact.
 Tomorrow is a possibility.
 Today is a challenge."







Re: [Pharo-users] pillar: how to link to different parts?

2016-09-30 Thread Johan Fabry

Yes, we do this in the Enterprise Pharo book.

For example there is a link to NeoJSON in the STON chapter 
https://ci.inria.fr/pharo-contribution/job/EnterprisePharoBook/lastSuccessfulBuild/artifact/book-result/STON/STON.html

--
Does this mail seem too brief? Sorry for that, I don’t mean to be rude! Please 
see http://emailcharter.org .

Johan Fabry   -   http://pleiad.cl/~jfabry
PLEIAD and RyCh labs  -  Computer Science Department (DCC)  -  University of 
Chile

> On Sep 30, 2016, at 15:45, Tudor Girba  wrote:
> 
> Hi,
> 
> I am playing with Pillar, and I am now would like to link different chapters 
> to one another. For example, in the old Pier book support, we could write 
> something like:
> 
>   *ref:../anotherchapter/section*
> 
> and this would result in a rendering like:
>   
>Section 15.3 (with a link)
> 
> Is there a support already in place for this in Pillar?
> 
> Cheers,
> Doru
> 
> 
> --
> www.tudorgirba.com
> www.feenk.com
> 
> "Every successful trip needs a suitable vehicle."
> 
> 
> 
> 
> 
> 
> 




[Pharo-users] pillar: how to link to different parts?

2016-09-30 Thread Tudor Girba
Hi,

I am playing with Pillar, and I am now would like to link different chapters to 
one another. For example, in the old Pier book support, we could write 
something like:

*ref:../anotherchapter/section*

and this would result in a rendering like:

 Section 15.3 (with a link)

Is there a support already in place for this in Pillar?

Cheers,
Doru


--
www.tudorgirba.com
www.feenk.com

"Every successful trip needs a suitable vehicle."








Re: [Pharo-users] pillar questions

2016-09-15 Thread Damien Pollet
I've been cleaning the book archetype's makefile this afternoon. I suspect
there is no list of chapters because the example is quite minimal.
Enterprise Pharo was the one Thibault and Yann worked with, so I need to
compare with it.

The recent work on pillar was about removing superfluous responsabilities
and moving it towards a simpler markup renderer. Chapter numbering is a
global information, which is OK in LaTeX because it can be computed by TeX
during its compilation pass; however HTML chapters are just generated one
for one following the pillar files.

On 15 September 2016 at 15:09, Serge Stinckwich 
wrote:

> Maybe you should have a look to Enterprise Pharo book pillar template ?
> https://github.com/SquareBracketAssociates/EnterprisePharo
>
> But apparently I'm not able to compile last version ...
> make book fails
>
>
>
> On Thu, Sep 15, 2016 at 2:06 PM, Tudor Girba  wrote:
> > Hi,
> >
> > I see that in the new book template, we have both a book.pillar that
> includes the chapter files, and a pillar.conf that is mostly empty. Is
> pillar.conf still used? If yes, what should it contain?
> >
> > If I embed the chapters in a book.pillar and I render the whole book,
> the numbering of the second chapter starts from 1 (instead of 2) when I
> render in html. Any idea how to do it differently?
> >
> > Cheers,
> > Doru
> >
> >
> > --
> > www.tudorgirba.com
> > www.feenk.com
> >
> > "Yesterday is a fact.
> >  Tomorrow is a possibility.
> >  Today is a challenge."
> >
> >
> >
> >
> >
>
>
>
> --
> Serge Stinckwich
> UCBN & UMI UMMISCO 209 (IRD/UPMC)
> Every DSL ends up being Smalltalk
> http://www.doesnotunderstand.org/
>
>


Re: [Pharo-users] pillar questions

2016-09-15 Thread Serge Stinckwich
Maybe you should have a look to Enterprise Pharo book pillar template ?
https://github.com/SquareBracketAssociates/EnterprisePharo

But apparently I'm not able to compile last version ...
make book fails



On Thu, Sep 15, 2016 at 2:06 PM, Tudor Girba  wrote:
> Hi,
>
> I see that in the new book template, we have both a book.pillar that includes 
> the chapter files, and a pillar.conf that is mostly empty. Is pillar.conf 
> still used? If yes, what should it contain?
>
> If I embed the chapters in a book.pillar and I render the whole book, the 
> numbering of the second chapter starts from 1 (instead of 2) when I render in 
> html. Any idea how to do it differently?
>
> Cheers,
> Doru
>
>
> --
> www.tudorgirba.com
> www.feenk.com
>
> "Yesterday is a fact.
>  Tomorrow is a possibility.
>  Today is a challenge."
>
>
>
>
>



-- 
Serge Stinckwich
UCBN & UMI UMMISCO 209 (IRD/UPMC)
Every DSL ends up being Smalltalk
http://www.doesnotunderstand.org/



[Pharo-users] pillar questions

2016-09-15 Thread Tudor Girba
Hi,

I see that in the new book template, we have both a book.pillar that includes 
the chapter files, and a pillar.conf that is mostly empty. Is pillar.conf still 
used? If yes, what should it contain?

If I embed the chapters in a book.pillar and I render the whole book, the 
numbering of the second chapter starts from 1 (instead of 2) when I render in 
html. Any idea how to do it differently?

Cheers,
Doru


--
www.tudorgirba.com
www.feenk.com

"Yesterday is a fact.
 Tomorrow is a possibility.
 Today is a challenge."







Re: [Pharo-users] Pillar question: PRCitationTransformer

2016-08-21 Thread Yann Dubois
Hi stef,

You can not have a citation annotation on a writer because the annotation
is transformed before to a PRCitation object. So you need to overwrite
visitCitation.

PRCitationTransformer is called in the phase mechanism. He is added in the
transform pipeline. PRCitationTransformer will be rename to
PRCitationAnnotationTransformer because this class change the citation
annotations and not the citations.

Le 22 août 2016 07:36, "stepharo"  a écrit :

Hi

I'm trying to extend Pillar to get new $publications:...$ structure and it
looks like Pillar is getting more and more complex. And the comments do not
really help because they are short and written for someone already
understanding it. :(

To try to understand I tried to

! Youpi

${cite:ref=Duca18rmod}$

!! Others

but I get

{"content":"!Youpi\n\n\n\n!!Others"}

./pillar export --to=pillar Example.pillar


May be I cannot export to pillar a citation. I have no idea.


I tried to add

PRPillarWriter >> visitCitationAnnotation: aCitation
"We invoke visitAnnotation: to make sure that the rest of the document
is visited."

self halt.
super visitCitationAnnotation: aCitation

Did not stop!

So I put an halt into

PRVisitor >> visitCitationAnnotation: aCitationAnnotation

self halt.
self createNewCitationWith: aCitationAnnotation.
self replace: (OrderedCollection with: tmpCitation) .
super visitCitationAnnotation: aCitationAnnotation

and it stopped.


I tried to understand who is calling

PRCitationTransformer

No luck. I'm sure that there is a magic registration mechanism but I failed
to find it.

Looking at tests (BTW Tests are not documentation or class comments, there
are tests).

It looks like I need a configuration.

 (self actualClass
executeOn:
(PRCompilationContext withDocument: anInput withConfiguration:
aConfig))
input

And then I fall on executeOn: implementors. LLPhase and
PRNodeTransformer.

and I have no idea how a Phase relates to a visitor.

To bad, after all the efforts on Pillar it looks like getting too complex.

So do not think that we can decently ask students to work on improving
Pillar anymore

because they will just get lost and disgusted from Pharo. :(

Sad news isn't.

I hope that I will not have to switch back to LaTeX or markdown (shit).

Stef


[Pharo-users] Pillar question: PRCitationTransformer

2016-08-21 Thread stepharo

Hi

I'm trying to extend Pillar to get new $publications:...$ structure and 
it looks like Pillar is getting more and more complex. And the comments 
do not really help because they are short and written for someone 
already understanding it. :(


To try to understand I tried to

! Youpi

${cite:ref=Duca18rmod}$

!! Others

but I get

{"content":"!Youpi\n\n\n\n!!Others"}

./pillar export --to=pillar Example.pillar


May be I cannot export to pillar a citation. I have no idea.


I tried to add

PRPillarWriter >> visitCitationAnnotation: aCitation
"We invoke visitAnnotation: to make sure that the rest of the 
document is visited."


self halt.
super visitCitationAnnotation: aCitation

Did not stop!

So I put an halt into

PRVisitor >> visitCitationAnnotation: aCitationAnnotation

self halt.
self createNewCitationWith: aCitationAnnotation.
self replace: (OrderedCollection with: tmpCitation) .
super visitCitationAnnotation: aCitationAnnotation

and it stopped.


I tried to understand who is calling

PRCitationTransformer

No luck. I'm sure that there is a magic registration mechanism but I 
failed to find it.


Looking at tests (BTW Tests are not documentation or class comments, 
there are tests).


It looks like I need a configuration.

 (self actualClass
executeOn:
(PRCompilationContext withDocument: anInput 
withConfiguration: aConfig))

input

And then I fall on executeOn: implementors. LLPhase and 
PRNodeTransformer.


and I have no idea how a Phase relates to a visitor.

To bad, after all the efforts on Pillar it looks like getting too complex.

So do not think that we can decently ask students to work on improving 
Pillar anymore


because they will just get lost and disgusted from Pharo. :(

Sad news isn't.

I hope that I will not have to switch back to LaTeX or markdown (shit).

Stef








[Pharo-users] Pillar question PRPrepareForGitBookCommandLineHandler

2016-08-05 Thread stepharo

Hi


PRPrepareForGitBookCommandLineHandler defines the following method.


PRPrepareForGitBookCommandLineHandler>>generateSummary
(baseDirectory / 'SUMMARY.md') asFileReference
writeStreamDo: [ :stream |
stream << '# Summary' << String lf << String lf.
stream << 'Abstract (to be done)' << String lf << String lf.
self flag: #todo."This cannot work anymore because 
inputFiles has been replaced by inputFile."

configuration inputFiles
do: [ :inputFile |
| document title |
document := configuration parseFile: inputFile.
title := document title.
stream << '* [' << title << ']('.
(inputFile , PRMarkdownWriter fileExtension 
relativeTo: baseDirectory)

printOn: stream
delimiter: $/.
stream << ')' << String lf ] ]


and I do not get why configuration is sent parseFile:

while only PRParsingPhase defines it.


Stef




Re: [Pharo-users] Pillar: PRTemplate?

2016-04-23 Thread Martin Dias
Thanks Yann. Ecstatic is currently using Pillar 0.62. Finally it's not
necessary to upgrade now so we can wait.

Martin

On Sat, Apr 23, 2016 at 1:30 PM, Yann Dubois 
wrote:

> Hi,
>
> PRTemplate was removed in the development version because our goal is
> simplify Pillar. To do this, we want Pillar generate only the content of a
> document, so the template system was removed. If you want use PRTemplate,
> you can use the last stable release of Pillar, and if you want use the
> development version, you wil need to write a Makefile (Our Makefile is not
> useful for the moment) and put the content in a template engine like
> Mustache (the Pharo version is usable with a command line since this week).
>
> Yann
>
> 2016-04-23 18:18 GMT+02:00 Martin Dias :
>
>> Hi Pillar developers,
>>
>> A method in Ecstatic [1] references a class named PRTemplate (as well as
>> PRTemplateError), which probably existed in a previous version of Pillar.
>> Do you know what happened to it? I'm trying to update Ecstatic code to work
>> with latest Pillar version released.
>>
>> Regards,
>> Martin
>>
>> [1]: https://github.com/guillep/ecstatic
>>
>
>


Re: [Pharo-users] Pillar: PRTemplate?

2016-04-23 Thread Yann Dubois
Hi,

PRTemplate was removed in the development version because our goal is
simplify Pillar. To do this, we want Pillar generate only the content of a
document, so the template system was removed. If you want use PRTemplate,
you can use the last stable release of Pillar, and if you want use the
development version, you wil need to write a Makefile (Our Makefile is not
useful for the moment) and put the content in a template engine like
Mustache (the Pharo version is usable with a command line since this week).

Yann

2016-04-23 18:18 GMT+02:00 Martin Dias :

> Hi Pillar developers,
>
> A method in Ecstatic [1] references a class named PRTemplate (as well as
> PRTemplateError), which probably existed in a previous version of Pillar.
> Do you know what happened to it? I'm trying to update Ecstatic code to work
> with latest Pillar version released.
>
> Regards,
> Martin
>
> [1]: https://github.com/guillep/ecstatic
>


[Pharo-users] Pillar: PRTemplate?

2016-04-23 Thread Martin Dias
Hi Pillar developers,

A method in Ecstatic [1] references a class named PRTemplate (as well as
PRTemplateError), which probably existed in a previous version of Pillar.
Do you know what happened to it? I'm trying to update Ecstatic code to work
with latest Pillar version released.

Regards,
Martin

[1]: https://github.com/guillep/ecstatic


[Pharo-users] [Pillar] Pillar 3.0.0 release

2016-04-20 Thread Thibault ARLOING
Hi everybody,


I'm happy to announce the latest release of Pillar.

This release has been possible because of the hard work of Damien Cassou, Cyril 
Ferlicot, Damien Pollet, Stephan Eggermont, Yann Dubois, Thibault Arloing and 
Lukas Komarek.

What did it bring and what are the largest changes ?


  *   Addition of an AsciiDoc Exporter
  *   LaTeX exporter:
 *   external links now produce footnotes
 *   replace \begin{code}{} with \begin{listing}[language=]
 *   replace \ct with \code
 *   use \textasciitilde instead of \texttildelow to represent a ~ 
character in Pillar
 *   SBALaTeX writer for sba book (by Damien Pollet) 
https://github.com/cdlm/sbabook
  *   HTML exporter:
 *   default template charset is UTF-8
  *   Features: For more  you can see Pillar documentation at 
https://ci.inria.fr/pharo-contribution/job/EnterprisePharoBook/lastSuccessfulBuild/artifact/book-result/PillarChap/Pillar.html
 *   hideable scripts with the option hideable.
*e.g., [[[hideable=true
with a parameter in pillar.conf "scriptHide"=true this text 
will be hidden.
 ]]]
*   It's, for example useful if you're a teacher and you want to have 
two versions of your document, one with solutions (for you) and one without 
(for students)
 *   auto anchor for headers
*   e.g, in a level configuration
 "level1":{
"numbering"=true,
"autoAnchor"=true
}
there will be an automatic creation of an anchor for headers of 
level 1.
*   It's useful when you want to link a title in the text, for example 
for a table of contents
 *   header capitalization in a level configuration with options: 
capitalize, capitalizeEnglish, uppercase, lowercase
*ex: "level1":{
"capitalization":"uppercase"
 }
Will render all headers of level 1 to Uppercase.
*   It's useful if you want all headers of a same level to be 
capitalize likewise
*   e.g., if you have "==i am a level 1 header" with 
"capitalizeEnglish" it will produce "I Am a Level 1 Header<\h2>"


Cheers,

Thibault




Re: [Pharo-users] [Pillar] Logo for Pillar

2016-03-23 Thread stepharo

I think more about the ones below the pier :)

http://www.routard.com/photos/los_angeles/18237-la_jetee_de_malibu.htm
http://fr.dreamstime.com/photos-libres-de-droits-jetée-avec-le-restaurant-à-la-mer-baltique-allemagne-image1493

but this is not good for a logo.

the one that sustain the pier :)
It was literally that in fact




Le 22/3/16 16:00, Ben Coman a écrit :

On Fri, Mar 18, 2016 at 10:30 PM, Thibault ARLOING
 wrote:

Hi,


With a mate, we've worked on a logo for Pillar.

We just want feedbacks on it.

I like the style. But as a logo I think it is too thin.

When I think of pillar I think of
http://tinyurl.com/pillar-images

And for a logo, something like...
http://www.presentation-process.com/wp-content/uploads/powerpoint-pillar-tutorial.jpg

Attached is a concept I knocked up.  Its too detailed for a logo, and
the font was plagiarized from
http://tinyurl.com/hhc5a3d
but may provide inspiration.

cheers -ben





Re: [Pharo-users] [Pillar] Logo for Pillar

2016-03-22 Thread Ben Coman
On Fri, Mar 18, 2016 at 10:30 PM, Thibault ARLOING
 wrote:
> Hi,
>
>
> With a mate, we've worked on a logo for Pillar.
>
> We just want feedbacks on it.

I like the style. But as a logo I think it is too thin.

When I think of pillar I think of
http://tinyurl.com/pillar-images

And for a logo, something like...
http://www.presentation-process.com/wp-content/uploads/powerpoint-pillar-tutorial.jpg

Attached is a concept I knocked up.  Its too detailed for a logo, and
the font was plagiarized from
http://tinyurl.com/hhc5a3d
but may provide inspiration.

cheers -ben


Re: [Pharo-users] [Pillar] Logo for Pillar

2016-03-21 Thread Esteban A. Maringolo
I don't like it. It's more an illustration than an actual iso/logotype. Sorry.

I didn't know there was a logo for Pillar, and though it's not
fantastic, it is nice and continues with the style of a Pharo thing.

Regards!

Esteban A. Maringolo


2016-03-21 11:05 GMT-03:00 Thibault ARLOING <thibault.arlo...@hotmail.fr>:
> oh I didn't see either that pillar had a logo.
> Moreover, he is better.
>
> thanks
>
> 
> De : Pharo-users <pharo-users-boun...@lists.pharo.org> de la part de Damien 
> Cassou <damien.cas...@inria.fr>
> Envoyé : lundi 21 mars 2016 14:19
> À : Yuriy Tymchuk; Any question about pharo is welcome
> Objet : Re: [Pharo-users] [Pillar] Logo for Pillar
>
> Yuriy Tymchuk <yuriy.tymc...@me.com> writes:
>
>> IMHO it’s too airy, to much free area. By the way, have you seen the 
>> previous logo?
>> https://github.com/pillar-markup
>
> I didn't know Pillar already had a logo :-). Thanks
>
> --
> Damien Cassou
> http://damiencassou.seasidehosting.st
>
> "Success is the ability to go from one failure to another without
> losing enthusiasm." --Winston Churchill
>
>



Re: [Pharo-users] [Pillar] Logo for Pillar

2016-03-21 Thread Thibault ARLOING
oh I didn't see either that pillar had a logo.
Moreover, he is better.

thanks


De : Pharo-users <pharo-users-boun...@lists.pharo.org> de la part de Damien 
Cassou <damien.cas...@inria.fr>
Envoyé : lundi 21 mars 2016 14:19
À : Yuriy Tymchuk; Any question about pharo is welcome
Objet : Re: [Pharo-users] [Pillar] Logo for Pillar

Yuriy Tymchuk <yuriy.tymc...@me.com> writes:

> IMHO it’s too airy, to much free area. By the way, have you seen the previous 
> logo?
> https://github.com/pillar-markup

I didn't know Pillar already had a logo :-). Thanks

--
Damien Cassou
http://damiencassou.seasidehosting.st

"Success is the ability to go from one failure to another without
losing enthusiasm." --Winston Churchill




Re: [Pharo-users] [Pillar] Logo for Pillar

2016-03-21 Thread Damien Cassou
Yuriy Tymchuk  writes:

> IMHO it’s too airy, to much free area. By the way, have you seen the previous 
> logo?
> https://github.com/pillar-markup

I didn't know Pillar already had a logo :-). Thanks

-- 
Damien Cassou
http://damiencassou.seasidehosting.st

"Success is the ability to go from one failure to another without
losing enthusiasm." --Winston Churchill



Re: [Pharo-users] [Pillar] Logo for Pillar

2016-03-21 Thread Yuriy Tymchuk
Hi,

IMHO it’s too airy, to much free area. By the way, have you seen the previous 
logo?
https://github.com/pillar-markup

Uko 

> On 18 Mar 2016, at 15:30, Thibault ARLOING  
> wrote:
> 
> Hi,
> 
> With a mate, we've worked on a logo for Pillar.
> We just want feedbacks on it.
> 
> You can fin the logo join files.
> 
> thanks :)
> 
> Good afternoon,
> Thibault
> 



Re: [Pharo-users] [Pillar] Logo for Pillar

2016-03-20 Thread Cyril Ferlicot
Hi,

Personally I do not like it. (Maybe I'm difficult :) ).

I think that it would be better to have the "illar" at the bottom and not
compressed in the middle.

The second column look like an "y" and we read "Pillary".

And why is there a wave under pillar?
I think that things in a logo have to be symbolic and I do not find
anything from the wave.

Anyway, thank you to invest your time in pillar :)

On Friday, 18 March 2016, Thibault ARLOING 
wrote:

> Hi,
>
>
> With a mate, we've worked on a logo for Pillar.
>
> We just want feedbacks on it.
>
>
> You can fin the logo join files.
>
>
> thanks :)
>
>
> Good afternoon,
>
> Thibault
>


-- 
Cheers
Cyril Ferlicot


Re: [Pharo-users] [Pillar] Logo for Pillar

2016-03-19 Thread Alexandre Bergel
Wow!!!

Alexandre


> On Mar 18, 2016, at 3:30 PM, Thibault ARLOING  
> wrote:
> 
> Hi,
> 
> With a mate, we've worked on a logo for Pillar.
> We just want feedbacks on it.
> 
> You can fin the logo join files.
> 
> thanks :)
> 
> Good afternoon,
> Thibault
> 

-- 
_,.;:~^~:;._,.;:~^~:;._,.;:~^~:;._,.;:~^~:;._,.;:
Alexandre Bergel  http://www.bergel.eu
^~:;._,.;:~^~:;._,.;:~^~:;._,.;:~^~:;._,.;:~^~:;.






  1   2   3   >