Re: r35714 - lyx-devel/trunk/src/frontends/qt4

2010-10-27 Thread Andre Poenitz
On Wed, Oct 27, 2010 at 06:34:22AM +0200, Vincent van Ravesteijn wrote: > >> I did something like this for Buffer::loadLyxFile(). Where would you > >> advice to put the UI then ? I can now spit out a lot of error messages > >> according to the number the functions comes up with. In Buffer ? In > >>

Re: r35714 - lyx-devel/trunk/src/frontends/qt4

2010-10-27 Thread Abdelrazak Younes
On 10/27/2010 06:34 AM, Vincent van Ravesteijn wrote: I did something like this for Buffer::loadLyxFile(). Where would you advice to put the UI then ? I can now spit out a lot of error messages according to the number the functions comes up with. In Buffer ? In buffer_funcs ? In GuiView ?

Re: r35714 - lyx-devel/trunk/src/frontends/qt4

2010-10-26 Thread Vincent van Ravesteijn
>> I did something like this for Buffer::loadLyxFile(). Where would you >> advice to put the UI then ? I can now spit out a lot of error messages >> according to the number the functions comes up with. In Buffer ? In >> buffer_funcs ? In GuiView ? > > Any direct user interaction in src/frontends/*,

Re: r35714 - lyx-devel/trunk/src/frontends/qt4

2010-10-25 Thread Andre Poenitz
On Mon, Oct 25, 2010 at 07:43:54PM +0200, Vincent van Ravesteijn wrote: > > The only safe way to use them is when you control not only "sender" and > > "receiver" but also all the code paths inbetween - i.e. basically only > > within the same function or at least not from a deeply nested function.

Re: r35714 - lyx-devel/trunk/src/frontends/qt4

2010-10-25 Thread Vincent van Ravesteijn
> The only safe way to use them is when you control not only "sender" and > "receiver" but also all the code paths inbetween - i.e. basically only > within the same function or at least not from a deeply nested function. > And in that cases using a singular return value does the trick as well. > >

Re: r35714 - lyx-devel/trunk/src/frontends/qt4

2010-10-19 Thread Andre Poenitz
On Tue, Oct 19, 2010 at 10:55:35AM -0400, Richard Heck wrote: > We had this discussion recently, when I introduced an exception in > math processing. There are real downsides to this of a return value. > Granted, C++ provides less support for the use of "normal" > exceptions than Java or Python doe

Re: r35714 - lyx-devel/trunk/src/frontends/qt4

2010-10-19 Thread Richard Heck
On 10/19/2010 10:59 AM, Pavel Sanda wrote: Richard Heck wrote: We had this discussion recently, when I introduced an exception in math processing. There are real downsides to this of a return value. Granted, what was the result in short? Nothing, really. Some of us thought one th

Re: r35714 - lyx-devel/trunk/src/frontends/qt4

2010-10-19 Thread Vincent van Ravesteijn
When trying to load the test case, a parse exception is thrown, and the load is aborted. However, the newly created buffer is still there, and everything that was read before the exception was thrown is in this buffer. Trying to load the file again, will only switch to this buffer which is incomple

Re: r35714 - lyx-devel/trunk/src/frontends/qt4

2010-10-19 Thread Pavel Sanda
Richard Heck wrote: > We had this discussion recently, when I introduced an exception in math > processing. There are real downsides to this of a return value. Granted, what was the result in short? pavel

Re: r35714 - lyx-devel/trunk/src/frontends/qt4

2010-10-19 Thread Richard Heck
On 10/19/2010 09:08 AM, Pavel Sanda wrote: v...@lyx.org wrote: Author: vfr Date: Tue Oct 19 12:42:54 2010 New Revision: 35714 URL: http://www.lyx.org/trac/changeset/35714 Log: Fix bug #6950: Cursor remains in waiting state after incompatible command. P.S. How do we prevent other cases like

Re: r35714 - lyx-devel/trunk/src/frontends/qt4

2010-10-19 Thread Pavel Sanda
v...@lyx.org wrote: > Author: vfr > Date: Tue Oct 19 12:42:54 2010 > New Revision: 35714 > URL: http://www.lyx.org/trac/changeset/35714 > > Log: > Fix bug #6950: Cursor remains in waiting state after incompatible command. > > P.S. How do we prevent other cases like this? By throwing exceptions, w