Archive for the ‘dtc’ tag
DTC, improved
The last one and a half days were spent in improving the DTC. As expected, the sons of the soil who rave and rant about “people doing nothing for their nation” and “subversion of our language and culture” were barely involved. More the pity…
Bala suggested two tweaks - form buttons and live preview.
The buttons are a good step ahead. I was able to dispose off the awkward tabs I had inserted to space out some characters. And do they look cool!

Firefox running on GNOME in Ubuntu (92 KB)

Opera (with Standard Skin, not default win32 skin) running on win32. (52 KB)
Live preview eliminates the need to click a button to see the results. The stuff appears as you click on the character buttons. You can also edit the code directly from now on. This live preview idea uses innerHTML. Don’t ask me what that is - I can only say it takes a string of HTML as it is and is useful for DHTML. The code snippet Bala presented threw up problems on all systems except IE and FF on win32. So I had a look around and updated the code with a more elaborate version of live preview. Also, as the footer says, this version of DTC has been tested on a lot of browsers. Still, if bugs crop up, let me know.
a hack to create Marathi webpages
The Unicode post put up day before yesterday was tedious to create. I had to keep jumping between the editor and the lookup pages until I decided to first get the entities in a line, on paper. Then, feeling rather like a Windtalker, I typed those entities in the editor. Thats a pretty roundabout way of doing things. If I required over forty minutes to write two sentences, there was no hope for transcribing full length Marathi and Hindi articles for the college magazine website. And unless the process was straightforward, people like Bhise (who is interested in putting up some stuff he has written in Marathi) would reject it out of hand.
I got a brainwave and sent a mail to a friend asking him to implement a script to generate the necessary representation in Unicode. The user would just have to click on the character he wants. A sort of typesetting software. After sending the mail, I realised how trivial the request was…
Yesterday, I spent the afternoon and evening in creating this hack. Just like the tyesetting machine I had visualized - it generates Unicode entities as fast as you can click the characters.
Implemented using Javascript, it takes up a tidy 9 KB. You click on the characters in the order you want them to appear. The Unicode entities appear in the text box below. Simply put them between your HTML tags as you would for normal text. And in the interest of the proof-reading public (count me in!), there’s a button that lets you see what you have created. The raw Unicode should be useful for compatible applications too. I don’t have any to test, so I don’t know.
I was tempted to get image files for the characters. It would have provided a better look and made it easier while clicking a particular character. A few reasons why I didn’t do it.
- The package would have grown from a single 9 KB file to a 9+ KB file and 148 image files.
- As it is now, you can test how your browser actually renders the characters, because the characters themselves are displayed using Unicode entities.
You can download the file for local use. Let me know how it works. It would be better to squash the bugs before I use it for creating the college magzine webpages.
8 responses