Re: r16675 [2/4] - in /lyx-devel/branches/BRANCH_1_4_X: devel...

2007-01-16 Thread Georg Baum
Uwe Stöhr wrote:

> Should I set the binary flag anyway?

Yes. Normally binary files do not show up in the diffs. This file seems to
be missing this flag, since the command

svn proplist lib/clipart/without_fntright.pdf

does not produce any output. In contrast, 

svn proplist lib/clipart/LyXNoteImageQt4.png

says

Properties on 'lib/clipart/LyXNoteImageQt4.png':
  svn:mime-type


Therefore I believe that something wnet wrong with setting the flag for this
file. This is trunk, I guess 1.4 is similar.


Georg



Re: r16622 [1/3] - in /lyx-devel/branches/BRANCH_1_4_X/lib: d...

2007-01-16 Thread Georg Baum
Uwe Stöhr wrote:

> Georg wrote:
>  > No GUI yet, just put
>  >  \use_converter_cache true
>  > in your preferences file.
> 
> We should add these nice features also to the GUI.

Yes, but we have many more important things to do first. I am happy that
this is in at all.


Georg



Re: [PATCH] put Gui language definition in lyxrc

2007-01-16 Thread Georg Baum
[EMAIL PROTECTED] wrote:

> Thanks. If I decide to use it (professionally) I'll have to look into it
> closer.

I recommend interested people monitoring the mailing list (or go through the
archives of the last few months), this will be interesting.


Georg



Re: r16675 [2/4] - in /lyx-devel/branches/BRANCH_1_4_X: devel...

2007-01-16 Thread Georg Baum
[EMAIL PROTECTED] wrote:

> I thought SVN treated all files as binaries?

No. It uses safer storage format than the diff based CVS format internally,
but from a users POV there is no difference.


Georg



Re: [part 3/4] again about LyX's default settings

2007-01-16 Thread Jean-Pierre Chrétien
Uwe Stöhr <[EMAIL PROTECTED]> writes:

> 
> Sorry that I bring this topic again on the list.
> The goal was to merge the changes I made in my LyXWinInstaller builds to the
official source.
> 
> There are now the following things left:
> 
> --- support for powerdot/beamer ---
> 
> This feature was ofteh requested on the users list and we included now the
files for beamer. But 
> there are the followiong two entries missing in chklatex.ltx:
> 
> \TestPackage{pgf} % needed by beamer
> \TestPackage{xcolor} % needed by beamer
> 
> Without these packages beamer is unusable.

Sure, that's why beamer requires them. I can't imagine a distribution
where beamer would be present without these two packages.
And \documentclass{beamer} triggers pgf and xcolor packages loading.

-- 
Jean-Pierre




Re: [part 1] again about LyX's default settings

2007-01-16 Thread Georg Baum
Uwe Stöhr wrote:

> - the linebreak button: It is in contrary to the one in SVN blue instead
> of read as this was
>requested. Personally I don't use this button but as this was requested
>several times and especially new users found this useful I added it.

Why blue? IMO the button should have the same color as the linebreak symbol
we draw in the text (so the current button is wrong, too).

> - one button to view DVI, one to View/Update DVi, and one to view PDF: all
> of them are needed for the standard workflow. Some users prefer DVi to
> prview the documents, therefore the first two buttons. Some, me also,
> prefer PDF to preview documents. There is no View/Update button, as this
> is not necessary for GSview and also for Adobe Reader. (Adressing
> Acrobat/Adobe Reader is very tricky, see part 2 of this thread.) I can
> also add a button for view PS if this is needed. For me the view PDF
> button is the most often used button af all and it seems to be the same
> for many users since whenever there was something wrong with it, I got
> lots of emails.

IMO you shoud definitely add the icons for viewing and updating pdf to svn,
since we already have some for dvi and ps.

I am not sure whether it is a good idea to add all the buttons to the
standard toolbar. In the long run I would like that the view and update
functionality is merged: If no viewer with the file is open: open one,
otherwise only update the file. Since this is not easy to implement so that
it works for all platforms and viewers it is definitely not for 1.5.0.
For now I think that an extra View toolbar as suggested by Jürgen is a good
compromise.


Georg




Re: [PATCH] delay bibfileCache first update

2007-01-16 Thread Jean-Marc Lasgouttes
> "Abdelrazak" == Abdelrazak Younes <[EMAIL PROTECTED]> writes:

>> It does not do so if it is somehere completely else, and you give
>> the absolute path. We do this for all included files BTW, and it
>> makes sense: Usually if I include files in the same directory or a
>> subdirectory I want relative paths, because I can then transfer the
>> whole document easily.

Abdelrazak> Agreed but for me relative path means './toto' and not
Abdelrazak> 'toto'.

I think showing a path like that will create more confusion for many
users than help clarify things.

JMarc


Re: [part 1] again about LyX's default settings

2007-01-16 Thread Jean-Marc Lasgouttes
> "Georg" == Georg Baum <[EMAIL PROTECTED]> writes:

Georg> I am not sure whether it is a good idea to add all the buttons
Georg> to the standard toolbar. In the long run I would like that the
Georg> view and update functionality is merged: If no viewer with the
Georg> file is open: open one, otherwise only update the file. Since
Georg> this is not easy to implement so that it works for all
Georg> platforms and viewers it is definitely not for 1.5.0. For now I
Georg> think that an extra View toolbar as suggested by Jürgen is a
Georg> good compromise.

Or we could have a dvi/ps toolbar and a pdf toolbar, so that people
can pick the style of output file they prefer.

JMarc


Re: [part 1] again about LyX's default settings

2007-01-16 Thread Jean-Marc Lasgouttes
> "Jürgen" == Jürgen Spitzmüller <[EMAIL PROTECTED]> writes:

Jürgen> Uwe Stöhr wrote:
>> - the linebreak button: It is in contrary to the one in SVN blue
>> instead of read as this was requested. Personally I don't use this
>> button but as this was requested several times and especially new
>> users found this useful I added it.

Jürgen> I don't like this. That is, you can add the icon to SNV IMHO
Jürgen> so that people who want this can add it themselves.
Jürgen> Personally, I don't think we should clutter the general
Jürgen> toolbar with such things.

I agree with Jurgen. We shall not add such things to the general
toolbars (especially when they tend to be frown upon in LaTeX).

JMarc


Re: [PATCH] put Gui language definition in lyxrc

2007-01-16 Thread Abdelrazak Younes

Alex wrote:

As a translator I often need to start two LyX session, one using my
local language and the other using english.

It would be impossible or hard to do this without the LANG variable!


The idea is just to allow the setting for those who wants to. It is even 
possible to have two different languages for two different views running 
the same instance if you want ;-)




This will also break the linux "locale" theorem.

But, if you switch to ignore the LANG variable:

 1. I prefer to create a command line switch to override the lyxrc settings.


Sure there will be an "Automatic" option by default that will keep using 
the environment variable.


Abdel.



Re: [part 3/4] again about LyX's default settings

2007-01-16 Thread Jean-Marc Lasgouttes
> "Uwe" == Uwe Stöhr <[EMAIL PROTECTED]> writes:

Uwe> Sorry that I bring this topic again on the list. The goal was to
Uwe> merge the changes I made in my LyXWinInstaller builds to the
Uwe> official source.

Uwe> There are now the following things left:

Uwe> --- support for powerdot/beamer ---

Uwe> This feature was ofteh requested on the users list and we
Uwe> included now the files for beamer. But there are the followiong
Uwe> two entries missing in chklatex.ltx:

Uwe> \TestPackage{pgf} % needed by beamer \TestPackage{xcolor} %
Uwe> needed by beamer

Change beamer.layout to start with (untested)

#% Do not delete the line below; configure depends on this
#  \DeclareLaTeXClass[beamer.cls,pgf.sty,xcolor.sty]{Beamer Presentation Class}

Uwe> Without these packages beamer is unusable.

Because MikTeX will not download them by default, right? This
'feature' is annoying... especially when people who do not have
persistent network connection firgure that it would be a good idea to
use it instead of installing a full-blown miktex and be done with it.

Uwe> I also shipped the files for powerdot, the compeditor to beamer
Uwe> as I got lots af requests here too. I ship the examle files of
Uwe> powerdot and its .layout file. I also added the following checks
Uwe> to chkconfig.ltx:

Uwe> \TestPackage{enumitem} % needed by powerdot \TestPackage{genmisc}
Uwe> % needed by powerdot \TestPackage{listings} % needed by powerdot
Uwe> \TestPackage{xkeyval} % needed by powerdot

Uwe> Can the powerdot stuff can go in, or not, or later?

Similarly, the beamer layout file should start with

#% Do not delete the line below; configure depends on this
#  
\DeclareLaTeXClass[powerdot.cls,enumitem.sty,genmisc.sty,listing.sty,xkeyval.sty]{Powerdot
 Presentation Class}

Also, it would be nice to make the list of presentations-related
classes coherent, like

presentation (foilTeX)
presentation (slides)
presentation (beamer)
presentation (powerdot)
presentation (seminar)

Finally, the modifications made to powerdot and beamer layout fields
should be sent back to their author.

JMarc


Re: [PATCH] put Gui language definition in lyxrc

2007-01-16 Thread Abdelrazak Younes

Lars Gullik Bjønnes wrote:

Abdelrazak Younes <[EMAIL PROTECTED]> writes:



| Objection?

Yes.

I think this will result in surprising behaviour.

1. Set languag inside lyx to "swedish" (why not?)
   - save and exit


Why would you do that at the first place if you don't like the feature?


2. run lyx with LANG=no_NO ./lyx
   - get a nice swedish lyx


Easy enough: go back to the dialog and set the language to "Automatic".



I think that the ui language should not be settable from inside lyx.


This is your opinion.

Abdel.



Re: inputencoding "default" again

2007-01-16 Thread Dov Feldstern

Georg Baum wrote:

Am Sonntag, 14. Januar 2007 13:18 schrieb Dov Feldstern:


One strange thing that I'm seeing, though, is that the dvi output when 
using "auto" and "default" is not identical: I tried this out on a file 
which fits really tightly on the page --- when using "default" it all 
fits on one page, but when using "auto" it doesn't. I don't know if this 
matters or not, but it's a little strange. If you're interested in 
following this up, I can give you the files, but I don't think that this 
is something which should hold anything up.



There are two possible reasons I can think of:

a) the \inputencoding command causes additional whitespace
b) LyX outputs some additional whitespace before or after \inputencoding 
commands.


It would be nice if you could check whether b) is the case by manually 
removing all whitespace before and/or after \inputencoding commands 
leaving paragraph breaks intact of course). Does it then fit on one page? 
If yes, we should fix the output of LyX, and I would be interested in the 
example file. If not, we cannot do anything.



Georg




Hi!

I just spent two hours playing around with this, and it turns out that 
the problem *is* with the way LyX is writing the output. I don't exactly 
understand what's going on, but I was able to fix it with a really 
simple patch (attached) --- although since I don't exactly understand 
the problem, I can't vouch for the patch's correctness. It does work for 
me, however.


If you want to see the example file I worked with, I can give it to you, 
but I'd rather not post it publicly (it's an old version of my CV). Is 
there any way for me to get it to you privately?


