Re: Source question
John Levon <[EMAIL PROTECTED]> writes: | Is this acceptable : | | bool someNewFunction(BufferView & bv) | { | someOldFunction(&bv); | } | | If we're not allowed to do this, then transitioning to using references | where pointers are not necessary is going to be really difficult As a temporary thing it is acceptable, but it should be marked with comments in the code. -- Lgb
Source question
Is this acceptable : bool someNewFunction(BufferView & bv) { someOldFunction(&bv); } If we're not allowed to do this, then transitioning to using references where pointers are not necessary is going to be really difficult regards john -- "Yeah, I woke up in the day accidentally once, the moon was on fire for some reason and I couldn't see very well and all the bandwidth disappeared, it was very scary :(" - Orion
Re: Source question
On Fri, Dec 07, 2001 at 11:37:38AM +0100, Jean-Marc Lasgouttes wrote: > John> Why do we have the check for cursor.pos() ? It works fine > John> without, as we check cursor.par()->size() at the start. If we > John> change the above to always do > > I'll try to have a look this week end. don't bother. Here is the case that needs that code : |blahblah blah press return. dumb patch, in all ways ... john -- "Faced with the prospect of rereading this book, I would rather have my brains ripped out by a plastic fork." - Charles Cooper on "Business at the Speed of Thought"
Re: Source question
> "John" == John Levon <[EMAIL PROTECTED]> writes: John> Why do we have the check for cursor.pos() ? It works fine John> without, as we check cursor.par()->size() at the start. If we John> change the above to always do I'll try to have a look this week end. John> setCursor(bview, cursor.par()->next(), 0); John> (after setting lyx code to KeepEmpty 1, which it should be right John> ?), then you can type empty lines with lyx-code, i.e. fix a bug Check that LaTeX likes it, and that the output makes sense. JMarc
Source question
in breakParagraph : 1739/* This check is necessary. Otherwise the new empty paragraph will 1740 * be deleted automatically. And it is more friendly for the user! */ 1741if (cursor.pos()) 1742setCursor(bview, cursor.par()->next(), 0); 1743else 1744setCursor(bview, cursor.par(), 0); Why do we have the check for cursor.pos() ? It works fine without, as we check cursor.par()->size() at the start. If we change the above to always do setCursor(bview, cursor.par()->next(), 0); and have : 1664 // can't break on empty paragraphs usually 1665 if ((cursor.par()->size() <= 0) && !layout.keepempty 1666 && layout.labeltype != LABEL_SENSITIVE) 1667 return; (after setting lyx code to KeepEmpty 1, which it should be right ?), then you can type empty lines with lyx-code, i.e. fix a bug Getting backspace to work properly is a bit harder ... john -- "Faced with the prospect of rereading this book, I would rather have my brains ripped out by a plastic fork." - Charles Cooper on "Business at the Speed of Thought"