Re: Key bindings

2008-11-29 Thread Peleg Michaeli
Thank you very much.

I think I will try to install LyX 1.6 some day here on my old ubuntu,
but it won't be in the next weeks, probably (for the solution of the
bindings of Ω, ψ, etc...). The bindings of the C-g y works well now.


Peleg.

On Mon, 2008-11-24 at 12:13 +, Guenter Milde wrote:
> Dov Feldstern <[EMAIL PROTECTED]> schrieb:
> > Peleg Michaeli wrote:
> >> On Sat, 2008-11-22 at 20:28 +0200, Dov Feldstern wrote:
> >>> They shouldn't all be bothering you, only the ones you include are
> >>> activated. 
> >>> Probably it's cua -- that's the default.
> 
> >>> what exactly does your bind file look like? 
> 
> >> I'm attaching cua and hebrew here.
> 
> >> The cua.bind is in usr/share/... and the hebrew.bind is in
> >> ~/.lyx1.5.1/bind/
> 
> 
> > The first line of hebrew.bind ("\bind_file cua") is including cua.bind.
> > I don't remember the rules in terms of whether you can override
> > bindings, and they may also have changes since 1.5. 
> 
> Generally, you can overwrite bindings. However in this case it is more
> complicated:
> 
>  ./bind/cua.bind:\bind "C-g" "error-next"
>  
> binds ^G, so LyX will not wait for ^G y.
> 
> @ the LyX experts: 
>   
>   Is there a way to "unbind" a key so that it can be used at basis for a
>   set of multi-key bindings?
>  
> > The easiest thing to do may be to just copy cua.bind from /usr to your
> > local lyx bind directory, rename it to mycua or something, 
> 
> Actually, there is no need to rename (other than clarity), as LyX will
> try the version in your personal LyXDir first.
> 
> > get rid of the "C-g y" in there, and include that in hebrew instead of
> > cua. 
> 
> It will not matter where the new bindings are included as long as the
> original binding is commented out:
> 
> -  \bind "C-g" "error-next"
> +  # \bind "C-g" "error-next"
> 
> Günter
> 



Re: Key bindings

2008-11-22 Thread Peleg Michaeli
On Sat, 2008-11-22 at 21:26 +0200, Dov Feldstern wrote:
> No. However, perhaps you can try installing 1.6 in a virtualized
> environment 
> (Qemu, VirtualBox are relatively easy to set up, I think), so that it
> won't 
> affect your production system until you've got it configured
> correctly... 


Thanks,
I might try that.

Peleg.




Re: Key bindings

2008-11-22 Thread Peleg Michaeli
On Sat, 2008-11-22 at 17:34 +, Peleg Michaeli wrote:
> > When you say "so I have configured my keyboard to have all of the
> greek letters, 
> > including √, ∞, ∝, ≤≥ ⊆⊇ ⊂⊃ ←→ ⇐⇒ − ≠ ≡ ∀ ∃ and many more" --- did
> you do 
> > anything to actually configure the keyboard, or just paste stickers
> on or 
> > something? I mean, when you press a key, will LyX be getting a "g"
> or some 
> > unicode character?
> 
> Very simple: I have reconfigured GNOME, so now when I press "Alt Gr +
> s", for example, I get σ. If I press the same key combination with
> Caps-Lock on, or with Shift key pressed as well, I get Σ. Pressing the
> key that is just near the "z" key on its left produces ∀, and doing
> that
> with Shift produces ∃, and many more options.
> 
> I haven't put any stickers. I know the keys (at least most of them) by
> heart − it's very simple. I do it like that since even though I know
> TeX
> quite good, it is much shorter to write emails to friends like this:
> "Let x∈P and y∈Q. Since P and Q are normal, xyx^-1y^-1∈P∩Q={e}... ⇒
> something..." or compare "...hence P\subseteq Q" to "...hence P⊆Q".
> 
> So, in LyX, when I press "Alt Gr + a" I get α, but I don't want to get
> α
> − I want to get "\alpha", and I believed that LyX might have a
> solution
> to this need (and, apparently, it has − but only in 1.6). Vim, for
> example, knows really well how to deal with that.
> 
> It is important to say also that the configuration is very basic, and
> it
> works in ANY software on my computer, including LyX. It's not a "hack"
> in the risky aspect of it.
> > 
> > Depending on your answers to these questions, I *may* be able to
> help a little... 

Hi Dov -
Can you think of any solution to this without switching to LyX 1.6 ?


Thanks,
Peleg.




Re: Key bindings

2008-11-22 Thread Peleg Michaeli
On Sat, 2008-11-22 at 20:42 +0200, Dov Feldstern wrote:
> > The first line of hebrew.bind ("\bind_file cua") is including
> > cua.bind. I don't 
> > remember the rules in terms of whether you can override bindings, and
> > they may 
> > also have changes since 1.5. The easiest thing to do may be to just
> > copy 
> > cua.bind from /usr to your local lyx bind directory, rename it to
> > mycua or 
> > something, get rid of the "C-g y" in there, and include that in hebrew
> > instead 
> > of cua. See if that helps. 

Works great, thanks!

Peleg.



Re: Key bindings

2008-11-22 Thread Peleg Michaeli
On Sat, 2008-11-22 at 20:28 +0200, Dov Feldstern wrote:
> They shouldn't all be bothering you, only the ones you include are
> activated. 
> Probably it's cua -- that's the default.
> 
> what exactly does your bind file look like? 

I'm attaching cua and hebrew here.

The cua.bind is in usr/share/... and the hebrew.bind is in
~/.lyx1.5.1/bind/

Thanks,
Peleg.



cua.bind
Description: Binary data
\bind_file cua
\bind "F12" "language hebrew"
\bind "M-9 "math-delim ( )"
\bind "M-0 "math-delim ( )"

\bind "M-m 7"   "math-insert \psi"
\bind "ψ"   "math-insert \psi"

