dev builds
themes manual
device status forums
mailing lists
IRC bugs
dev guide

Rockbox mail archive

Subject: Re: What function loads a .lang file?
From: Linus Nielsen Feltzing (
Date: 2003-04-27

TP Diffenbach wrote:
> Well, I'm thinking I'll do it another way anyhow.
> But we do have code that assigns pointers to the language strings.
> For example, in settings.c, function set_time

Uh!!! What a bug! We'll have to fix that.

> I wanted to maintain arrays that were subsets of the language_strings
> array, and change mine whenver language_strings was changed.


> Instead I'm thinking of indexing directly into language_strings.

But that is exactly what the str() macro does. Why not use that?

> Admittly, that fails if the strings in english.lang are reorderd, but
> it doesn't seem to be too much of a burden on maintainers to insist
> that like strings be kept together, and in a certain order.

The current concept depends on the order of the strings. Use the str()
macro and stay out of trouble.


Page was last modified "Jan 10 2012" The Rockbox Crew