Hope this helps!
Dov
Index: src/output_latex.C
===
--- src/output_latex.C  (revision 16673)
+++ src/output_latex.C  (working copy)
@@ -307,7 +307,7 @@
// account. This may result in some unneeded encoding changes.
if (switchEncoding(os, bparams, outer_encoding,
   *(basefont.language()->encoding( {
-   os << '\n';
+   os << "%\n";
texrow.newline();
}
 
@@ -474,7 +474,7 @@
basefont = pit->getLayoutFont(bparams, outerfont);
if (switchEncoding(os, bparams, *(basefont.language()->encoding()),
   outer_encoding)) {
-   os << '\n';
+   os << "%\n";
texrow.newline();
}
 


Re: [PATCH] put Gui language definition in lyxrc

2007-01-16 Thread Jean-Marc Lasgouttes
> "Abdelrazak" == Abdelrazak Younes <[EMAIL PROTECTED]> writes:

Abdelrazak> The idea is to allow the user to choose the language via
Abdelrazak> the settings if he _choose_ to do so.

Abdelrazak> You and Lars and all users that do not need this feature
Abdelrazak> can simply ignore it.

If a button exist in preferences, people are bound to use it just to
see what it does...

>> Where is this setting in word? In firefox?

Abdelrazak> Yes and many others. Most free programs with
Abdelrazak> internationalisation allows to do this on Wondows.

Seriously, one can do that in firefox? How? And in ms word?

>> The one example that Abdel gave is for translators. To be more
>> precise, it would be for translators that translate in more that
>> one language :)

Abdelrazak> And this is also good to people like me who share his
Abdelrazak> computer with other people sometimes. I don't want to edit
Abdelrazak> a batch file or launch a console to do this.

>>  I really do not think we need to add lyxrc entries for each and
>> every feature that might be useful to someone.

Abdelrazak> This one is really useful to a lot of people on Windows.

So on windows one can change the language of, say, internet explorer?
Or is there a way to change the language of the whole environment? How
does it work?

JMarc


Re: [part 3/4] again about LyX's default settings

2007-01-16 Thread Georg Baum
Jean-Marc Lasgouttes wrote:

> Because MikTeX will not download them by default, right? This
> 'feature' is annoying... especially when people who do not have
> persistent network connection firgure that it would be a good idea to
> use it instead of installing a full-blown miktex and be done with it.

I agree. I also think that we should only put those packages in
chkconfig.ltx that are needed by LyX features, not those needed by document
classes.

> Uwe> I also shipped the files for powerdot, the compeditor to beamer
> Uwe> as I got lots af requests here too. I ship the examle files of
> Uwe> powerdot and its .layout file. I also added the following checks
> Uwe> to chkconfig.ltx:
> 
> Uwe> \TestPackage{enumitem} % needed by powerdot \TestPackage{genmisc}
> Uwe> % needed by powerdot \TestPackage{listings} % needed by powerdot
> Uwe> \TestPackage{xkeyval} % needed by powerdot
> 
> Uwe> Can the powerdot stuff can go in, or not, or later?

I propose to do the same what I did with beamer.layout: Make an agreement
with the author to distribute it under the GPL with LyX in the future.
Then, check it carefully, fix it if needed and put it in.

> Also, it would be nice to make the list of presentations-related
> classes coherent, like
> 
> presentation (foilTeX)
> presentation (slides)
> presentation (beamer)
> presentation (powerdot)
> presentation (seminar)

Yes.

> Finally, the modifications made to powerdot and beamer layout fields
> should be sent back to their author.

We maintain beamer.layout in LyX now, Till Tantau will release future beamer
versions without it, so in this case we don't need to do that.


Georg



Re: Problem stripLeadingSpaces()

2007-01-16 Thread Abdelrazak Younes

Michael Gerz wrote:

Abdelrazak Younes schrieb:

Michael Gerz wrote:

Abdelrazak Younes schrieb:

I don't understand, why the space in the first line should be deleted?


 means a space that was marked as deleted.

Use the attached lyx file. Press return after "hello". The leading 
spaces are marked as deleted but the screen is not updated.


Well, I still don't understand because the screen seems fine here, see 
attached.


No, the screen is not fine: the second space should be marked as deleted!


Why is that? Before I hit "Enter", the second space was not deleted; was 
should it be deleted after?


I am missing something, obviously.



Re: [PATCH] put Gui language definition in lyxrc

2007-01-16 Thread Jean-Marc Lasgouttes
> "Abdelrazak" == Abdelrazak Younes <[EMAIL PROTECTED]> writes:

>>  This will also break the linux "locale" theorem.
>> 
>> But, if you switch to ignore the LANG variable:
>> 
>> 1. I prefer to create a command line switch to override the lyxrc
>> settings.

Abdelrazak> Sure there will be an "Automatic" option by default that
Abdelrazak> will keep using the environment variable.

No, the 'automatic' version should not set any environment variable
and get the language from windows global settings (which is what
gettext does by default). I do not understand why each and every
application would need to care in what language it is shown. 

JMarc


Re: [PATCH] put Gui language definition in lyxrc

2007-01-16 Thread Abdelrazak Younes

Georg Baum wrote:

Am Sonntag, 14. Januar 2007 15:13 schrieb Abdelrazak Younes:

The Gui elements uses messages_["GUI"] and the translatable element 
inside a document (mainly layout items) are using messages_[language] 
where language is given by the Buffer language. We can change that to 
use the Paragraph layout language instead by the way if there is an 
interest to do that.


That should be done IMHO (but not necessarily now), since the output will 
look like that.


This was easy so I've done it yesterday.

Abdel.



Re: [part 3/4] again about LyX's default settings

2007-01-16 Thread Jean-Marc Lasgouttes
> "Georg" == Georg Baum <[EMAIL PROTECTED]> writes:

Georg> We maintain beamer.layout in LyX now, Till Tantau will release
Georg> future beamer versions without it, so in this case we don't
Georg> need to do that.

Very good.

JMarc


Re: About bug 3099 (lyx seems to lock while loading previews)

2007-01-16 Thread Abdelrazak Younes

Jean-Marc Lasgouttes wrote:

Abdel,

I guess this bug is for you. If I load a document with 300 math
formulas, they are converted in one go and then
RenderPreview::imageReady is triggered for each of these
previews. The problem here is that is that every call triggers
LyXView::updateInset which does 
		work_area_->bufferView().update(Update::Force);

work_area_->redraw();

So in my example I get exactly 341 full redraws :(

Can you think of a solution?


Yes. I am going to delay the redraw until the next cursor blink happens. 
This way all the asked screen updates that happens between two cursor 
blinks will be unified in a single redraw.


I'll try to do this now.

Abdel.



Re: r16646 - /lyx-devel/trunk/src/buffer_funcs.C

2007-01-16 Thread Abdelrazak Younes

Lars Gullik Bjønnes wrote:

[EMAIL PROTECTED] writes:

| Author: younes
| Date: Thu Jan 11 16:58:26 2007
| New Revision: 16646
| 
| URL: http://www.lyx.org/trac/changeset/16646

| Log:
| optimization.

I don't belive you.


This change a full docstring copy at each iteration of the loop so this 
is clearly an optimisation. We probably don't have the same definition 
of "optimisation"; for me, any CPU cycle saved _is_ an optimisation.




Please provide numbers.


I don't have time for this.

Abdel.



Re: Bugzilla cleanup - results - conclusions

2007-01-16 Thread Abdelrazak Younes

Uwe Stöhr wrote:
As Michael reported that we making progress concerning the open bugs I 
started a bugzilla cleanup:


- We have currently 15 confirmed crashes, 9 of them are also in LyX 1.4.x


As soon as we fix those crashes, we should produce a beta IMO. Could you 
send out a list of those please?


Abdel.




Re: LyX-1.4.3 patches

2007-01-16 Thread Jacek M. Holeczek
Hi,

> Jacek> "src/insets/insetlatexaccent.C" is not changed
>
> Some time ago, you told me that there may be problems related to
> fontencoding or current language. What is the status of that/

The "full story" is the following ... in the file:
http://www.bitjungle.com/files/isoent-ref.pdf
in the chapter "5.4 Characters unavailable to normal PDF output" (page
34), you can read that "when loaded, the T1 encoding causes dcaron,
lcaron, tcaron (lat2) to be displayed with an apostrophe instead of the
caron above" (they missed the "Lcaron", btw.).
I have not found any other places describing it (in particular, I do not
know if there are another conditions which trigger this behavior, too).
In principle, the "fall through" in the patch should take place only when
LaTeX does it, too ... but I don't know how to test for "T1" (nor which
additional conditions should trigger this behavior and thus be tested).
However, according to:
http://en.wikipedia.org/wiki/Caron
http://de.wikipedia.org/wiki/Caron
these four special characters (d,l,L,t) are ONLY used with caron in Czech
and Slovak languages, and ALWAYS with the "special caron" form.
Thus, I believe one can safely put this "unconditional fall through" ...
unless you know any other languages for which is should not be done ...
which I have not found (working hard on this issue) ...
(Last, but not least, please note that, this patch influences ONLY the LyX
window display, the generated LaTeX/ps/eps files will ALWAYS be fine,
regardless if this patch is in or out.)

> Jacek> 2. the patch to "src/trans_mgr.C" contains a yet better
>
> I am not sure about this one. It is really an 'ad hoc' behavior and
> may be surprising for users.

Please commit this patch. This is a bug fix. A serious one for me. On a
couple of occasions, I have already reported that, the current LyX
produces INCORRECT LaTeX code when it finds a character, in the ".kmap"
file, which it cannot display by itself. This patch is a fix to this
problem. A working one ... I believe it does not influence anything else.
(Note here, even if you "migrate the kmap files to use unicode
codepoints", why should you DENY users to define their own "characters" /
"symbols" / "LaTeX sequences" in their ".kmap" files? Thus, even in the
future, if LyX finds a character that it can display, it should do it,
however, if LyX finds something that it cannot display, it should make an
ERT out of it, and let LaTeX do the job later, when generating ps/eps.)

> Jacek> 3. the patch to "src/text3.C" is not changed
>
> Concerning this patch, I think you should cancel accent for anything
> that is not LFUN_SELF_INSERT.

What exactly do you propose?
Going through the "src/text3.C", I can clearly see that, at least in the
following cases: LFUN_BACKSPACE, LFUN_SELFINSERT, LFUN_UMLAUT,
LFUN_CIRCUMFLEX, ..., LFUN_CIRCLE, LFUN_OGONEK, the TransManager is used,
so I believe that at least for all these cases this should NOT be done.
And how about "combined" cases?
For the moment, I have made this patch as simple as possible ... fixing
only the nasty bug with "keyboard enter" ...

> So, now what shall we do about the patches? Concerning 1.4, I am
> currently not very willing to change these little tested part of the
> code now. Part 1 could probably go in though.

Please put these patches into 1.4.
As I have already told you, many of the people I work with will not be
able to use 1.5 for a very very long time. And because we need to exchange
files, we have to stick to a "common standard" that works on different OS
flavors and different OS versions ... for the moment, this can only be LyX
1.4, and if not, we will have to drop LyX going back to the "common" pure
LaTeX.

Best regards,
Jacek.


Re: [PATCH] put Gui language definition in lyxrc

2007-01-16 Thread Abdelrazak Younes

Jean-Marc Lasgouttes wrote:

"Abdelrazak" == Abdelrazak Younes <[EMAIL PROTECTED]> writes:


Abdelrazak> The idea is to allow the user to choose the language via
Abdelrazak> the settings if he _choose_ to do so.

Abdelrazak> You and Lars and all users that do not need this feature
Abdelrazak> can simply ignore it.

If a button exist in preferences, people are bound to use it just to
see what it does...


Where is this setting in word? In firefox?


Abdelrazak> Yes and many others. Most free programs with
Abdelrazak> internationalisation allows to do this on Wondows.

Seriously, one can do that in firefox?


Tools->options->Advanced->Languages.


How? And in ms word?


The standard Word version I am not sure but I am sure that the Arabic 
version allows it. And OO allows it also.





The one example that Abdel gave is for translators. To be more
precise, it would be for translators that translate in more that
one language :)


Abdelrazak> And this is also good to people like me who share his
Abdelrazak> computer with other people sometimes. I don't want to edit
Abdelrazak> a batch file or launch a console to do this.


 I really do not think we need to add lyxrc entries for each and
every feature that might be useful to someone.


Abdelrazak> This one is really useful to a lot of people on Windows.

So on windows one can change the language of, say, internet explorer?
Or is there a way to change the language of the whole environment? How
does it work?


I guess it depends on your IE and Windows versions.

I am mostly talking about free software programs.

Abdel.




Re: Bugzilla cleanup - results - conclusions

2007-01-16 Thread jamatos

Quoting Abdelrazak Younes <[EMAIL PROTECTED]>:

Uwe Stöhr wrote:

As Michael reported that we making progress concerning the open bugs
I started a bugzilla cleanup:

- We have currently 15 confirmed crashes, 9 of them are also in LyX 1.4.x


As soon as we fix those crashes, we should produce a beta IMO.


 I agree. :-)


Could you send out a list of those please?

Abdel.



-
A FCUP utiliza o sistema de webmail Horde/IMP (www.horde.org)

Visite: http://www.fc.up.pt/




Re: [PATCH] put Gui language definition in lyxrc

2007-01-16 Thread Jean-Marc Lasgouttes
> "Abdelrazak" == Abdelrazak Younes <[EMAIL PROTECTED]> writes:

>>  Seriously, one can do that in firefox?

Tools-> options->Advanced->Languages.

Isn't this the language of the web pages? At least on linux this is
the only one I have.

>> How? And in ms word?

Abdelrazak> The standard Word version I am not sure but I am sure that
Abdelrazak> the Arabic version allows it. And OO allows it also.

I know about OO. It shows its unixish roots :)

Abdelrazak> This one is really useful to a lot of people on Windows.
>>  So on windows one can change the language of, say, internet
>> explorer? Or is there a way to change the language of the whole
>> environment? How does it work?

Abdelrazak> I guess it depends on your IE and Windows versions.

Abdelrazak> I am mostly talking about free software programs.

Yes, but we had a lot of discussions these last months about how LyX
should look like a real windows program. I am all for working like
real windows programs and hiding the 'free software' habits.

JMarc


Re: [PATCH] put Gui language definition in lyxrc

2007-01-16 Thread Jürgen Spitzmüller
Abdelrazak Younes wrote:
> > Seriously, one can do that in firefox?
>
> Tools->options->Advanced->Languages.

Nope. That is the language of websites (that are available in multiple 
languages). At least in the Linux version

> > How? And in ms word?
>
> The standard Word version I am not sure but I am sure that the Arabic
> version allows it. 

I couldn't find such a setting in Word 2000.

> And OO allows it also. 

Yes (however, OOo is a good example on how to clutter the preferences with all 
sorts of stuff).

Jürgen


Re: [PATCH] put Gui language definition in lyxrc

2007-01-16 Thread Edwin Leuven

Jürgen Spitzmüller wrote:
Yes (however, OOo is a good example on how to clutter the preferences with all 
sorts of stuff).


why not set the language when installing lyx and be done with it...


Re: [part 4/4] again about LyX's default settings

2007-01-16 Thread Andreas K .
Uwe Stöhr <[EMAIL PROTECTED]> writes:

>Enabling the 
> automatic appearance of the toolbar is at the moment also to complicated for 
>new users, so we should 
> at least:
> - Add buttons to delete/add columns/rows in the table dialog
> and, or
> - enable the toolbar appearance feature by default.
 
The best way to evaluate a software is to look at what an ordinary user want 
from the program. And of course both these suggestions should be implemented. 
Why make it hard for a user when one can make it easy?

Andreas



Re: [PATCH] put Gui language definition in lyxrc

2007-01-16 Thread Abdelrazak Younes

Jean-Marc Lasgouttes wrote:

"Abdelrazak" == Abdelrazak Younes <[EMAIL PROTECTED]> writes:



 Seriously, one can do that in firefox?


Tools-> options->Advanced->Languages.

Isn't this the language of the web pages? At least on linux this is
the only one I have.


You're right. Weird, I am sure I've done that in the past.


Yes, but we had a lot of discussions these last months about how LyX
should look like a real windows program.


OK, forget about it. I am not going to fight for it but let me say that 
I think it is useful at least to get rid of the need for the batch file 
under windows. If you don't want a dialog, that's OK, it is not really 
important. But I think we can put put the setting in lyxrc.dist so that 
packager allows the user to choose a language.



I am all for working like
real windows programs and hiding the 'free software' habits.



The real problem is that, quite often, when you buy a French window 
licence, you cannot change the settings or are not allowed to. If I am 
forced to use a french window why should I be forced to use a french LyX?


Abdel.


Abdel.




Re: [PATCH] put Gui language definition in lyxrc

2007-01-16 Thread Abdelrazak Younes

Edwin Leuven wrote:

Jürgen Spitzmüller wrote:
Yes (however, OOo is a good example on how to clutter the preferences 
with all sorts of stuff).


why not set the language when installing lyx and be done with it...


Yes, we can just put it lyxrc.dist and be done with it. Forget about the 
dialog.


I think this is a good compromise.

Abdel.



Re: [PATCH] put Gui language definition in lyxrc

2007-01-16 Thread Georg Baum
Abdelrazak Younes wrote:

> OK, forget about it. I am not going to fight for it but let me say that
> I think it is useful at least to get rid of the need for the batch file
> under windows. If you don't want a dialog, that's OK, it is not really
> important. But I think we can put put the setting in lyxrc.dist so that
> packager allows the user to choose a language.

I think that is a good compromise. It would eliminate the problem the users
play with the setting and see that it has no effect on linux. The installer
could offer a nice menu to choose the language from.

> The real problem is that, quite often, when you buy a French window
> licence, you cannot change the settings or are not allowed to. If I am
> forced to use a french window why should I be forced to use a french LyX?

You should not be forced to use a french LyX, it should simply be the
default.


Georg



Re: [Bug 3099] Instant Preview blocks user interaction

2007-01-16 Thread Jean-Marc Lasgouttes
> "Edwin" == Edwin Leuven <[EMAIL PROTECTED]> writes:

>> --- Additional Comments From [EMAIL PROTECTED] 2007-01-15 14:42
>> --- If someone could produce a profile while scrolling that
>> would help me investigating the issue.

Edwin> profile here

Edwin> http://leuven.ecodip.net/lyx/preview.zip

The relevant part (even clearer than the data on why my previous
message on the subject was based) is:

