Re: more on lyxtext

2003-03-10 Thread Alfredo Braunstein
John Levon wrote: > Sure you do Hmpf Ok, I'm trying. Alfredo

Re: more on lyxtext

2003-03-10 Thread John Levon
On Mon, Mar 10, 2003 at 10:09:56AM +0100, Alfredo Braunstein wrote: > Hey, be my guest! I don't have the skills. Sure you do john

Re: more on lyxtext

2003-03-10 Thread John Levon
On Mon, Mar 10, 2003 at 08:42:50AM +0100, Andre Poenitz wrote: > The document is _logically_ unchanged after a CursorRight. Wrong. The saved document can contain empty paragraphs. > So what about implementing it and let the rest have a look. This is the > kind of things were consensus is never r

Re: more on lyxtext

2003-03-10 Thread Jean-Marc Lasgouttes
> "Alfredo" == Alfredo Braunstein <[EMAIL PROTECTED]> writes: Alfredo> Jean-Marc Lasgouttes wrote: >> Something I do not understand: you have "aa b cc" and remove the b. >> How do you remove the double space? Alfredo> In option 4), I would remove also one space when removing the Alfredo> 'b'

Re: more on lyxtext

2003-03-10 Thread Alfredo Braunstein
Jean-Marc Lasgouttes wrote: > Something I do not understand: you have "aa b cc" and remove the b. > How do you remove the double space? In option 4), I would remove also one space when removing the 'b' and remember the space to be added for if the user wants to insert something. Or remove it and

Re: more on lyxtext

2003-03-10 Thread Jean-Marc Lasgouttes
> "Alfredo" == Alfredo Braunstein <[EMAIL PROTECTED]> writes: Alfredo> What about removing the double space/par removal mechanism? Alfredo> Before you throw me something in the head, I have some Alfredo> proposals to replace it: Alfredo> Proposal 1) Plain forbid 3 spaces / 2 empty paragraphs

Re: more on lyxtext

2003-03-10 Thread Alfredo Braunstein
John Levon wrote: > deleteEmptyParagraphMechanism. I'm really tempted to try your idea > myself, just to have the pleasure oof the death of DEPM, but I think > you should have the glory (I think reading the Three Musketeers has made > me all chivalrous or something) Hey, be my guest! I don't have

Re: more on lyxtext

2003-03-10 Thread Andre Poenitz
On Mon, Mar 10, 2003 at 10:05:27AM +0100, Lars Gullik Bjønnes wrote: > | The document is _logically_ unchanged after a CursorRight. > > It is not the document we talk about, it is the lyxtext. Ok, I was still mixing up lyxtext and insettext. Sorry for the confusion. Andre' -- Those who desire

Re: more on lyxtext

2003-03-10 Thread Lars Gullik Bjønnes
Andre Poenitz <[EMAIL PROTECTED]> writes: | On Sat, Mar 08, 2003 at 04:06:54PM +0100, Alfredo Braunstein wrote: | > It seems to me that lots of the const/mutable confusion in lyxtext comes | > from the fact that cursor movement methods are declared const but are not | > const at all, mostly becaus

Re: more on lyxtext

2003-03-10 Thread Andre Poenitz
On Sat, Mar 08, 2003 at 09:03:31PM +0100, Lars Gullik Bjønnes wrote: > Because when you change documents you have to rebreak... rebreaking is > expensive and takes time. As it is now. I don't believe there are hard technical reasons why rebreaking has to be expensive. I think all we need is the

Re: more on lyxtext

2003-03-10 Thread Alfredo Braunstein
Hi André. Andre Poenitz wrote: >> As a first step, I propose the removal of constness to all methods that >> are _not_ const, like cursorRight etc. > > I think that's a move in the wrong direction and 'mutable' is indeed the > way to go here. I strongly disagree with you here. > The document

Re: more on lyxtext

2003-03-10 Thread Andre Poenitz
On Sat, Mar 08, 2003 at 07:39:17PM +0100, Alfredo Braunstein wrote: > Also remember that the cursor & selection are members of LyXTexts, Which is completely broken. Both cursor and selection should be implemented on top of proper document iterators, not as some collection of LyXText members... An

Re: more on lyxtext