# First: Greek, start with C-g
\bind "C-g a"  "math-insert \alpha"
\bind "C-g b"  "math-insert \beta"
\bind "C-g c"  "math-insert \chi"
\bind "C-g d"  "math-insert \delta"
\bind "C-g e"  "math-insert \varepsilon"
\bind "C-g f"  "math-insert \phi"
\bind "C-g g"  "math-insert \gamma"
\bind "C-g h"  "math-insert \eta"
\bind "C-g i"  "math-insert \iota"
\bind "C-g j"  "math-insert \varphi"
\bind "C-g k"  "math-insert \kappa"
\bind "C-g l"  "math-insert \lambda"
\bind "C-g m"  "math-insert \mu"
\bind "C-g n"  "math-insert \nu"
\bind "C-g o"  "math-insert \omega"
\bind "C-g p"  "math-insert \pi"
\bind "C-g q"  "math-insert \vartheta"
\bind "C-g r"  "math-insert \rho"
\bind "C-g s"  "math-insert \sigma"
\bind "C-g t"  "math-insert \tau"
\bind "C-g u"  "math-insert \upsilon"
\bind "C-g v"  "math-insert \theta"
\bind "C-g w"  "math-insert \omega"
\bind "C-g x"  "math-insert \xi"
\bind "C-g y"  "math-insert \psi"
\bind "C-g z"  "math-insert \zeta"

\bind "C-g S-D""math-insert \Delta"
\bind "C-g S-E""math-insert \epsilon"
\bind "C-g S-F""math-insert \Phi"
\bind "C-g S-G""math-insert \Gamma"
\bind "C-g S-I""math-insert \iota"
\bind "C-g S-J""math-insert \epsilon"
\bind "C-g S-L""math-insert \Lambda"
\bind "C-g S-O""math-insert \Omega"
\bind "C-g S-P""math-insert \Pi"
\bind "C-g S-Q""math-insert \vartheta"
\bind "C-g S-R""math-insert \varrho"
\bind "C-g S-S""math-insert \Sigma"
\bind "C-g S-T""math-insert \varsigma"
\bind "C-g S-U""math-insert \Upsilon"
\bind "C-g S-V""math-insert \Theta"
\bind "C-g S-W""math-insert \Omega"
\bind "C-g S-X""math-insert \Xi"
\bind "C-g S-Y""math-insert \Psi"


Re: Key bindings

2008-11-22 Thread Peleg Michaeli
On Fri, 2008-11-21 at 13:27 +, Guenter Milde wrote:
> You could try to grep for C-g in all bind files that are read directly
> or
> indirectly. 

I have found these:
./bind/xemacs.bind:\bind "C-g"  "cancel"
./bind/xemacs.bind:\bind "C-x C-g""buffer-view ps"
./bind/mac.bind:\bind "C-g" "error-next"
./bind/emacs.bind:\bind "C-g" "cancel"
./bind/emacs.bind:\bind "C-x C-g""buffer-view ps"
./bind/cua.bind:\bind "C-g" "error-next"

Do you think it is safe to delete these?

And: how can I know if these files are really readed?

(the above is the result of grep in /usr/share/lyx1.5.1/)


Thanks,
Peleg.




Re: Key bindings

2008-11-22 Thread Peleg Michaeli
Hi Dov,
Thanks for your reply.

My answers:

On Sat, 2008-11-22 at 18:55 +0200, Dov Feldstern wrote:
> I'm not totally clear as to how your keyboard is set up, and I think that 
> that 
> may be the problem (for what it's worth, I'm able to create the "C-g y" 
> binding 
> without any trouble, with Hebrew; this is in 2.0svn, but I don't think this 
> should have changed appreciably even from 1.5).

This problem existed much before I have reconfigured my keyboard.
> 
> Do you use a keyboard map (Tools->Preferences->Keyboard-> "use keyboard 
> math"; 
> the exact menus may be a little different in 1.5)?

