Uwe Stöhr wrote: > Jürgen Spitzmüller schrieb: > >> + Length indentation; > > > > Why not HSpace indentation? > > The last email you suggested to introduce an HspaceKind enum to Length, now > I should leave Length untouched but introduce an HSpace class.
No, you probably misunderstood me. I suggested a HSpace class. Quoting myself: >>The by far best method, I think, would be to setup a HSpace class similar to >>the VSpace class. This class could inherit Length and DEFAULT. I.e., >> >> enum HSpaceKind { >> DEFAULT, >> LENGTH ///< user-defined length >> }; >> >>I think it is trivial to set up such a class if you start from VSpace. > I don't have > time right now to play longer with this issue. Please take my attached path > and finish it as you like. I will learn from how you will implement this > and can take care of the lyx2lyx part when your patch is ready. Sorry. I do not have time either. But there's no need to hurry. It is more important to implement this properly right from the beginning. > >> + // "0" is the case for a new document > > > > Then something is wrong. You have to initialize HSpace to default. > > Where is this done? I'm going crazy with the source code. There's no > information about the structure. I mean how is Buffer.cpp connected to > BufferParams.cpp and to GuiDocument.cpp? Where are parameters initialized? > Where are length visualized in LyX... The BufferParams constructor (BufferParams.cpp, line 322ff.). Adding indendation = "default" will do the trick. But if you set up a HSpace class, this will probably be not needed, since the class itself will construct the correct default. > thanks and regards Uwe Jürgen