---
0.00  830.485640/5640
lyx::LyX::updateInset(lyx::InsetBase const*) const [4]
[5] 99.30.00  830.485640 
lyx::LyXView::updateInset(lyx::InsetBase const*) const [5]
0.00  538.715640/5645
lyx::BufferView::update(lyx::Update::flags) [11]
0.01  291.755640/5646
lyx::frontend::WorkArea::redraw() [17]
0.010.00   11280/17448   
lyx::frontend::WorkArea::bufferView() [454]
0.000.005640/99410212 lyx::BufferView::buffer() 
const [191]
---

So 99.3 of the time (that gprof sees) is spent updating and
redisplaying the workarea after each inset update!

I am not sure what the best solution is though.

JMarc


Re: About bug 3099 (lyx seems to lock while loading previews)

2007-01-16 Thread Jean-Marc Lasgouttes
> "Abdelrazak" == Abdelrazak Younes <[EMAIL PROTECTED]> writes:

Abdelrazak> Yes. I am going to delay the redraw until the next cursor
Abdelrazak> blink happens. This way all the asked screen updates that
Abdelrazak> happens between two cursor blinks will be unified in a
Abdelrazak> single redraw.

Looks like a nice solution. Are we sure that the cursor always blinks?

JMarc


Re: [PATCH] put Gui language definition in lyxrc

2007-01-16 Thread Jean-Marc Lasgouttes
> "Abdelrazak" == Abdelrazak Younes <[EMAIL PROTECTED]> writes:

Abdelrazak> Georg Baum wrote:
>> Am Sonntag, 14. Januar 2007 15:13 schrieb Abdelrazak Younes:
>> 
>>> The Gui elements uses messages_["GUI"] and the translatable
>>> element inside a document (mainly layout items) are using
>>> messages_[language] where language is given by the Buffer
>>> language. We can change that to use the Paragraph layout language
>>> instead by the way if there is an interest to do that.
>>  That should be done IMHO (but not necessarily now), since the
>> output will look like that.

Abdelrazak> This was easy so I've done it yesterday.

Note that to do that properly, _all_ calls to Buffer::B_ should be
audited.

JMarc


bug 3077

2007-01-16 Thread Edwin Leuven

the attached patch gets rid of this one (and a crash)

i also got rid of 2 mailer updates which i think are not necessary since 
 workarea dispatch already updates the dialog on key and mouse events 
(i might be wrong though)


can someone (uwe?) test it?

btw, is it necessary to update toolbars/dialogs both on mousepress and 
mouserelease?


this tabular stuff (and its controller) are really evol. i intend to 
clean up a bit for 1.6


thanks
Index: src/frontends/qt4/QTabularDialog.C
===
--- src/frontends/qt4/QTabularDialog.C  (revision 16692)
+++ src/frontends/qt4/QTabularDialog.C  (working copy)
@@ -57,7 +57,8 @@
connect(interlinespaceUnit, 
SIGNAL(selectionChanged(lyx::LyXLength::UNIT)),
this, SLOT(interlinespace_changed()));
connect(interlinespaceCO, SIGNAL(activated(int)), this, 
SLOT(interlinespace_changed()));
-   connect(booktabsRB, SIGNAL(clicked()), this, 
SLOT(on_booktabsRB_toggled()));
+   connect(booktabsRB, SIGNAL(clicked(bool)), this, 
SLOT(booktabsChanged(bool)));
+   connect(borderDefaultRB, SIGNAL(clicked(bool)), this, 
SLOT(booktabsChanged(bool)));
connect(borderSetPB, SIGNAL(clicked()), this, 
SLOT(borderSet_clicked()));
connect(borderUnsetPB, SIGNAL(clicked()), this, 
SLOT(borderUnset_clicked()));
connect(longTabularCB, SIGNAL(toggled(bool)), longtableGB, 
SLOT(setEnabled(bool)));
@@ -107,7 +108,7 @@
 }
 
 
-void QTabularDialog::on_booktabsRB_toggled()
+void QTabularDialog::booktabsChanged(bool)
 {
form_->changed();
form_->controller().booktabs(booktabsRB->isChecked());
Index: src/frontends/qt4/QTabularDialog.h
===
--- src/frontends/qt4/QTabularDialog.h  (revision 16692)
+++ src/frontends/qt4/QTabularDialog.h  (working copy)
@@ -35,7 +35,7 @@
virtual void topspace_changed();
virtual void bottomspace_changed();
virtual void interlinespace_changed();
-   virtual void on_booktabsRB_toggled();
+   virtual void booktabsChanged(bool);
virtual void close_clicked();
virtual void borderSet_clicked();
virtual void borderUnset_clicked();
Index: src/frontends/qt4/ui/QTabularUi.ui
===
--- src/frontends/qt4/ui/QTabularUi.ui  (revision 16692)
+++ src/frontends/qt4/ui/QTabularUi.ui  (working copy)
@@ -315,6 +315,9 @@
   
Fo&rmal
   
+  
+   true
+  
  
 
 
Index: src/insets/insettabular.C
===
--- src/insets/insettabular.C   (revision 16692)
+++ src/insets/insettabular.C   (working copy)
@@ -1271,8 +1271,6 @@
}
 
cur.updateFlags(Update::Force | Update::FitCursor);
-
-   InsetTabularMailer(*this).updateDialog(&bv);
 }
 
 
@@ -1760,8 +1758,6 @@
case LyXTabular::LAST_ACTION:
break;
}
-
-   InsetTabularMailer(*this).updateDialog(&bv);
 }
 
 


Re: [PATCH] put Gui language definition in lyxrc

2007-01-16 Thread Abdelrazak Younes

Jean-Marc Lasgouttes wrote:

"Abdelrazak" == Abdelrazak Younes <[EMAIL PROTECTED]> writes:


Abdelrazak> Georg Baum wrote:

Am Sonntag, 14. Januar 2007 15:13 schrieb Abdelrazak Younes:


The Gui elements uses messages_["GUI"] and the translatable
element inside a document (mainly layout items) are using
messages_[language] where language is given by the Buffer
language. We can change that to use the Paragraph layout language
instead by the way if there is an interest to do that.

 That should be done IMHO (but not necessarily now), since the
output will look like that.


Abdelrazak> This was easy so I've done it yesterday.

Note that to do that properly, _all_ calls to Buffer::B_ should be
audited.


Of course I've done that and I was planning to remove the method altogether:

Find all "B_", Match case, Whole word, Subfolders, Find Results 1, 
"lyx-trunk", "*.c;*.cpp;*.cxx;*.cc;*.tli;*.tlh;*.h;*.hpp;*.hxx;*.hh"

  buffer.C(1466):docstring const Buffer::B_(string const & l10n) const
  buffer.h(202):docstring const B_(std::string const & l10n) const;
  insets\insetfloatlist.C(57):  return buf.B_(it->second.listName());
  insets\insetfloatlist.C(120):			   << buf.B_(cit->second.listName()) 
<< "}\n";

  Matching lines: 4Matching files: 3Total files searched: 974

Abdel.



Re: [PATCH] put Gui language definition in lyxrc

2007-01-16 Thread Jean-Marc Lasgouttes
> "Edwin" == Edwin Leuven <[EMAIL PROTECTED]> writes:

Edwin> Jürgen Spitzmüller wrote:
>> Yes (however, OOo is a good example on how to clutter the
>> preferences with all sorts of stuff).

Edwin> why not set the language when installing lyx and be done with
Edwin> it...

This is indeed what we do now. Also, considering that we ship 2.5M of
translations, we could consider to install only those that people
choose.

JMarc


Re: bug 3077

2007-01-16 Thread Edwin Leuven

Edwin Leuven wrote:

the attached patch gets rid of this one (and a crash)


i also think it gets rid of this one:

http://bugzilla.lyx.org/show_bug.cgi?id=3076

please test


Re: [part 4/4] again about LyX's default settings

2007-01-16 Thread Georg Baum
Andreas K. wrote:

> The best way to evaluate a software is to look at what an ordinary user
> want from the program. And of course both these suggestions should be
> implemented. Why make it hard for a user when one can make it easy?

That is not the question. For historical reasons, the table dialog is
unusable and has been for years. I doubt that anybody questions this. The
question is: Are we going to fix this for 1.5.0, or not? I guess the asnwer
is: If we find a volunteer to do so. I think that we have many more srious
bugs to solve first.
What was the result when we discussed last time whether the table toolbar
should be automatic by default or not? I don't remember, but we should not
start this discussion again, rather use the old conclusions.


Georg



Re: [PATCH] put Gui language definition in lyxrc

2007-01-16 Thread Edwin Leuven

Jean-Marc Lasgouttes wrote:

This is indeed what we do now. Also, considering that we ship 2.5M of
translations, we could consider to install only those that people
choose.


indeed


Re: [part 1] again about LyX's default settings

2007-01-16 Thread Andreas K .
Uwe Stöhr <[EMAIL PROTECTED]> writes:

> There are now the following things left:
> 
> --- the different toolbar ---
> Attached a Screenshot of the current toolbar. There are 4 extra buttons:
> 
> - the linebreak button: It is in contrary to the one in SVN blue instead
> of read as this was requested. Personally I don't use this button but as
> this was requested several times and especially new users found this
> useful I added it.
> 
> - one button to view DVI, one to View/Update DVi, and one to view PDF:
> all of them are needed for the standard workflow.

[snip]

>I can also add a button for view PS if this is needed.

An ordinary user (most users are not hackers, and do not know anything about 
programming) want easy to use, self-explaining, easily accessible toolbar 
buttons and menus.

In my opinion, as an ordinary LyX user, the linebreak button, the buttons to 
view DVI, View/Update DVi, and view PDF, should be in the default toolbar, 
together with a view PS button.

But there should also of course be the possibility for the user who do not want 
these buttons to turn them of later (all or just some of them). Customizability 
is the key word.

Andreas






Re: [part 4/4] again about LyX's default settings

2007-01-16 Thread Jean-Marc Lasgouttes
> "Andreas" == Andreas K <[EMAIL PROTECTED]> writes:

Andreas> Uwe Stöhr <[EMAIL PROTECTED]> writes:
>> Enabling the automatic appearance of the toolbar is at the moment
>> also to complicated for new users, so we should at least: - Add
>> buttons to delete/add columns/rows in the table dialog and, or -
>> enable the toolbar appearance feature by default.
 
Andreas> The best way to evaluate a software is to look at what an
Andreas> ordinary user want from the program. And of course both these
Andreas> suggestions should be implemented. Why make it hard for a
Andreas> user when one can make it easy?

Well, then how do we catter for users that do not like this feature
but are forced to live with it? OpenOffice has these popping toolbars
because it has a delay before activating them.

JMarc


Re: [PATCH] put Gui language definition in lyxrc

2007-01-16 Thread Jean-Marc Lasgouttes
> "Abdelrazak" == Abdelrazak Younes <[EMAIL PROTECTED]> writes:

>>  Note that to do that properly, _all_ calls to Buffer::B_ should be
>> audited.

Abdelrazak> Of course I've done that and I was planning to remove the
Abdelrazak> method altogether:

Very good! I thought there were more of these.

JMarc


Re: bug 3077

2007-01-16 Thread Jürgen Spitzmüller
Edwin Leuven wrote:
> can someone (uwe?) test it?

I couldn't reproduce bug 3077, but I can confirm this fixes 3076. Put it in.

> btw, is it necessary to update toolbars/dialogs both on mousepress and
> mouserelease?

Maybe because of selecting? No idea.

> this tabular stuff (and its controller) are really evol. i intend to
> clean up a bit for 1.6

Great. This is long overdue.

Jürgen


Name of layout or name of layout file - what's important? (Was: [part 3/4] again about LyX's default settings)

2007-01-16 Thread christian . ridderstrom

On Tue, 16 Jan 2007, Georg Baum wrote:


Also, it would be nice to make the list of presentations-related
classes coherent, like

presentation (foilTeX)
presentation (slides)
presentation (beamer)
presentation (powerdot)
presentation (seminar)


What's the important parameter to avoid breaking old .lyx-files?
Is it the name of the .layout-file, or is it the name in the layout file?

