Re: [PATCH] Add LFUN_SERVER_GET_STATISTICS command

2014-10-19 Thread Alfredo Braunstein
On Sun, Oct 19, 2014 at 4:16 PM, Jean-Marc Lasgouttes wrote: > Le 17/10/2014 18:56, Alfredo Braunstein a écrit : >> >> I see. IMO the LFUN way is preferable. I'll give one use case where I >> would find this useful: when writing a document with length >> constraints (e.g. # words, # chars), it wou

Re: [PATCH] Add LFUN_SERVER_GET_STATISTICS command

2014-10-19 Thread Jean-Marc Lasgouttes
Le 17/10/2014 18:56, Alfredo Braunstein a écrit : I see. IMO the LFUN way is preferable. I'll give one use case where I would find this useful: when writing a document with length constraints (e.g. # words, # chars), it would be nice to have the information accessible through a shortcut on the st

Re: [PATCH] Add LFUN_SERVER_GET_STATISTICS command

2014-10-18 Thread Alfredo Braunstein
It's a nice idea, thanks. I once tried something like this for my own use, but I gave up because the precise counting is picky and journal dependent, e.g. for aps journals: http://journals.aps.org/authors/length-guide-faq They want the footnotes, but don't want the bibliography nor figures and equa

Re: [PATCH] Add LFUN_SERVER_GET_STATISTICS command

2014-10-18 Thread Jürgen Spitzmüller
Alfredo Braunstein wrote: > I see. IMO the LFUN way is preferable. I'll give one use case where I > would find this useful: when writing a document with length > constraints (e.g. # words, # chars), it would be nice to have the > information accessible through a shortcut on the status bar (instead

Re: [PATCH] Add LFUN_SERVER_GET_STATISTICS command

2014-10-17 Thread Alfredo Braunstein
Just tested and you're right. A/ On Fri, Oct 17, 2014 at 9:23 PM, Pavel Sanda wrote: > Alfredo Braunstein wrote: >> Btw, it would be also nice to have selection-bound statistics (e.g. in >> some journals / grant calls there are rigid bounds for each section or >> part). > > IIRC statistics dialo

Re: [PATCH] Add LFUN_SERVER_GET_STATISTICS command

2014-10-17 Thread Pavel Sanda
Alfredo Braunstein wrote: > Btw, it would be also nice to have selection-bound statistics (e.g. in > some journals / grant calls there are rigid bounds for each section or > part). IIRC statistics dialog will give you selection-count already. P

Re: [PATCH] Add LFUN_SERVER_GET_STATISTICS command

2014-10-17 Thread Alfredo Braunstein
On Fri, Oct 17, 2014 at 6:56 PM, Alfredo Braunstein wrote: > I see. IMO the LFUN way is preferable. I'll give one use case where I > would find this useful: when writing a document with length > constraints (e.g. # words, # chars), it would be nice to have the > information accessible through a sh

Re: [PATCH] Add LFUN_SERVER_GET_STATISTICS command

2014-10-17 Thread Alfredo Braunstein
I see. IMO the LFUN way is preferable. I'll give one use case where I would find this useful: when writing a document with length constraints (e.g. # words, # chars), it would be nice to have the information accessible through a shortcut on the status bar (instead of going to where the inset was in

Re: [PATCH] Add LFUN_SERVER_GET_STATISTICS command

2014-10-17 Thread Pavel Sanda
Jean-Marc Lasgouttes wrote: > The problem with insetinfo is that havbing to update this information at > every keystroke can be expensive, unless of course the value is not shown > in the edit window (but then you know that this is the next thing people > would ask for...). Bummer indeed. > OT

Re: [PATCH] Add LFUN_SERVER_GET_STATISTICS command

2014-10-17 Thread Pavel Sanda
Alfredo Braunstein wrote: > Sorry for the dumb question, but what is InsetInfo good for (in terms > of usecase). It seems like a very strange concept IMHO. Why can't it > be e.g a dialog or a panel? It's part of the document and it will be printed, so dialog won't work. Originally for shortcuts, n

Re: [PATCH] Add LFUN_SERVER_GET_STATISTICS command

2014-10-17 Thread Alfredo Braunstein
On Fri, Oct 17, 2014 at 9:57 AM, Jean-Marc Lasgouttes wrote: > Le 17/10/2014 04:09, Pavel Sanda a écrit : >> Jean-Marc Lasgouttes wrote: >> >> What usecase lead to this lfun? If the point is to store this info in >> document >> more proper way would be insetinfo. Sorry for the dumb question, but

Re: [PATCH] Add LFUN_SERVER_GET_STATISTICS command

2014-10-17 Thread Stéphane Mourey
Le 17/10/2014 09:57, Jean-Marc Lasgouttes a écrit : Le 17/10/2014 04:09, Pavel Sanda a écrit : Jean-Marc Lasgouttes wrote: Hi, There has been quite a bit of discussion on lyx-fr on the possibility of reading the statistics of a document for further processing. As a result, Stéphane Mourey im

Re: [PATCH] Add LFUN_SERVER_GET_STATISTICS command

2014-10-17 Thread Jean-Marc Lasgouttes
Le 17/10/2014 04:09, Pavel Sanda a écrit : Jean-Marc Lasgouttes wrote: Hi, There has been quite a bit of discussion on lyx-fr on the possibility of reading the statistics of a document for further processing. As a result, Stéphane Mourey implemented a new LFUN, server-get-statistics. If there i

Re: [PATCH] Add LFUN_SERVER_GET_STATISTICS command

2014-10-16 Thread Pavel Sanda
Jean-Marc Lasgouttes wrote: > Hi, > > There has been quite a bit of discussion on lyx-fr on the possibility of > reading the statistics of a document for further processing. As a result, > Stéphane Mourey implemented a new LFUN, server-get-statistics. If there is > no objection, I am going to pu

Re: [PATCH] Add LFUN_SERVER_GET_STATISTICS command

2014-10-15 Thread Richard Heck
On 10/15/2014 07:46 AM, Jean-Marc Lasgouttes wrote: Hi, There has been quite a bit of discussion on lyx-fr on the possibility of reading the statistics of a document for further processing. As a result, Stéphane Mourey implemented a new LFUN, server-get-statistics. If there is no objection,

[PATCH] Add LFUN_SERVER_GET_STATISTICS command

2014-10-15 Thread Jean-Marc Lasgouttes
aa3ca9d2b Mon Sep 17 00:00:00 2001 From: brokenclock Date: Tue, 14 Oct 2014 21:55:04 +0200 Subject: [PATCH] Add LFUN_SERVER_GET_STATISTICS command This function can be used with the LyX server to obtain the word, character or character+space count in the current document or selection. --- lib/