jeudi 31 janvier 2013

[FORWARD] Use bold in att

> Hello,
>
> I fail to bold my word using alltt module
>
> \documentclass{article}
> \usepackage{alltt} % for normal formating inside verbat
> \begin{document}
>
> \begin{alltt}
> hello \textbf{hello}
> \end{alltt}
>
> \end{document}
>
> Any suggestions?

txfonts has bold ttfonts. If you just want set the tt font to be txtt,
just invoke :
\renewcommand{\ttdefault}{txtt}

Example :

\documentclass{article}
\usepackage{alltt}
\renewcommand{\ttdefault}{txtt}

\begin{document}

\begin{alltt}
hello \textbf{hello}
\end{alltt}

\end{document}

--
B.R

Original: http://newsgroups.derkeiler.com/Archive/Comp/comp.text.tex/2006-01/msg00179.html

jeudi 24 janvier 2013

[F]LaTeX: Adding Footnotes to Paragraph Titles

LaTeX: Adding Footnotes to Paragraph Titles

When you put foonotes in paragraph titles or section titles, you will get complaints from LaTeX. The following fixes this and puts no footnotes in the table of contents.
\paragraph[foo-title]{foo-title \protect\footnote{bar-footnote}}
 
original:
http://lesoluzioni.blogspot.fr/2013/01/latex-adding-footnotes-to-paragraph.html

dimanche 20 janvier 2013

[Forward] How to use mathematics in a verbatim-like environment

How to use mathematics in a verbatim-like environment

  1. Add the alltt package to your document.
  2. Enter an encapsulated TeX field.
  3. Type \begin{alltt} to begin the alltt environment.
  4. Begin entering the content of the verbatim environment.
  5. For each mathematical element,
    1. Type \( to begin mathematics.
    2. Type the commands for the mathematical statement or symbol you want.
    3. Type \) to end mathematics.
  6. Complete the content.
  7. Type \end{alltt} to close the environment.
  8. Choose OK.
The package has no options. Alltt is provided automatically with LaTeX and is installed in the TCITeX/TeX/LaTeX/base directory of your program directory. 

The original Website can be found here: http://www.mackichan.com/index.html?techtalk/458.htm~mainFrame

lundi 3 décembre 2012

latex floatflt.sty not found in mac



mkdir -p /usr/share/texmf-texlive/tex/latex/floatflt
cd /usr/share/texmf-texlive/tex/latex/floatflt
rm -f floatflt.* float*.tex
wget http://mirror.ctan.org/macros/latex/contrib/floatflt/floatflt.ins
wget http://mirror.ctan.org/macros/latex/contrib/floatflt/floatflt.dtx
latex floatflt.ins
texhash /usr/share/texmf-texlive
PS: using mac, the folder is ~/Library/texmf/tex/latex, then go to that directory, and run the command wget ...
Ref: Incidentally, if you want to add files to TEX Live for one particular user, install them in a similar tree ~/Library/texmf where ~/Library
 is the Library folder in that user’s home directory. The folder texmf 
and other folders for the tree will have to be created. For instance, 
TEX will find any file in ~/Library/texmf/tex or a subfolder of this location, LATEX will find any file in ~/Library/texmf/tex/latex or a subfolder of this location, and BibTEX will find any .bib file in ~/Library/texmf/bibtex/bib or a subfolder of this location, and any .bst file in ~/Library/texmf/bibtex/bst or a subfolder of this location. It is not necessary to use texhash when adding files to this local tree.    

jeudi 1 novembre 2012

MAC 下屏蔽某些网站

为了使我在工作的时候不去某些网站浪费时间,在苹果电脑上可以使用以下方法屏蔽某些域名,使之转向与自己的电脑。

1: 使用命令:
 sudo vim /private/etc/hosts


2: 显示如下:
  1 ##
  2 # Host Database
  3 #
  4 # localhost is used to configure the loopback interface
  5 # when the system is booting.  Do not change this entry.
  6 ##
  7 127.0.0.1   localhost
  8 255.255.255.255 broadcasthost
  9 ::1             localhost
 10 fe80::1%lo0 localhost


3: 在文件后添加若干行(11-13行),每行对应一个域名,文件如下:
  1 ##
  2 # Host Database
  3 #
  4 # localhost is used to configure the loopback interface
  5 # when the system is booting.  Do not change this entry.
  6 ##
  7 127.0.0.1   localhost
  8 255.255.255.255 broadcasthost
  9 ::1             localhost
 10 fe80::1%lo0 localhost
 11 127.0.0.1   www.weibo.com/
 12 127.0.0.1   www.renren.com/
 13 127.0.0.1   sports.sina.com.cn/


4: 退出编辑器:wq

如果是linux 机器,修改/etc/hosts 文件应该可以达到想通的效果。

jeudi 18 octobre 2012

有关rmi 的一些问题

- the java.rmi.server.codebase Property

    the classes needed to execute remote method calls can be downloaded from "file:///" URLs, but like applets, a "file:///" URL generally requires that the client and the server reside on the SAME physical host

information from: http://docs.oracle.com/javase/1.4.2/docs/guide/rmi/codebase.html

-

samedi 13 octobre 2012

Latex TexShop 输入中文

%!TEX encoding = UTF-8 Unicode
\documentclass[12pt]{article}
\usepackage{CJKutf8}
\begin{document}
\begin{CJK}{UTF8}{bsmi}
This is a test. 中文字測試。
\end{CJK}
\end{document}

原址:http://philip.pixnet.net/blog/post/18367221-%5Bmac%5D%E5%9C%A8mac%E4%B8%8A%E5%AE%89%E8%A3%9Dlatex%E6%95%99%E5%AD%B8