Re: Issue 5 in pseudolocalization-tool: Document how to use pseudolocalizer for ExtJS apps

26 views
Skip to first unread message

pseudolocal...@googlecode.com

unread,
Feb 13, 2013, 3:01:02 PM2/13/13
to pseudolocal...@googlegroups.com
Updates:
Summary: Document how to use pseudolocalizer for ExtJS apps
Status: Accepted
Owner: j...@jaet.org
Labels: -Type-Defect Type-Enhancement

Comment #1 on issue 5 by j...@jaet.org: Document how to use pseudolocalizer
for ExtJS apps
http://code.google.com/p/pseudolocalization-tool/issues/detail?id=5

So are your strings extracted into a message catalog? What format is it?
If it is Java properties files, you can do it right now with the
command-line tool, running pseudolocalizer foo.properties will create
foo_psaccent.properties and then use that to produced the localized app.

If you need a different format, you will need to write a MessageCatalog
implementation for it, but that isn't hard -- look at JavaProperties for an
example.

--
You received this message because this project is configured to send all
issue notifications to this address.
You may adjust your notification preferences at:
https://code.google.com/hosting/settings

pseudolocal...@googlecode.com

unread,
Feb 13, 2013, 3:02:02 PM2/13/13
to pseudolocal...@googlegroups.com
Updates:
Status: NeedInfo

Comment #2 on issue 5 by j...@jaet.org: Document how to use pseudolocalizer
(No comment was entered for this change.)

tester...@gmail.com

unread,
Feb 15, 2013, 1:28:03 PM2/15/13
to pseudolocal...@googlegroups.com, codesite...@google.com, pseudolocal...@googlecode.com
Our app uses xml files for labels. They are manually translated by our localization team. What I am trying to do is verify that in different locales, our app appears as expected (CSS changes, button label changes, button length changes etc). I think what you mentioned below helps me at development time. I want to QE the app, so it's post development time. I am sorry for not being clear the first time around.

John A. Tamplin

unread,
Feb 15, 2013, 1:53:00 PM2/15/13
to pseudolocal...@googlegroups.com, codesite...@google.com, pseudolocal...@googlecode.com
On Friday, February 15, 2013 1:28:03 PM UTC-5, tester...@gmail.com wrote:
Our app uses xml files for labels. They are manually translated by our localization team. What I am trying to do is verify that in different locales, our app appears as expected (CSS changes, button label changes, button length changes etc). I think what you mentioned below helps me at development time. I want to QE the app, so it's post development time. I am sorry for not being clear the first time around.
 
So what XML format do you use, is it something standard like XLIFF, or something home-grown?  In either case, there isn't any file format support for XML, so it would have to be written.  XLIFF would be complicated to support completely, but a simple XML format wouldn't be hard at all.

Do you have a small sample of your XML format?

Note that what the pseudolocalizer will do is give you translated strings for a pseudolocale, and you can hook that into your testing process without having to use real locales.  That will let you see problems like not giving room for particular labels, not supporting Bidi, not handling accented characters, improperly concatenating messages so they can't be translated as a unit, etc.  It doesn't have anything to do with how your app decides what locale to use -- that is going to be entirely up to your app.  As an example, the default way a GWT app gets the locale is in a query parameter, like ?locale=fr.  To run it with a pseudolocale, you generate the pseudolocalizations like any other, and then run the app with ?locale=en_psaccent.

--
John A. Tamplin

pseudolocal...@googlecode.com

unread,
Feb 15, 2013, 2:29:01 PM2/15/13
to pseudolocal...@googlegroups.com