2003-03-09 Thread Andre Poenitz
On Sat, Mar 08, 2003 at 04:26:05PM +0100, Alfredo Braunstein wrote: > Then you need several lyxtexts (all sharing the same buffer), because a > lyxtext depends on the size of the view. So this marks a bug in the implementation which can e.g. be fixed by moving all drawing caches and helpers which

Re: more on lyxtext

2003-03-09 Thread Andre Poenitz
On Sat, Mar 08, 2003 at 03:26:01PM +, John Levon wrote: > Well the old idea was that you could view the same document multiple > times. Personally I think it's a little bit silly and we're no closer to > being able to do it anyway. I think we are. And this option in mind alone helps a lot to f

Re: more on lyxtext

2003-03-09 Thread Andre Poenitz
On Sat, Mar 08, 2003 at 04:06:54PM +0100, Alfredo Braunstein wrote: > It seems to me that lots of the const/mutable confusion in lyxtext comes > from the fact that cursor movement methods are declared const but are not > const at all, mostly because of the double space/double paragraph removal > me

Re: more on lyxtext

2003-03-09 Thread Christian Ridderström
On Mon, 10 Mar 2003, John Levon wrote: > On Sun, Mar 09, 2003 at 06:32:41PM +0100, Alfredo Braunstein wrote: > > > What about this behaviour (for empty pars): if the cursor is at the end or > > at the start of a par and press enter, then the cursor becomes horizontal > > and places itself between

Re: more on lyxtext

2003-03-09 Thread John Levon
On Sun, Mar 09, 2003 at 06:32:41PM +0100, Alfredo Braunstein wrote: > What about this behaviour (for empty pars): if the cursor is at the end or > at the start of a par and press enter, then the cursor becomes horizontal > and places itself between the two pars. if he inserts or types something >

Re: more on lyxtext

2003-03-09 Thread Alfredo Braunstein
John Levon wrote: > Because your solutions are really awkward otherwise, if we allow it "a > bit". The user won't know what hit them if their empty pars have some > mark around them. The first-time user doesn't know what kind of finger paralisis has got that forbids him to inserts spaces or newli

Re: more on lyxtext

2003-03-09 Thread Alfredo Braunstein
Lars Gullik Bjønnes wrote: > That might be possible. > > I am pondering a bit on the idea on having a fixed mapping > > BufferView -> buffer > > and what this would need of changes. > Could you please ponder loudly? :) I'm in favour of this. After all, _bv_ is a lightweight object, so why to

Re: more on lyxtext

2003-03-08 Thread Lars Gullik Bjønnes
Alfredo Braunstein <[EMAIL PROTECTED]> writes: | Lars Gullik Bjønnes wrote: | | > and then you must cache bv's instead... | | Ah... I see your point I think. Your plan is to have a bufferview for say an | 'actually visible view'. So you will have simultaneosly the same nr. of | bv's as these sho

Re: more on lyxtext

2003-03-08 Thread Alfredo Braunstein
Lars Gullik Bjønnes wrote: > and then you must cache bv's instead... Ah... I see your point I think. Your plan is to have a bufferview for say an 'actually visible view'. So you will have simultaneosly the same nr. of bv's as these shown 'views'. These views can be windows splits or stale windows

Re: more on lyxtext

2003-03-08 Thread Lars Gullik Bjønnes
Alfredo Braunstein <[EMAIL PROTECTED]> writes: | Lars Gullik Bjønnes wrote: | | > Alfredo Braunstein <[EMAIL PROTECTED]> writes: | > | > | Lars Gullik Bjønnes wrote: | > | | > | > Because when you change documents you have to rebreak... rebreaking is | > | > expensive and takes time. that is wh

Re: more on lyxtext

2003-03-08 Thread Alfredo Braunstein
Lars Gullik Bjønnes wrote: > Alfredo Braunstein <[EMAIL PROTECTED]> writes: > > | Lars Gullik Bjønnes wrote: > | > | > Because when you change documents you have to rebreak... rebreaking is > | > expensive and takes time. that is why we have the textcache. > | > > | > | Sorry for being bold. I

Re: more on lyxtext

2003-03-08 Thread Lars Gullik Bjønnes
Alfredo Braunstein <[EMAIL PROTECTED]> writes: | Lars Gullik Bjønnes wrote: | | > Because when you change documents you have to rebreak... rebreaking is | > expensive and takes time. that is why we have the textcache. | > | | Sorry for being bold. I guess I don't know enough lyx terminology to