In Tools->Preferences->Keyboard I have "use keyboard map" (not "use
keyboard math") checked, and the First is null, and the Second is
hebrew.
> 
> Does your keyboard output english or hebrew (i.e., do you switch languages at 
> the keyboard level, or *only* using F12 in LyX)?

I am staying always in English, and using F12 exclusively to switch
between the languages (usually I don't even need that − I type only in
Hebrew, and in math mode it types the variables in English
automatically)
> 
> When you say "so I have configured my keyboard to have all of the greek 
> letters, 
> including √, ∞, ∝, ≤≥ ⊆⊇ ⊂⊃ ←→ ⇐⇒ − ≠ ≡ ∀ ∃ and many more" --- did you do 
> anything to actually configure the keyboard, or just paste stickers on or 
> something? I mean, when you press a key, will LyX be getting a "g" or some 
> unicode character?

Very simple: I have reconfigured GNOME, so now when I press "Alt Gr +
s", for example, I get σ. If I press the same key combination with
Caps-Lock on, or with Shift key pressed as well, I get Σ. Pressing the
key that is just near the "z" key on its left produces ∀, and doing that
with Shift produces ∃, and many more options.

I haven't put any stickers. I know the keys (at least most of them) by
heart − it's very simple. I do it like that since even though I know TeX
quite good, it is much shorter to write emails to friends like this:
"Let x∈P and y∈Q. Since P and Q are normal, xyx^-1y^-1∈P∩Q={e}... ⇒
something..." or compare "...hence P\subseteq Q" to "...hence P⊆Q".

So, in LyX, when I press "Alt Gr + a" I get α, but I don't want to get α
− I want to get "\alpha", and I believed that LyX might have a solution
to this need (and, apparently, it has − but only in 1.6). Vim, for
example, knows really well how to deal with that.

It is important to say also that the configuration is very basic, and it
works in ANY software on my computer, including LyX. It's not a "hack"
in the risky aspect of it.
> 
> Depending on your answers to these questions, I *may* be able to help a 
> little...

Actually, I have mentioned here two different problems. With the "C-g y"
problem, I still have to check the solution that Guenter Milde offered
me (something about collisions). About the αβγ problem (unicode
characters' bindings), I thought of moving to 1.6 (but still
hesitating), unless you have a better solution!

Again,
Thank you very much for your help.

Peleg.




Re: Key bindings

2008-11-22 Thread Peleg Michaeli
On Fri, 2008-11-21 at 23:18 +, Guenter Milde wrote:
> So you really have a Psi-key?

Well, yes. I type a lot of math, so I have configured my keyboard to
have all of the greek letters, including √, ∞, ∝, ≤≥ ⊆⊇ ⊂⊃ ←→ ⇐⇒ − ≠ ≡ ∀
∃ and many more. I thought that it might really shorten my LyX
experience (though, I still mostly use vim for LaTeX, but LyX is much
better with Hebrew), but...
> 
> In 1.6, you will get a  text-psi in text and (with the above fix) a
> kursive math \psi in the LaTeX output. 

...but I guess I'll need 1.6 for that. Well, I'm quite scared of this,
since I only have ubuntu 7.04 and I don't know how it'll react, and
since it took me a while to configure Hebrew properly in that LyX (I've
been through hell, actually... but maybe this hell is related to
configuring the Hebrew fonts in pdflatex, actually, and not in LyX? I'm
not so sure...)

I'll have to think about it a bit (add information if you like to!)

Thanks a lot,
Peleg.




Re: Key bindings

2008-11-21 Thread Peleg Michaeli
Oh, sorry!

Only now I understood what you've said.

I did this:
a. copied the file unicodesymbols
from /usr/share/lyx1.5.1/unicodesymbols
to /home/peleg/.lyx1.5.1/unicodesymbols
b. opened the copy with vim. there was no "0x03c8" string there at all,
so instead of modifying the file, I have added this line: 
0x03c8 "\\textgreek{y}"   "textgreek" "" "mathalpha" "\\psi" #
GREEK SMALL LETTER PSI
c. I have restarted LyX. Nothing has changed: I am clicking ψ on my
keyboard and getting the usual non-mathematical ψ.
d. I have tried to add the line to the original file in /usr/share/...
instead of in my home folder. restarted LyX. Still the same.
e. I have read this correspondance:
http://www.mail-archive.com/[EMAIL PROTECTED]/msg129516.html
(well, not all of it...) - still couldn't understand.


Any ideas?

Thanks ahead,
Peleg.

On Fri, 2008-11-21 at 12:45 +, Peleg Michaeli wrote:
> Sorry... I am forwarding it to the list.
> 
> On Fri, 2008-11-21 at 12:41 +, Peleg Michaeli wrote:
> > On Fri, 2008-11-21 at 08:21 +, Guenter Milde wrote:
> > > However, you could adapt the unicodesymbols file (place a copy in
> > > ~/.lyx/unicodesymbols) and change
> > > 
> > > - 0x03c8 "\\textgreek{y}"   "textgreek" "" # GREEK SMALL
> > > LETTER PSI
> > > + 0x03c8 "\\textgreek{y}"   "textgreek" "" "mathalpha" "\\psi"
> > > # GREEK SMALL LETTER PSI
> > > 
> > > and you should be able to use an unicode ψ in math (untested). 
> > 
> > Thanks for your reply!
> > 
> > However, I have tried to put, as you recommended, this text:
> > - 0x03c8 "\\textgreek{y}"   "textgreek" "" # GREEK SMALL LETTER
> > PSI
> > + 0x03c8 "\\textgreek{y}"   "textgreek" "" "mathalpha" "\\psi" #
> > GREEK SMALL LETTER PSI
> > 
> > In the file ~/.lyx1.5.1/unicodesymbols (this is my relevant folder), and
> > I have restarted LyX - but nothing has changed. When I type ψ, either in
> > math mode or not, I get ψ and not \\psi.
> > 
> > What else can I try?




Re: Key bindings

2008-11-21 Thread Peleg Michaeli
Sorry... I am forwarding it to the list.

On Fri, 2008-11-21 at 12:41 +, Peleg Michaeli wrote:
> On Fri, 2008-11-21 at 08:21 +, Guenter Milde wrote:
> > However, you could adapt the unicodesymbols file (place a copy in
> > ~/.lyx/unicodesymbols) and change
> > 
> > - 0x03c8 "\\textgreek{y}"   "textgreek" "" # GREEK SMALL
> > LETTER PSI
> > + 0x03c8 "\\textgreek{y}"   "textgreek" "" "mathalpha" "\\psi"
> > # GREEK SMALL LETTER PSI
> > 
> > and you should be able to use an unicode ψ in math (untested). 
> 
> Thanks for your reply!
> 
> However, I have tried to put, as you recommended, this text:
> - 0x03c8 "\\textgreek{y}"   "textgreek" "" # GREEK SMALL LETTER
> PSI
> + 0x03c8 "\\textgreek{y}"   "textgreek" "" "mathalpha" "\\psi" #
> GREEK SMALL LETTER PSI
> 
> In the file ~/.lyx1.5.1/unicodesymbols (this is my relevant folder), and
> I have restarted LyX - but nothing has changed. When I type ψ, either in
> math mode or not, I get ψ and not \\psi.
> 
> What else can I try?
> 
> 
> Thanks,
> Peleg.
> 



Re: Key bindings

2008-11-21 Thread Peleg Michaeli
On Fri, 2008-11-21 at 08:21 +, Guenter Milde wrote:
> > For example:
> 
> > \bind "M-m 7" "math-insert \psi"
> 
> > is working great.
> 
> > \bind "C-g y"  "math-insert \psi"
> 
> > is not working at all.
> 
> Could be a keybindings clash.
> 

Is there a way to check this?
When I just type C-g in LyX I get "Command disabled" on the status bar.

I have to add that I've put all of these keybindings in a file named
~/.lyx1.5.1/bind/hebrew.bind; this file is indeed readed by LyX, since -
as I said - all of the Alt-something bindings that I add work great.


Thanks,
Peleg.




Key bindings

2008-11-20 Thread Peleg Michaeli
Hello!

It looks like - and it's like that for at least a year now - that I
cannot create key-bindings using C (the ctrl button), but only using M
(the alt button). For example:

\bind "M-m 7"   "math-insert \psi"

is working great.

\bind "C-g y"  "math-insert \psi"

is not working at all.

And I even tried this cute one:

\bind "ψ"   "math-insert \psi"

Which is also not working.

I am using Ubuntu 7.04 (don't ask me why) with Gnome and LyX 1.5.1.
I am also writing Hebrew documents, which means I have some hebrew key
bindings (F12 switches between languages, for example). Maybe it is
relevant.

Any ideas?

Thanks ahead,
Peleg.




Re: Embedding asymptote in LyX

2008-05-14 Thread Peleg Michaeli
Ok, I have succeded to export to TeX, and I am now trying asymptote as
the instructions advised.

It is NOT a LyX question, I guess, but still it might be useful to ask
it here, since I believe that there are LyX users who use Asymptote...
and because it might be still LyX related, because of the following
fact:
doing what the instructions advised, on a test.tex file which contains
only what's written in this document, works well. Here is the code:

\documentclass[10pt]{article}
\usepackage[pdftex]{graphicx}
\usepackage{asymptote}
\begin{document}
\begin{figure}
\centering
\begin{asy}
size (3cm);
draw (unitcircle);
\end{asy}
\caption{Embedded Asymptote figures are easy!}
\label{fig:embedded}
\end{figure}
\end{document}

Again - this code works WELL.

So now I am trying to do the same with an exported-to-tex LyX document.
For that purpose, I have created a very simple LyX document, and
exported it to TeX; it worked as well.

I have tried to make it a bit more complicated - I tried to do the SAME
simple document, but in Hebrew (as I usually do). I have left the code
inside the asymptote example in English.

And that's it. Now it is not working any more...

A simple analyzation of the situation:
a. when the document was in English, the first "pdflatex asytest2" had
created a file named "asytest2.asy" with this line in it:
defaultfilename='asytest2_1';
this is probably good, because the command "asy asytest2" generates a
file "asytest2_1.pdf" with the unit circle, and the second "pdflatex
asytest2" generates "asytest2.pdf" with the unit circle embedded.
but:
b. when the document is still mainly in English, but I have a *single
word* in Hebrew (actually, in a Hebrew "direction", but it is still with
English characters; it looks like that: [in the tex file] sometext
\inputencoding{cp1255}\R{some more text}) then the first "pdflatex
asytest2" generates the file "asytest2.asy" as before, but in it, the
relevant line is now:
defaultfilename='asytest2_\protect \beginL 1\endL ';
and that is probably not good, since the command "asy asytest2"
generates a file named "asytest2_\protect eginL 1\endL .pdf" (which
can't be good) and of course, the second "pdflatex asytest2" does *not*
embed the nice unitcircle from that pdf.

manually removing the line "\inputencoding{cp1255}\R{text}" does not
make any difference, so I assumed it is something with the main
configuration of the tex file. So, I have compared to files, one with
thi encoding difference, and one without, that are otherwise the same,
and these are the results:
The ONLY difference (besides the line with
\inputencoding{cp1255}\R{text} - which its removal changes nothing), is
in the heading -
\documentclass[10pt,english]{article} becomes
\documentclass[10pt,hebrew,english]{article}
and \usepackage[latin9]{inputenc} becomes
\usepackage[cp1255,latin9]{inputenc}

I have tried to remove only one of them, so see what happens... I have
tried only to remove hebrew from the first line, but then the second
line caused an error; so I have kept the "hebrew" in the first line, and
removed "cp1255" from the second line. well, that didn't change anything
either.
Removing both changes, that is, removing both "hebrew" and "cp1255" from
the heading, return the situation - of course - to the one we had in the
beginning - a pure English document; then, of course, it worked well
again.

That's my little research...
Any ideas?

Thanks ahead,
Peleg.

On Wed, 2008-05-14 at 08:40 +0100, Peleg Michaeli wrote:
> Oh, I see...
> 
> They also wrote this line under that figure: "For ASYMPTOTE versions ≥
> 1.14, you can simply call PDFLATEX directly" - but I have misunderstood
> it, probably; I thought it meant that in this specific case (version ≥
> 1.14), I *don't* need to do that.
> 
> Well, then...
> 
> I am looking for a workaround now.
> 
> Is it possible to export a LyX document to a TeX document without losing
> data? Then, I'll be able to do what they suggest in the documentation.
> 
> Thanks,
> Peleg.
> 
> On Tue, 2008-05-13 at 19:38 +0200, Manveru wrote:
> > Hough!
> > 
> > I am not a specialist of ASYMPTOTE, but I've just looked into the
> > documentation. They directly tell about makefile for latex with asymptote:
> > 
> > document.pdf: document.tex
> > pdflatex -shell-escape document
> > asy document
> > pdflatex -shell-escape document
> > 
> > It means that ASYMPTOTE need an additional step during document generation
> > which launch "asy" command between two "pdflatex" invocations. This is what
> > LyX is *not able* to do. Generation process is compiled in, automatic... and
> &

Re: Embedding asymptote in LyX

2008-05-14 Thread Peleg Michaeli
Oh, I see...

They also wrote this line under that figure: "For ASYMPTOTE versions ≥
1.14, you can simply call PDFLATEX directly" - but I have misunderstood
it, probably; I thought it meant that in this specific case (version ≥
1.14), I *don't* need to do that.

Well, then...

I am looking for a workaround now.

Is it possible to export a LyX document to a TeX document without losing
data? Then, I'll be able to do what they suggest in the documentation.

Thanks,
Peleg.

On Tue, 2008-05-13 at 19:38 +0200, Manveru wrote:
> Hough!
> 
> I am not a specialist of ASYMPTOTE, but I've just looked into the
> documentation. They directly tell about makefile for latex with asymptote:
> 
> document.pdf: document.tex
> pdflatex -shell-escape document
> asy document
> pdflatex -shell-escape document
> 
> It means that ASYMPTOTE need an additional step during document generation
> which launch "asy" command between two "pdflatex" invocations. This is what
> LyX is *not able* to do. Generation process is compiled in, automatic... and
> as some people suggests, not user configurable.
> 
> Maybe it is worth to put feature request in bugzilla, to get this to work
> when \usepackage{asymptote} is used in preamble definition.
> 
> Regards,
> M.
> 
> 2008/5/13 Peleg Michaeli <[EMAIL PROTECTED]>:
> 
> > Hello!
> >
> > I am trying to embed Asymptote in LyX documents.
> >
> > I am following this tutorial:
> > http://www.dse.nl/~dario/projects/asylatex/asylatex.pdf<http://www.dse.nl/%7Edario/projects/asylatex/asylatex.pdf>
> >
> > I am doing everything as suggested:
> > * I have included \usepackage{asymptote} and
> > \usepackage[pdftex]{graphicx} in the LaTeX preamble
> > * I have done Crtl-L in the middle of the document and added this LaTeX
> > code:
> >
> > \begin{figure}
> > \centering
> > \begin{asy}
> > size (3cm);
> > draw (unitcircle);
> > \end{asy}
> > \caption{Embedded Asymptote figures are easy!}
> > \label{fig:embedded}
> > \end{figure}
> >
> > When I generate the document (using pdflatex), I get nothing special: a
> > "figure" with "PDF" written there, but no image (no "unitcircle")...
> > when I do the same, but with DVI, I get "EPS" written instead of the
> > unitcircle. Either way, I don't see any picture...
> >
> > I have a new version of Asymptote: 1.18 - so it should work
> > automatically with pdflatex.
> >
> > Any ideas?
> > Maybe I should ask a different list?
> >
> > Thanks ahead,
> > Peleg.
> >
> >
> >
> 
> 



Embedding asymptote in LyX

2008-05-13 Thread Peleg Michaeli
Hello!

I am trying to embed Asymptote in LyX documents.

I am following this tutorial:
http://www.dse.nl/~dario/projects/asylatex/asylatex.pdf

I am doing everything as suggested:
* I have included \usepackage{asymptote} and
\usepackage[pdftex]{graphicx} in the LaTeX preamble
* I have done Crtl-L in the middle of the document and added this LaTeX
code:

\begin{figure}
\centering
\begin{asy}
size (3cm);
draw (unitcircle);
\end{asy}
\caption{Embedded Asymptote figures are easy!}
\label{fig:embedded}
\end{figure}

When I generate the document (using pdflatex), I get nothing special: a
"figure" with "PDF" written there, but no image (no "unitcircle")...
when I do the same, but with DVI, I get "EPS" written instead of the
unitcircle. Either way, I don't see any picture...

I have a new version of Asymptote: 1.18 - so it should work
automatically with pdflatex.

Any ideas?
Maybe I should ask a different list?

Thanks ahead,
Peleg.




Re: Fuzzy fonts (Hebrew)

2008-05-13 Thread Peleg Michaeli
I have opened an Ubuntu page on the wiki, and also added this:
http://wiki.lyx.org/LyX/HebrewOnLinux

I'll be happy to hear comments, if there are... :-)

Thanks,
Peleg.

On Sun, 2008-04-27 at 15:40 +0200, Jürgen Spitzmüller wrote:
> Peleg Michaeli wrote:
> > After a short discussion with Ivritex, I got this conclusion (and it
> > might help some others, so I write it here).
> 
> could you add this to the LyX wiki as well?
> 
> Jürgen



Re: Fuzzy fonts (Hebrew)

2008-04-27 Thread Peleg Michaeli
Ok,

After a short discussion with Ivritex, I got this conclusion (and it
might help some others, so I write it here).

Using culmus fonts IS possible in ubuntu 7.04. This is the way to do
that:

* first of all, the right thing to do is to install texlive and not
tetex; tetex is not maintained any more.
* trying to install ivritex package will fail, because ivritex depends
on tetex.
* instead, we should install texlive-font-utils
* Installing culmus fonts (and other Hebrew fonts): sudo aptitude
install culmus culmus-fancy xfonts-efont-unicode xfonts-efont-unicode-ib
xfonts-intl-european msttcorefonts
* Installing culmus-latex package; first of all, downloading it from
http://sourceforge.net/project/showfiles.php?group_id=33341 (as Dov
suggested)
* extracting in some folder
* make CULMUSDIR=/usr/share/fonts/X11/Type1/
TEXMFDIR=/usr/share/texmf-texlive/
* sudo make install CULMUSDIR=/usr/share/fonts/X11/Type1/
TEXMFDIR=/usr/share/texmf-texlive/

The last 2 commands are ubuntu 7.04/7.10-specific, but might work on
other distros; if not, try to remove the CULMUSDIR=... (until the end of
the line) and see if the make recognizes the right directories instead.

Now my PDFs look much better!

By the way, Dov - now, even using evince, the PDFs look great; maybe we
can avoid adobe reader from now on? ;-)

Thanks you all, and have a nice week,
Peleg.

On Sun, 2008-02-24 at 03:20 +0200, Dov Feldstern wrote:
> Peleg Michaeli wrote:
> > Thank you all for your replies!
> > 
> > I will try ivritex's mailing list; it's quite weird, because I do have
> > culmus fonts installed - the problem is with ivritex, still?
> > 
> 
> Probably. My understanding is that most of the functionality of ivritex 
> has already been incorporated into babel (3.8, I believe). However, that 
> does *not* include usage of the culmus fonts --- so the fact that 
> they're installed in the system doesn't mean that latex knows how to use 
> them yet. That is still under development under the auspices of ivritex, 
> and can be downloaded here 
> https://sourceforge.net/project/showfiles.php?group_id=33341. But I 
> think that it's not complete yet, though I'm not sure.
> 
> So here's what I would do:
> 
> 1) try installing culmus-latex from the above link, and see how it is. 
> You might want to try the subversion repository, which is slightly more 
> up-to-date.
> 
> 2) If it's not good enough, get in touch with the ivritex mailing list 
> and see if anyone knows what the current status is: is this still being 
> developed? Will this work ever be incorporated into babel, too?
> 
> 3) It would be interesting to understand how the culmus fonts *do* 
> already work in latex on Windows --- maybe that can point in a direction 
> for getting it working on Linux, too... Agai, the ivritex list is where 
> I would pursue this...
> 
> > Anyway, it is comfoting that you can see both in a good quality.
> > 
> > Yes, I am not using adobe reader (since it is not free software); I am
> > using just simple PDF viewer (actually, Evince 0.8.1) - for the
> > experiment, I have tried a different PDF viewer - KGhostView 0.2.0 - and
> > it looks much better - but this software is awfully slow and have
> > problems with zoomings.
> > 
> 
> Hmmm, I guess you're more idealistic than me... I have found that the 
> quality in Acrobat Reader (which is at least free as in beer) is often 
> significantly better than the open source alternatives that I have tried 
> --- though I haven't tried these in a couple of years, so things may be 
> better today. I'm sorry to hear the evince isn't better, I was hoping 
> that perhaps it would be. You might want to try okular --- it's the new 
> KDE viewer, still under development, I believe. Haven't tried it myself, 
> though...
> 
> Dov



