Dear all,
I am a newbie in LyX. I have some questions of using
LyX. Could you please give me some help?
1. When I use Lyx-code, the line goes over the page
width. Is there any possible way to configure lyx-code
that auto address the paragraph into the document page
width with full justify, since formatting line by line
of these codes is very annoying and they are not fully
justtified due to the difference lengths of the words.
Some people suggested to use listings.sty. However I
do not know how to use it in LyX.
2. I am currently writing a document that needs to
include large amount of some source codes and these
source codes are changed very often. Is there any
possible way to import the source codes DYNAMICALLY in
a similar way to the figures.
what I mean is that I create a directory called "src"
then put all source code files there. In Lyx, I only
need to refer to the file name of the source code,
then LyX import it for me. When the source code is
changed, I only need to replace the corresponding file
under "src" rather than searching the *.lyx file for
modifications.
I know "insert ASCII file as line" is able to import a
file but it is not dynamically. "Include file with
verbatim" seems able to import file dynamically, but
it does not format the codes so that the over page
width problem still exists for a long line of code.
Moreover, using "algorithm float" seems has a better
font, but it has a problem that when my code is longer
than 1page, it does not break to multiple pages.
3. If there is a way for the above question. How to
format the imported source codes as it is well known
that some editors use TAB for indent but some use
space. Will LyX auto format this for me? I mean for
example using different font for source codes.
4. (Optional) Is there any way to import partial of
the codes from the source file? for instance, from
line xx to line yy? If yes, these will be very nice.
5. From the standard importing options, I can only
import figure, table and algorithm. Obviously, source
codes do not fall into any of these categorise. Is
there any way to create a new type of citations for
quoting the source codes?
Moreover, how to formate the is new type? I mean the
format of Algorithm is good, it has two lines above
and below the citation and has a line at the end of
the code.
I think I asked too many questions and I am very sorry
for the trouble. You help is very appreciated.
Best Regards,
Peter Chan
__
Do You Yahoo!?
Tired of spam? Yahoo! Mail has the best spam protection around
http://mail.yahoo.com