Re: more on lyxtext

2003-03-08 Thread Lars Gullik Bjønnes
John Levon <[EMAIL PROTECTED]> writes: | On Sat, Mar 08, 2003 at 09:03:31PM +0100, Lars Gullik Bj?nnes wrote: | | > | Sorry, why is this better than having a separate (fixed) lyxtext for every | > | bv? | > | > Because when you change documents you have to rebreak... rebreaking is | > expensive

Re: more on lyxtext

2003-03-08 Thread Alfredo Braunstein
Lars Gullik Bjønnes wrote: > Because when you change documents you have to rebreak... rebreaking is > expensive and takes time. that is why we have the textcache. > Sorry for being bold. I guess I don't know enough lyx terminology to understand you (or I'm just plain dumb). Change documents in w

Re: more on lyxtext

2003-03-08 Thread John Levon
On Sat, Mar 08, 2003 at 09:03:31PM +0100, Lars Gullik Bj?nnes wrote: > | Sorry, why is this better than having a separate (fixed) lyxtext for every > | bv? > > Because when you change documents you have to rebreak... rebreaking is > expensive and takes time. that is why we have the textcache. Wh

Re: more on lyxtext

2003-03-08 Thread Lars Gullik Bjønnes
Alfredo Braunstein <[EMAIL PROTECTED]> writes: | Lars Gullik Bjønnes wrote: | | | > No, not lyxtext charing, but the ability to move a lyxtext between | > bvs. | > | > If you have the same buffer visible in two bvs at the same time then | > there also needs to be two lyxtext. | > | | Sorry,

Re: more on lyxtext

2003-03-08 Thread Alfredo Braunstein
Lars Gullik Bjønnes wrote: > No, not lyxtext charing, but the ability to move a lyxtext between > bvs. > > If you have the same buffer visible in two bvs at the same time then > there also needs to be two lyxtext. > Sorry, why is this better than having a separate (fixed) lyxtext for every b

Re: more on lyxtext

2003-03-08 Thread Lars Gullik Bjønnes
Alfredo Braunstein <[EMAIL PROTECTED]> writes: | Lars Gullik Bjønnes wrote: | | > No, not really. I would be easy enough to set and rest the bv as a | > member in the lyxtext. | | What I say is to have only one bv for every lyxtext. | | So you want to do this lyxtext sharing because of the par

Re: more on lyxtext

2003-03-08 Thread John Levon
On Sat, Mar 08, 2003 at 07:55:32PM +0100, Alfredo Braunstein wrote: > > Blah blah blah.| > > Blah Blah Blah. > > What's the blah? I like much more say option 2 than the current situation. > There are situations in which putting an empty par are handy. For instance > for remembering that you have

Re: more on lyxtext

2003-03-08 Thread Alfredo Braunstein
John Levon wrote: > Blah blah blah.| > Blah Blah Blah. What's the blah? I like much more say option 2 than the current situation. There are situations in which putting an empty par are handy. For instance for remembering that you have to enter text there. Why to forbid it completely? Getting sure

Re: more on lyxtext

2003-03-08 Thread Alfredo Braunstein
Lars Gullik Bjønnes wrote: > No, not really. I would be easy enough to set and rest the bv as a > member in the lyxtext. What I say is to have only one bv for every lyxtext. So you want to do this lyxtext sharing because of the particular case in which the (say two) bv have exactly the same wid

Re: more on lyxtext

2003-03-08 Thread John Levon
On Sat, Mar 08, 2003 at 05:08:35PM +0100, Lars Gullik Bj?nnes wrote: > | But it's forcing us to pass BV around in lyxtext all over the place like > | Alfredo pointed out. > > No, not really. I would be easy enough to set and rest the bv as a > member in the lyxtext. > > Remember that lyxtext is

Re: more on lyxtext

2003-03-08 Thread Lars Gullik Bjønnes
John Levon <[EMAIL PROTECTED]> writes: | On Sat, Mar 08, 2003 at 05:00:49PM +0100, Lars Gullik Bj?nnes wrote: | | > | The cache ? So lets not do that if it's complicating the code | > | everywhere. | > | > The use of the cache does not complicate code in a lot of places... | > only a couple of p

Re: more on lyxtext

