On 2015-08-19, alex wrote:
> I have managed to write a serviceable script that uses LyX server and 
> LFUNs and toggles between languages only with the shortcut Alt + Shift. 
> I am quite pleased with the result, but I have come up with a slight 
> improvement, that can be achieved by tracking the current language used 
> to spell check in LyX. However, all the LFUNs seem to be 
> "one-directional", that is they transfer information from the external 
> application to LyX. Is there a way (for example, a get-language LFUN 
> that I am missing) to echo the current LyX language in the terminal, so 
> that I can use it in a script?

I don't know of any. Did you have a look in the Help>Lfuns (or what it is
called in English or Greek) manual?

OTOH, if you know tie the system-keybord-layout and the text language in LyX¹
it should be fairly easy: "language greek" when the keybord layout is set to
Greek, "language english" (or whatever you use as secondary language), else.
It may become a problem if you use several non-Greek languages or language
variants.

Günter




¹ not only used for spellchecking, but also for hyphenation and
  auto-generated strings.

Reply via email to