Dov Feldstern wrote:

b. Probably the visual_cursor option should only be enabled if rtl_support is on --- if rtl_support is false, visual_cursor should definitely be false, and should be disabled in the GUI (only because it uses the bidi tables, which will not be computed in the non-rtl_support case). What's the best way of going about this --- both in terms of the GUI presentation, and should there be any further enforcement in the code, or is it enough if the GUI will take care of it?

I think it should be enough.


2. the actual visual-mode functionality. Currently only Left has been implemented, Right will more or less mirror it. I hope to get to it in the next few days, but I figured I might as well get feedback now that the framework is in place.

Sorry Dov, this is an area I am interested in but I don't have the time to properly review your patches. Just a stylish issue: I just had a quick glance at the code and I noticed that you almost never make use of the "return early" idiom. Just in case, I will explain what this is about:

Bad style:

if (foo) {
        return false;
} else {
        bar;
        return true;
}

Good Style:

if (foo)
        return false;
bar;
return true;

Please try to make those corrections before you commit.

Debug printouts --- I'd like to leave them in for future debugging. How do I add, and make use of, a debug category for them (or is there an existing category which I should use)?

What about RTL? i.e. instead of 'lyxerr << xxx' you should use 'LYXERR(Debug::RTL, xxx)'

Abdel.

Reply via email to