2003-03-08 Thread John Levon
On Sat, Mar 08, 2003 at 05:00:49PM +0100, Lars Gullik Bj?nnes wrote: > | The cache ? So lets not do that if it's complicating the code > | everywhere. > > The use of the cache does not complicate code in a lot of places... > only a couple of places in BufferView. But it's forcing us to pass BV a

Re: more on lyxtext

2003-03-08 Thread Lars Gullik Bjønnes
John Levon <[EMAIL PROTECTED]> writes: | On Sat, Mar 08, 2003 at 04:48:31PM +0100, Lars Gullik Bj?nnes wrote: | | > | I don't think anybody would grieve for the loss of DEPM, as initiates | > | into its ways know it. I would say: GO FOR IT. I bet it's not even | > | mega-hard ! | > | > depm is n

Re: more on lyxtext

2003-03-08 Thread John Levon
On Sat, Mar 08, 2003 at 04:48:31PM +0100, Lars Gullik Bj?nnes wrote: > | I don't think anybody would grieve for the loss of DEPM, as initiates > | into its ways know it. I would say: GO FOR IT. I bet it's not even > | mega-hard ! > > depm is not the complexity that I would work to remove first. I

Re: more on lyxtext

2003-03-08 Thread Lars Gullik Bjønnes
John Levon <[EMAIL PROTECTED]> writes: | I don't think anybody would grieve for the loss of DEPM, as initiates | into its ways know it. I would say: GO FOR IT. I bet it's not even | mega-hard ! depm is not the complexity that I would work to remove first. I'd rather try to get rid of the hardcode

Re: more on lyxtext

2003-03-08 Thread John Levon
On Sat, Mar 08, 2003 at 04:41:15PM +0100, Christian Ridderstr?m wrote: > 1. Create text in LyX Code environment. > 2. Add lots of spaces in sequence > 3. Convert to standard environment > 4. Move with the cursor (left/right) and watch the spaces disappear one > by one... > Well... probably that

Re: more on lyxtext

2003-03-08 Thread Christian Ridderström
On Sat, 8 Mar 2003, Alfredo Braunstein wrote: > > What about removing the double space/par removal mechanism? Before you throw > me something in the head, I have some proposals to replace it: > This reminded me of a funny behaviour I've forgot to report. 1. Create text in LyX Code environment.

Re: more on lyxtext

2003-03-08 Thread John Levon
On Sat, Mar 08, 2003 at 04:26:05PM +0100, Alfredo Braunstein wrote: > > How on earth do I insert a new paragraph then ? How do I insert a word ? > > Have a brick from me too ! Though from me it's only a rubber brick. > > You type the paragraph, then enter. Or the word, then space. And what about

Re: more on lyxtext

2003-03-08 Thread Alfredo Braunstein
John Levon wrote: > On Sat, Mar 08, 2003 at 04:06:54PM +0100, Alfredo Braunstein wrote: > >> Proposal 3) A space after a space is forbidden, a space before makes the >> cursor move to the right. Same for paragraphs: an enter after a newline >> forbidden, an enter before a newline goes down. > >

Re: more on lyxtext

2003-03-08 Thread Lars Gullik Bjønnes
John Levon <[EMAIL PROTECTED]> writes: | On Sat, Mar 08, 2003 at 04:06:54PM +0100, Alfredo Braunstein wrote: | | > Proposal 3) A space after a space is forbidden, a space before makes the | > cursor move to the right. Same for paragraphs: an enter after a newline | > forbidden, an enter before a

Re: more on lyxtext

2003-03-08 Thread John Levon
On Sat, Mar 08, 2003 at 04:06:54PM +0100, Alfredo Braunstein wrote: > Proposal 3) A space after a space is forbidden, a space before makes the > cursor move to the right. Same for paragraphs: an enter after a newline > forbidden, an enter before a newline goes down. How on earth do I insert a new

Re: more on lyxtext

2003-03-08 Thread Lars Gullik Bjønnes
Alfredo Braunstein <[EMAIL PROTECTED]> writes: | | Ok, now you can throw me something in the head. I have a *brick* for you here. -- Lgb

more on lyxtext

2003-03-08 Thread Alfredo Braunstein
It seems to me that lots of the const/mutable confusion in lyxtext comes from the fact that cursor movement methods are declared const but are not const at all, mostly because of the double space/double paragraph removal mechanism. As a first step, I propose the removal of constness to all methods