>>>>> "Abdelrazak" == Abdelrazak Younes <[EMAIL PROTECTED]> writes:
>> The fact that the bv is not known where it should be simply >> indicates that the methods in questions are lacking a bv parameter. >> For example InsetTabular::dist should have this parameter, which >> means that InsetTabular::getNearestCell should have it too (which >> is not a problem since there is a cursor around when it is called). >> All these changes make sense, so they should be done. Abdelrazak> The think is that once we add the additional argument Abdelrazak> somewhere then it will be needed to all methods in the Abdelrazak> calling hierarchy (butterfly effect). Yes, but I suspect that the bv is known without going too high in the hierarchy. Abdelrazak> Passing BufferView to every method of InsetBase does not Abdelrazak> seem very clean to me. I would prefer to add a BufferView Abdelrazak> reference member to InsetBase filled at construction. I Abdelrazak> don't think InsetBase should be BufferView independent but Abdelrazak> perhaps I am wrong. What do you think? Is it every methods? It is needed for things like xo(), which are definitely BufferView-dependent. The two solutions are - add a BufferView const & argument to InsetBase::[xy]o() and InsetBase::covers. - move these methods (which are not virtual anyway) out of InsetBase. They could be replaced by a helper function in bufferview_funcs, for example. Things like dist() could be moved also. JMarc