Writing anyone?
March 22nd, 2006
Another feature that people ask for in the zdt is printing. Unfortunately, I havn’t seen too much support for printing in Eclipse so I’m not sure how to do something really nice within the app itself. But since I added this export to any format support, I thought to myself, “Why not export categories to pdf and print from it?” I found an excellent free Java-PDF library called iText and I’ve played around with it a bit. My goal was to output something like the Practical Chinese Reader Character Writing Sheets that I used to use when I was taking classes. Check out the pdf I generated and let me know if you think something like this would be useful. If you’re using Adobe Reader you’ll need to install the Chinese fonts if you havn’t already.
My first thought for this export function was that it should be purely character based. It would take all the individual characters from the specified category and generate a writing sheet from them. Good idea or bad?
Entry Filed under: ZDT
11 Comments Add your own
1. Stephan Hodges | March 24th, 2006 at 11:42 am
I am pretty sure I mailed you my Word version of this same layout a few months ago. It had a macro that let you choose from three different layouts for the boxes. Empty, “Big X”, or “Plus +”, or both. So, that would be a good set of options for you.
Also, if you’re practicing characters, then why not add an option to just geneate a character list, with the words summarized on a separate page, or whereever…
Personally, I’d prefer to also see the category name (if applicable).
DimSum is also adding a similar feature in their next release (or was last time I heard anyways). I’ve tested the feature. So, we’ll have to see who releases first!!
2. Chris | March 24th, 2006 at 1:52 pm
I don’t remember seeing that word document you mention. Could you send it to me again?
Also, could you expand more or give an example about your second point about generating a character list? I’m not sure I quite understand what you mean.
I havn’t actually worked too much on the next release of zdt. Just thinking about what I want to put in. I’m actually quite busy with other stuff these days. =(
3. Stephan | March 25th, 2006 at 7:12 am
I’ll try and send on Monday.
If I have a vocabulary list of 10 words, which average 1.4 characters per word, then the generated character list would be 14 characters, assuming there were no duplicates. But, if there were duplicates, then I would have less characters. However, I could still have the entire word list BELOW (or different page) the character practice sheet.
Example 6 words:
今 jīn
今儿 jinr1
今天 jÄ«ntiÄn
今日 jīnrì
å½“å‰ dÄngqián
这天 zhètiÄn
would generate list of 7 characters:
今
å„¿
天
æ—¥
当
å‰
è¿™
4. Charles Bluett | March 26th, 2006 at 5:18 am
Great Idea
here is the layout i use
http://www.users.on.net/~bluett/chinese_sheet.xls
it’s a bit rough i think the actuall file i use is on my other pc so i quickly made one up.
Big squre for the char the rectangulare ones are for pinyin or english. great for testing sheets (you can choose ehich skills your testing)
The user could then have two layout options learning (yours) testing (mine with option to choose which things you want shown min of one) both can have the option to hide duplicates.
Additional note on mine is that i use either a heavy or coloured boarder to denote char pairs.
5. Chris | March 27th, 2006 at 11:29 am
Looks cool Charles. Do you think you could send me your actual file so I can see how you use it?
6. Erik | April 13th, 2006 at 10:33 am
Perhaps you could use the DocumentRenderer class. It makes printing out a JEditorPane very easy. See http://www.ftponline.com/javapro/2002_12/online/print_kgauthier_12_10_02/
7. Chris | April 13th, 2006 at 11:54 am
Hi Erik. Thanks for your suggestion. Is that what Dimsum uses? I never actually looked at what printing capabilities Dimsum has. Then again, I don’t own a printer either.
I’m not sure JEditorPane would work well in my case since ZDT is a SWT based application. And while its possible to embed Swing components in SWT, I havn’t found the results to be too satisfying in my own experience.
8. Stephan Hodges | April 17th, 2006 at 11:01 am
We just use a browser to print out everything. We have XSL style sheets that define the output, and then generate XLM and render with the current web browser. We train the users to use the “print” menu option
9. Charles Bluett | April 18th, 2006 at 3:08 pm
I sort of prefer the pdf generation as i could save what i have generated easier and no that no matter what pc i am on it would be rendered exactly the same.
10. Stephan Hodges | April 19th, 2006 at 8:47 am
Well, I use Pdf Factory to generate PDFs from any printing. However, for the above (using a browser), it’s really simple to just save the page as an HTML file. Almost as good, except that you can’t embed fonts, and some of the other PDF “extras”.
But, Chris is already generating PDF files, so it’s somewhat moot.
)
11. Chris | April 19th, 2006 at 10:29 am
Yeah, the next release will have the writing sheets in PDF format. I just found it was the easiest way to format things the way I wanted. But only because I only have a cursory experience of XML/XSL.
I’m still looking into being able to export to Supermemo’s xml format. Once that works, you could use XSL to output that xml into whatever representation you’d like, right?
Leave a Comment
Some HTML allowed:
<a href="" title=""> <abbr title=""> <acronym title=""> <b> <blockquote cite=""> <cite> <code> <del datetime=""> <em> <i> <q cite=""> <strike> <strong>
Trackback this post | Subscribe to the comments via RSS Feed