(I'm guessing only the name of the .layout-file matters, but...)

/Christian

--
Christian Ridderström, +46-8-768 39 44   http://www.md.kth.se/~chr

Re: [PATCH] put Gui language definition in lyxrc

2007-01-16 Thread christian . ridderstrom



 I think that the ui language should not be settable from inside lyx.


I haven't really followed this thread, so I might just repeate what 
someone else has said.


I can think of one reason why normal users might want to be able to 
temporarily change the language of the UI from within LyX.


Let's say we have a user that runs LyX in Swedish, but don't know how to 
do something. So the user reads the manual and is instructed to to go to a 
menu/dialog, however, the user doesn't know how that menu/dialog has been 
translated into Swedish so he can't find it...


I don't know if this makes it worth all the hassle, but I actually run 
most of my software with English UI for this reason. When I need to find 
out how to do something it's easier if the UI is in English.


/Christian

--
Christian Ridderström, +46-8-768 39 44   http://www.md.kth.se/~chr

Re: bug 3077

2007-01-16 Thread Edwin Leuven

Jürgen Spitzmüller wrote:

I couldn't reproduce bug 3077, but I can confirm this fixes 3076. Put it in.


it is in:

http://www.lyx.org/trac/changeset/16705

perhaps someone can close bugs 3076 and 3077?

thanks


Re: bug 3077

2007-01-16 Thread Jürgen Spitzmüller
Edwin Leuven wrote:
> perhaps someone can close bugs 3076 and 3077?

I closed the former. The latter should be verified and then closed (Uwe?).

Jürgen


Re: Name of layout or name of layout file - what's important?

2007-01-16 Thread Jean-Marc Lasgouttes
> "christian" == christian ridderstrom <[EMAIL PROTECTED]> writes:

christian> On Tue, 16 Jan 2007, Georg Baum wrote:
>>> Also, it would be nice to make the list of presentations-related
>>> classes coherent, like
>>> 
>>> presentation (foilTeX) presentation (slides) presentation (beamer)
>>> presentation (powerdot) presentation (seminar)

christian> What's the important parameter to avoid breaking old
christian> .lyx-files? Is it the name of the .layout-file, or is it
christian> the name in the layout file?

christian> (I'm guessing only the name of the .layout-file matters,
christian> but...)

Yes, only the name of the layout file matters. What is shown above is
just the description for the UI.

JMarc


FYI: SVN and binary files (Was: Re: r16675 [2/4] ...)

2007-01-16 Thread christian . ridderstrom

On Tue, 16 Jan 2007, Georg Baum wrote:


[EMAIL PROTECTED] wrote:


I thought SVN treated all files as binaries?


No. It uses safer storage format than the diff based CVS format internally,
but from a users POV there is no difference.


Thanks for the clarification.

As a side note, the FAQ I copied below helped me fix a mysterious 
behaviour I've had with some PDF's in my work repository.


It turns out that some PDFs had not been tagged as binary files, so when 
browsing the repository (via WebDav/SVN) clicking on them didn't bring 
them up as PDFs. Instead you were just shown the raw content of the file.


Setting the mime type fixed this problem

thanks
/Christian

I found the FAQ enlightning, so I've copied it here in case it helps 
anyone else [ http://subversion.tigris.org/faq.html#binary-files ]:


How does Subversion handle binary files?

When you first add or import a file into Subversion, the file is examined 
to determine if it is a binary file. Currently, Subversion just looks at 
the first 1024 bytes of the file; if any of the bytes are zero, or if more 
than 15% are not ASCII printing characters, then Subversion calls the file 
binary. This heuristic might be improved in the future, however.


If Subversion determines that the file is binary, the file receives an 
svn:mime-type property set to "application/octet-stream". (You can always 
override this by using the auto-props feature or by setting the property 
manually with svn propset.)


Subversion treats the following files as text:
* Files with no svn:mime-type
* Files with a svn:mime-type starting "text/"
* Files with a svn:mime-type equal to "image/x-xbitmap"
* Files with a svn:mime-type equal to "image/x-xpixmap"

All other files are treated as binary, meaning that Subversion will:
* Not attempt to automatically merge received changes with local changes
  during svn update or svn merge
* Not show the differences as part of svn diff
* Not show line-by-line attribution for svn blame

In all other respects, Subversion treats binary files the same as text 
files, e.g. if you set the svn:keywords or svn:eol-style properties, 
Subversion will perform keyword substitution or newline conversion on 
binary files.


Note that whether or not a file is binary does not affect the amount of 
repository space used to store changes to that file, nor does it affect 
the amount of traffic between client and server. For storage and 
transmission purposes, Subversion uses a diffing method that works equally 
well on binary and text files; this is completely unrelated to the diffing 
method used by the 'svn diff' command.



--
Christian Ridderström, +46-8-768 39 44   http://www.md.kth.se/~chr

[O-T] Re: [PATCH] put Gui language definition in lyxrc

2007-01-16 Thread christian . ridderstrom

On Tue, 16 Jan 2007, Georg Baum wrote:


[EMAIL PROTECTED] wrote:


Thanks. If I decide to use it (professionally) I'll have to look into it
closer.


I recommend interested people monitoring the mailing list (or go through 
the archives of the last few months), this will be interesting.


Good tip.

http://groups.google.com/group/comp.soft-sys.math.scilab

seems they might end up with at least a dual GPL/LGPL license.

thanks
/Christian

--
Christian Ridderström, +46-8-768 39 44   http://www.md.kth.se/~chr

cursor related(?) crash

2007-01-16 Thread Edwin Leuven

recipe:

insert ERT
right click -> inline -> OK
click in ERT box


i get this in the console:


Assertion triggered in void __thiscall lyx::LyXText::dispatch(class 
lyx::LCursor
 &,class lyx::FuncRequest &) by failing check "cur.text() == this" in 
file ..\..\..\src\text3.C:310



backtrace:



 	lyx-qt4.exe!lyx::LyXServerSocket::`scalar deleting destructor'()  + 
0x27 bytes	C++


lyx-qt4.exe!boost::checked_delete(lyx::LyXServerSocket 
* x=0x00318d98)  Line 34 + 0x1c bytes	C++


lyx-qt4.exe!boost::scoped_ptr::~scoped_ptr() 
 Line 77 + 0xb bytes	C++


lyx-qt4.exe!boost::scoped_ptr::reset(lyx::LyXServerSocket 
* p=0x)  Line 84	C++

lyx-qt4.exe!lyx::LyX::emergencyCleanup()  Line 976  C++
01a89d40()  
 	lyx-qt4.exe!boost::assertion_failed(const char * expr=0x00e3eec8, 
const char * function=0x00e3ee70, const char * file=0x00e3ee58, long 
line=310)  Line 57	C++
>	lyx-qt4.exe!lyx::LyXText::dispatch(lyx::LCursor & cur={...}, 
lyx::FuncRequest & cmd={...})  Line 310 + 0x28 bytes	C++
 	lyx-qt4.exe!lyx::InsetText::doDispatch(lyx::LCursor & cur={...}, 
lyx::FuncRequest & cmd={...})  Line 260	C++
 	lyx-qt4.exe!lyx::InsetCollapsable::doDispatch(lyx::LCursor & 
cur={...}, lyx::FuncRequest & cmd={...})  Line 333 + 0x10 bytes	C++
 	lyx-qt4.exe!lyx::InsetERT::doDispatch(lyx::LCursor & cur={...}, 
lyx::FuncRequest & cmd={...})  Line 261	C++
 	lyx-qt4.exe!lyx::InsetBase::dispatch(lyx::LCursor & cur={...}, 
lyx::FuncRequest & cmd={...})  Line 132 + 0x1a bytes	C++
 	lyx-qt4.exe!lyx::BufferView::workAreaDispatch(const lyx::FuncRequest 
& cmd0={...})  Line 1135	C++
 	lyx-qt4.exe!lyx::frontend::WorkArea::dispatch(const lyx::FuncRequest 
& cmd0={...})  Line 196 + 0xf bytes	C++
 	lyx-qt4.exe!lyx::frontend::GuiWorkArea::mousePressEvent(QMouseEvent * 
e=0x01a8c468)  Line 295	C++

QtGuid4.dll!QWidget::event(QEvent * event=0x01a8c468)  Line 5695
C++
QtGuid4.dll!QFrame::event(QEvent * e=0x01a8c468)  Line 634  C++
 	QtGuid4.dll!QAbstractScrollArea::viewportEvent(QEvent * e=0x01a8c468) 
 Line 854 + 0xc bytes	C++
 	QtGuid4.dll!QAbstractScrollAreaPrivate::viewportEvent(QEvent * 
event=0x01a8c468)  Line 78 + 0x28 bytes	C++
 	QtGuid4.dll!QAbstractScrollAreaFilter::eventFilter(QObject * 
o=0x0030b8e8, QEvent * e=0x01a8c468)  Line 89 + 0x29 bytes	C++
 	QtGuid4.dll!QApplicationPrivate::notify_helper(QObject * 
receiver=0x0030b8e8, QEvent * e=0x01a8c468)  Line 3426 + 0x1b bytes	C++
 	QtGuid4.dll!QApplication::notify(QObject * receiver=0x0030b8e8, 
QEvent * e=0x01a8c468)  Line 3133 + 0x2f bytes	C++
 	QtCored4.dll!QCoreApplication::sendSpontaneousEvent(QObject * 
receiver=0x0030b8e8, QEvent * event=0x01a8c468)  Line 186 + 0x40 bytes	C++
 	QtGuid4.dll!QETWidget::translateMouseEvent(const tagMSG & msg={...}) 
 Line 2622 + 0x14 bytes	C++
 	QtGuid4.dll!QtWndProc(HWND__ * hwnd=0x00250a36, unsigned int 
message=516, unsigned int wParam=2, long lParam=2359344)  Line 1278 + 
0xc bytes	C++
 	QtCored4.dll!QEventDispatcherWin32::processEvents(QFlagsQEventLoop::ProcessEventsFlag> flags={...})  Line 437 + 0x17 bytes	C++
 	QtGuid4.dll!QGuiEventDispatcherWin32::processEvents(QFlagsQEventLoop::ProcessEventsFlag> flags={...})  Line 930 + 0x15 bytes	C++
 	QtCored4.dll!QEventLoop::processEvents(QFlagsQEventLoop::ProcessEventsFlag> flags={...})  Line 127	C++
 	QtCored4.dll!QEventLoop::exec(QFlagsQEventLoop::ProcessEventsFlag> flags={...})  Line 172 + 0x2d bytes	C++

QtCored4.dll!QCoreApplication::exec()  Line 727 + 0x15 bytesC++
QtGuid4.dll!QApplication::exec()  Line 2928 C++
 	lyx-qt4.exe!lyx::frontend::GuiApplication::exec()  Line 155 + 0x8 
bytes	C++
 	lyx-qt4.exe!lyx::LyX::exec(int & argc=1, char * * argv=0x003e56a8) 
Line 435 + 0x30 bytes	C++
 	lyx-qt4.exe!main(int argc=1, char * * argv=0x003e56a8)  Line 48 + 
0x10 bytes	C++

lyx-qt4.exe!__tmainCRTStartup()  Line 586 + 0x19 bytes  C
lyx-qt4.exe!mainCRTStartup()  Line 403  C
kernel32.dll!7c816fd7() 


Cannot compile. Latest in trunk

2007-01-16 Thread Kornel Benko
gcc: gcc-3.3.4-11

if g++ -DHAVE_CONFIG_H -I. -I. -I.   -I../boost -W -Wall   -I/usr/X11R6/include 
 -g -O -MT CutAndPaste.o -MD -MP -MF ".deps/CutAndPaste.Tpo" -c -o 
CutAndPaste.o CutAndPaste.C; \
then mv -f ".deps/CutAndPaste.Tpo" ".deps/CutAndPaste.Po"; else rm -f 
".deps/CutAndPaste.Tpo"; exit 1; fi
CutAndPaste.C: In function `void lyxputClipboard(const
   lyx::ParagraphList&, unsigned int, const lyx::docstring&)':
CutAndPaste.C:331: error: type specifier omitted for parameter
CutAndPaste.C:331: error: syntax error before `false'
CutAndPaste.C:332: error: request for member `setUnnamed' in `
...
regards Kornel
-- 
Kornel Benko
[EMAIL PROTECTED]


pgpPcX7kOYib4.pgp
Description: PGP signature


Re: [PATCH] put Gui language definition in lyxrc

2007-01-16 Thread Abdelrazak Younes

Jean-Marc Lasgouttes wrote:

"Edwin" == Edwin Leuven <[EMAIL PROTECTED]> writes:


Edwin> Jürgen Spitzmüller wrote:

Yes (however, OOo is a good example on how to clutter the
preferences with all sorts of stuff).


Edwin> why not set the language when installing lyx and be done with
Edwin> it...

This is indeed what we do now.


What do you mean here? The current solution is to create a batch file 
that sets LANG before launching LyX truly. I rckon this is not a good 
solution.



Also, considering that we ship 2.5M of
translations, we could consider to install only those that people
choose.


Yep, why not.

Abdel.



Re: Cannot compile. Latest in trunk

2007-01-16 Thread Kornel Benko
Am Dienstag, 16. Januar 2007 15:09 schrieb Kornel Benko:

Attached cures it.

Kornel

-- 
Kornel Benko
[EMAIL PROTECTED]
Index: src/CutAndPaste.C
===
--- src/CutAndPaste.C	(revision 16705)
+++ src/CutAndPaste.C	(working copy)
@@ -328,7 +328,7 @@
 void putClipboard(ParagraphList const & paragraphs, textclass_type textclass,
   docstring const & plaintext)
 {
-	Buffer buffer(string(), false);
+	Buffer buffer(string(""), false);
 	buffer.setUnnamed(true);
 	buffer.paragraphs() = paragraphs;
 	buffer.params().textclass = textclass;
@@ -671,7 +671,7 @@
 	if (theClipboard().hasLyXContents()) {
 		string lyx = theClipboard().getAsLyX();
 		if (!lyx.empty()) {
-			Buffer buffer(string(), false);
+			Buffer buffer(string(""), false);
 			buffer.setUnnamed(true);
 			if (buffer.readString(lyx)) {
 recordUndo(cur);


pgp9bMUaGovRL.pgp
Description: PGP signature


signal cleanup frontend

2007-01-16 Thread Edwin Leuven

the attached patch replaces all toggled(bool) signals with clicked(bool)

the latter is triggered on user interaction while the former is also 
triggered when we set checkboxes and radiobuttons ourselves.


in case of the tabular dialog this led to crashes and i think it leads 
to unexpected behavior


will commit unless someone points out a conceptual flaw here

thanks

Index: BulletsModule.C
===
--- BulletsModule.C (revision 16705)
+++ BulletsModule.C (working copy)
@@ -143,7 +143,7 @@
 }
 
 
-void BulletsModule::on_customCB_toggled(bool custom)
+void BulletsModule::on_customCB_clicked(bool custom)
 {
if (!custom) {
if (current_font_ < 0)
Index: BulletsModule.h
===
--- BulletsModule.h (revision 16705)
+++ BulletsModule.h (working copy)
@@ -43,7 +43,7 @@
 protected Q_SLOTS:
 
void on_bulletsizeCO_activated(int level);
-   void on_customCB_toggled(bool);
+   void on_customCB_clicked(bool);
void on_customLE_textEdited(const QString &);
void bulletSelected(QListWidgetItem *, QListWidgetItem*);
void showLevel(int);
Index: FloatPlacement.C
===
--- FloatPlacement.C(revision 16705)
+++ FloatPlacement.C(working copy)
@@ -32,13 +32,13 @@
connect(herepossiblyCB, SIGNAL(clicked()), this, SLOT(tbhpClicked()));
connect(defaultsCB, SIGNAL(clicked()), this, SLOT(tbhpClicked()));
 
-   connect(defaultsCB, SIGNAL(toggled(bool)), this, SLOT(changedSlot()));
-   connect(ignoreCB, SIGNAL(toggled(bool)), this, SLOT(changedSlot()));
-   connect(pageCB, SIGNAL(toggled(bool)), this, SLOT(changedSlot()));
-   connect(heredefinitelyCB, SIGNAL(toggled(bool)), this, 
SLOT(changedSlot()));
-   connect(herepossiblyCB, SIGNAL(toggled(bool)), this, 
SLOT(changedSlot()));
-   connect(bottomCB, SIGNAL(toggled(bool)), this, SLOT(changedSlot()));
-   connect(topCB, SIGNAL(toggled(bool)), this, SLOT(changedSlot()));
+   connect(defaultsCB, SIGNAL(clicked(bool)), this, SLOT(changedSlot()));
+   connect(ignoreCB, SIGNAL(clicked(bool)), this, SLOT(changedSlot()));
+   connect(pageCB, SIGNAL(clicked(bool)), this, SLOT(changedSlot()));
+   connect(heredefinitelyCB, SIGNAL(clicked(bool)), this, 
SLOT(changedSlot()));
+   connect(herepossiblyCB, SIGNAL(clicked(bool)), this, 
SLOT(changedSlot()));
+   connect(bottomCB, SIGNAL(clicked(bool)), this, SLOT(changedSlot()));
+   connect(topCB, SIGNAL(clicked(bool)), this, SLOT(changedSlot()));
 
spanCB->hide();
sidewaysCB->hide();
Index: QBibtexDialog.C
===
--- QBibtexDialog.C (revision 16705)
+++ QBibtexDialog.C (working copy)
@@ -58,7 +58,7 @@
this, SLOT( change_adaptor() ) );
connect(databaseLW, SIGNAL( itemSelectionChanged() ),
this, SLOT( databaseChanged() ) );
-   connect(bibtocCB, SIGNAL( toggled(bool) ),
+   connect(bibtocCB, SIGNAL( clicked(bool) ),
this, SLOT( change_adaptor() ) );
connect(btPrintCO, SIGNAL( activated(int) ),
this, SLOT( change_adaptor() ) );
Index: QCharacterDialog.C
===
--- QCharacterDialog.C  (revision 16705)
+++ QCharacterDialog.C  (working copy)
@@ -38,7 +38,7 @@
 connect( shapeCO, SIGNAL( activated(int) ), this, SLOT( change_adaptor() ) 
);
 connect( colorCO, SIGNAL( activated(int) ), this, SLOT( change_adaptor() ) 
);
 connect( langCO, SIGNAL( activated(int) ), this, SLOT( change_adaptor() ) 
);
-connect( toggleallCB, SIGNAL( toggled(bool) ), this, SLOT( 
change_adaptor() ) );
+connect( toggleallCB, SIGNAL( clicked(bool) ), this, SLOT( 
change_adaptor() ) );
 }
 
 
Index: QDocumentDialog.C
===
--- QDocumentDialog.C   (revision 16705)
+++ QDocumentDialog.C   (working copy)
@@ -90,14 +90,14 @@
connect(textLayoutModule->lspacingCO, SIGNAL(activated(int)), this, 
SLOT(change_adaptor()));
connect(textLayoutModule->lspacingCO, SIGNAL(activated(int)), this, 
SLOT(setLSpacing(int)));
connect(textLayoutModule->lspacingLE, SIGNAL(textChanged(const 
QString&)), this, SLOT(change_adaptor()));
-   connect(textLayoutModule->skipRB, SIGNAL(toggled(bool)), this, 
SLOT(change_adaptor()));
-   connect(textLayoutModule->indentRB, SIGNAL(toggled(bool)), this, 
SLOT(change_adaptor()));
+   connect(textLayoutModule->skipRB, SIGNAL(clicked(bool)), this, 
SLOT(change_adaptor()));
+   connect(textLayoutModule->indentRB, SIGNAL(clicked(bool)), this, 
SLOT(change_adaptor()));
connect(textLayoutModule->skipCO, SIGNAL(activated(int)), this, 
SLOT(change_adaptor()));
connect(textLay

Re: Cannot compile. Latest in trunk

2007-01-16 Thread Abdelrazak Younes

Kornel Benko wrote:

Am Dienstag, 16. Januar 2007 15:09 schrieb Kornel Benko:

Attached cures it.


But this is not the good fix ;-)
I think the missing  header was the problem.

Try again.

Abdel.



Re: Cannot compile. Latest in trunk

2007-01-16 Thread Georg Baum
Abdelrazak Younes wrote:

> Kornel Benko wrote:
>> Am Dienstag, 16. Januar 2007 15:09 schrieb Kornel Benko:
>> 
>> Attached cures it.
> 
> But this is not the good fix ;-)

Indeed not. string() should work even in older gcc versions.

> I think the missing  header was the problem.

I don't think so. Otherwise it would have complained about docstring, too.


Georg



[PATCH] bug 2933: Repeatable crash when deleting superscripts in math block.

2007-01-16 Thread Jean-Marc Lasgouttes

This is one of the few crashes assigned to 1.4.4. I hope I got it
right. The culprit is that, when the mouse is in an empty script and
the user click elsewhere, the script is deleted and, if it was the
only one, the nucleus is dissolved at upper level. So far so good.

Imagine now that the new cursor is precisely in the nucleus that just
got deleted. The we have a problem. To avoid that, the new cursor
position is examined and resized if needed.

Comments welcome.

JMarc

Index: src/BufferView.C
===
--- src/BufferView.C	(revision 16692)
+++ src/BufferView.C	(working copy)
@@ -336,7 +336,25 @@ void BufferView::mouseSetCursor(LCursor 
 	if (!badcursor && cursor().inTexted())
 		cursor().text()->deleteEmptyParagraphMechanism(cur, cursor());
 
-	cursor() = cur;
+	// check up to what depth the cursor is correct; if the cursor
+	// was in an empty script inset and the new position is in the
+	// nucleus of the inset, notifyCursorLeaves will kill the
+	// script inset itself. So we check all the elements of the
+	// cursor to make sure that they are correct. 
+	// For an example, see bug 2933: 
+  	// http://bugzilla.lyx.org/show_bug.cgi?id=2933
+	// The code below could maybe be moved to a DocIterator method.
+	//lyxerr << "cur before " << cur 

Re: Cannot compile. Latest in trunk

2007-01-16 Thread Jean-Marc Lasgouttes
> "Kornel" == Kornel Benko <[EMAIL PROTECTED]> writes:

Kornel> Am Dienstag, 16. Januar 2007 15:09 schrieb Kornel Benko:
Kornel> Attached cures it.

How come string("") is needed? I thought we had plenty of these
string() constructs.

JMarc


Re: Cannot compile. Latest in trunk

2007-01-16 Thread Kornel Benko
Am Dienstag, 16. Januar 2007 15:34 schrieb Abdelrazak Younes:
> Kornel Benko wrote:
> > Am Dienstag, 16. Januar 2007 15:09 schrieb Kornel Benko:
> > 
> > Attached cures it.
> 
> But this is not the good fix ;-)
> I think the missing  header was the problem.
> 
> Try again.

Hmm... still the same.
if g++ -DHAVE_CONFIG_H -I. -I. -I.   -I../boost -W -Wall   -I/usr/X11R6/include 
 -g -O -MT CutAndPaste.o -MD -MP -MF ".deps/CutAndPaste.Tpo" -c -o 
CutAndPaste.o CutAndPaste.C; \
then mv -f ".deps/CutAndPaste.Tpo" ".deps/CutAndPaste.Po"; else rm -f 
".deps/CutAndPaste.Tpo"; exit 1; fi
CutAndPaste.C: In function `void lyxputClipboard(const
   lyx::ParagraphList&, unsigned int, const lyx::docstring&)':
CutAndPaste.C:333: error: type specifier omitted for parameter
CutAndPaste.C:333: error: syntax error before `false'
CutAndPaste.C:334: error: request for member `setUnnamed' in `
   lyxbuffer', which is of non-aggregate type `lyx::Buffer ()(...)
   '
...
Kornel

-- 
Kornel Benko
[EMAIL PROTECTED]


pgpeR0oPlq3Dx.pgp
Description: PGP signature


Re: Cannot compile. Latest in trunk

2007-01-16 Thread Abdelrazak Younes

Georg Baum wrote:

Abdelrazak Younes wrote:


Kornel Benko wrote:

Am Dienstag, 16. Januar 2007 15:09 schrieb Kornel Benko:

Attached cures it.

But this is not the good fix ;-)


Indeed not. string() should work even in older gcc versions.


I think the missing  header was the problem.


I don't think so. Otherwise it would have complained about docstring, too.


Indeed... It's probably the std::xxx declaration which were in the lyx 
namespace. This is known to fail for mingw for example.

I've fixed that.

Abdel.



Re: Cannot compile. Latest in trunk

2007-01-16 Thread Kornel Benko
Am Dienstag, 16. Januar 2007 15:46 schrieb Abdelrazak Younes:
> Georg Baum wrote:
> > Abdelrazak Younes wrote:
> > 
> >> Kornel Benko wrote:
> >>> Am Dienstag, 16. Januar 2007 15:09 schrieb Kornel Benko:
> >>>
> >>> Attached cures it.
> >> But this is not the good fix ;-)
> > 
> > Indeed not. string() should work even in older gcc versions.
> > 
> >> I think the missing  header was the problem.
> > 
> > I don't think so. Otherwise it would have complained about docstring, too.
> 
> Indeed... It's probably the std::xxx declaration which were in the lyx 
> namespace. This is known to fail for mingw for example.
> I've fixed that.

But it's still not compilable.

if g++ -DHAVE_CONFIG_H -I. -I. -I.   -I../boost -W -Wall   -I/usr/X11R6/include 
 -g -O -MT CutAndPaste.o -MD -MP -MF ".deps/CutAndPaste.Tpo" -c -o 
CutAndPaste.o CutAndPaste.C; \
then mv -f ".deps/CutAndPaste.Tpo" ".deps/CutAndPaste.Po"; else rm -f 
".deps/CutAndPaste.Tpo"; exit 1; fi
CutAndPaste.C: In function `void lyxputClipboard(const
   lyx::ParagraphList&, unsigned int, const lyx::docstring&)':
CutAndPaste.C:332: error: type specifier omitted for parameter
CutAndPaste.C:332: error: syntax error before `false'
CutAndPaste.C:333: error: request for member `setUnnamed' in `
   lyxbuffer', which is of non-aggregate type `lyx::Buffer ()(...)
   '
C
 regards Kornel

-- 
Kornel Benko
[EMAIL PROTECTED]


pgpV6KIlQ2wXT.pgp
Description: PGP signature


Re: cursor related(?) crash

2007-01-16 Thread Jean-Marc Lasgouttes
> "Edwin" == Edwin Leuven <[EMAIL PROTECTED]> writes:

Edwin> recipe: insert ERT right click -> inline -> OK click in ERT box


Edwin> i get this in the console:


This is a bug of BufferView::workAreaDispatch. When InsetCollapsable
is invoked, cur does not point inside the inset (as most code assumes)
but just outside. I do not know when this change happened, but it
should be reverted.

A linux backtrace:

#4  0x08b693f5 in lyx::support::abort ()
at ../../../lyx-devel/src/support/abort.C:25
#5  0x081a3726 in boost::assertion_failed (
expr=0x8c7dec4 "cur.text() == this",
function=0x8c7d220 "void lyx::LyXText::dispatch(lyx::LCursor&, 
lyx::FuncRequest&)", file=0x8c7de58 "../../lyx-devel/src/text3.C", line=310)
at ../../lyx-devel/src/boost.C:56
#6  0x0858356b in lyx::LyXText::dispatch (this=0x910e7b0, [EMAIL PROTECTED],
[EMAIL PROTECTED]) at ../../lyx-devel/src/text3.C:310
#7  0x087e6620 in lyx::InsetText::doDispatch (this=0x910e788, [EMAIL PROTECTED],
[EMAIL PROTECTED]) at ../../../lyx-devel/src/insets/insettext.C:259
#8  0x08719390 in lyx::InsetCollapsable::doDispatch (this=0x910e788,
[EMAIL PROTECTED], [EMAIL PROTECTED])
at ../../../lyx-devel/src/insets/insetcollapsable.C:362
#9  0x0873470b in lyx::InsetERT::doDispatch (this=0x910e788, [EMAIL PROTECTED],
[EMAIL PROTECTED]) at ../../../lyx-devel/src/insets/insetert.C:258
#10 0x086c20fa in lyx::InsetBase::dispatch (this=0x910e788, [EMAIL PROTECTED],
[EMAIL PROTECTED]) at ../../../lyx-devel/src/insets/insetbase.C:132
#11 0x0807ae69 in lyx::BufferView::workAreaDispatch (this=0x9018d78,
[EMAIL PROTECTED]) at ../../lyx-devel/src/BufferView.C:1130
#12 0x0885a69a in lyx::frontend::WorkArea::dispatch (this=0x90094cc,
[EMAIL PROTECTED]) at ../../../lyx-devel/src/frontends/WorkArea.C:196