Re: Oh god!

2008-04-26 Thread Peleg Michaeli
Thanks!

Peleg.

On Fri, 2008-04-25 at 21:51 -0400, Steve Litt wrote:
> On Friday 25 April 2008 14:07, Peleg Michaeli wrote:
> > On Fri, 2008-04-25 at 13:41 -0400, Steve Litt wrote:
> > > On Friday 25 April 2008 11:24, Abdelrazak Younes wrote:
> > > > Steve Litt wrote:
> > > > > On Friday 25 April 2008 05:07, Glen Whitehead wrote:
> > > > >> Thank you everyone for your replies :-)
> > > > >>
> > > > >> I am so relieved (after throwing up).
> > > > >>
> > > > >> The error was being returned by bibtex and was nothing serious 0_o
> > > > >
> > > > > Good!
> > > > >
> > > > > Prevent future occurrence. Create a shellscript or batch file to back
> > > > > up the file (to a different version) and run it every 10 minutes so
> > > > > that if you get knocked back, you only get knocked back 10 minutes.
> > > >
> > > > Maybe you are not aware that LyX already autosaves your files? Look at
> > > > the Preferences settings dialog; the default is to make a backup every
> > > > 5 minutes.
> > >
> > > My backups work for every app, and work in a way I know.
> 
> http://www.troubleshooters.com/lpm/200609/200609.htm
> 
> SteveT