Comment #3 on issue 5 by Testerga...@gmail.com: Document how to use
Sorry if I am sending this multiple times. Google is behaving weird today :(
Our app uses xml files for labels and we have one xml file per locale. The
suggestion to use command line tool seem to apply at development time. I am
looking at using the tool during QE cycles and also for regression testing.
We have a pretty robust autobuild system built on Java. We have java and
selenium based automation as our functional regression test suites. I want
to incorporate Pseudolocalizer as part of the localization testing
framework (currently we use Selenium to do this and I feel like it is an
overkill). I am a lead QE engineer and hence I am exploring options to
design a framework for localization testing of our app that produces great
results and consumes as little time as possible to run end to end, so our
dev team will be more encouraged to run the tests on their local before
checking in.
I appreciate your guidance so far! Thanks a lot for your time!

pseudolocal...@googlecode.com

unread,
Feb 21, 2013, 2:44:01 PM2/21/13
to pseudolocal...@googlegroups.com

Comment #4 on issue 5 by Testerga...@gmail.com: Document how to use
pseudolocalizer [--ext=fqcn[,fqcn...]] [--variant=varname|
--method=method[,method...] [--type=filetype]
[<--interactive|files>]

using this commandline tool seems to be a bit tedious when I have thousands
of css classes. And we don't always have classnames for our elements and we
use dynamic ext ids as well. Do you have any suggestions on how to go about
using this in this case? Here's a sample page source html from one of our
public pages. Can you please let me know how I can use the tool to test
similar pages? - <div id="filtersPanel" class=" x-panel x-panel-noborder
x-border-panel" style="left: 0px; top: 0px; width: 1710px;"><div
class="x-panel-bwrap" id="ext-gen106"><div class="x-panel-body
x-panel-body-noheader x-panel-body-noborder" id="ext-gen107" style="height:
160px; width: 1710px;"><div id="filterContainerPanel" class=" x-panel"
style="width: 1710px;"><div class="x-panel-bwrap" id="ext-gen131"><div
class="x-panel-body x-panel-body-noheader" id="ext-gen132" style="width:
1710px; height: 160px;"><div id="filterPanel" class=" x-panel filterPanel"
style="width: 1710px;"><div class="x-panel-bwrap" id="ext-gen134"><div
class="x-panel-tbar x-panel-tbar-noheader" id="ext-gen135" style="width:
1710px;"><div id="ext-comp-1060" class="x-toolbar x-small-editor
sectionHeaderBar x-toolbar-layout-ct" style="width: 1710px;"><table
cellspacing="0" class="x-toolbar-ct"><tbody><tr><td class="x-toolbar-left"
align="left"><table cellspacing="0"><tbody><tr
class="x-toolbar-left-row"><td class="x-toolbar-cell" id="ext-gen157"><div
class="xtb-text filterPanelLabel" id="ext-comp-1061" style="width:
53px;"><span>Filters</span></div></td><td class="x-toolbar-cell"
id="ext-gen158"><table id="filterPanel_addFilterButton" cellspacing="0"
class="x-btn addFilterButton x-btn-noicon" style="width: auto;"><tbody
class="x-btn-small x-btn-icon-small-left"><tr><td
class="x-btn-tl"><i>&nbsp;</i></td><td class="x-btn-tc"></td><td
class="x-btn-tr"><i>&nbsp;</i></td></tr><tr><td
class="x-btn-ml"><i>&nbsp;</i></td><td class="x-btn-mc"><em
class="x-btn-split" unselectable="on"><button type="button" id="ext-gen159"
style="" class=" x-btn-text">Add</button></em></td><td
class="x-btn-mr"><i>&nbsp;</i></td></tr><tr><td
class="x-btn-bl"><i>&nbsp;</i></td><td class="x-btn-bc"></td><td
class="x-btn-br"><i>&nbsp;</i></td></tr></tbody></table></td></tr></tbody></table></td><td
class="x-toolbar-right" align="right"><table cellspacing="0"
class="x-toolbar-right-ct"><tbody><tr><td><table cellspacing="0"><tbody><tr
class="x-toolbar-right-row"><td class="x-toolbar-cell"
id="ext-gen160"><label id="ext-comp-1066" for="ext-gen26" class="
filter-form-item-label ">Filter Language</label></td><td
class="x-toolbar-cell" id="ext-gen161"><div class="x-form-field-wrap
x-form-field-trigger-wrap" id="ext-gen162" style="width: 170px;"><input
type="hidden" name="filterLanguage" id="ext-gen164" value="1"><input
type="text" size="24" autocomplete="off" id="ext-gen26" class="x-form-text
x-form-field filterLanguage x-trigger-noedit" style="width: 143px;"
title="" readonly=""><img src="/s.gif" alt="" class="x-form-trigger
x-form-arrow-trigger" id="ext-gen163"
style=""></div></td></tr></tbody></table></td><td><table
cellspacing="0"><tbody><tr
class="x-toolbar-extras-row"></tr></tbody></table></td></tr></tbody></table></td></tr></tbody></table></div><div
id="filterPanel_sfp" class=" stdFilters x-table-layout-ct"><table
class="x-table-layout" cellspacing="0" style="width:100%;"><tbody><tr><td
class="x-table-layout-cell firstLabelTd" rowspan="1" id="ext-gen138"
style="width: 57px;"><div id="ext-comp-1050" class=" firstLblContainer"
style="width: 57px;"><label id="ext-comp-1051" for="scope-ext-gen18"
class=" filter-form-item-label bold firstLabel">Show</label></div></td><td
class="x-table-layout-cell" rowspan="1" id="ext-gen139"><div
id="ext-comp-1052" class=" stdPlugins"><div id="ext-comp-1053" class="
stdPluginWrapper"><div class="x-form-field-wrap x-form-field-trigger-wrap"
id="ext-gen145" style="width: 179px;"><input type="text" size="24"
autocomplete="off" id="scope-ext-gen18" name="scope" class="x-form-text
x-form-field scope x-trigger-noedit" title="" readonly="" style="width:
152px;"><img src="/s.gif" alt="" class="x-form-trigger
x-form-arrow-trigger" id="ext-gen146"
style=""></div></div></div></td></tr><tr><td class="x-table-layout-cell
firstLabelTd" rowspan="1" id="ext-gen141" style="width: 57px;"><div
id="ext-comp-1054" class=" firstLblContainer" style="width: 57px;"><label
id="ext-comp-1055" for="ext-gen20" class=" filter-form-item-label bold
firstLabel">Date Field</label></div></td><td class="x-table-layout-cell"
rowspan="1" id="ext-gen142"><div id="ext-comp-1056" class=" x-panel
dateFilters x-panel-noborder"><div class="x-panel-bwrap"
id="ext-gen143"><form class="x-panel-body dateFiltersBody
x-panel-body-noheader x-panel-body-noborder x-form x-box-layout-ct"
method="POST" id="ext-gen24"><div class="x-box-inner" id="ext-gen147"
style="width: 1642px; height: 22px;"><div class="x-form-field-wrap
x-form-field-trigger-wrap x-box-item" id="ext-gen148" style="width: 130px;
left: 0px; top: 0px;"><input type="text" size="24" autocomplete="off"
id="ext-gen20" name="dateColumn" class="x-form-text x-form-field dateColumn
x-trigger-noedit" style="width: 103px;" title="" readonly=""><img
src="/s.gif" alt="" class="x-form-trigger x-form-arrow-trigger"
id="ext-gen149" style=""></div><label id="ext-comp-1057"
for="duration-ext-gen17" class=" filter-form-item-label x-box-item"
style="left: 140px; top: 0px;">Range</label><div class="x-form-field-wrap
x-form-field-trigger-wrap x-box-item" id="ext-gen150" style="width: 100px;
left: 180px; top: 0px;"><input type="text" size="24" autocomplete="off"
id="duration-ext-gen17" name="duration" class="x-form-text x-form-field
duration x-trigger-noedit" style="width: 73px;" title="" readonly=""><img
src="/s.gif" alt="" class="x-form-trigger x-form-arrow-trigger"
id="ext-gen151" style=""></div><label id="ext-comp-1058"
for="ext-comp-1044" class=" filter-form-item-label x-box-item"
style="left: 290px; top: 0px;">From</label><div class="x-form-field-wrap
x-form-field-trigger-wrap x-box-item" id="ext-gen152" style="width: 95px;
left: 321px; top: 0px;"><input type="text" size="10" autocomplete="off"
id="ext-comp-1044" name="startDate" class="x-form-text x-form-field
startDate" title="" style="width: 68px;"><img src="/s.gif" alt=""
class="x-form-trigger x-form-date-trigger" id="ext-gen153"
style=""></div><label id="ext-comp-1059" for="ext-comp-1047" class="
filter-form-item-label x-box-item" style="left: 426px; top:
0px;">To</label><div class="x-form-field-wrap x-form-field-trigger-wrap
x-box-item" id="ext-gen154" style="width: 95px; left: 443px; top:
0px;"><input type="text" size="10" autocomplete="off" id="ext-comp-1047"
name="endDate" class="x-form-text x-form-field endDate" title=""
style="width: 68px;"><img src="/s.gif" alt="" class="x-form-trigger
x-form-date-trigger" id="ext-gen155"
style=""></div></div></form></div></div></td></tr></tbody></table></div></div><div
class="x-panel-body x-panel-body-noheader" id="ext-gen136" style="overflow:
auto; width: 1710px; height: 78px;"><div id="filterPanel_cfp" class="
cfPanel"><div id="filterPanel_cfp_noFilterText" class=" noFilterText">To
add filters, click <b>Add</b>.</div><div
id="filterPanel_cfp_booleanFilterSection" class="
cfPanel_booleanFilterSection x-hide-display" style=""></div><div
id="filterPanel_cfp_fieldFiltersSection" class=" cfPanel_fieldFilterSection
x-hide-display" style=""></div><div
id="filterPanel_cfp_objectFiltersSection" class="
cfPanel_objectFilterSection x-hide-display" style=""></div><div
id="filterPanel_cfp_topNFilterSection" class=" cfPanel_topNFilterSection
x-hide-display"
style=""></div></div></div></div></div></div></div></div></div></div></div>

pseudolocal...@googlecode.com

unread,
Mar 9, 2013, 8:46:06 AM3/9/13
to pseudolocal...@googlegroups.com

Comment #5 on issue 5 by j...@squareup.com: Document how to use
It should already handle any HTML -- so if you have that text saved in an
HTML file, you can just run pseudolocalizer foo.html and it will generate
foo_psaccent.html, or likewise pseudolocalizer --variant=psbidi foo.html =>
foo_psbidi.html.

pseudolocal...@googlecode.com

unread,
Mar 9, 2013, 8:50:36 AM3/9/13
to pseudolocal...@googlegroups.com

Comment #6 on issue 5 by j...@jaet.org: Document how to use pseudolocalizer
for ExtJS apps
http://code.google.com/p/pseudolocalization-tool/issues/detail?id=5

It should already handle any HTML -- so if you have that text saved in an
HTML file, you can just run pseudolocalizer foo.html and it will generate
foo_psaccent.html, or likewise pseudolocalizer --variant=psbidi foo.html =>
foo_psbidi.html.

If your XML contains non-HTML, then you might need to write your own
equivalent of HtmlPreserver that parses it properly (HtmlPreserver uses the
HtmlParser library, and if it can't parse the input it will leave it
unchanged).
Reply all
Reply to author
Forward
0 new messages