Hi,
I've just installed your advanced_forum module and I must say, it looks really good.
I've translated the strings I could find to danish (I need the site to be in danish), but realized that the buttons you have (such as mark-read.png) are not translatable :(
I'd suggest the following:
1) more advanced: replace buttons with a background "button image" and put text on top - using css. This is the most flexible, but also more advanced solution.
2) enclose the image url's in t() to allow them to be changed for different languages and if you would be so kind to enclose a source file for a button (gimp .xcf format preferably :) - or just enclose a "blank" button and information of which font is used for the text.
Comments
Comment #1
michelleThere are already blank buttons included. Desaturated ones in naked and blue tinged ones in blue_lagoon. I'm not going to attempt to add text dynamically with css. That is way more complicated than I want to get. In the next version of AF the image replacement will be more easily themeable if someone wants to attempt such a thing.
Michelle
Comment #2
klavs commentedHi Michelle,
I'm sorry if I offended you in any way.
I'm happy to hear there's a blank button, that I just missed.
The reason I think this is a bug report, is that the way it is now, the module is not fully i18n'ed.
I can replace the mark-read.png with a button in another language - but I cannot have a multilanguage site.
My point (the nr. 2 option) was
If you simply replace lines like these:
$title_image = advanced_forum_theme_image('mark-read.png', t('Mark read'));
with this
$title_image = advanced_forum_theme_image(t('mark-read.png'), t('Mark read'));
I can translate the text mark-read.png to mark-read-da.png, create a mark-read-da.png button with danish text - and thus have buttons in multiple languages.
Comment #3
klavs commentedforgot to change status.
Comment #4
akis p commentedDoes anyone knows what font type is used on the default english images?
This is probably the same issue,
http://drupal.org/node/365578
Comment #5
michelleThis is not a bug; AF translates just fine without the buttons, which are not critical functionality. I will look into your suggestion since it looks like a minor change. Even though it breaks the string freeze, they are strings which are not normally translated anyway.
Michelle
Comment #6
michelleOk, I've made the change. It breaks the strings but does so to make this more translatable so I guess it's an ok compromise. I've tested it to the point of making sure it doesn't break anything. I haven't tested to see if this trick actually works, though I don't see any reason why it wouldn't.
Michelle
Comment #7
klavs commentedThank you - I'm sure this will help others.
I've tested it on my own site, and it works perfectly :)
Forgive my ignorance, but what's "the string freeze"?
"they are strings which are not normally translated anyway."
I'm glad you agree though, that they need be, for a 100% internationalization (it looks kinda bad to have the entire forum translated and then the buttons stand out in the wrong language :)
Comment #8
michelleString freeze is when you announce that there will be no more changes in strings in a module to give the translators time to get all the translations up to date, which happened almost two weeks ago. Now that I've done this, all the translators are going to have to go back again and make new translations, which means more work for them. What I meant by not normally translated is that translating filenames is very unsual so these are all new translations and it won't really hurt anything if they decide they don't want to go through the effort of updating them. I never said I agreed with this but it seemed like an ok compromise for the 1.x release. Personally, I think it's an abuse of the translation system to be passing filenames through t().
Michelle
Comment #9
klavs commentedThanks for enlightening me about string freeze :)
You are absolutely right, that translating filenames are bordering abuse, but unfortunately that seems to be the closest to a "proper" solution, when the filenames are images with strings - that needs to be translatable. That's also why I suggested option 1 - as the most correct way of solving the problem :)
Comment #10
michelle#1 sounds like a nightmare. The "proper" solution for me would be to have a directory per language but no one was willing to take the time to make it happen and it isn't my itch to scratch. This solution won out because it didn't take much of my time and had minimal impact on existing code. I'm still hoping for a better solution in 2.x but i18n isn't a high priority for me so we'll see.
Michelle