Go to the navigation

elblogg

Posts Tagged ‘english’

Ubuntus new window buttons

Okay, so Ubuntu has moved the close, minimize and maximise buttons to the left. I know there’s been a huge controversy around this since one of the early alphas. Well, I don’t care so much about that. You get used to it after a while, the only problem I see is that there’s a lot going on around the close button, like the file menu, and if the window is maximized, the gnome-menu, so you might easily close a window accidentally.

That’s not the biggest problem with the design though, that is that the active area for the close button is bigger than the button itself. Look at the image below:

You might think that there’s a bit of titlebar to the left of the close-button, right? So you could think that you could click-and-drag here to move the window, right?
Well, if you try to do that, the window will close! The close button goes all the way to the edge of the window, even though it doesn’t look like it does.

I hope this will be fixed prior to release of the final version of Ubuntu 10.04

Printer setup

We got a new Xerox network printer at work a few months back. I haven’t had that much use for it, so I never bothered setting it up on my computer. People around me, using Macs and Windows, were complaining that it was hard getting it to work, and some never managed to get it to work.

Knowing that Macs use the same printing system as Ubuntu, I assumed that this would be complicated as well, so I had postponed it for some time. This week I finally got to setting it up, and it was really simple.

I didn’t have to enter any information at all, it was just a matter of clicking four buttons.

Start the printers control panel from the System menu. This reveals the following window:

Skjermdump-Skriverkonfigurasjon - localhost

  1. Click the “new” button (“Ny” in Norwegian).  This revealed the following window:
    Skjermdump-Ny skriver
  2. You don’t have to enter anything, just click “Forward” (“Framover” in Norwegian). The configuration wizard then asks you to verify some settings, like the name of the printer:
    Skjermdump-Ny skriver-1
  3. Still, no need to change anything. Just click “Use” (“Bruk” in norwegian)
    Skjermdump-Vindu uten tittel
  4. Now click “Yes” if you want to see the glorius and colorful ubuntu test page coming from your printer.

That’s it. Who said Linux where complicated?

I later used the information revealed by the Ubuntu (and Fedora) printer configuration tool to help out my collegues figure out how to set up the printer on a Mac, and in Windows Vista.

ubuntu-user at Narvesen

When I’m travelling, I often visit the kiosks at the airport, to see what they have of intresting magazines, specially Linux and Digital Photography magazines. I was visiting Trondheim last weekend, and on the way back, while I were waiting for my plane back to Bergen, I was looking on the shelves at Narvesen at Trondheim airport, Værnes. There were actually a quite good choice of Linux magazines, and one specially catched my eye. I had heard about the new Ubuntu User magazine at the Ubuntu UK podcast, which by the way is a pretty good podcast. But I didn’t expect to find it in a news-stand in Norway, I thought I had to order it from the UK.

So I bought it.

The magazine was priced to around £7, which would translate to about 74 norwegian kroner, or €8.20. But at when I got to the counter, I had to pay 210 NOK for it, which is about £19 or €23. In comparison, one years subscription to the magazine is €29.90 if you live in Europe outside the UK, which would include Norway. €29.90 is 269NOK or £25.5

This is a total rip-off. I understand that Narvesen needs a margin for magazines with a narrow group of readers, but this pricing is insane.

Great news in the software world

During the last week there has been a couple of great releases in the software I use every day.


First out was Python 3.1. It was released June 27th and features

  • An ordered dictionary type
  • Various optimizations to the int type
  • New unittest features including test skipping and new assert methods.
  • A much faster io module
  • Tile support for Tkinter
  • A pure Python reference implementation of the import statement
  • New syntax for nested with statements


Next out was Mozilla Firefox 3.5, which was released earlier today (June 30th), most noteworty items from that release is the @font-face css-attribute, that allows web-designers to bundle custom fonts with their website designs, and use custom fonts in their design.  I have used that feature to change the header of my blog, you would se a grudge font if you use the new Firefox or Safari. They have also released a new javascript-engine, which they claim to be a lot faster than the old one. Also, support for the <video>-tag has been added.


Then last, but not least, the long awaited PHP 5.3.0 has been released, which provides namespaces and closures for PHP.

Sugar

Ok. It has been a while since my last post, and quite a few things have happened since then, some of which I will get back to in some later posts.

One of the things that have happened is that I attended the “Skolelinux developer summit” or Debian Edu developer summit here in Bergen, with the goal to do some real contribution to free software. I didn’t end up contributing any code at that event.

Cecilie had asked Knut Yrvin to do a talk about community based projects, which inspired some of the other attendees, Walter Bender, to talk about his organization, Sugarlabs. Sugarlabs organizes the development and promotion of Sugar, the user interface for the One Laptop Per Child (OLPC) project.

from sugarlabs.org, click the image to show the whole series in context.


Sugar is an user interface aimed at kids and learning, rather than changing the learning process to use the computer and the web, it changes the user interface, so it is suited for a classroom environment. That being said, using sugar will probably revolutionize the way learning is done in the classroom, to a much more collaborative approach. Everything in sugar is made for sharing between the pupils and/or the teacher.

I had seen some screenshots of Sugar before, but I was totally blown away about the collaboration part of the system, and also how it changes the approach to computers, where we make the computer suitable for the classroom, rather than making the classroom suitable for the computer.

My contribution during the developer summit ended up beeing translating the Turtle Art activity into Norwegian, and helping Mr. Bender finding some bugs.

Since then I’ve translated the download pages on the Sugarlabs wiki into Norwegian. Sadly the current state of Sugar is that it’s quite buggy as “Sugar on a Stick”, completely broken in Ubuntu, and probably somewhat buggy in Fedora.

Also, listen to the Episode 66 of the FLOSS weekly podcast about the implementation of the OLPC in Nepal, which goes more into detail about Sugar.

armering


armering, originally uploaded by elzapp.

tak


DSC_3722.JPG, originally uploaded by elzapp.

hvit søle


hvit søle, originally uploaded by elzapp.

Jeg gikk forbi Florida i Bergen for noen dager siden, på det som skal bli en fotgjengerovergang over bybanen lå denne blåhvite sølen.

Fascinerende farger

pusekatter


pusekatter, originally uploaded by elzapp.

Våren er på vei…

Merging two lists

Lets say you have two lists, one of them containing the values [1,2,3] and the other one containing the values [4,5,6], and you want to combine these two lists into one list, like this one: [1,2,3,4,5,6].

Let’s see how this can be done in different (high level) programming (or scripting or templating) languages.

Java

Java has multiple list implementations, lets start with the most basic one, the builtin array.

int[] A = {1,2,3};
int[] B = {4,5,6};
int[] C = new int[A.length + B.length];
int counter=0;
for(int e : A){
  C[counter]=e;
  counter++;
}
for(int e : B){
  C[counter]=e;
  counter++;
}

or with an ArrayList:

/*Dropped importing the correct classes, 
and constructing the ArrayLists A and B, since thats not the focus here...*/
List<Integer> C = new ArrayList();
C.addAll(A);
C.addAll(B);

PHP

So, how is the same done in PHP?

$A=array(1,2,3);
$B=array(4,5,6);
$C=array_merge($A,$B);

Python

And at last, how does the Pythonistas do this?

?View Code PYTHON
A=[1,2,3]
B=[4,5,6]
C=A + B

Note: the rubyists use the same approach.

Bloggurat Twingly BlogRank Blogglisten