Abdel? Bo?

JMarc


Re: [PATCH] put Gui language definition in lyxrc

2007-01-16 Thread Jean-Marc Lasgouttes
> "Abdelrazak" == Abdelrazak Younes <[EMAIL PROTECTED]> writes:

Edwin> why not set the language when installing lyx and be done with
Edwin> it...
>>  This is indeed what we do now.

Abdelrazak> What do you mean here? The current solution is to create a
Abdelrazak> batch file that sets LANG before launching LyX truly. I
Abdelrazak> rckon this is not a good solution.

It is not very nice indeed, but since we need the batch file anyway...

JMarc


Re: [PATCH] put Gui language definition in lyxrc

2007-01-16 Thread Abdelrazak Younes

Jean-Marc Lasgouttes wrote:

"Abdelrazak" == Abdelrazak Younes <[EMAIL PROTECTED]> writes:


Edwin> why not set the language when installing lyx and be done with
Edwin> it...

 This is indeed what we do now.


Abdelrazak> What do you mean here? The current solution is to create a
Abdelrazak> batch file that sets LANG before launching LyX truly. I
Abdelrazak> rckon this is not a good solution.

It is not very nice indeed, but since we need the batch file anyway...


This is the content of the batch file:

@echo off
SET LC_ALL=en_EN
SET AIK_DATA_DIR=D:\program\LyX14\aiksaurus
start "LyX" "D:\program\LyX14\bin\lyx.exe" %*

Does the aiksaurus support really needs this variable or is there a way 
to put that in the lyxrc.dist and use that?


Bo, Enrico?



Re: About bug 3099 (lyx seems to lock while loading previews)

2007-01-16 Thread Abdelrazak Younes

Jean-Marc Lasgouttes wrote:

"Abdelrazak" == Abdelrazak Younes <[EMAIL PROTECTED]> writes:


Abdelrazak> Yes. I am going to delay the redraw until the next cursor
Abdelrazak> blink happens. This way all the asked screen updates that
Abdelrazak> happens between two cursor blinks will be unified in a
Abdelrazak> single redraw.

Looks like a nice solution. Are we sure that the cursor always blinks?


It blinks for sure only for the active view. We need to find a solution 
for the other views. In the mean time, this commit is fixing bug 3099.
The renderPreview needs some cleanup because the signal is send but we 
don't know from which buffer. Because of that, we cannot distinguish 
between necessary redraws or not.
Also, even if ths is the current buffer, a redraw will happen even if 
this inset is not visible on screen...


Abdel.


Author: younes
Date: Tue Jan 16 16:16:09 2007
New Revision: 16708

URL: http://www.lyx.org/trac/changeset/16708
Log:
* LyXView::updateInset(): schedule a redraw instead of redraw immediately.

* WorkArea::sheduleRedraw(): new pure virtual method.

* GuiWorkArea::showCursor(): handle the scheduled redraw.

Modified:
lyx-devel/trunk/src/frontends/LyXView.C
lyx-devel/trunk/src/frontends/WorkArea.h
lyx-devel/trunk/src/frontends/qt4/GuiWorkArea.C
lyx-devel/trunk/src/frontends/qt4/GuiWorkArea.h

Modified: lyx-devel/trunk/src/frontends/LyXView.C
URL: 
http://www.lyx.org/trac/file/lyx-devel/trunk/src/frontends/LyXView.C?rev=16708

==
--- lyx-devel/trunk/src/frontends/LyXView.C (original)
+++ lyx-devel/trunk/src/frontends/LyXView.C Tue Jan 16 16:16:09 2007
@@ -431,11 +431,10 @@
 {
Buffer const * buffer_ptr = 0;
if (inset) {
+   BOOST_ASSERT(work_area_);
+   work_area_->sheduleRedraw();
+
buffer_ptr = work_area_->bufferView().buffer();
-   // No FitCursor:
-   BOOST_ASSERT(work_area_);
-   work_area_->bufferView().update(Update::Force);
-   work_area_->redraw();
}
return buffer_ptr;
 }

