- ods << "%% The greyedout annotation environment (with RTL support)\n"
- << "\\NewEnviron{lyxgreyedout}{%\n";
- if (lua && !babel)
- // luabidi uses this switch
- ods << " \\if@RTL%\n";
- else
- ods << " \\if@rl%\n";
- ods << " \\everypar{%\n";
- if (lua)
- ods << " \\color{note_fontcolor}\\pardir TRT \\textdir TRT\\ignorespaces%\n"
- << " }%\n";
- else
- ods << " \\textcolor{note_fontcolor}\\beginL\\ignorespaces%\n"
- << " }%\n";
- if (ct)
- ods << " \\colorlet{lyxadded}{lyxadded!30}\\colorlet{lyxdeleted}{lyxdeleted!30}%\n";
- if (lua)
- ods << " \\BODY\\everypar{\\ignorespacesafterend}%\n";
- else
- ods << " \\BODY\\everypar{\\ignorespacesafterend\\endL}%\n";
- ods << " \\else%\n";
- if (ct)
- ods << " \\colorlet{lyxadded}{lyxadded!30}\\colorlet{lyxdeleted}{lyxdeleted!30}%\n";
- ods << " \\textcolor{note_fontcolor}\\bgroup\\ignorespaces%\n"
- << " \\BODY\\ignorespacesafterend\\egroup%\n"
- << " \\fi%\n"
- << "}\n";
+ if (rtl) {
+ ods << "%% The greyedout annotation environment (with RTL support)\n"
+ << "\\NewEnviron{lyxgreyedout}{%\n";
+ if (lua && !babel)
+ // luabidi uses this switch
+ ods << " \\if@RTL%\n";
+ else
+ ods << " \\if@rl%\n";
+ ods << " \\everypar{%\n";
+ if (lua)
+ ods << " \\pardir TRT \\textdir TRT\\textcolor{note_fontcolor}\\ignorespaces%\n";
+ else
+ ods << " \\textcolor{note_fontcolor}\\beginL\\ignorespaces%\n";
+ ods << " }%\n";
+ if (ct)
+ ods << " \\colorlet{lyxadded}{lyxadded!30}\\colorlet{lyxdeleted}{lyxdeleted!30}%\n";
+ if (lua)
+ ods << " \\BODY\\everypar{\\ignorespacesafterend}%\n";
+ else
+ ods << " \\BODY\\everypar{\\ignorespacesafterend\\endL}%\n";
+ ods << " \\else%\n";
+ if (ct)
+ ods << " \\colorlet{lyxadded}{lyxadded!30}\\colorlet{lyxdeleted}{lyxdeleted!30}%\n";
+ ods << " \\textcolor{note_fontcolor}\\bgroup\\ignorespaces%\n"
+ << " \\BODY\\ignorespacesafterend\\egroup%\n"
+ << " \\fi%\n"
+ << "}\n";
+ } else {
+ ods << "%% The greyedout annotation environment\n"
+ << "\\newenvironment{lyxgreyedout}\n"
+ << "{";
+ if (ct)
+ ods << "\\colorlet{lyxadded}{lyxadded!30}\\colorlet{lyxdeleted}{lyxdeleted!30}%\n ";
+ ods << "\\textcolor{note_fontcolor}\\bgroup\\ignorespaces}\n"
+ << "{\\ignorespacesafterend\\egroup}\n";
+ }