Re: Oh god!

2008-04-25 Thread Peleg Michaeli
On Fri, 2008-04-25 at 13:41 -0400, Steve Litt wrote:
> On Friday 25 April 2008 11:24, Abdelrazak Younes wrote:
> > Steve Litt wrote:
> > > On Friday 25 April 2008 05:07, Glen Whitehead wrote:
> > >> Thank you everyone for your replies :-)
> > >>
> > >> I am so relieved (after throwing up).
> > >>
> > >> The error was being returned by bibtex and was nothing serious 0_o
> > >
> > > Good!
> > >
> > > Prevent future occurrence. Create a shellscript or batch file to back up
> > > the file (to a different version) and run it every 10 minutes so that if
> > > you get knocked back, you only get knocked back 10 minutes.
> >
> > Maybe you are not aware that LyX already autosaves your files? Look at
> > the Preferences settings dialog; the default is to make a backup every 5
> > minutes.
> 
> My backups work for every app, and work in a way I know.

Maybe it is off topic, but would you mind expand a bit about this backup
script you have? It might give me some good ideas of how to create my
own, and I have just started to program it...
> 
> >
> > > I know you're done with this project, but do this for all your projects.
> > >
> > > By the way, I have a system to use rsync to make incremental backups,
> > > taking maybe a minute. I can run it several times a day so nothing can
> > > mess me up. My backup system saves each incremental so I can restore
> > > files to any of the backup times.
> >
> > Why don't use a source control management (SCM) system instead?
> 
> That's a good idea. I haven't yet because it's not a high priority, given 
> that 
> I have an excellent backup system.
> 
> Let me rephrase what I said -- find SOME way of backing up your file often 
> during the day, whether it's something built into the app, source control, a 
> incremental backup schedule, or just plain copies.
> 
> SteveT
> 
> Steve Litt
> Books written in LyX:
>   Troubleshooting Techniques of the Successful Technologist
>   Twenty Eight Tales of Troubleshooting
>   Troubleshooting: Just the Facts