Modified: lyx-devel/trunk/src/frontends/WorkArea.h
URL: 
http://www.lyx.org/trac/file/lyx-devel/trunk/src/frontends/WorkArea.h?rev=16708

==
--- lyx-devel/trunk/src/frontends/WorkArea.h (original)
+++ lyx-devel/trunk/src/frontends/WorkArea.h Tue Jan 16 16:16:09 2007
@@ -82,6 +82,9 @@
 */
 	virtual void setScrollbarParams(int height, int pos, int line_height) 
= 0;


+   ///
+   virtual void sheduleRedraw() = 0;
+
/// redraw the screen, without using existing pixmap
virtual void redraw();
///

Modified: lyx-devel/trunk/src/frontends/qt4/GuiWorkArea.C
URL: 
http://www.lyx.org/trac/file/lyx-devel/trunk/src/frontends/qt4/GuiWorkArea.C?rev=16708

==
--- lyx-devel/trunk/src/frontends/qt4/GuiWorkArea.C (original)
+++ lyx-devel/trunk/src/frontends/qt4/GuiWorkArea.C Tue Jan 16 16:16:09 2007
@@ -159,7 +159,7 @@


 GuiWorkArea::GuiWorkArea(int w, int h, int id, LyXView & lyx_view)
-   : WorkArea(id, lyx_view), need_resize_(false)
+   : WorkArea(id, lyx_view), need_resize_(false), shedule_redraw_(false)
 {
cursor_ = new frontend::CursorWidget();
cursor_->hide();
@@ -535,6 +535,19 @@

 void GuiWorkArea::showCursor(int x, int y, int h, CursorShape shape)
 {
+   if (shedule_redraw_) {
+   if (buffer_view_ && buffer_view_->buffer()) {
+   buffer_view_->update(Update::Force);
+   updateScreen();
+			viewport()->update(QRect(0, 0, viewport()->width(), 
viewport()->height()));

+   }
+   shedule_redraw_ = false;
+   // Show the cursor immediately after the update.
+   hideCursor();
+   toggleCursor();
+   return;
+   }
+
cursor_->update(x, y, h, shape);
cursor_->show();
viewport()->update(cursor_->rect());

Modified: lyx-devel/trunk/src/frontends/qt4/GuiWorkArea.h
URL: 
http://www.lyx.org/trac/file/lyx-devel/trunk/src/frontends/qt4/GuiWorkArea.h?rev=16708

==
--- lyx-devel/trunk/src/frontends/qt4/GuiWorkArea.h (original)
+++ lyx-devel/trunk/src/frontends/qt4/GuiWorkArea.h Tue Jan 16 16:16:09 2007
@@ -103,6 +103,8 @@
virtual int height() const { return viewport()->height(); }
///
virtual void setScrollbarParams(int height, int pos, int line_height);
+   ///
+   virtual void sheduleRedraw() { shedule_redraw_ = true; }

/// update the passed area.
void update(int x, int y, int w, int h);
@@ -171,6 +173,8 @@
QPixmap screen_;
///
bool need_resize_;
+   ///
+   bool shedule_redraw_;
 };

 } // namespace fr

Re: Cannot compile. Latest in trunk

2007-01-16 Thread Abdelrazak Younes

Kornel Benko wrote:

Am Dienstag, 16. Januar 2007 15:46 schrieb Abdelrazak Younes:

Georg Baum wrote:

Abdelrazak Younes wrote:


Kornel Benko wrote:

Am Dienstag, 16. Januar 2007 15:09 schrieb Kornel Benko:

Attached cures it.

But this is not the good fix ;-)

Indeed not. string() should work even in older gcc versions.


I think the missing  header was the problem.

I don't think so. Otherwise it would have complained about docstring, too.
Indeed... It's probably the std::xxx declaration which were in the lyx 
namespace. This is known to fail for mingw for example.

I've fixed that.


But it's still not compilable.

if g++ -DHAVE_CONFIG_H -I. -I. -I.   -I../boost -W -Wall   -I/usr/X11R6/include  -g -O 
-MT CutAndPaste.o -MD -MP -MF ".deps/CutAndPaste.Tpo" -c -o CutAndPaste.o 
CutAndPaste.C; \
then mv -f ".deps/CutAndPaste.Tpo" ".deps/CutAndPaste.Po"; else rm -f 
".deps/CutAndPaste.Tpo"; exit 1; fi
CutAndPaste.C: In function `void lyxputClipboard(const
   lyx::ParagraphList&, unsigned int, const lyx::docstring&)':
CutAndPaste.C:332: error: type specifier omitted for parameter
CutAndPaste.C:332: error: syntax error before `false'


hum, could it be because of the 'explicit' in:

explicit Buffer(std::string const & file, bool b = false);

???

Abdel.



Re: Session: cursor position not retrieved when loading from last session

2007-01-16 Thread Bo Peng

On 1/15/07, Bennett Helm <[EMAIL PROTECTED]> wrote:

Another minor session bug (or is this a feature?): When starting up
LyX with the "Load opened files from last session" option selected,
the files get loaded, but the cursor position is not restored;
instead, the cursor is always at the top of the document. (This is
with Mac, current svn.)


I can not reproduce this. Can you try again?

Bo


Re: Cannot compile. Latest in trunk

2007-01-16 Thread Kornel Benko
Am Dienstag, 16. Januar 2007 16:32 schrieb Abdelrazak Younes:
> Kornel Benko wrote:
> > Am Dienstag, 16. Januar 2007 15:46 schrieb Abdelrazak Younes:
> >> Georg Baum wrote:
> >>> Abdelrazak Younes wrote:
> >>>
>  Kornel Benko wrote:
> > Am Dienstag, 16. Januar 2007 15:09 schrieb Kornel Benko:
> >
> > Attached cures it.
>  But this is not the good fix ;-)
> >>> Indeed not. string() should work even in older gcc versions.
> >>>
>  I think the missing  header was the problem.
> >>> I don't think so. Otherwise it would have complained about docstring, too.
> >> Indeed... It's probably the std::xxx declaration which were in the lyx 
> >> namespace. This is known to fail for mingw for example.
> >> I've fixed that.
> > 
> > But it's still not compilable.
> > 
> > if g++ -DHAVE_CONFIG_H -I. -I. -I.   -I../boost -W -Wall   
> > -I/usr/X11R6/include  -g -O -MT CutAndPaste.o -MD -MP -MF 
> > ".deps/CutAndPaste.Tpo" -c -o CutAndPaste.o CutAndPaste.C; \
> > then mv -f ".deps/CutAndPaste.Tpo" ".deps/CutAndPaste.Po"; else rm -f 
> > ".deps/CutAndPaste.Tpo"; exit 1; fi
> > CutAndPaste.C: In function `void lyxputClipboard(const
> >lyx::ParagraphList&, unsigned int, const lyx::docstring&)':
> > CutAndPaste.C:332: error: type specifier omitted for parameter
> > CutAndPaste.C:332: error: syntax error before `false'
> 
> hum, could it be because of the 'explicit' in:
> 
>   explicit Buffer(std::string const & file, bool b = false);
> 
> ???

It is very fishy here.
If I replace the call with:
string a("");
Buffer buffer(a, false);
then it compiles.

On the other hand
string a();
Buffer buffer(a, false);
yields to
CutAndPaste.C:676: error: no matching function for call to 
`lyx::Buffer::Buffer
   (std::string (&)(), bool)'
buffer.h:73: error: candidates are: lyx::Buffer::Buffer(const lyx::Buffer&)
buffer.h:92: error: lyx::Buffer::Buffer(const std::string&,
   bool)

regards Kornel
-- 
Kornel Benko
[EMAIL PROTECTED]


pgpLYZ9Vo3qND.pgp
Description: PGP signature


Re: Session: cursor position not retrieved when loading from last session

2007-01-16 Thread Bennett Helm

On Jan 16, 2007, at 10:47 AM, Bo Peng wrote:


On 1/15/07, Bennett Helm <[EMAIL PROTECTED]> wrote:

Another minor session bug (or is this a feature?): When starting up
LyX with the "Load opened files from last session" option selected,
the files get loaded, but the cursor position is not restored;
instead, the cursor is always at the top of the document. (This is
with Mac, current svn.)


I can not reproduce this. Can you try again?


Cursor is still always at the top of the document with just updated svn.

Bennett


Re: [part 4/4] again about LyX's default settings

2007-01-16 Thread Andreas K .
Jean-Marc Lasgouttes <[EMAIL PROTECTED]> writes:

> Well, then how do we catter for users that do not like this feature
> but are forced to live with it? OpenOffice has these popping toolbars
> because it has a delay before activating them.
> 
> JMarc

Make it possible for the user to de-activate this function in the preferences. 
Freedom of choice and customizability is the solution to all these disputes.

Regards,
Andreas






Re: [PATCH] put Gui language definition in lyxrc

2007-01-16 Thread Enrico Forestieri
On Tue, Jan 16, 2007 at 04:08:14PM +0100, Abdelrazak Younes wrote:

> Jean-Marc Lasgouttes wrote:
> >> "Abdelrazak" == Abdelrazak Younes <[EMAIL PROTECTED]> writes:
> > 
> > Edwin> why not set the language when installing lyx and be done with
> > Edwin> it...
> >>>  This is indeed what we do now.
> > 
> > Abdelrazak> What do you mean here? The current solution is to create a
> > Abdelrazak> batch file that sets LANG before launching LyX truly. I
> > Abdelrazak> rckon this is not a good solution.
> > 
> > It is not very nice indeed, but since we need the batch file anyway...
> 
> This is the content of the batch file:
> 
> @echo off
> SET LC_ALL=en_EN
> SET AIK_DATA_DIR=D:\program\LyX14\aiksaurus
> start "LyX" "D:\program\LyX14\bin\lyx.exe" %*
> 
> Does the aiksaurus support really needs this variable or is there a way 
> to put that in the lyxrc.dist and use that?

On Windows, the Aiksaurus data dir location can be set in the registry:
HKLM\Software\Aiksaurus\Data_Dir
The environment variable simply overrides the registry setting.

The language setting could be asked to the system when LC_ALL or LANG
are not set in the environment. See for example:
http://blogs.msdn.com/michkap/archive/2005/02/01/364707.aspx
http://www.microsoft.com/globaldev/DrIntl/faqs/Locales.mspx

So, the batch file is not needed, and, after all, neither setting it
in lyxrc.dist.

-- 
Enrico


Re: [PATCH] put Gui language definition in lyxrc

2007-01-16 Thread Abdelrazak Younes

Enrico Forestieri wrote:

On Tue, Jan 16, 2007 at 04:08:14PM +0100, Abdelrazak Younes wrote:


Jean-Marc Lasgouttes wrote:

"Abdelrazak" == Abdelrazak Younes <[EMAIL PROTECTED]> writes:

Edwin> why not set the language when installing lyx and be done with
Edwin> it...

 This is indeed what we do now.

Abdelrazak> What do you mean here? The current solution is to create a
Abdelrazak> batch file that sets LANG before launching LyX truly. I
Abdelrazak> rckon this is not a good solution.

It is not very nice indeed, but since we need the batch file anyway...

This is the content of the batch file:

@echo off
SET LC_ALL=en_EN
SET AIK_DATA_DIR=D:\program\LyX14\aiksaurus
start "LyX" "D:\program\LyX14\bin\lyx.exe" %*

Does the aiksaurus support really needs this variable or is there a way 
to put that in the lyxrc.dist and use that?


On Windows, the Aiksaurus data dir location can be set in the registry:
HKLM\Software\Aiksaurus\Data_Dir
The environment variable simply overrides the registry setting.


Very good then. Uwe, could you modify the package to do that?



The language setting could be asked to the system when LC_ALL or LANG
are not set in the environment. See for example:
http://blogs.msdn.com/michkap/archive/2005/02/01/364707.aspx
http://www.microsoft.com/globaldev/DrIntl/faqs/Locales.mspx

So, the batch file is not needed, and, after all, neither setting it
in lyxrc.dist.


Unless you want a different language than the one defined in LANG. So it 
is really needed in the lyxrc.dist.
As I see it, the package should ask by default if the system language is 
OK. If yes, put nothing in lyxrc.dist, if not ask the user which 
language he chooses and put that in lyxrc.dist.


Abdel.



Re: [PATCH] put Gui language definition in lyxrc

2007-01-16 Thread Enrico Forestieri
On Tue, Jan 16, 2007 at 05:27:24PM +0100, Abdelrazak Younes wrote:

> Enrico Forestieri wrote:

> > On Windows, the Aiksaurus data dir location can be set in the registry:
> > HKLM\Software\Aiksaurus\Data_Dir
> > The environment variable simply overrides the registry setting.
> 
> Very good then. Uwe, could you modify the package to do that?

I think that Joost did it through the env var such that LyX can be
installed without having privileges. I don't think that a normal
user can write to HKLM.

-- 
Enrico


LyX-1.4.3 patches

2007-01-16 Thread Jacek M. Holeczek
Hi,
please find attached an improved version of my patches.
As compared to the yesterday's version ...
1. the patch to "src/insets/insetlatexaccent.C" is not changed
2. the patch to "src/trans_mgr.C" is not changed
3. the patch to "src/text3.C" is improved in order to fix the problem with
   \", which I have found today being the same as the one with 

What concerns the patch 3. ... earlier today, in my previous email, I have
listed some special cases in the "src/text3.C", which explicitly call the
TransManager ... I have also mentioned that there are "combined" cases,
but I did not explicitly said what I meant ... I meant, for example,
places in the "src/text3.C", in the function LyXText::dispatch, where you
can find (recursive?) calls to "dispatch" and/or on-the-fly changes of the
"cmd" by the "FuncRequest" (if there is no call to "dispatch", you will
find a call to "undispatched()" in all such places).

Hope it helps,
Best regards,
Jacek.===
--- ./src/insets/insetlatexaccent.C.000 2005-11-25 15:40:34.0 +0100
+++ ./src/insets/insetlatexaccent.C 2007-01-10 14:06:34.0 +0100
@@ -460,14 +460,16 @@
LColor::foreground);
break;
 
-   case CARON: {
-   int xp[3], yp[3];
-   xp[0] = int(x2 - hg35);yp[0] = int(y + hg35);
-   xp[1] = int(x2);   yp[1] = int(y + hg);
-   xp[2] = int(x2 + hg35);yp[2] = int(y + hg35);
-   pi.pain.lines(xp, yp, 3, LColor::foreground);
-   break;
-   }
+   case CARON:
+   if (!contains("dlLt", ic)) {
+   int xp[3], yp[3];
+   xp[0] = int(x2 - hg35);yp[0] = int(y + 
hg35);
+   xp[1] = int(x2);   yp[1] = int(y + hg);
+   xp[2] = int(x2 + hg35);yp[2] = int(y + 
hg35);
+   pi.pain.lines(xp, yp, 3, LColor::foreground);
+   break;
+   }
+   // fall through for Czech and Slovak characters "dlLt" 
...
 
case SPECIAL_CARON: {
switch (ic) {

===
--- ./src/trans_mgr.C.000   2005-07-14 15:05:03.0 +0200
+++ ./src/trans_mgr.C   2007-01-15 15:56:52.0 +0100
@@ -13,6 +13,8 @@
 
 #include "trans_mgr.h"
 
+#include "buffer.h"
+#include "language.h"
 #include "BufferView.h"
 #include "CutAndPaste.h"
 #include "cursor.h"
@@ -22,6 +24,7 @@
 #include "trans.h"
 
 #include "insets/insetlatexaccent.h"
+#include "insets/insetert.h"
 
 #include "support/lstrings.h"
 
@@ -289,6 +292,15 @@
lyx::cap::replaceSelection(cur);
cur.insert(new InsetLatexAccent(ins));
cur.posRight();
+   } else if ((str.size() > 1) && ((str[0] == '{') || (str[0] == 
'\\') || (str[0] == '$')) && (str[1] != ' ')) {
+   // str looks like a LaTeX code ... make an ERT out of 
it ...
+   InsetERT * ert = new 
InsetERT(text->bv()->buffer()->params(), InsetBase::Open);
+   LyXFont font(LyXFont::ALL_INHERIT, latex_language);
+   ert->setText(str, font);
+   LCursor & cur = text->bv()->cursor();
+   cur.insert(ert);
+   ert->setStatus(cur, InsetBase::Collapsed);
+   cur.posRight();
} else {
insertVerbatim(str, text);
}

===
--- ./src/text3.C.000   2006-09-14 15:50:37.0 +0200
+++ ./src/text3.C   2007-01-16 17:41:52.0 +0100
@@ -325,6 +325,18 @@
// Remember the old paragraph metric (_outer_ paragraph!)
Dimension olddim = cur.bottom().paragraph().dim();
 
+   // if  or \" pressed after an  ... kill the  ...
+   switch (cmd.action) {
+   case LFUN_BREAKLINE:
+   case LFUN_BREAKPARAGRAPH:
+   case LFUN_BREAKPARAGRAPHKEEPLAYOUT:
+   case LFUN_BREAKPARAGRAPH_SKIP:
+   case LFUN_END_OF_SENTENCE:
+   case LFUN_QUOTE:
+   // combined_state_ -> deadkey_state_ -> init_state_
+   while (!(bv->owner()->getIntl().getTransManager().backspace())) 
;
+   }
+
switch (cmd.action) {
 
case LFUN_APPENDIX: {



Re: [part 1] again about LyX's default settings

2007-01-16 Thread Jürgen Spitzmüller
Georg Baum wrote:
> IMO you shoud definitely add the icons for viewing and updating pdf to svn,
> since we already have some for dvi and ps.

Here are some alternative ones (crystal style). But I don't know how they fit 
with LyX's default icons (since I use crystal icons myself).

Jürgen


buffer-update_pdf2.xpm
Description: X pixmap


buffer-view_pdf2.xpm
Description: X pixmap


Re: Cannot compile. Latest in trunk

2007-01-16 Thread Angus Leeming
Kornel Benko <[EMAIL PROTECTED]> writes:
> It is very fishy here.
> If I replace the call with:
>   string a("");
> Buffer buffer(a, false);
> then it compiles.
> 
> On the other hand
>   string a();
>   Buffer buffer(a, false);
> yields to
>   CutAndPaste.C:676: error: no matching function for call to 
`lyx::Buffer::Buffer
>(std::string (&)(), bool)'
> buffer.h:73: error: candidates are: lyx::Buffer::Buffer(const lyx::Buffer&)
> buffer.h:92: error: lyx::Buffer::Buffer(const std::string&,
>bool)

