Thursday Sep 04, 2008

Extending Star and Open Office

Ian Curtain wrote to me the other day in reply to a colleague that was trying to get up to speed on Openoffice BASIC and macros and offered the following sites as useful.

There is also the Open Office Wiki page as well. Hope you find them useful.

tags:

Thursday Nov 02, 2006

More about Roller tagging

I have just been experimenting with the tag macros. It is possible to display an articles roller tags using the #showEntryTags($entry) macro. This can be inserted in the entries loop in _day file. 

Because I am planning to continue to use the technorati tags, unless I plan to use a hidden display format I would have two copies of the tag list in the HTML rendered version. So I have not implemented this macro in the _day file. 

I am struggling to get the tag cloud displayed, it seems to refuse to interpret the macro call

The #showTagCloud macro was not implemented since the velociraptor code is so simple (yeah right, I couldn't work it out). I now have a tag cloud implemented on the "About Me" page; Dave Johnson gave me some sample code to make it work. There were other reasons for not implementing showTagCloud as a macro. The team were unclear given the number of customisations that would be required, how used the macro would be, because no matter how few used it, it would need to be maintained.

First set up some CSS rules, roller offers five levels of weight, so five rules is good. 

          .s1 {font-size:60%;}
          .s2 {font-size:80%;}
          .s3 {font-size:100%;}
          .s4 {font-size:120%;}
          .s5 {font-size:140%;}

These are relative rules, which is jolly good so they inherit from the Body or Paragraph rules, but you can make the rules as complex as you want. The following velociraptor/roller code implements the tag cloud in the html file.

          #set($mytags = $model.weblog.getPopularTags(-1, 100))
          #foreach ($tag in $mytags)
              <a class="tag s${tag.intensity}" href="$url.tag($tag.name)"
                  title="$tag.count">$tag.name</a>
          #end

Note the way that the CSS rule names agree with the class attribute of the anchor tag.

This article was updated at 13:30 GMT 3rd November GMT.

tags:

About

DaveLevy

Search

Archives
« April 2014
MonTueWedThuFriSatSun
 
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
    
       
Today