And one more question: do you have one (or more) of these books
available on the net, or otherwise free? I have never seen a full-length
book that was written with LyX, and I would like to see one in order to
get a feeling about LyX's abilities.

Thanks ahead,
Peleg.



Re: Hotkeys

2008-02-29 Thread Peleg Michaeli
Thanks you all!

Peleg.

On Sat, 2008-03-01 at 10:12 +, Bo Peng wrote:
> On Sat, Mar 1, 2008 at 1:28 AM, Ignacio García
> <[EMAIL PROTECTED]> wrote:
> > Peleg wrote:
> >  > Is there a possibility to create in LyX hotkeys (keyboard shortcuts) for
> 
> Have a look at 
> http://wiki.lyx.org/uploads/LyX/keyboardShortcuts/bpeng/personal.bind
> in http://wiki.lyx.org/LyX/KeyboardShortcuts
> 
> Bo



Hotkeys

2008-02-28 Thread Peleg Michaeli
Hello.

Is there a possibility to create in LyX hotkeys (keyboard shortcuts) for
specific math characters, e.g.:
ctrl-(  =>  imitate the action of the () button on the math bar
ctrl-shift-p  =>  \pi
etc.

Thanks ahead,
Peleg.




Re: Fuzzy fonts (Hebrew)

2008-02-28 Thread Peleg Michaeli
Thank you!

I will check with Ivritex and let this list know about it; I will post
here any solution that works, if there will be such.

Peleg.

On Sun, 2008-02-24 at 03:20 +0200, Dov Feldstern wrote:
> Peleg Michaeli wrote:
> > Thank you all for your replies!
> > 
> > I will try ivritex's mailing list; it's quite weird, because I do have
> > culmus fonts installed - the problem is with ivritex, still?
> > 
> 
> Probably. My understanding is that most of the functionality of ivritex 
> has already been incorporated into babel (3.8, I believe). However, that 
> does *not* include usage of the culmus fonts --- so the fact that 
> they're installed in the system doesn't mean that latex knows how to use 
> them yet. That is still under development under the auspices of ivritex, 
> and can be downloaded here 
> https://sourceforge.net/project/showfiles.php?group_id=33341. But I 
> think that it's not complete yet, though I'm not sure.
> 
> So here's what I would do:
> 
> 1) try installing culmus-latex from the above link, and see how it is. 
> You might want to try the subversion repository, which is slightly more 
> up-to-date.
> 
> 2) If it's not good enough, get in touch with the ivritex mailing list 
> and see if anyone knows what the current status is: is this still being 
> developed? Will this work ever be incorporated into babel, too?
> 
> 3) It would be interesting to understand how the culmus fonts *do* 
> already work in latex on Windows --- maybe that can point in a direction 
> for getting it working on Linux, too... Agai, the ivritex list is where 
> I would pursue this...
> 
> > Anyway, it is comfoting that you can see both in a good quality.
> > 
> > Yes, I am not using adobe reader (since it is not free software); I am
> > using just simple PDF viewer (actually, Evince 0.8.1) - for the
> > experiment, I have tried a different PDF viewer - KGhostView 0.2.0 - and
> > it looks much better - but this software is awfully slow and have
> > problems with zoomings.
> > 
> 
> Hmmm, I guess you're more idealistic than me... I have found that the 
> quality in Acrobat Reader (which is at least free as in beer) is often 
> significantly better than the open source alternatives that I have tried 
> --- though I haven't tried these in a couple of years, so things may be 
> better today. I'm sorry to hear the evince isn't better, I was hoping 
> that perhaps it would be. You might want to try okular --- it's the new 
> KDE viewer, still under development, I believe. Haven't tried it myself, 
> though...
> 
> Dov



