Customizing counters of theorem environments.

Rudi Gaelzer rgaelzer at
Wed Jul 21 15:46:08 UTC 2021

I would like to run by you my solution and ask another question.

I copied the files theorems-ams-bytype.module and into my 
local layouts directory (with new names), then edited them accordingly.  For instance, in 
the .inc file, for the Lemma style, inside the Preamble EndPreamble field I included the line 
\thearea being the prefix to the lemma counter.

Did similar things for the other styles, then reconfigured LyX and voila! My customized 
module is accessible (and works as intended).
I just don't know if this solution is sanctioned by you LyX developers...

Now the question I want to ask.
I want to create a new theorem-like environment.  Reading through the Customization.lyx 
manual, I understand that the different translations for the names of the environs reside 
in the layouttranslations file.  Looking into it, it says that

# This file has been automatically generated by po/
# this file from the translations, run `make ../lib/layouttranslations' in po.
# Python polib library is needed for building the output file.

I confess I did not quite grasp the process. Do I have to create a local layouttranslations 
file containing the translations for the new environment name?  Is there a more detailed 
guide for this procedure?

On terça-feira, 20 de julho de 2021 20:20:41 -03 Rudi Gaelzer wrote:
> Well, it seems that the solution is indeed via \renewtheorem.  However, I
> had to dig deep into the installation of AMS theorem to find the proper
> names of the counters. So far, I've found \thethm, \thelem, \thedefn, etc.
> I did not find a full list of counters, so if someone could point me out
> where I can find such a list, I'd be grateful.

Rudi Gaelzer
Institute of Physics
Federal University of Rio Grande do Sul
Registered linux user # 153741
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <>

More information about the lyx-users mailing list