Hi all
I'm ****fighting**** to try to produce a first documentation of
SmallWiki.
The idea is to extract as much as possible from the class comments. But
when there is no comment, I cannot invent it and as it may change in
the future I do not want to spend time updating it.
So please think that for every class you will write we will generate a
wiki page that show that ***YOU*** did not write any comment :)
Your code will be read by others so....
For now you will have to live with the fact that the documentation of
SmallWiki will be draft, I cannot do too much about it.
Stef
Prof. Dr. Stéphane DUCASSE
http://www.iam.unibe.ch/~ducasse/
"if you knew today was your last day on earth, what would you do
different? ... especially if,
by doing something different, today might not be your last day on
earth" Calvin&Hobbes
"The best way to predict the future is to invent it..." Alan Kay.
Open Source Smalltalks: http://www.squeak.org,
http://www.gnu.org/software/smalltalk/smalltalk.html
Free books for Universities at
http://www.esug.org/sponsoring/promotionProgram.html
Free Online Book at
http://www.iam.unibe.ch/~ducasse/WebPages/FreeBooks.html
Just load the bundle names 'SmallWiki Examples', and start a SmallWiki server, and that should work.
If not, please tell me.
Alexandre
--
_,.;:~^~:;._,.;:~^~:;._,.;:~^~:;._,.;:~^~:;._,.;:
Alexandre Bergel http://www.iam.unibe.ch/~bergel
^~:;._,.;:~^~:;._,.;:~^~:;._,.;:~^~:;._,.;:~^~:;.
A new action for having all the comment of classes and methods of SmallWiki:
http://kilana.unibe.ch:9090/HowTos/
Also there were some mistakes on all the action-related wiki. Lukas and I have changed it for using the registration mechanism instead of changing directly the class Page.
I would be very very pleased if I have some comments/english correction/code reviewing...
Alexandre
--
_,.;:~^~:;._,.;:~^~:;._,.;:~^~:;._,.;:~^~:;._,.;:
Alexandre Bergel http://www.iam.unibe.ch/~bergel
^~:;._,.;:~^~:;._,.;:~^~:;._,.;:~^~:;._,.;:~^~:;.
Hi all,
i just found a nice way to use a real editor like emacs for a Wiki.
I have installed the w3m emacs mode (http://emacs-w3m.namazu.org/), so i have the
emacs power with the power of w3m that typeset HTML as plain text.
It works nice with SmallWiki.
--
Serge Stinckwich -< ) multiagent.com
Université de Caen>CNRS UMR 6072>GREYC>MAD /~\ squeak.orghttp://www.iutc3.unicaen.fr/serge/ (/ | zope.org
Smalltalkers do: [:it | All with: Class, (And love: it)] _|_/ debian.org
> I did a pass on all the how to and I'm worried about the use of
> isKindOf:
We could avoid this using a second visitor implementing #acceptPage:
and #acceptFolder. This is necessary because these messages are already
implemented for a different purpose in VisitorRenderHtmlLight.
VisitorRendererHtmlLight>>acceptTemplateStatistic: aTemplate
NewVisitor new visit: action structure
NewVisitor>>acceptFolder: aStructure
self displayFolderStatistic: structure
NewVisitor>>acceptPage: aStruture
self displayPageStatistic: structure
> Alex I really think that we need to have a document explaining the
> design of SmallWiki, can you ask lukas his pictures so that we can
> have a document for the next lecture.
Unfortunately I did not got very far with the documentation that I
should write one day. Although there are some class-comments in the
most important classes as WikiItem, Action, HtmlWriteStream, Structure,
...
Lukas
--
Lukas Renggli
http://renggli.freezope.org
is available on: http://kilana:9090/HowTos/AddinganewVisitor/
I deal mainly with visitors.
The example is how to build a statistic component showing how many children a folder has, or how many characters a page contains.
Smallwiki is really cool!
Alexandre
--
_,.;:~^~:;._,.;:~^~:;._,.;:~^~:;._,.;:~^~:;._,.;:
Alexandre Bergel http://www.iam.unibe.ch/~bergel
^~:;._,.;:~^~:;._,.;:~^~:;._,.;:~^~:;._,.;:~^~:;.
> I'm trying to implement a LikePagesAction for pages, that will list
> all the pages that start and end with the same words as a current
> pages. But i don't know how to collect all the pages in a folder from
> a children page ...
Inside the action write something list this:
structure parent children collect: [ :child |
... ].
Additional information:
structure. "the structure the action is executed on"
structure parent. "the parent folder of the structure the action is
..."
structure parent children. "the children of the parent folder ..."
HTH
Lukas
--
Lukas Renggli
http://renggli.freezope.org
Alexandre, I replay this mail e-mail to the mailing-lists as others are
probably also interested in those questions.
> I would like to play with resource, but I am stop by some issues:
> - What Mimetype means?
The mime-type describes the type of a file in a platform independent
manner. The browser needs this information to know how to display the
resource.
If you like to know more about the internals of the http-protocol I
suggest to read the standard-documentation. There you will find also
references to documents about the mime-type standard:
Hypertext Transfer Protocol -- HTTP/1.1
http://www.ietf.org/rfc/rfc2616.txt
> - and Embedding?
This i-var is a boolean telling the renderer ...
true: to try to embed the resource in the document
false: to make a link to the resource.
Note that current browser only support to embed images, videos and
sound into a web-pages. For pdf- and other binary-files, a link will be
generated instead.
This is something that will go away in one of the next versions. I
think it should be the responsibility of the InternalLink and not of
the Resource itself to decide about the link generation. Implementing
this I was a bit lacy, you see ;-)
> - how could I see all the files attached to a resource (within the
> web browser)?
Only one file can be attached to a given resource. To find out all the
pages using a resource you start a visitor:
visitor := VisitorReferences startAt: server root to: myResource.
visitor collection inspect.
Those references are calculated automatically in the class
TemplateStructuresReferences for the currently browsed page. The
standard wiki-layout displays this data below the actions, if there are
any references.
> - If I load an image, how could I see it?
If you want to include an image into your page:
1. create a page and create a new link
2. create a resource from that link
3. edit the resource and upload your image
4. going back to your page should display your resource
Cheers
Lukas
--
Lukas Renggli
http://renggli.freezope.org