Re: Fuzzy fonts (Hebrew)

2008-02-22 Thread Peleg Michaeli
Thank you all for your replies!

I will try ivritex's mailing list; it's quite weird, because I do have
culmus fonts installed - the problem is with ivritex, still?

Anyway, it is comfoting that you can see both in a good quality.

Yes, I am not using adobe reader (since it is not free software); I am
using just simple PDF viewer (actually, Evince 0.8.1) - for the
experiment, I have tried a different PDF viewer - KGhostView 0.2.0 - and
it looks much better - but this software is awfully slow and have
problems with zoomings.

So, thanks again - now I figure out what the problem is - and these are
the still "open" questions:
a. I have culmus fonts installed - is it not sufficient for tex2pdf to
use them? What should I ask ivritex?
b. Can one of you recommend a good PDF viewer, which is a free software,
for linux?

Thanks again,
Peleg.

On Mon, 2008-02-18 at 21:31 +0200, Dov Feldstern wrote:
> Peleg Michaeli wrote:
> > Hey...
> > 
> > First of all - thanks for your reply.
> > 
> > Before I do all of your suggested tests (which I will do) I just have to
> > say: it seems like the pdf you've sent me has fuzzy Hebrew as well!
> 
> Perhaps the problem is with the pdf *viewer* that you're using? Some 
> files I use look horrible in gv, but they're fine using acroread...
> 
> > 
> > Well - as I understand, PDF should embed the fonts inside it, so it's
> > not impossible that we see the documents in two computers in two
> > different ways; so for the example, I will add here links to two
> > documents that I have generated using LyX, one while I had Windows, and
> > one in my ubuntu. The two documents are generated from the same source
> > file, so you'll probably see the huge differences.
> > 
> > The link to the "windows" generated PDF is here:
> > - http://www.freeall.org/peleg/math/TOP_MMN16-C-windows.pdf
> > And the link the the "ubuntu" generated PDF is here:
> > - http://www.freeall.org/peleg/math/TOP_MMN16-C-ubuntu.pdf
> > 
> > See the difference?
> 
> Hmmm, not really :( ... both files look OK to me. Of course they use 
> different fonts --- on Windows you're probably using the culmus fonts, 
> and on ubuntu the fonts that come with ivritex (which are not yet culmus 
> fonts, and not as nice) --- but in terms of "quality" I don't see a 
> difference... Regarding the use of culmus fonts on linux, there has been 
> some work in that direction going on in ivritex, I strongly urge you to 
> ping the mailing list there to see if there's any progress with this 
> (and I don't really know the details, they may be able to confirm 
> whether or not what I'm saying is correct).
> 
> > 
> > Here is the source for BOTH of the PDFs:
> > - http://www.freeall.org/peleg/math/TOP_MMN16.lyx
> > 
> > Thanks again,
> > hopefully I will do the rest of the tests some other time.
> > 
> > Peleg.



Re: Fuzzy fonts (Hebrew)

2008-02-17 Thread Peleg Michaeli
Hey...

First of all - thanks for your reply.

Before I do all of your suggested tests (which I will do) I just have to
say: it seems like the pdf you've sent me has fuzzy Hebrew as well!

Well - as I understand, PDF should embed the fonts inside it, so it's
not impossible that we see the documents in two computers in two
different ways; so for the example, I will add here links to two
documents that I have generated using LyX, one while I had Windows, and
one in my ubuntu. The two documents are generated from the same source
file, so you'll probably see the huge differences.

The link to the "windows" generated PDF is here:
- http://www.freeall.org/peleg/math/TOP_MMN16-C-windows.pdf
And the link the the "ubuntu" generated PDF is here:
- http://www.freeall.org/peleg/math/TOP_MMN16-C-ubuntu.pdf

See the difference?

Here is the source for BOTH of the PDFs:
- http://www.freeall.org/peleg/math/TOP_MMN16.lyx

Thanks again,
hopefully I will do the rest of the tests some other time.

Peleg.

On Sun, 2008-02-17 at 22:16 +0200, Dov Feldstern wrote:
> Peleg Michaeli wrote:
> > Hello.
> > 
> > Since I have moved to Linux (ubuntu 7.04) and installed LyX (1.5.1)
> > (before that I had Windows XP and LyX 1.5.something), my PDF documents
> > are generated with low quality, both in Hebrew and English; though,
> > DVI/PS documents are fine.
> > 
> > I believe that it is somehow related to fonts; and I guess that this is
> > a problem with pdflatex and not directly with LyX; but when I tried to
> > generate PDFs from pure .tex files (with Hebrew) using pdflatex, it
> > seems like it wasn't fuzzy, so maybe LyX DOES have something to do with
> > that.
> > 
> > For sure, I will add here two files that I have tested. The first test
> > is in Hebrew and is very simple; I have tried it with pdftex command,
> > and it worked fine. here is the code:
> > 
> 
> Hi!
> 
> I'm afraid I can't help too much, but it does sound like the problem is 
> with fonts or with the tex setup, and not with LyX per se. I tried 
> generating from the LyX file you attached and it looks fine to me  (see 
> attached; BTW, your binary attachments don't seem to have made it 
> through...). Here are a few things you can try:
> 
> *) try going the ps2pdf or dvipdfm path, instead of pdflatex. Does that 
> make any difference?
> 
> *) try exporting from LyX to .tex (both plain tex and pdflatex), and 
> then generating the pdf from those files as if they were pure .tex. Does 
> that work?
> 
> *) If none of these things help, I would also try asking on the ivritex 
> mailing list --- chances are someone there will be able to provide more 
> help. Also, try providing more information abut your setup: what tex 
> distribution are you using (TeXLive, tetex, ...)?
> 
> Once you provide the answers to the above issues, perhaps we'll  be able 
> to figure out what's going wrong...
> 
> Good luck!
> Dov



