Re: [PATCH] add meta info to EmbeddedFile (to solve InsetBibtex problems).

2008-03-28 Thread Bo Peng
> OK. I can see this then, and can adjust for it. That said, however, > speaking as a potential user of this feature, I find this very > counterintuitive. I select a bibliography file, choose "Embed" (let's > say the document is already in embedded status), and now the edits I > make the file

Re: LyX1.6svn Build Errors Mac OSX 10.5.2 Leopard

2008-03-28 Thread Pavel Sanda
> It fails on src/insets/InsetBibtex.cpp where an #include is needed > and in src/support/abort.cpp where an #include is required. > > The later is funny because #include is not enough. > > That file has a > > #ifdef HAVE_STDLIB_H > # include > #endif > > because the C standard does not re

Re: LyX1.6svn Build Errors Mac OSX 10.5.2 Leopard

2008-03-28 Thread Pavel Sanda
> Convert.cpp now compiles with the patch added. > I also had to add > #include > to socktools.cpp to get it to compile. yes, these headers seems to be ok. i commited them. > However, I still get the fo;;owing strange failure: maybe Stefan has some idea? > /bin/sh ../../libtool --mode=compil

Re: [PATCH] add meta info to EmbeddedFile (to solve InsetBibtex problems).

2008-03-28 Thread rgheck
Bo Peng wrote: Allow me to answer this critical question first: Why does it need to happen then? (I understand that this is a high-level design question.) This seems like something that needs to happen only when there are certain buffer-level events: Export, saving, etc. For exampl

Re: [PATCH] add meta info to EmbeddedFile (to solve InsetBibtex problems).

2008-03-28 Thread Bo Peng
Allow me to answer this critical question first: > Why does it need to happen then? (I understand that this is a high-level > design question.) This seems like something that needs to happen only > when there are certain buffer-level events: Export, saving, etc. For example, when you insert a

Re: LyX1.6svn Build Errors Mac OSX 10.5.2 Leopard

2008-03-28 Thread Roger Mc Murtrie
On 29/03/2008, at 3:28 AM, [EMAIL PROTECTED] wrote: Roger, the following patch helps wrt convert.cpp ? pavel Pavel Convert.cpp now compiles with the patch added. I also had to add #include to socktools.cpp to get it to compile. However, I still get the fo;;owing strange failure: /bin/sh .

Re: [PATCH] add meta info to EmbeddedFile (to solve InsetBibtex problems).

2008-03-28 Thread rgheck
Bo Peng wrote: If you're agreed, I can change the patch this way. The only task is to write the update() method, really---we could just take over the old createBibFiles, but that seems like overkill---and for me to undo some other bits, like registerEmbeddedFile(). OK? I knew we'd figure th

Re: [on-list] Re: Questions about the new site

2008-03-28 Thread Rex C. Eastbourne
[EMAIL PROTECTED] wrote: On Fri, 28 Mar 2008, Rex C. Eastbourne wrote: -How private is the new site at the moment? Should it be shown to anyone outside the developers' list, or should we just keep discussion to the developer's list for now? I don't think it's private at all... there's no guara

Re: Doxygen (was Re: r24006 [1/2] - in /lyx-devel/trunk/src: LyXFunc.cpp Makef...)

2008-03-28 Thread Abdelrazak Younes
Andre Poenitz wrote: On Fri, Mar 28, 2008 at 08:47:45AM +0100, Abdelrazak Younes wrote: [EMAIL PROTECTED] wrote: -/** Used to insert bibitem's information (key and label) +/ +// +// InsetBibItem +// +//

Re: Doxygen (was Re: r24006 [1/2] - in /lyx-devel/trunk/src: LyXFunc.cpp Makef...)

2008-03-28 Thread Abdelrazak Younes
Andre Poenitz wrote: On Fri, Mar 28, 2008 at 08:47:45AM +0100, Abdelrazak Younes wrote: [EMAIL PROTECTED] wrote: -/** Used to insert bibitem's information (key and label) +/ +// +// InsetBibItem +// +//

Re: space insets are broken in trunk due to insets optimizations

2008-03-28 Thread Andre Poenitz
On Fri, Mar 28, 2008 at 03:04:48AM +0100, Uwe Stöhr wrote: > André, > as you stated in > http://www.lyx.org/trac/changeset/24006: > > "please check your favourite insets, I am sure I broke _something_..." > > I found out that the space insets are now totally broken: > http://bugzilla.lyx.org/show_b

[on-list] Re: Questions about the new site

2008-03-28 Thread christian . ridderstrom
On Fri, 28 Mar 2008, Rex C. Eastbourne wrote: Hi Christian, I have two questions about the new site. -How can I view a list of all the pages that have been created on the new site? It's easy if you know how to do it, just search for '/'. Or if you want all pages in a particular group, sear

Re: Doxygen (was Re: r24006 [1/2] - in /lyx-devel/trunk/src: LyXFunc.cpp Makef...)

2008-03-28 Thread Andre Poenitz
On Fri, Mar 28, 2008 at 08:47:45AM +0100, Abdelrazak Younes wrote: > [EMAIL PROTECTED] wrote: > >> -/** Used to insert bibitem's information (key and label) >> +/ >> +// >> +// InsetBibItem >> +// >> +//

Re: Doxygen (was Re: r24006 [1/2] - in /lyx-devel/trunk/src: LyXFunc.cpp Makef...)

2008-03-28 Thread Andre Poenitz
On Fri, Mar 28, 2008 at 08:47:45AM +0100, Abdelrazak Younes wrote: > [EMAIL PROTECTED] wrote: > >> -/** Used to insert bibitem's information (key and label) >> +/ >> +// >> +// InsetBibItem >> +// >> +//

Re: [PATCH] add meta info to EmbeddedFile (to solve InsetBibtex problems).

2008-03-28 Thread Bo Peng
> If you're agreed, I can change the patch this way. The only task is to > write the update() method, really---we could just take over the old > createBibFiles, but that seems like overkill---and for me to undo some > other bits, like registerEmbeddedFile(). OK? > > I knew we'd figure this out

Re: LyX1.6svn Build Errors Mac OSX 10.5.2 Leopard

2008-03-28 Thread José Matos
On Friday 28 March 2008 16:24:20 Pavel Sanda wrote: > courageous ;)  http://it.slashdot.org/article.pl?sid=08/03/18/2335206 I am not running this on x86_64 that was affected by this particular bug, but even if I was a fix was ready. So I have no complain. > btw i have seen some complaint about

RE: Re: drawing problems?

2008-03-28 Thread Leuven, E.
Abdel wrote: >> comments? > > None. ok to commit?

Re: Updating Buffer::embeddedFiles

2008-03-28 Thread rgheck
Abdelrazak Younes wrote: [snip, snip, snip] Just return early if there's nothing to do. i.e. no performance penalty. OK. I'm going to put this message in my special saved messages bit in case we end up needing this more global approach. rh

Re: [PATCH] add meta info to EmbeddedFile (to solve InsetBibtex problems).

2008-03-28 Thread rgheck
Abdelrazak Younes wrote: If you want my 2 euro cents Having read superficially this thread, I think Richard has a point here. I don't think the performance penalty will be sensible going this way... Yeah, well nobody asked your view. (There would be a smiley there, but it's Friday, right?)

Re: [PATCH] add meta info to EmbeddedFile (to solve InsetBibtex problems).

2008-03-28 Thread rgheck
I think we're nearing a solution. You've got two parallel representations of the parameters, one in the EmbeddedFileList and one in the InsetCommandParams, and there is simply no way to guarantee that they are synchronized and therefore that you don't over-write information that was committ

Re: drawing problems?

2008-03-28 Thread Abdelrazak Younes
Leuven, E. wrote: slowly learning... I was about to suggest those changes ;-) the attached works! Good! comments? None. Abdel.

Re: Updating Buffer::embeddedFiles

2008-03-28 Thread Abdelrazak Younes
rgheck wrote: Abdelrazak Younes wrote: Bo, Richard, This all business seems very complicated. May I suggest that you use the same technique as for labels and refs? I am talking about initView()/updateLabels()/addToToc(). Don't be mislead by the method names, those should be renamed to: * i

Re: LyX1.6svn Build Errors Mac OSX 10.5.2 Leopard

2008-03-28 Thread Pavel Sanda
> > $ g++ t.cpp > > t.cpp: In function ???int main()???: > > t.cpp:4: error: ???strtol??? is not a member of ???std??? > > > > strtol is declared in > > http://www.cplusplus.com/reference/clibrary/cstdlib/strtol.html > > PS: As you know by now I am using gcc 4.3.0 courageous ;) http://it.slashd

Re: [PATCH] add meta info to EmbeddedFile (to solve InsetBibtex problems).

2008-03-28 Thread Abdelrazak Younes
rgheck wrote: Bo Peng wrote: Hi, Richard, I think most of your problems can be solved in a less-radical way, by saving relative path, or something like that, so that you can recover user input. The attached patch tries to do exactly this. It adds meta_ to EmbeddedFile and allow InsetBibtex to

Re: LyX1.6svn Build Errors Mac OSX 10.5.2 Leopard

2008-03-28 Thread Pavel Sanda
> > I am not. :-) > $ g++ t.cpp > t.cpp: In function ???int main()???: > t.cpp:4: error: ???strtol??? is not a member of ???std??? > > strtol is declared in > http://www.cplusplus.com/reference/clibrary/cstdlib/strtol.html ai :) btw have you tried to put '' into google :D ? Roger, the followin

Re: Updating Buffer::embeddedFiles

2008-03-28 Thread rgheck
Abdelrazak Younes wrote: Bo, Richard, This all business seems very complicated. May I suggest that you use the same technique as for labels and refs? I am talking about initView()/updateLabels()/addToToc(). Don't be mislead by the method names, those should be renamed to: * initView(): init

Re: LyX1.6svn Build Errors Mac OSX 10.5.2 Leopard

2008-03-28 Thread José Matos
On Friday 28 March 2008 15:51:39 José Matos wrote: > On Friday 28 March 2008 15:40:09 Pavel Sanda wrote: > > #include > > > > int main(){ > > return std::strtol("5",0,10); > > } > > I am not. :-) > $ g++ t.cpp > t.cpp: In function ‘int main()’: > t.cpp:4: error: ‘strtol’ is not a member of

Re: [PATCH] add meta info to EmbeddedFile (to solve InsetBibtex problems).

2008-03-28 Thread Bo Peng
> I hate to be a pain the ... about this, but I am morally certain that > this will not work, at least in the long term. The problem isn't just > the lack of meta-info. It's the fact that this way of doing things is > completely contrary to how the InsetCommand hierarchy is supposed to > work.

Re: Updating Buffer::embeddedFiles

2008-03-28 Thread rgheck
Bo Peng wrote: I don't really understand this. The registered file will get its enabled status when it's constructed: EmbeddedFile::EmbeddedFile(std::string const & file, std::string const & inzipName, bool embed, Buffer const & buf) : DocFileName("", false), inzip_name_(inzipName)

Re: Updating Buffer::embeddedFiles

2008-03-28 Thread Bo Peng
> I don't really understand this. The registered file will get its enabled > status when it's constructed: > EmbeddedFile::EmbeddedFile(std::string const & file, > std::string const & inzipName, bool embed, Buffer const & buf) > : DocFileName("", false), inzip_name_(inzipName), inset

Re: [PATCH] add meta info to EmbeddedFile (to solve InsetBibtex problems).

2008-03-28 Thread rgheck
Bo Peng wrote: Hi, Richard, I think most of your problems can be solved in a less-radical way, by saving relative path, or something like that, so that you can recover user input. The attached patch tries to do exactly this. It adds meta_ to EmbeddedFile and allow InsetBibtex to add 'biblio' to

Re: Updating Buffer::embeddedFiles

2008-03-28 Thread Bo Peng
> > This is wrong. Because buffer_->embeddedFiles(), unless an update() is > > called, > > > updateBibfilesCache() calls EmbeddedFileList::enable(), which calls > update(). This is what the other question was about, really. > > +} > The vector tells us what files we have, and

Re: Updating Buffer::embeddedFiles

2008-03-28 Thread rgheck
Bo Peng wrote: On Thu, Mar 27, 2008 at 9:47 PM, Bo Peng <[EMAIL PROTECTED]> wrote: I am reading your patch and hopefully can make it > work. void InsetBibtex::registerEmbeddedFiles(EmbeddedFileList & files) const { - if (bibfiles_.empty()) - createBibFi

Re: Updating Buffer::embeddedFiles

2008-03-28 Thread Bo Peng
> OK, that's helpful by way of explanation. But here's where I was getting > the crash: You have an existing InsetBibtex, embedded, and then you > change the bibfiles. Now you try to save. Boom, because the newly chosen > bibfiles haven't been copied and, when the exception is thrown, LyX > tr

Re: LyX1.6svn Build Errors Mac OSX 10.5.2 Leopard

2008-03-28 Thread José Matos
On Friday 28 March 2008 15:40:09 Pavel Sanda wrote: > #include > > int main(){ > return std::strtol("5",0,10); > } I am not. :-) $ g++ t.cpp t.cpp: In function ‘int main()’: t.cpp:4: error: ‘strtol’ is not a member of ‘std’ strtol is declared in http://www.cplusplus.com/reference/clibra

Re: Updating Buffer::embeddedFiles

2008-03-28 Thread rgheck
Bo Peng wrote: I am reading your patch and hopefully can make it work. + // Make sure we are up to date. + buffer_->updateBibfilesCache(); + EmbeddedFileList & efl = buffer_->embeddedFiles(); + vector const files = getFiles(); +

Re: LyX1.6svn Build Errors Mac OSX 10.5.2 Leopard

2008-03-28 Thread Pavel Sanda
> Pavel, > I tried your patch in support/convert.cpp: > namespace lyx { > using boost::lexical_cast; > +using std::strtol; > +using std::strtoul; > +using std::strtod; > template<> > string convert(bool b) > But I got the same errors: are you able to compile the attached ? pavel #include int m

Re: Updating Buffer::embeddedFiles

2008-03-28 Thread rgheck
Bo Peng wrote: It seems to me that it would be a good idea, in general, if we were to do that after, say, InsetInclude's parameters were changed. I saw some crashes with InsetBibtex that were related to my not updating this structure. E.g., I changed the bibfiles and then tried to save, but t

RE: Re: drawing problems?

2008-03-28 Thread Leuven, E.
Edwin wrote: > the attached works! and the proof: http://leuven.economists.nl/lyx/selection.png

RE: Re: drawing problems?

2008-03-28 Thread Leuven, E.
slowly learning... the attached works! comments? Index: src/Color.cpp === --- src/Color.cpp (revision 24016) +++ src/Color.cpp (working copy) @@ -102,6 +102,8 @@ { Color_background, N_("background"), "background", "linen", "b

Re: Embedded Files

2008-03-28 Thread Jean-Marc Lasgouttes
"Bo Peng" <[EMAIL PROTECTED]> writes: > When I re-think this problem, the current approach should work just > fine. It is true that these files might be anywhere, but EmbeddedFile > will *not* embed them if it can not find it. As long as the latex > output is corrected written through the use of a

Re: Embedded Files

2008-03-28 Thread Bo Peng
> I do not think that even a InsetGraphics object has to be a valid > file. If I have Logo_INRIA.pdf in my TeX path at work, I want to be > able to use it. Currently, LyX does not find graphics through > kpsewhich, but there has been a request for that (and I think we > should do it). Therefor

Re: More website progress

2008-03-28 Thread Pavel Sanda
> I'm going to gradually keep adding and fixing stuff. Please feel free to > jump in and make changes. if you want some feedback,than: - we should use bigger fonts (at least what the current wiki has). - could be the width bigger or even automatically stretch to the whole screen? on my screen t

RE: Re: drawing problems?

2008-03-28 Thread Leuven, E.
Abdel wrote: > You should use Row::sel_beg and Row::sel_end instead of > cursor().selBegin().pos() and cursor().selEnd().pos(). thanks. the attached *almost* works, but the text in the whole row where the selection starts/ends ends up being marked as selected (hope i am clear). haven't been abl

lyx1.6svn24004 beamer alert problem

2008-03-28 Thread Neal Becker
The "alert" seems to do nothing to the character style in this example: newfile2.lyx Description: application/lyx

Re: Need Urgent Help

2008-03-28 Thread Ankur Verma
Hi Liviu and John. Thank you for your help. I am entering the equations graphically thorugh LyX. After some tweaking, I can succesfully export the pdf from it, but don't know how is it working! I entered the equation and they were in blue color like this: RH=c1+c2*result+c3*result^{2} but when

Re: drawing problems?

2008-03-28 Thread Abdelrazak Younes
Edwin Leuven wrote: i am trying to get a different text color in a selection (not very succesfully up until now) and have the attached code which only changes some color settings in rowpainter now the odd thing is that if i start selecting regular text, the cells in (an adjacent) tabular are

Re: selection with cursor in math is broken

2008-03-28 Thread Abdelrazak Younes
Abdelrazak Younes wrote: Andre Poenitz wrote: During selection one can't leave a nested inset anymore. Confirmed. Hum... probably my fault, I'll have a look. Doesn't seem to be my fault after all, I only changed the text mouse selection part... Abdel.

Re: Need Urgent Help

2008-03-28 Thread Liviu Andronic
On Fri, Mar 28, 2008 at 9:46 AM, Ankur Verma <[EMAIL PROTECTED]> wrote: > without the equations. But I cannot export a pdf or dvi, when I copy the > equations into the .lyx file. Could not say whether this would lead anywhere, but how exactly did you enter the equations (using ERT or graphically

Re: space insets are broken in trunk due to insets optimizations

2008-03-28 Thread Jean-Marc Lasgouttes
Uwe Stöhr <[EMAIL PROTECTED]> writes: > But when you are sure you break something, why do you commit it then? Because he does not know _what_ is broken? JMarc

Re: Need Urgent Help

2008-03-28 Thread John McCabe-Dansted
On Fri, Mar 28, 2008 at 5:46 PM, Ankur Verma <[EMAIL PROTECTED]> wrote: > The problem which I am facing is solved when I remove the equations from > .lyx file. Now, I can successfully export the pdf from the .lyx file, > without the equations. But I cannot export a pdf or dvi, when I copy t

Re: i18n - some progress

2008-03-28 Thread Jean-Marc Lasgouttes
[EMAIL PROTECTED] writes: > Just to let you know that I've made some progress on generation i18n > statistics, see here: > > http://www.lyx.org/~chr/www/index.php/Main/I18n > > Basically I've ported the code in i18n.php into a pmwiki directive. Very good, except that the URLs are unreadable

Re: More website progress

2008-03-28 Thread Jean-Marc Lasgouttes
[EMAIL PROTECTED] writes: > I'm waiting for Jean-Marc, so that I can test the site closer to the > real URI. Ah yes, you are waiting for me :) In what directory do you want this stuff? Can you tell me again what options you want? JMarc

Re: [Cvslog] r23983 - /lyx-devel/trunk/src/BufferView.cpp

2008-03-28 Thread Jean-Marc Lasgouttes
Abdelrazak Younes <[EMAIL PROTECTED]> writes: >>> i was thinking about some shortcut for find next, but both F3 and >>> CTRL+N are already used. suggestions? >> >> F3 >> >> there is no need to bind file-open twice > > Agreed. For reference, here is what microsoft says about common shortcuts: http

Re: InsetListing_s_?

2008-03-28 Thread Jean-Marc Lasgouttes
Andre Poenitz <[EMAIL PROTECTED]> writes: >> Because the package is named listings. > > Hm... this is a reason... but I am not sure I think it's a good enough > reason ;-) Especially since the inset can only hold one listing and the relevant LaTeX commands do not have the 's'... JMarc

Re: Need Urgent Help

2008-03-28 Thread Ankur Verma
Hi Liviu. Thanks for your reply. The problem which I am facing is solved when I remove the equations from .lyx file. Now, I can successfully export the pdf from the .lyx file, without the equations. But I cannot export a pdf or dvi, when I copy the equations into the .lyx file. I am using L

Re: Discrepnacies between fils upgraded to 1.6 from 1.5.4

2008-03-28 Thread Jean-Marc Lasgouttes
Jean-Pierre Chrétien <[EMAIL PROTECTED]> writes: > Bug 4679. > > But shouldn't LyX use internally lyx2lyx to manage format? One of he files has been written directly by LyX, the other one is a lyx2lyx translation of a file written by a previous verison of LyX. The code used is therefore different

Re: Embedded Files

2008-03-28 Thread Jean-Marc Lasgouttes
"Bo Peng" <[EMAIL PROTECTED]> writes: >> I'm skeptical that this will solve the problems. The issue doesn't >> really have anything to do with relative versus absolute paths. If I >> choose "biblio" as my BibTeX file, that is NOT a pathname. > > I see your point now. Unlike InsetInclude and Ins

Re: Discrepnacies between fils upgraded to 1.6 from 1.5.4

2008-03-28 Thread Jean-Pierre Chrétien
José Matos <[EMAIL PROTECTED]> writes: > > On Thursday 27 March 2008 17:36:34 Jean-Pierre Chrétien wrote: > > This seems harmless as both files can be edited in lyx-1.6svn, but > > does it deserve an entry in bugzilla ? > > Yes, it does. This means that some of the previous lyx2lyx convertions

Doxygen (was Re: r24006 [1/2] - in /lyx-devel/trunk/src: LyXFunc.cpp Makef...)

2008-03-28 Thread Abdelrazak Younes
[EMAIL PROTECTED] wrote: -/** Used to insert bibitem's information (key and label) +/ +// +// InsetBibItem +// +/ - Must be automatically inserted as

Re: Updating Buffer::embeddedFiles

2008-03-28 Thread Abdelrazak Younes
Bo Peng wrote: On Thu, Mar 27, 2008 at 9:59 PM, Bo Peng <[EMAIL PROTECTED]> wrote: On Thu, Mar 27, 2008 at 9:47 PM, Bo Peng <[EMAIL PROTECTED]> wrote: > > I am reading your patch and hopefully can make it > > work. > +EmbeddedFile const * EmbeddedFileList::findFile(std::string const & fi