Archive for November, 2006

Just an Observation

November 11th, 2006 by ailon

I just realized that when you make a slider for percentage value it has to accept 101 values and not 100. In other words precise slider should be 101, 202 and so on pixels wide/high. I know this is very simple but I never thought about it :)

event.preventDefault()

November 8th, 2006 by ailon

I was struggling for quite some time trying to prevent Firefox from dragging an image when I wanted to use it as a resizing grip. I was trying to cancel default event using event.preventDefault() method in onmousemove event with no success. Thanks to Michael Foster (from cross-browser.com) at SitePoint forums I now know that it’s onmousedown event where I should’ve canceled the default (dragging) behavior.

Who Needs Photoshop?

November 8th, 2006 by ailon

Well, designers do. But for developers investing in something like Photoshop is overkill. To say more any investment in image editors is not easily justifiable if all you do with it is a couple of icons or small simple images once in a while.

This is where Paint.net shines. Sure it can’t compete with Photoshop on a high level (yet) but it does all developer needs plus a little more. Testimonial on the site says that someone actually uninstalled Photoshop for Paint.net. We have a dedicated “Photoshop computer” which was used by whoever needed to do a little graphics work. Well, in a month I have Paint.net on my machine I’ve done some images for SPAW2, a couple of buttons, a background image and I’ve never used our “photoshoputer” for this.

P.S.: I’m afraid that Paint.net will dissapoint me in a huge way now, when I praised it :)

Table Layout

November 3rd, 2006 by ailon

I’ve spent a day trying to layout SPAW2 toolbars with divs, spans and css. When it worked fine in IE and Firefox it did freaky things in Opera, in other cases it looked good in IE but a little wrong in Firefox. So I gave up and made it ok with tables in a matter of a few minutes. I know it’s considered bad taste and stuff but actually in this case I don’t understand why.

Yes, I understand that table means table and not a layout grid. So, let’s introduce a GRID tag with allowed children GR and GD. Yes, yes, I know about markup and presentation separation. But when I create a web based WYSIWYG editor it’s a whole thing - a control, not a piece of content wrapped in nice presentation layer. And with current trend for web based applications this is often the case.

Let’s take this blog as an example. Front-end is pure content wrapped in presentation (that is everything but content) but admin interface is a web application where presentation consists of colors, fonts, etc. but layout looks more like part of the content to me.

Firefox Sucks

November 1st, 2006 by ailon

For those who don’t believe here are some screenshots of the same test page rendered in IE7, Opera 9 and Firefox 1.5


IE7 


Opera 9

 
Firefox 1.5

I have an idea why this is happening but so far no idea what is wrong with how it’s done. And both Opera and IE seem to work as I expected but Firefox thinks different. Oh well…

SPAW2 and Opera 9

November 1st, 2006 by ailon

A couple of days back I’ve confirmed that there will be no support for Opera in SPAW 1.x. Well, today I made my development copy of SPAW2 work in Opera 9 no worser than in Firefox (cut/copy/paste works in IE only).

So there definitely will be Opera 9 support in SPAW2 from the first public release.