[kde-doc-english]Re: Tool to check the menu items and the GUI labels

Anders Lund anders at alweb.dk
Mon Feb 11 11:57:22 CET 2002


On Monday 11 February 2002 10:33, Eric Bischoff wrote:
> Le Lundi 11 Février 2002 09:18, Jacob Sparre Andersen a écrit :
> > Eric Bischoff wrote:
> > > What would really help would be a tool that:
> > > -extracts the <guimenu>s, <guilabel>s and <guimenuitem>s from the
> > > documentation messages
> > > - searches the equivalent(s) in the po files used by the application
> > > (not taking into account the keyboard accelerator mark '&')
> > > - issues a warning if it has not been found
> > > - proposes a translation if there is one.
> >
> > I must be sligthly more lazy than you, because I would
> > prefer to have the US English versions of the menu texts
> > pulled directly out of the source code [1], and then use
> > that information to look up the exact translation.
>
> ??? It's what I'm proposing.
>
> > > Comments? Suggestions? Criticism?
> >
> > Sounds like a useful tool.
> >
> > Jacob
> >
> > 1) I don't know much about Qt, so I can't say how difficult
> >    this is.
>
> It's mainly text file manipulation.

well, most of use KAction whereever we can. Afaicr the text is allways the 
first arg to a KAction, so those woulb be grepable. Many actions are 
standard, and the text for a standard action would never even be mentioned in 
the source, it is just there. But the standrad actions them selves are not 
hard to find.

Then there are nonstarndard stuff, people using (sic!) menuitems directly, and 
changing texts. knowing which objects calling a setText( i18n(<strong>) ) 
method is a menuitem is nontrivial.

Texts for QWhatsThis is easily grepabble.

Texts for labels, buttons, checkboxes etc are nontrivial, as they may be set 
in the object constructor or using setText().

Some developers even prefer using constants or variables to define tet lables.

-anders


> _______________________________________________
> kde-doc-english mailing list
> kde-doc-english at mail.kde.org
> http://mail.kde.org/mailman/listinfo/kde-doc-english
-- 
Kmail filter regexp generation HOWTO
-------------------------------------------------------------------------------
KMail fails to privide an "insensitive" option for its filters, here's how to 
fast create a regexp for a (pop Subject) filter:
[anders at pluto anders]$ perl -e 'for (@ARGV) { $word = $_ ;  $word =~ 
s/(\w)/[\U$1\L$1]/g ; push @words, $word }; print q#\b(#, join ("|", @words), 
q#)\b#, "\n"' mortage credit buisness market free cheap valentine insurance 
"hair loss"
\b([Mm][Oo][Rr][Tt][Aa][Gg][Ee]|[Cc][Rr][Ee][Dd][Ii][Tt]|[Bb][Uu][Ii][Ss][Nn]
[Ee][Ss][Ss]|[Mm][Aa][Rr][Kk][Ee][Tt]|[Ff][Rr][Ee][Ee]|[Cc][Hh][Ee][Aa][Pp]|
[Vv][Aa][Ll][Ee][Nn][Tt][Ii][Nn][Ee]|[Ii][Nn][Ss][Uu][Rr][Aa][Nn][Cc][Ee]|[Hh]
[Aa][Ii][Rr] [Ll][Oo][Ss][Ss])\b
[anders at pluto anders]$





More information about the kde-doc-english mailing list