Fuzzy fonts (Hebrew)

2008-02-16 Thread Peleg Michaeli
Hello.

Since I have moved to Linux (ubuntu 7.04) and installed LyX (1.5.1)
(before that I had Windows XP and LyX 1.5.something), my PDF documents
are generated with low quality, both in Hebrew and English; though,
DVI/PS documents are fine.

I believe that it is somehow related to fonts; and I guess that this is
a problem with pdflatex and not directly with LyX; but when I tried to
generate PDFs from pure .tex files (with Hebrew) using pdflatex, it
seems like it wasn't fuzzy, so maybe LyX DOES have something to do with
that.

For sure, I will add here two files that I have tested. The first test
is in Hebrew and is very simple; I have tried it with pdftex command,
and it worked fine. here is the code:



\def\t{\null\hfill íåìù\break}
\def\tt{\null\hfill --- íÉåìÈù\break}

\font\a htimes at 30pt \a\t
\font\a htimes at 30pt \a\tt
\end



(forget about the encoding there...)

When I have generated the PDF using pdftex for the first time, I got the
input as you can see in the attached file (test.pdf) - no fuzziness...
though, now when I try again, I just get errors, like "! Font \a=htimes
at 30.0pt not loadable: Metric (TFM) file not found.".

The second test is the following code:



#LyX 1.5.1 created this file. For more info see http://www.lyx.org/
\lyxformat 276
\begin_document
\begin_header
\textclass article
\language hebrew
\inputencoding auto
\font_roman default
\font_sans default
\font_typewriter default
\font_default_family default
\font_sc false
\font_osf false
\font_sf_scale 100
\font_tt_scale 100
\graphics default
\paperfontsize default
\spacing single
\papersize default
\use_geometry false
\use_amsmath 1
\use_esint 1
\cite_engine basic
\use_bibtopic false
\paperorientation portrait
\secnumdepth 3
\tocdepth 3
\paragraph_separation indent
\defskip medskip
\quotes_language english
\papercolumns 1
\papersides 1
\paperpagestyle default
\tracking_changes false
\output_changes false
\author "" 
\author "" 
\end_header

\begin_body

\begin_layout Standard

\lang english
Peleg Michaeli is writing a test PDF.
\end_layout

\begin_layout Standard

\lang english
What is this PDF good for? many things.
\end_layout

\begin_layout Standard

\lang english
Mostly - a test.
\end_layout

\begin_layout Standard

\lang english
Peleg Michaeli is writing a test PDF.
\end_layout

\begin_layout Standard

\lang english
What is this PDF good for? many things.
\end_layout

\begin_layout Standard

\lang english
Mostly - a test.
\end_layout

\begin_layout Standard

\lang english
Peleg Michaeli is writing a test PDF.
\end_layout

\begin_layout Standard

\lang english
What is this PDF good for? many things.
\end_layout

\begin_layout Standard

\lang english
Mostly - a test.
\end_layout

\begin_layout Standard

\lang english
Peleg Michaeli is writing a test PDF.
\end_layout

\begin_layout Standard

\lang english
What is this PDF good for? many things.
\end_layout

\begin_layout Standard

\lang english
Mostly - a test.
\end_layout

\begin_layout Standard
עברית
\end_layout

\begin_layout Standard
עברית
\end_layout

\begin_layout Standard
שלום שלום שלום שלום שלום!
\end_layout

\begin_layout Standard
פלג מיכאלי כותב דף שמטרתו ניסיון ב-
\lang english
PDF
\lang hebrew
, ותו לא.
\end_layout

\begin_layout Standard
פלג מיכאלי כותב דף שמטרתו ניסיון ב-
\lang english
PDF
\lang hebrew
, ותו לא.
\end_layout

\begin_layout Standard
פלג מיכאלי כותב דף שמטרתו ניסיון ב-
\lang english
PDF
\lang hebrew
, ותו לא.
\end_layout

\begin_layout Standard
פלג מיכאלי כותב דף שמטרתו ניסיון ב-
\lang english
PDF
\lang hebrew
, ותו לא.
\end_layout

\begin_layout Standard
והנה נוסחה:
\begin_inset Formula \[
\lim_{n\to\infty}\sum_{k=1}^{n}a_{n}x^{n}=3\]

\end_inset


\end_layout

\begin_layout Standard
וזהו.
\end_layout

\end_body
\end_document



And this code, using LyX and pdflatex (the default, I haven't changed
anything there) generates the second attached file (newfile3.pdf).

As you can see, the English is OK, but the Hebrew is fuzzy.

So - I thought it might be related to TTF - hence I have followed this
tutorial:
http://www.guyrutenberg.com/2006/12/08/using-hebrew-truetype-fonts-with-pdftex/ 
which looks promising.
Everything went well following the instructions, but in the buttom line
- nothing new.

I would appreciate any help - I am an open-university student, and LyX
is my only notepad - this is how I send all of my assignments (math).

Thanks ahead,
Peleg.

(I hope the attachments will be accepted, but if not, I will send them
to anyone who care to help.)