Author Archives: Stéphane Ducasse

Pharo contributor: to contribute to Pharo

Hi Sven

if you like you can also use my "" - at least 
on Ubuntu (where I wrote, tested and use it)

- just clone the project
- use "" to download latest P7 automatically and started, it will also load a contribution 
  help book I did where all is explained

- For a quick start usually you just have to go to the very last help page of the appearing help tool and click 

    CPTCloneTool run

  to automagically download and update you fork (after giving your Github username)

Then you can contribute as usual by having a branch for a bug number in Iceberg and so on. 

Side note:
Currently new Iceberg still has some trouble:
 - one has to discard the changes on Fuel (as there are none) after the automatic synch of the tool
 - one has to "LGitLibrary initialize" when one reopens a saved image (see, otherwise VM will crash
I already notfied Esteban.

For questions on my workflow with the tool: I'm usually available on Discord.

I'm sure there will also be an update of the official contribution tutorial and AFAIK Esteban
want to do some screencasts. 


Using P3 to connect to CockroachDB


Just a quick note: it is possible to use P3 (the lean and mean PostgreSQL client for Pharo using frontend/backend protocol 3.0, to connect to CockroachDB (an SQL database for global cloud services, an open source clone of Google Spannner, as it supports the same line protocol. 

Just make sure to load the latest version of P3 (and ZTimestamp when you are on Pharo 7).

If you do their tutorial, you can set up your connection as follows:

  P3Client url: 'psql://root@localhost:26257/bank'.


Pharo Weekly is looking for a good soul

Dear reader,

I hope that you enojoyed Pharo Weekly. For me it helps me to remember what was happening in this super cool environment.

Now I will take a break and I do not expect to have the time and energy to feed this great blog. If you want to feed Pharo Weekly please contact me at


Migration of Seaside book started!


I decided to start to migrate the Seaside book to Pillar and make it a community-oriented book.
I will work regularly on it and offer it as a gift to the community.

If some of you want to join the effort, you are welcome.


QRCode – A thank you note


Given that the mailing lists are often used to ask questions when we get in trouble, report bugs and other issues, conduct public discussion between strong headed individuals, we quickly forget what a fantastic platform Pharo is.
Last month I implemented a rough MVP-style ticket sales platform that was successfully used to sell and validate at the entrance, about 1000 digital, online tickets for a relatively large 3000+ attendance event (a party). It took only a couple of days to build and deploy, and it was a lot of fun – it was even done in ‘unstable’ Pharo 7.
Early on I decided to identify each individual ticket by a unique URL. For easier presentation and scanning purposes, I encoded that URL in a QR code.
Although I am grateful for the whole Pharo ecosystem (including Seaside), we all build on top of other people’s work, I was especially happy with Jochen Rick’s QRCode package (!/~JochenRick/QRCode/). This is such a great piece of work !
It worked right out of the box in Pharo 7 (even though it is from 2013/2014), was well designed, easy to figure out, was well documented, had unit tests. I can’t say anything bad about it, it is as close to perfect as I have ever seen. So: thanks Jochen, you made my day !
Here is how a ticket generates its own QR code:

^ self url asString asQRCode formWithQuietZone magnifyBy: 5

Just beautiful.
It is also easy (for a non-graphics, non-UI person like me) to combine the QR code with some text:
T123Ticket >>#asQRCodeWithText

| form font |
form := Form extent: 535 @ 185 depth: 1.
font := LogicalFont familyName: ‘Bitmap DejaVu Sans’ pointSize: 14.
self asQRCode displayOn: form at: 0 @ 0.
form getCanvas
drawString: self url asString at: 180 @ 20 font: font color: Color black;
drawString: self id36, ‘ – ‘, ticketId asString at: 180 @ 45 font: font color: Color black;
drawString: (name ifNil: [ ‘N.N’ ]) at: 180 @ 90  font: font color: Color black;
drawString: (email ifNil: [ ‘@’ ]) at: 180 @ 115 font: font color: Color black;
drawString: (phone ifNil: [ ‘+’ ]) at: 180 @ 140 font: font color: Color black.
^ form

Next we combine this with a nice template designed by a graphics artist:
T123Ticket >>#asQRCodeWithTextInTemplate
| templateFile form |
templateFile := ‘tickets123-template-{1}.jpg’ format: { self event id }.
form := PluginBasedJPEGReadWriter formFromFileNamed: templateFile.
self asQRCodeWithText displayOn: form at: 20@540.
^ form
And finally, the ticket form is encoded as a JPEG (to be mailed and so on):
T123Ticket >>#asJPEGBytes
^ ByteArray streamContents: [ :out |
PluginBasedJPEGReadWriter putForm: self asQRCodeWithTextInTemplate onStream: out ]
I also found GT Inspector very handy (again) in doing back end work (managing payments and other administration), especially the ability to use Spotter on a collection open in an inspector.
Anyway, I know many of you have similar happy experiences, I just wanted to share (one of) mine.
Thanks Jochen, thanks everyone.

[Testimony] migration to 6.1 was super easy.

Thanks for all the hard work.

It took me about 30 minutes to migrate one of my projects from 32bit Pharo 5 to 64bit 6.1 this afternoon.  It has about 40 external dependencies so I thought it would take much longer to get everything sorted.


[Pharo-dev] [ann] gt diagrammer


We are happy to announce an initial version of GT Diagrammer, an engine for constructing diagrams interactively. This is the newest addition to the next generation GT built on Bloc.

It looks like this:

We chose to work on Diagrammer for multiple reasons. First, developers often need to create hand-built diagrams to communicate intentions, and an integrated experience should not require us to leave our environment to create them. At the same time, Diagrammer is an application that requires a widget and interactions, and thus it is a nice exercise for Bloc and Brick.

One requirement we had from the beginning was to make it work with any Bloc element. This means that the editing part had to be reasonably generic. To this end, we now have elements that can define visual editors. This is somewhat a combination between Magritte descriptions, and inspector extensions. An interesting side effect is that now we can edit visual properties when inspecting any element. In other words, we got the basic infrastructure of a UI painter. It looks like this:

The user interface essentially relies on two widgets: scrollable list and toggle button. While the visual look of the toggle button is inspired from material design, the most interesting part is that now we have an implementation for controlling looks per element instance. A key issue here is that looks can react to events coming from the element and inject visual attributes and possible even change behavior (for example, changing an icon while pressing a button). We will post more about looks soon.

We now also have a nice solution for overlays. For example, we have an overlay showing selection and an overlay for resizing elements.

Perhaps less obvious, Diagrammer also offers a basic infrastructure for the area of visual languages. As Diagrammer works with any Bloc elements, we can simply create dedicated visual elements. As an example, Diagrammer comes with an implementation of a UML class figure. Furthermore, as the functionality does not impose a specific model, custom language semantics can be mapped on visual actions.

There are several things to do still for it to become a mature solution. An important next step is to serialize a diagram scene in a reproducible manner. Currently, the diagram (or any element) can be exported as pdf (, svg (, png, gif or jpeg by directly using the low level canvas. However, for the diagram to be truly useful we need to store the result in either code or another reloadable form such as STON. Other future directions are related to figure controlling (for example, custom anchors or line bending points) and to enhanced editors.

To play with it, the easiest way is to download the new GT in a Pharo 6.1 image:
Metacello new
baseline: ‘GToolkit’;
repository: ‘github://feenkcom/gtoolkit/src’;

And then inspect:
GtDiagrammerElement new

The feenk team

“Presenting is storytelling.”

Learning Object-Oriented Programming, Design and TDD with Pharo


We are happy to officially announce that

Learning Object-Oriented Programming, Design and TDD with Pharo

is now available for print on

Pharo association members will soon receive a 20% reduction!

Stéphane Ducasse and Damien Pollet


[ANN] MaterialDesignLite v1.2.0 for Seaside

Hello everyone,

Today I released the version v1.2.0 of MaterialDesignLite for Seaside.

The main changes are:
– There is a brand new demo with more examples and documentation. You
can find it here:
– There is a new concepts: The extensions. Extensions are not describe
by Material Design but are meant to help developers while building web
application. This release contains 3. A way to simplify the use of
dialogs, called “root dialog”, a resizeable left panel and a resizeable
right panel with tabs.
– There is a new widget: the progress widget
– New brushes to use premade typography and typogaphy styles

This release is tagged with v1.2.0 and I also introduced tags v1.2.x and
v1.x.x which are moving tags following patch and minor versions.

Here is the full changelog of the release:

If you have issues, need a new feature or have a comment on the project
feel free to open a issue:

Have a nice day!

Cyril Ferlicot