That's not fishy at all.

   string a("");

defines a variable "a" and initializes it with "". The same thing is achieved 
more elegantly and less expensively with:

   string a;

By way of contrast,

   string a();

is a declaration of a function "a" that takes no arguments and returns a 
string...

If you look a little closely at the error message, you'll see that the 
compiler is even trying to tell you that.

Regards,
Angus



Re: inputencoding "default" again

2007-01-16 Thread Georg Baum
Am Dienstag, 16. Januar 2007 10:50 schrieb Dov Feldstern:

> I just spent two hours playing around with this, and it turns out that 
> the problem *is* with the way LyX is writing the output.

That is good, because it means that we can fix it.

> I don't exactly  
> understand what's going on, but I was able to fix it with a really 
> simple patch (attached) --- although since I don't exactly understand 
> the problem, I can't vouch for the patch's correctness. It does work for 
> me, however.

When I did something similar in one of the first versions of the patch it 
had the effect that a paragraph break vanished, but since I have a test 
case for that it should be possible to revise the patch so that it works 
in both cases.

> If you want to see the example file I worked with, I can give it to you, 
> but I'd rather not post it publicly (it's an old version of my CV). Is 
> there any way for me to get it to you privately?

Just send it to my email address.


Georg



Re: Cannot compile. Latest in trunk

2007-01-16 Thread Georg Baum
Am Dienstag, 16. Januar 2007 16:52 schrieb Kornel Benko:
> It is very fishy here.
> If I replace the call with:
>   string a("");
> Buffer buffer(a, false);
> then it compiles.
> 
> On the other hand
>   string a();

This is a function declaration of a function 'a' returning a string. What 
you want is

string a;

and I am sure it would work.


Georg



Question about SVN size

2007-01-16 Thread killermike

Hiya all

Unfortunately, my home internet access is download capped (don't ask, 
it's a long story). For that reason, I would be curious to know roughly 
how much data would be pulled down if I were to fetch the SVN 1.5 source 
code on my Ubuntu box?


--
http://www.unmusic.co.uk - about me, music, geek sitcom etc.
http://www.unmusic.co.uk/amhs/ - alt.music.home-studio 





Source for latex-xft-fonts?

2007-01-16 Thread Per Olofsson
Hi,

There is a bug filed against the latex-xft-fonts Debian package about
the lack of source code for it (http://bugs.debian.org/402148). This
prevents the package from entering etch (the upcoming stable release
of Debian).

Apparently the fonts have been converted from the corresponding LaTeX
.pfb fonts. Does anyone know how this was done? Is it possible to
automate?

-- 
Pelle


Re: Cannot compile. Latest in trunk

2007-01-16 Thread Kornel Benko
Am Dienstag, 16. Januar 2007 19:41 schrieb Angus Leeming:
> That's not fishy at all.
>
>    string a("");
>
> defines a variable "a" and initializes it with "". The same thing is
> achieved more elegantly and less expensively with:
>
>    string a;
>
> By way of contrast,
>
>    string a();
>
> is a declaration of a function "a" that takes no arguments and returns a
> string...

Of course you are right. Now I feel very unconfortable.

Kornel
-- 
Kornel Benko
[EMAIL PROTECTED]


pgpkWxT9IOUdR.pgp
Description: PGP signature


Re: LyX-1.4.3 patches

2007-01-16 Thread Georg Baum
Am Dienstag, 16. Januar 2007 11:29 schrieb Jacek M. Holeczek:

> In principle, the "fall through" in the patch should take place only when
> LaTeX does it, too ... but I don't know how to test for "T1" (nor which
> additional conditions should trigger this behavior and thus be tested).
> However, according to:
>   http://en.wikipedia.org/wiki/Caron
>   http://de.wikipedia.org/wiki/Caron
> these four special characters (d,l,L,t) are ONLY used with caron in Czech
> and Slovak languages, and ALWAYS with the "special caron" form.

That is interesting, we finally found somebody who knows what this "special 
caron" is. This is really amazing: No LyX developer knew that this was 
indeed working, and that people used it. The same is true for 
the "default" encoding: First we thought it was useless, no we know that 
the opposite is true.

We are going to get rid of InsetLaTeXAccent for 1.5.0, because it is not 
needed anymore since we support unicode. When importing old documents with 
lyx2lyx we are going to convert the normal caron to the unicode character 
0x030c. Can you please tell us what we should do with the special caron? 
Convert to 0x030c too, or to something else?

> Thus, I believe one can safely put this "unconditional fall through" ...
> unless you know any other languages for which is should not be done ...
> which I have not found (working hard on this issue) ...
> (Last, but not least, please note that, this patch influences ONLY the 
LyX
> window display, the generated LaTeX/ps/eps files will ALWAYS be fine,
> regardless if this patch is in or out.)

I think this part could go really in, since it is no risk and it seems to 
be very important for Jacek.

> Please commit this patch. This is a bug fix. A serious one for me. On a
> couple of occasions, I have already reported that, the current LyX
> produces INCORRECT LaTeX code when it finds a character, in the ".kmap"
> file, which it cannot display by itself. This patch is a fix to this
> problem. A working one ... I believe it does not influence anything else.

Can you give an example please? E.g. character typed in, resulting stuff in 
the .lyx file and resulting .tex output.

> And how about "combined" cases?
> For the moment, I have made this patch as simple as possible ... fixing
> only the nasty bug with "keyboard enter" ...

I have no idea how these kmap files work, but can they really contain LaTeX 
code? I would rather think that they could contain anything you would 
normally type in LyX, that means not arbitrary LaTeX. Therefore I don't 
think the part that patches TransManager is correct.

> As I have already told you, many of the people I work with will not be
> able to use 1.5 for a very very long time. And because we need to 
exchange
> files, we have to stick to a "common standard" that works on different OS
> flavors and different OS versions ... for the moment, this can only be 
LyX
> 1.4, and if not, we will have to drop LyX going back to the "common" pure
> LaTeX.

If they can't upgrade to 1.5, how can they upgrade to 1.4.4? It looks like 
1.5.0 will really have a lot of improvements over the 1.4.x series, and it 
will definitely be more stable than 1.4.0 was. Therefore I recommend to 
upgrade.


Georg



Re: Source for latex-xft-fonts?

2007-01-16 Thread John Levon
On Tue, Jan 16, 2007 at 08:11:22PM +0100, Per Olofsson wrote:

> There is a bug filed against the latex-xft-fonts Debian package about
> the lack of source code for it (http://bugs.debian.org/402148). This
> prevents the package from entering etch (the upcoming stable release
> of Debian).
> 
> Apparently the fonts have been converted from the corresponding LaTeX
> .pfb fonts. Does anyone know how this was done? Is it possible to
> automate?

I've entirely forgotten how I did it, but it definitely involved some
manual fixing of the fonts. I used some popular open-source font editor,
which I've also forgotten, and I had to fix some stuff up if I remember
rightly.

I have no idea what "sources" they're looking for. It's like complaining
a .jpg doesn't have sources when it's a scanned in photo.

One solution might be to add the missing families to Mozilla's TTF
fonts, and get them working with LyX?

regards
john


Re: Source for latex-xft-fonts?

2007-01-16 Thread Georg Baum
Am Dienstag, 16. Januar 2007 20:36 schrieb John Levon:
> On Tue, Jan 16, 2007 at 08:11:22PM +0100, Per Olofsson wrote:
> 
> > There is a bug filed against the latex-xft-fonts Debian package about
> > the lack of source code for it (http://bugs.debian.org/402148). This
> > prevents the package from entering etch (the upcoming stable release
> > of Debian).
> > 
> > Apparently the fonts have been converted from the corresponding LaTeX
> > .pfb fonts. Does anyone know how this was done? Is it possible to
> > automate?
> 
> I've entirely forgotten how I did it, but it definitely involved some
> manual fixing of the fonts. I used some popular open-source font editor,
> which I've also forgotten, and I had to fix some stuff up if I remember
> rightly.

You probably used fontforge (formerly called PFAEdit IIRC).

> I have no idea what "sources" they're looking for. It's like complaining
> a .jpg doesn't have sources when it's a scanned in photo.

No, it is rather like looking for the source of a jpeg that somebody 
created by manually modifying another one. This cannot be automated 
either.

To me the ttf fonts look like a derived work of the original pfb versions. 
So, these could be considered as source, but the normal way of automated 
building from source would not work, so it would be pointless. AFAIK the 
original pfb fonts are under the LPPL, so I think the following would 
work:

- The ttf files are considered as source technically.
- The README documents that they were converted from the .pfb files and 
polished manually after that.
- The README documents where to get the .pfb files (required by the LPPL).

IANAL, but I see no reason why this would not work.


Georg



Getting rid of InsetLaTeXAccent: Current state

2007-01-16 Thread Georg Baum
Lars,

during your break I have worked a bit on your patch that removes 
InsetLaTeXAccent. The lyx2lyx conversion is much better now, but has still 
some problems. I changed the part that touches TransManager because I 
think that disabling the TransManager completely should be done in a 
separate patch.
I post the current version and a test document because I won't have too 
much time during the next days to work on it, and maybe somebody else 
wants to have a look. lyx2lyx still has some FIXMEs, and somebody should 
verify that LaTeX output is also OK for non-utf8 encodings. It is in many 
cases, since we can now switch the encoding not only per paragraph, but 
more fine grained, so we can simply output the accented character in the 
appropriate encoding, but what about accent/character combinations that 
are not available in any 8bit encoding?
Since some people start to use 1.5svn for serious work we should only apply 
this after these issues have been fixed IMHO.


Georg
Index: src/insets/insetlatexaccent.C
===
--- src/insets/insetlatexaccent.C	(Revision 16710)
+++ src/insets/insetlatexaccent.C	(Arbeitskopie)
@@ -1,626 +0,0 @@
-/**
- * \file insetlatexaccent.C
- * This file is part of LyX, the document processor.
- * Licence details can be found in the file COPYING.
- *
- * \author Lars Gullik Bjønnes
- *
- * Full author contact details are available in file CREDITS.
- */
-
-#include 
-
-#include "insetlatexaccent.h"
-
-#include "debug.h"
-#include "language.h"
-#include "LColor.h"
-#include "lyxlex.h"
-#include "lyxrc.h"
-#include "metricsinfo.h"
-
-#include "frontends/FontMetrics.h"
-#include "frontends/Painter.h"
-
-#include "support/lstrings.h"
-
-
-namespace lyx {
-
-using support::contains;
-using support::trim;
-
-using std::endl;
-using std::string;
-using std::auto_ptr;
-using std::ostream;
-
-
-/* LatexAccent. Proper handling of accented characters */
-/* This part is done by Ivan Schreter, [EMAIL PROTECTED] */
-/* Later modified by Lars G. Bjønnes, [EMAIL PROTECTED] */
-
-InsetLatexAccent::InsetLatexAccent()
-	: candisp(false)
-{}
-
-
-InsetLatexAccent::InsetLatexAccent(string const & str)
-	: contents(str)
-{
-	checkContents();
-}
-
-
-auto_ptr InsetLatexAccent::doClone() const
-{
-	return auto_ptr(new InsetLatexAccent(contents));
-}
-
-
-void InsetLatexAccent::checkContents()
-	// check, if we know the modifier and can display it ok on screen
-{
-	candisp = false;
-
-	if (contents.empty() || contents.length() < 2) {
-		lyxerr[Debug::KEY] << "Cannot decode: " << contents << endl;
-		return;
-	}
-
-	contents = trim(contents);
-	if (contents[0] != '\\') { // demand that first char is a '\\'
-		lyxerr[Debug::KEY] << "Cannot decode: " << contents << endl;
-		return;
-	}
-
-	lyxerr[Debug::KEY] << "Decode: " << contents << endl;
-
-	remdot = false;
-	plusasc = false;
-	plusdesc = false;
-
-	switch (contents[1]) { // second char should be one of these
-	case '\'':  // acute
-		modtype = ACUTE;// acute
-		plusasc = true;// at the top of character
-		break;
-	case '`':   // grave
-		modtype = GRAVE;// grave
-		plusasc = true;// at the top
-		break;
-	case '=':   // macron
-		modtype = MACRON;// macron
-		plusasc = true;// at the top
-		break;
-	case '~':   // tilde
-		modtype = TILDE;// tilde
-		plusasc = true;// at the top
-		break;
-	case 'b':   // underbar
-		modtype = UNDERBAR;// underbar
-		plusdesc = true;   // at the bottom
-		break;
-	case 'c':   // cedilla
-		modtype = CEDILLA;// cedilla
-		plusdesc = true;   // at the bottom
-		break;
-	case 'd':   // underdot
-		modtype = UNDERDOT;// underdot
-		plusdesc = true;   // at the bottom
-		break;
-	case 'r':   // circle
-		modtype = CIRCLE;// circle
-		plusasc = true;// at the top
-		break;
-	case 't':   // tie
-		modtype = TIE;// tie
-		plusasc = true;// at the top
-		break;
-	case 'u':   // breve
-		modtype = BREVE;// breve
-		plusasc = true;// at the top
-		break;
-	case 'v':   // caron
-		modtype = CARON;   // caron
-		plusasc = true;// at the top
-		break;
-	case 'q':   // special caron
-		modtype = SPECIAL_CARON;   // special caron
-		plusasc = true;// at the top
-		break;
-	case 'H':   // hungarian umlaut
-		modtype = HUNGARIAN_UMLAUT;   // hungarian umlaut
-		plusasc = true;// at the top
-		break;
-	case '"':   // umlaut
-		modtype = UMLAUT;   // umlaut
-		plusasc = true;// at the top
-		break;
-	case '.':   // dot
-		modtype = DOT;   // dot
-		plusasc = true;// at the top
-		break;
-	case '^':   // circumflex
-		modtype = CIRCUMFLEX;   // circumflex
-		plusasc = true;// at the top
-		break;
-	case 'k':   // ogonek
-		modtype = OGONEK;  // ogonek
-		plusdesc = true;
-		break;
-	case 'i': // dot-less-i
-		modtype = DOT_LESS_I;  // dot-less-i
-		plusasc = true; // at the top (not really needed)
-		remdot = true;
-		break;
-	case 'j': // dot-less-j
-		modtype = DOT_LESS_J; // dot-less-j

Re: [Pkg-lyx-devel] Re: Source for latex-xft-fonts?

2007-01-16 Thread Per Olofsson
John Levon:
> I've entirely forgotten how I did it, but it definitely involved some
> manual fixing of the fonts. I used some popular open-source font editor,
> which I've also forgotten, and I had to fix some stuff up if I remember
> rightly.

Perhaps fontforge?

> I have no idea what "sources" they're looking for. It's like complaining
> a .jpg doesn't have sources when it's a scanned in photo.

Not exactly, because these fonts have been generated from the original
font files. The thinking is that they have been "compiled" from the
originals. But I'm not sure that's really the case here.

If you had to fix up stuff, and have forgotten exactly how you
generated the fonts, then I think the ttf files actually qualify as
"source" as far as Debian is concerned. Debian's definition of source
code is "preferred form of modification", which these files seem to
be.

> One solution might be to add the missing families to Mozilla's TTF
> fonts, and get them working with LyX?

I'm not familiar with these fonts so I can't say.

-- 
Pelle


Re: Question about SVN size

2007-01-16 Thread christian . ridderstrom

On Tue, 16 Jan 2007, killermike wrote:

Unfortunately, my home internet access is download capped (don't ask, 
it's a long story). For that reason, I would be curious to know roughly 
how much data would be pulled down if I were to fetch the SVN 1.5 source 
code on my Ubuntu box?


On Windows, the directory where I've checked out and *compiled* LyX, the 
size is about 500 MB.


Just the directory with a download of the source is about 80 MB, but I 
that's twice as big as what'll you actually download. So say 40-80 MB.


However, you might need additional packages...

How big is your quota?

/Christian

--
Christian Ridderström, +46-8-768 39 44   http://www.md.kth.se/~chr

Re: cursor related(?) crash

2007-01-16 Thread Bo Peng

This is a bug of BufferView::workAreaDispatch. When InsetCollapsable
is invoked, cur does not point inside the inset (as most code assumes)
but just outside. I do not know when this change happened, but it
should be reverted.


Index: src/insets/insetcollapsable.C
===
--- src/insets/insetcollapsable.C   (revision 16710)
+++ src/insets/insetcollapsable.C   (working copy)
@@ -306,7 +306,7 @@
InsetBase * InsetCollapsable::editXY(LCursor & cur, int x, int y)
{
   //lyxerr << "InsetCollapsable: edit xy" << endl;
-   if (status() == Collapsed || button_dim.contains(x, y))
+   if (status() == Collapsed || (button_dim.contains(x, y) &&
status() != Inlined))
   return this;
   cur.push(*this);
   return InsetText::editXY(cur, x, y);
@@ -320,7 +320,7 @@

   switch (cmd.action) {
   case LFUN_MOUSE_PRESS:
-   if (cmd.button() == mouse_button::button1 && hitButton(cmd)) {
+   if (cmd.button() == mouse_button::button1 &&
hitButton(cmd) && status() != Inlined) {
   // reset selection if necessary (see bug 3060)
   if (cur.selection())
   cur.bv().cursor().clearSelection();


Should fix this. The first change was done by me
((button_dim.contains(x, y) ) to not add text to cursor when the inset
is closed (the cursor before inset crash). The inline case is
forgotten. I do not know who is responsible for the second missing
Inline case.

OK to apply?
Bo


bug 3077

2007-01-16 Thread Uwe Stöhr

Edwin wrote:

> the attached patch gets rid of this one (and a crash)
>
> i also got rid of 2 mailer updates which i think are not necessary since workarea dispatch 
already > updates the dialog on key and mouse events (i might be wrong though)

>
> can someone (uwe?) test it?

Many thanks Edwin,

your patch fixed bug 3076 and 3077.

regards Uwe


[Patch] Re: [Cvslog] r16590 - /lyx-devel/trunk/lib/ui/stdmenus.inc

2007-01-16 Thread Martin Vermeer
On Mon, Jan 15, 2007 at 10:16:48AM +0100, Leuven, E. wrote:
> > The latter is misleading, as every batch of lines separated by a blank
> > line will produce one paragraph. So there may be many "single lines"
> > produced. 
> > Also, calling it a "single line" is technically correct, but in the word
> > processor sense it is a "paragraph".
> 
> ok. but the first one doesn't need a qualifier i think
> 
> - Plain Text
> - Plain Text (Join Lines)


Would the attached patch be committable (1.5)?

- Martin 

Index: stdmenus.inc
===
--- stdmenus.inc(revision 16710)
+++ stdmenus.inc(working copy)
@@ -125,11 +125,11 @@
End
 
Menu "edit_paste"
-   Item "Plain Text as Lines|T" "clipboard-paste"
-   Item "Plain Text as Paragraphs|e" "clipboard-paste paragraph"
+   Item "Plain Text|T" "clipboard-paste"
+   Item "Plain Text, Join Lines|J" "clipboard-paste paragraph"
Separator
-   Item "Selection as Lines|L" "primary-selection-paste"
-   Item "Selection as Paragraphs|P" "primary-selection-paste 
paragraph"
+   Item "Selection|S" "primary-selection-paste"
+   Item "Selection, Join Lines|i" "primary-selection-paste 
paragraph"
End
 
Menu "edit_pasterecent"
@@ -377,8 +377,8 @@
 
Menu "insert_file"
Item "LyX Document...|X" "file-insert"
-   Item "Plain Text as Lines...|L" "file-insert-plaintext"
-   Item "Plain Text as Paragraphs...|P" 
"file-insert-plaintext-para"
+   Item "Plain Text...|T" "file-insert-plaintext"
+   Item "Plain Text, Join Lines...|J" "file-insert-plaintext-para"
Separator
Item "External Material...|M" "dialog-show-new-inset external"
Item "Child Document...|d" "dialog-show-new-inset include"


pgpZZ1VZS6vU1.pgp
Description: PGP signature


Re: Question about SVN size

2007-01-16 Thread killermike

[EMAIL PROTECTED] wrote:

On Tue, 16 Jan 2007, killermike wrote:

Unfortunately, my home internet access is download capped (don't ask, 
it's a long story). For that reason, I would be curious to know 
roughly how much data would be pulled down if I were to fetch the SVN 
1.5 source code on my Ubuntu box?


On Windows, the directory where I've checked out and *compiled* LyX, 
the size is about 500 MB.


Just the directory with a download of the source is about 80 MB, but I 
that's twice as big as what'll you actually download. So say 40-80 MB.


However, you might need additional packages...

How big is your quota?


My quota is 2gig a month (no laughing!) so, that looks quite do able.
I've built 1.4.3 on this machine so, hopefully, I'll already have some
of what I need. Thanks for the response.

--
http://www.unmusic.co.uk - about me, music, geek sitcom etc.
http://www.unmusic.co.uk/amhs/ - alt.music.home-studio





Gmane OK?

2007-01-16 Thread lyx
Am I correct in that Gmane is now working fine?  My server reports messages
accepted by the gmane email server...

Máté


Re: Gmane OK?

2007-01-16 Thread Paul A. Rubin

[EMAIL PROTECTED] wrote:

Am I correct in that Gmane is now working fine?  My server reports messages
accepted by the gmane email server...

Máté


The news server is working (promptly) for me now.

/Paul



Re: r16675 [2/4] - in /lyx-devel/branches/BRANCH_1_4_X: devel...

2007-01-16 Thread Uwe Stöhr

Georg wrote:

>> Should I set the binary flag anyway?
>
> Yes. Normally binary files do not show up in the diffs. This file seems to
> be missing this flag, since the command
>
> Therefore I believe that something wnet wrong with setting the flag for this
> file. This is trunk, I guess 1.4 is similar.

This was the same in trunk and branch, fixed now.

thanks Uwe


Re: [PATCH] put Gui language definition in lyxrc

2007-01-16 Thread Uwe Stöhr

>>This is the content of the batch file:
>>
>>@echo off
>>SET LC_ALL=en_EN
>>SET AIK_DATA_DIR=D:\program\LyX14\aiksaurus
>>start "LyX" "D:\program\LyX14\bin\lyx.exe" %*

No, the current version is e.g.:

@echo off
SET OUTPUT_CHARSET=cp-1252
SET LANG=de_DE
SET AIK_DATA_DIR=C:\Program Files (x86)\LyX 1.5svn-15-01-2007\aiksaurus
start "LyX" "C:\Program Files (x86)\LyX 1.5svn-15-01-2007\bin\lyx.exe" %*

The
SET OUTPUT_CHARSET=xxx
setting is needed that LyX can be installed in folder/paths with accented characters, umlauts, etc. 
I've build in a lookup table for the different languages. Unfortunately utf-8 cannot be used, only a 
cp charset - I found out that this is a windows restriction.


>>   On Windows, the Aiksaurus data dir location can be set in the registry:
>>   HKLM\Software\Aiksaurus\Data_Dir
>>   The environment variable simply overrides the registry setting.
>
> Very good then. Uwe, could you modify the package to do that?

I'll check this and change this if it works for me too. I see the problem of multiple installations 
of LyX. For example when LyX 1.3.7 AND LyX 1.4.x is installed sise by side. Without this setting I 
have to install aiksaurus in a different folder, independent from LyX, like Aspell. This requires 
some changes but it's in my opinion worth to be implemented.


>>  The language setting could be asked to the system when LC_ALL or LANG
>>  are not set in the environment. See for example:
>>  http://blogs.msdn.com/michkap/archive/2005/02/01/364707.aspx
>>  http://www.microsoft.com/globaldev/DrIntl/faqs/Locales.mspx

I don't understand what you mean. I know users who use a German Windows but install LyX with Spanish 
menus. LyX menu language should be independent from Windows' language settings.


> Unless you want a different language than the one defined in LANG. So it is 
really needed in the
> lyxrc.dist. As I see it, the package should ask by default if the system 
language is OK. If yes,
> put nothing in lyxrc.dist, if not ask the user which language he chooses and 
put that in
> lyxrc.dist.

What do you mean with "if the system language is OK"? The current behaviour is:
The installer checks the actual Windows language and proposes this one in a droplist. So the user 
can easily choose the language while installing LyX.
There's currently set nothing language specific in the lyxrc.dist, only the \path_prefix is set to 
this file. This can easily be changed if you specify the format how this should be specified (please 
send me an example lixrc.dist with the language entry).


Btw. I want to upload my installer stuff to SVN, is that OK?

regards Uwe


Re: [part 3/4] again about LyX's default settings

2007-01-16 Thread Uwe Stöhr

> Change beamer.layout to start with (untested)
>
> #% Do not delete the line below; configure depends on this
> #  \DeclareLaTeXClass[beamer.cls,pgf.sty,xcolor.sty]{Beamer Presentation 
Class}

This won't really help because the problematic is the following:

Uwe> \TestPackage{pgf} % needed by beamer
Uwe> \TestPackage{xcolor} % needed by beamer
Uwe>
Uwe> Without these packages beamer is unusable.

> Because MikTeX will not download them by default, right?

When chklatex.ltx is invoked, MiKTeX will download/install the packages checked there. Currently we 
only check for beamer, that means MiKTeX only installs beamer and not xcolor and pgf.
If the user uses now beamer, latex will use also the missing packages and, if an internet connection 
is opened, MiKTeX will install them at runtime. This is fine, but if no internet in on the user will 
get LaTeX-error messages about missing packages.


So if we we recommand to install LyX while the internet is on we could assure that all needed 
packages are installed when we check for them in chkconfig.ltx.
I let you decide, yes or no, it'ts not that important as the user can install the packages later and 
most of the users won't get LaTeX error when MiKteX installs them in the background at runtime.


---
Btw. The MiKTeX developer is working on the problem that chklatex.ltx is quit at the first check 
when no internet connection is available. I'll inform you if the fix is ready.


regards Uwe


Re: [part 4/4] again about LyX's default settings

2007-01-16 Thread Uwe Stöhr

> What was the result when we discussed last time whether the table toolbar
> should be automatic by default or not? I don't remember, but we should not
> start this discussion again, rather use the old conclusions.

I remember the dicussion but couldn't find an exact conclusion about the 
toolbar popup.
OK, postponing this.

regards Uwe


  1   2   >