From 5d98a27d9c3cb2597acbe8ff0d16d72462e02905 Mon Sep 17 00:00:00 2001 From: "yusuke.shinyama.dummy" Date: Sat, 25 Dec 2010 08:41:11 +0000 Subject: [PATCH] test cases updated git-svn-id: https://pdfminerr.googlecode.com/svn/trunk/pdfminer@282 1aa58f4a-7d42-0410-adbc-911cccaed67c --- samples/Makefile | 5 +- samples/jo.html.ref | 1035 +-- samples/nonfree/dmca.html.ref | 2016 +---- samples/nonfree/dmca.txt.ref | 20 +- samples/nonfree/dmca.xml.ref | 84 +- samples/nonfree/f1040nr.html.ref | 4747 +----------- samples/nonfree/f1040nr.txt.ref | 192 +- samples/nonfree/f1040nr.xml.ref | 1156 ++- samples/nonfree/i1040nr.html.ref | 5865 +-------------- samples/nonfree/i1040nr.txt.ref | 259 +- samples/nonfree/i1040nr.xml.ref | 8087 ++++++++++----------- samples/nonfree/kampo.html.ref | 2866 +------- samples/nonfree/kampo.txt.ref | 8 +- samples/nonfree/kampo.xml.ref | 96 +- samples/nonfree/naacl06-shinyama.html.ref | 3053 +------- samples/nonfree/naacl06-shinyama.txt.ref | 27 +- samples/nonfree/naacl06-shinyama.xml.ref | 103 +- samples/nonfree/nlp2004slides.html.ref | 93 +- samples/simple1.html.ref | 70 +- samples/simple3.html.ref | 43 +- tools/pdf2html.cgi | 78 +- 21 files changed, 5742 insertions(+), 24161 deletions(-) diff --git a/samples/Makefile b/samples/Makefile index c0723cf..aecabfb 100644 --- a/samples/Makefile +++ b/samples/Makefile @@ -5,7 +5,7 @@ RM=rm -f CMP=: PYTHON=python2 -PDF2TXT=PYTHONPATH=.. $(PYTHON) ../tools/pdf2txt.py -Dx -p1 +PDF2TXT=PYTHONPATH=.. $(PYTHON) ../tools/pdf2txt.py -p1 HTMLS=$(HTMLS_FREE) $(HTMLS_NONFREE) HTMLS_FREE= \ @@ -49,8 +49,7 @@ XMLS_NONFREE= \ nonfree/naacl06-shinyama.xml \ nonfree/nlp2004slides.xml -all: - $(MAKE) test CMP=cmp +all: test test: htmls texts xmls diff --git a/samples/jo.html.ref b/samples/jo.html.ref index 11333f9..db6bde9 100644 --- a/samples/jo.html.ref +++ b/samples/jo.html.ref @@ -3,973 +3,70 @@
Page 1
- - -  -  - - - -  - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -  -  - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -  - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -  -  - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -  - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -  -  -  - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -  -  - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -  -  - - - - - - - - - -廿 - -  -  - - - - -
Page: 1
+
  序 +
  +
わたくしといふ現象は +
假定された有機交流電燈の +
ひとつの青い照明です +
(あらゆる透明な幽霊の複合体) +
風景やみんなといっしょに +
せはしくせはしく明滅しながら +
いかにもたしかにともりつづける +
因果交流電燈の +
ひとつの青い照明です +
(ひかりはたもち、その電燈は失はれ) +
   +
これらは二十二箇月の +
過去とかんずる方角から +
紙と鑛質インクをつらね +
(すべてわたくしと明滅し +
 みんなが同時に感ずるもの) +
ここまでたもちつゞけられた +
かげとひかりのひとくさりづつ +
そのとほりの心象スケッチです +
   +
これらについて人や銀河や修羅や海膽は +
宇宙塵をたべ、または空気や塩水を呼吸しながら +
それぞれ新鮮な本体論もかんがへませうが +
それらも畢竟こゝろのひとつの風物です +
たゞたしかに記録されたこれらのけしきは +
記録されたそのとほりのこのけしきで +
それが虚無ならば虚無自身がこのとほりで +
ある程度まではみんなに共通いたします +
(すべてがわたくしの中のみんなであるやうに +
 みんなのおのおののなかのすべてですから) +
けれどもこれら新世代沖積世の +
巨大に明るい時間の集積のなかで +
正しくうつされた筈のこれらのことばが +
わづかその一點にも均しい明暗のうちに +
   (あるひは修羅の十億年) +
すでにはやくもその組立や質を變じ +
しかもわたくしも印刷者も +
それを変らないとして感ずることは +
傾向としてはあり得ます +
けだしわれわれがわれわれの感官や +
風景や人物をかんずるやうに +
そしてたゞ共通に感ずるだけであるやうに +
記録や歴史、あるひは地史といふものも +
それのいろいろの論料といっしょに +
(因果の時空的制約のもとに) +
われわれがかんじてゐるのに過ぎません +
おそらくこれから二千年もたったころは +
それ相當のちがった地質學が流用され +
相當した證據もまた次次過去から現出し +
みんなは二千年ぐらゐ前には +
青ぞらいっぱいの無色な孔雀が居たとおもひ +
新進の大學士たちは気圏のいちばんの上層 +
きらびやかな氷窒素のあたりから +
すてきな化石を發堀したり +
あるひは白堊紀砂岩の層面に +
透明な人類の巨大な足跡を +
発見するかもしれません +
   +
すべてこれらの命題は +
心象や時間それ自身の性質として +
第四次延長のなかで主張されます +
   +
大正十三年一月廿日  宮澤賢治 +
Page: 1
diff --git a/samples/nonfree/dmca.html.ref b/samples/nonfree/dmca.html.ref index 662cada..4147a6b 100644 --- a/samples/nonfree/dmca.html.ref +++ b/samples/nonfree/dmca.html.ref @@ -3,1978 +3,48 @@
Page 1
- - -T -H -E - -D -I -G -I -T -A -L - -M -I -L -L -E -N -N -I -U -M - -C -O -P -Y -R -I -G -H -T - -A -C -T - -O -F - -1 -9 -9 -8 - -U -. -S -. - -C -o -p -y -r -i -g -h -t - -O -f -f -i -c -e - -S -u -m -m -a -r -y - - -I -N -T -R -O -D -U -C -T -I -O -N - - -D -e -c -e -m -b -e -r - -1 -9 -9 -8 - - -T -h -e - -D -i -g -i -t -a -l - -M -i -l -l -e -n -n -i -u -m - -C -o -p -y -r -i -g -h -t - -A -c -t - -( -D -M -C -A -) - -w -a -s - -s -i -g -n -e -d - -i -n -t -o - -l -a -w - -b -y - -1 - -P -r -e -s -i -d -e -n -t - -C -l -i -n -t -o -n - -o -n - -O -c -t -o -b -e -r - -2 -8 -, - -1 -9 -9 -8 -. - - -T -h -e - -l -e -g -i -s -l -a -t -i -o -n - -i -m -p -l -e -m -e -n -t -s - -t -w -o - -1 -9 -9 -6 - -W -o -r -l -d - -I -n -t -e -l -l -e -c -t -u -a -l - -P -r -o -p -e -r -t -y - -O -r -g -a -n -i -z -a -t -i -o -n - -( -W -I -P -O -) - -t -r -e -a -t -i -e -s -: - - -t -h -e - -W -I -P -O - -C -o -p -y -r -i -g -h -t - -T -r -e -a -t -y - -a -n -d - -t -h -e - -W -I -P -O - -P -e -r -f -o -r -m -a -n -c -e -s - -a -n -d - -P -h -o -n -o -g -r -a -m -s - -T -r -e -a -t -y -. - - -T -h -e - -D -M -C -A - -a -l -s -o - -a -d -d -r -e -s -s -e -s - -a - -n -u -m -b -e -r - -o -f - -o -t -h -e -r - -s -i -g -n -i -f -i -c -a -n -t - -c -o -p -y -r -i -g -h -t -- -r -e -l -a -t -e -d - -i -s -s -u -e -s -. - - -T -h -e - -D -M -C -A - -i -s - -d -i -v -i -d -e -d - -i -n -t -o - -f -i -v -e - -t -i -t -l -e -s -: - - - - -T -i -t -l -e - -I -, - -t -h -e - - -W -I -P -O - -C -o -p -y -r -i -g -h -t - -a -n -d - -P -e -r -f -o -r -m -a -n -c -e -s - -a -n -d - -P -h -o -n -o -g -r -a -m -s - -T -r -e -a -t -i -e -s - -I -m -p -l -e -m -e -n -t -a -t -i -o -n - -A -c -t - -o -f - -1 -9 -9 -8 -, - - -i -m -p -l -e -m -e -n -t -s - -t -h -e - -W -I -P -O - -t -r -e -a -t -i -e -s -. - -T -i -t -l -e - -I -I -, - -t -h -e - - -O -n -l -i -n -e - -C -o -p -y -r -i -g -h -t - -I -n -f -r -i -n -g -e -m -e -n -t - -L -i -a -b -i -l -i -t -y - -L -i -m -i -t -a -t -i -o -n - -A -c -t -, - - -c -r -e -a -t -e -s - -l -i -m -i -t -a -t -i -o -n -s - -o -n - -t -h -e - -l -i -a -b -i -l -i -t -y - -o -f - -o -n -l -i -n -e - -s -e -r -v -i -c -e - -p -r -o -v -i -d -e -r -s - -f -o -r - -c -o -p -y -r -i -g -h -t - -i -n -f -r -i -n -g -e -m -e -n -t - - -w -h -e -n - -e -n -g -a -g -i -n -g - -i -n - -c -e -r -t -a -i -n - -t -y -p -e -s - -o -f - -a -c -t -i -v -i -t -i -e -s -. - -T -i -t -l -e - -I -I -I -, - -t -h -e - - -C -o -m -p -u -t -e -r - -M -a -i -n -t -e -n -a -n -c -e - -C -o -m -p -e -t -i -t -i -o -n - -A -s -s -u -r -a -n -c -e - -A -c -t -, - - -c -r -e -a -t -e -s - -a -n - -e -x -e -m -p -t -i -o -n - -f -o -r - -m -a -k -i -n -g - -a - -c -o -p -y - -o -f - -a - -c -o -m -p -u -t -e -r - -p -r -o -g -r -a -m - -b -y - -a -c -t -i -v -a -t -i -n -g - -a - -c -o -m -p -u -t -e -r - -f -o -r - -p -u -r -p -o -s -e -s - -o -f - -m -a -i -n -t -e -n -a -n -c -e - -o -r - -r -e -p -a -i -r -. - -T -i -t -l -e - -I -V - -c -o -n -t -a -i -n -s - -s -i -x - -m -i -s -c -e -l -l -a -n -e -o -u -s - -p -r -o -v -i -s -i -o -n -s -, - -r -e -l -a -t -i -n -g - -t -o - -t -h -e - -f -u -n -c -t -i -o -n -s - -o -f - -t -h -e - -C -o -p -y -r -i -g -h -t - -O -f -f -i -c -e -, - -d -i -s -t -a -n -c -e - -e -d -u -c -a -t -i -o -n -, - -t -h -e - -e -x -c -e -p -t -i -o -n -s - -i -n - -t -h -e - -C -o -p -y -r -i -g -h -t - -A -c -t - -f -o -r - -l -i -b -r -a -r -i -e -s - -a -n -d - -f -o -r - -m -a -k -i -n -g - -e -p -h -e -m -e -r -a -l - -r -e -c -o -r -d -i -n -g -s -, - - -w -e -b -c -a -s -t -i -n -g - - -o -f - -s -o -u -n -d - -r -e -c -o -r -d -i -n -g -s - -o -n - -t -h -e - -I -n -t -e -r -n -e -t -, - -a -n -d - -t -h -e - -a -p -p -l -i -c -a -b -i -l -i -t -y - -o -f - -c -o -l -l -e -c -t -i -v -e - -b -a -r -g -a -i -n -i -n -g - -a -g -r -e -e -m -e -n -t - -o -b -l -i -g -a -t -i -o -n -s - -i -n - -t -h -e - -c -a -s -e - -o -f - -t -r -a -n -s -f -e -r -s - -o -f - -r -i -g -h -t -s - -i -n - -m -o -t -i -o -n - -p -i -c -t -u -r -e -s -. - -T -i -t -l -e - -V -, - -t -h -e - - -V -e -s -s -e -l - -H -u -l -l - -D -e -s -i -g -n - -P -r -o -t -e -c -t -i -o -n - -A -c -t -, - - -c -r -e -a -t -e -s - -a - -n -e -w - -f -o -r -m - -o -f - -p -r -o -t -e -c -t -i -o -n - -f -o -r - -t -h -e - -d -e -s -i -g -n - -o -f - -v -e -s -s -e -l - -h -u -l -l -s -. - - -! - - -! - - -! - - -! - - -! - - -T -h -i -s - -m -e -m -o -r -a -n -d -u -m - -s -u -m -m -a -r -i -z -e -s - -b -r -i -e -f -l -y - -e -a -c -h - -t -i -t -l -e - -o -f - -t -h -e - -D -M -C -A -. - - -I -t - -p -r -o -v -i -d -e -s - -m -e -r -e -l -y - -a -n - -o -v -e -r -v -i -e -w - -o -f - -t -h -e - -l -a -w - -s - -p -r -o -v -i -s -i -o -n -s -; - -f -o -r - -p -u -r -p -o -s -e -s - -o -f - -l -e -n -g -t -h - -a -n -d - -r -e -a -d -a -b -i -l -i -t -y - -a - -s -i -g -n -i -f -i -c -a -n -t - -a -m -o -u -n -t - -o -f - -d -e -t -a -i -l - -h -a -s - -b -e -e -n - -o -m -i -t -t -e -d -. - - -A - -c -o -m -p -l -e -t -e - -u -n -d -e -r -s -t -a -n -d -i -n -g - -o -f - -a -n -y - -p -r -o -v -i -s -i -o -n - -o -f - -t -h -e - -D -M -C -A - -r -e -q -u -i -r -e -s - -r -e -f -e -r -e -n -c -e - -t -o - -t -h -e - -t -e -x -t - -o -f - -t -h -e - -l -e -g -i -s -l -a -t -i -o -n - -i -t -s -e -l -f -. - - -P -u -b -. - -L -. - -N -o -. - -1 -0 -5 -- -3 -0 -4 -, - -1 -1 -2 - -S -t -a -t -. - -2 -8 -6 -0 - -( -O -c -t -. - -2 -8 -, - -1 -9 -9 -8 -) -. - -1 - - -C -o -p -y -r -i -g -h -t - -O -f -f -i -c -e - -S -u -m -m -a -r -y - - -D -e -c -e -m -b -e -r - -1 -9 -9 -8 - - -P -a -g -e - -1 - - +
THE DIGITAL MILLENNIUM COPYRIGHT ACT OF 1998 +
U.S. Copyright Office Summary +
INTRODUCTION +
December 1998 +
The Digital Millennium Copyright Act (DMCA) was signed into law by +
1 +
President Clinton on October 28, 1998. The legislation implements two 1996 World +
Intellectual Property Organization (WIPO) treaties: the WIPO Copyright Treaty and +
the WIPO Performances and Phonograms Treaty. The DMCA also addresses a +
number of other significant copyright-related issues. +
The DMCA is divided into five titles: +
! +
! +
! +
! +
! +
Title I, the “WIPO Copyright and Performances and Phonograms +
Treaties Implementation Act of 1998
,” implements the WIPO +
treaties. +
Title II, the “
Online Copyright Infringement Liability Limitation +
Act
,” creates limitations on the liability of online service providers for +
copyright infringement when engaging in certain types of activities. +
Title III, the “
Computer Maintenance Competition Assurance +
Act
,” creates an exemption for making a copy of a computer program +
by activating a computer for purposes of maintenance or repair. +
Title IV contains six
miscellaneous provisions, relating to the +
functions of the Copyright Office, distance education, the exceptions +
in the Copyright Act for libraries and for making ephemeral recordings, +
“webcasting” of sound recordings on the Internet, and the applicability +
of collective bargaining agreement obligations in the case of transfers +
of rights in motion pictures. +
Title V, the “
Vessel Hull Design Protection Act,” creates a new form +
of protection for the design of vessel hulls. +
This memorandum summarizes briefly each title of the DMCA. It provides +
merely an overview of the law’s provisions; for purposes of length and readability a +
significant amount of detail has been omitted.
A complete understanding of any +
provision of the DMCA requires reference to the text of the legislation itself. +
Pub. L. No. 105-304, 112 Stat. 2860 (Oct. 28, 1998). +
1 +
Copyright Office Summary +
December 1998 +
Page 1 +
Page: 1
diff --git a/samples/nonfree/dmca.txt.ref b/samples/nonfree/dmca.txt.ref index 1706ca6..df91f96 100644 --- a/samples/nonfree/dmca.txt.ref +++ b/samples/nonfree/dmca.txt.ref @@ -14,6 +14,16 @@ number of other significant copyright-related issues. The DMCA is divided into five titles: +! + +! + +! + +! + +! + Title I, the “WIPO Copyright and Performances and Phonograms Treaties Implementation Act of 1998,” implements the WIPO treaties. @@ -32,16 +42,6 @@ of rights in motion pictures. Title V, the “Vessel Hull Design Protection Act,” creates a new form of protection for the design of vessel hulls. -! - -! - -! - -! - -! - This memorandum summarizes briefly each title of the DMCA. It provides merely an overview of the law’s provisions; for purposes of length and readability a significant amount of detail has been omitted. A complete understanding of any diff --git a/samples/nonfree/dmca.xml.ref b/samples/nonfree/dmca.xml.ref index d1f1c75..6326320 100644 --- a/samples/nonfree/dmca.xml.ref +++ b/samples/nonfree/dmca.xml.ref @@ -568,7 +568,42 @@ - + + +! + + + + + + +! + + + + + + +! + + + + + + +! + + + + + + +! + + + + + T i @@ -1669,41 +1704,6 @@ - - -! - - - - - - -! - - - - - - -! - - - - - - -! - - - - - - -! - - - - T @@ -2194,20 +2194,20 @@ - - - + + - + - + - + + diff --git a/samples/nonfree/f1040nr.html.ref b/samples/nonfree/f1040nr.html.ref index d2ced61..d83b46b 100644 --- a/samples/nonfree/f1040nr.html.ref +++ b/samples/nonfree/f1040nr.html.ref @@ -3,4432 +3,327 @@ - - -O -M -B - -N -o -. - -1 -5 -4 -5 -- -0 -0 -7 -4 - -2 -0 -0 -7 - - - - -, - -2 -0 - - - -I -d -e -n -t -i -f -y -i -n -g - -n -u -m -b -e -r - -( -s -e -e - -p -a -g -e - -8 -) - - - - -I - - - -C -h -e -c -k - -i -f -: - - - - -n -d -i -v -i -d -u -a -l - - - -E -s -t -a -t -e - -o -r - -T -r -u -s -t - -T -y -p -e - -o -f - -e -n -t -r -y - -v -i -s -a - -( -s -e -e - -p -a -g -e - -8 -) - - - - - - -7 - -a - -Y -o -u -r -s -e -l -f - - - - -7 - -b - -S -p -o -u -s -e - - - - - - - - - - - - - - - - - - - - - - - - - - - -N -o -. - -o -f - -b -o -x -e -s - -c -h -e -c -k -e -d - -o -n - -7 -a - -a -n -d - -7 -b - - - -N -o -. - -o -f - -c -h -i -l -d -r -e -n - -o -n - -7 -c - -w -h -o -: - - - -l -i -v -e -d - -w -i -t -h - -y -o -u - - - - - - -d -i -d - -n -o -t - -l -i -v -e - -w -i -t -h - -y -o -u - -d -u -e - -t -o - -d -i -v -o -r -c -e - - -o -r - -s -e -p -a -r -a -t -i -o -n - - - -D -e -p -e -n -d -e -n -t -s - -o -n - -7 -c - -n -o -t - -e -n -t -e -r -e -d - -a -b -o -v -e - - -d -d - -n -u -m -b -e -r -s - -e -n -t -e -r -e -d - -o -n - -l -i -n -e -s - -a -b -o -v -e - - - -8 - - - -9 - -a - - - -A - - -1 -0 -4 -0 -N -R - - - -F -o -r -m - - - -D -e -p -a -r -t -m -e -n -t - -o -f - -t -h -e - -T -r -e -a -s -u -r -y - -b -e -g -i -n -n -i -n -g - -I -n -t -e -r -n -a -l - -R -e -v -e -n -u -e - -S -e -r -v -i -c -e - - - -Y -o -u -r - -f -i -r -s -t - -n -a -m -e - -a -n -d - -i -n -i -t -i -a -l - - -U -. -S -. - -N -o -n -r -e -s -i -d -e -n -t - -A -l -i -e -n - -I -n -c -o -m -e - -T -a -x - -R -e -t -u -r -n - - - -F -o -r - -t -h -e - -y -e -a -r - -J -a -n -u -a -r -y - -1 - -D -e -c -e -m -b -e -r - -3 -1 -, - -2 -0 -0 -7 -, - -o -r - -o -t -h -e -r - -t -a -x - -y -e -a -r - - - - -, - -2 -0 -0 -7 -, - -a -n -d - -e -n -d -i -n -g - - -L -a -s -t - -n -a -m -e - - - - -r -e -s -e -n -t - -h -o -m -e - -a -d -d -r -e -s -s - -( -n -u -m -b -e -r -, - -s -t -r -e -e -t -, - -a -n -d - -a -p -t -. - -n -o -. -, - -o -r - -r -u -r -a -l - -r -o -u -t -e -) -. - -I -f - -y -o -u - -h -a -v -e - -a - -P -. -O -. - -b -o -x -, - -s -e -e - -p -a -g -e - -8 -. - - -C -i -t -y -, - -t -o -w -n - -o -r - -p -o -s -t - -o -f -f -i -c -e -, - -s -t -a -t -e -, - -a -n -d - -Z -I -P - -c -o -d -e -. - -I -f - -y -o -u - -h -a -v -e - -a - -f -o -r -e -i -g -n - -a -d -d -r -e -s -s -, - -s -e -e - -p -a -g -e - -8 -. - - - - -C -o -u -n -t -r -y - - -O -f - -w -h -a -t - -c -o -u -n -t -r -y - -w -e -r -e - -y -o -u - -a - -c -i -t -i -z -e -n - -o -r - -n -a -t -i -o -n -a -l - -d -u -r -i -n -g - -t -h -e - -t -a -x - -y -e -a -r -? - - - - - - -G -i -v -e - -a -d -d -r -e -s -s - -o -u -t -s -i -d -e - -t -h -e - -U -n -i -t -e -d - -S -t -a -t -e -s - -t -o - -w -h -i -c -h - -y -o -u - -w -a -n -t - -a -n -y - -G -i -v -e - -a -d -d -r -e -s -s - -i -n - -t -h -e - -c -o -u -n -t -r -y - -w -h -e -r -e - -y -o -u - -a -r -e - -a - -p -e -r -m -a -n -e -n -t - -r -e -s -i -d -e -n -t -. - -r -e -f -u -n -d - -c -h -e -c -k - -m -a -i -l -e -d -. - -I -f - -s -a -m -e - -a -s - -a -b -o -v -e -, - -w -r -i -t -e - - -S -a -m -e -. - - -I -f - -s -a -m -e - -a -s - -a -b -o -v -e -, - -w -r -i -t -e - - -S -a -m -e -. - - - - - - - - -P - - - - - -. -e -p -y -t - -r -o - -t -n -i -r -p - -e -s -a -e -l -P - - - - - -. -d -l -e -h -h -t -i -w - -s -a -w - -x -a -t - -f -i - -R -- -9 -9 -0 -1 - -) -s -( -m -r -o -F - -h -c -a -t -t -a - -o -s -l -A - -. -e -r -e -h - -2 -- -W - -s -m -r -o -F - -h -c -a -t -t -A - - - - - - - - - -I -f - -y -o -u - -c -h -e -c -k - -b -o -x - -7 -b -, - -e -n -t -e -r - -y -o -u -r - -s -p -o -u -s -e - -s - -i -d -e -n -t -i -f -y -i -n -g - -n -u -m -b -e -r - - - -( -3 -) - -D -e -p -e -n -d -e -n -t - -s - -r -e -l -a -t -i -o -n -s -h -i -p - -t -o - -y -o -u - - - - -( -4 -) - - -i -f - -q -u -a -l -i -f -y -i -n -g - -c -h -i -l -d - -f -o -r - -c -h -i -l -d - -t -a -x - -c -r -e -d -i -t - -( -s -e -e - -p -a -g -e - -9 -) - - - - - - - - -F -i -l -i -n -g - -S -t -a -t -u -s - -a -n -d - -E -x -e -m -p -t -i -o -n -s - -f -o -r - -I -n -d -i -v -i -d -u -a -l -s - -( -s -e -e - -p -a -g -e - -8 -) - - - -F -i -l -i -n -g - -s -t -a -t -u -s -. - -C -h -e -c -k - -o -n -l -y - -o -n -e - -b -o -x - -( -1 - -6 - -b -e -l -o -w -) -. - - - -1 - -S -i -n -g -l -e - -r -e -s -i -d -e -n -t - -o -f - -C -a -n -a -d -a - -o -r - -M -e -x -i -c -o -, - -o -r - -a - -s -i -n -g -l -e - -U -. -S -. - -n -a -t -i -o -n -a -l - - - -2 - -O -t -h -e -r - -s -i -n -g -l -e - -n -o -n -r -e -s -i -d -e -n -t - -a -l -i -e -n - - - - - -3 - -M -a -r -r -i -e -d - -r -e -s -i -d -e -n -t - -o -f - -C -a -n -a -d -a - -o -r - -M -e -x -i -c -o -, - -o -r - -a - -m -a -r -r -i -e -d - -U -. -S -. - -n -a -t -i -o -n -a -l - - - - - -4 - -M -a -r -r -i -e -d - -r -e -s -i -d -e -n -t - -o -f - -t -h -e - -R -e -p -u -b -l -i -c - -o -f - -K -o -r -e -a - -( -S -o -u -t -h - -K -o -r -e -a -) - - - - - -5 - -O -t -h -e -r - -m -a -r -r -i -e -d - -n -o -n -r -e -s -i -d -e -n -t - -a -l -i -e -n - - - - - -6 - -Q -u -a -l -i -f -y -i -n -g - -w -i -d -o -w -( -e -r -) - -w -i -t -h - -d -e -p -e -n -d -e -n -t - -c -h -i -l -d - -( -s -e -e - -p -a -g -e - -9 -) - - - - - -C -a -u -t -i -o -n -: - -D -o - -n -o -t - -c -h -e -c -k - -b -o -x - -7 -a - -i -f - -y -o -u -r - -p -a -r -e -n -t - -( -o -r - -s -o -m -e -o -n -e - -e -l -s -e -) - -c -a -n - -c -l -a -i -m - -y -o -u - -a -s - -a - -d -e -p -e -n -d -e -n -t -. - -D -o - -n -o -t - -c -h -e -c -k - -b -o -x - -7 -b - -i -f - -y -o -u -r - -s -p -o -u -s -e - -h -a -d - -a -n -y - -U -. -S -. - -g -r -o -s -s - -i -n -c -o -m -e -. - - - -7 - -c - -D -e -p -e -n -d -e -n -t -s -: - -( -s -e -e - -p -a -g -e - -9 -) - - - - - - - - - - -( -1 -) - -F -i -r -s -t - -n -a -m -e - - - - -L -a -s -t - -n -a -m -e - - - - -( -2 -) - -D -e -p -e -n -d -e -n -t - -s - - -i -d -e -n -t -i -f -y -i -n -g - -n -u -m -b -e -r - - - -. - -. - -. - -. - -. - -. - - - - - -. - -. - -. - -. - -. - -. - - - - - -. - -. - -. - -. - -. - -. - - - - - -. - -. - -. - -. - -. - -. - - - - - - -1 -0 -a - - - - -1 - -1 - -1 - -2 - -1 - -3 - -1 - -4 - -1 - -5 - -1 -6 -b - - - -1 -7 -b - - - -1 - -8 - -1 - -9 - -2 - -0 - -2 - -1 - - -2 - -3 - - -3 - -4 - -3 - -5 - - -d - - - - - - - - - - - - - - - - - - - - - - - - - - - -9 - -b - - - - - - -8 - - - -9 - -a - -b - - - -1 -0 -a - - - -b - - - - -T -o -t -a -l - -n -u -m -b -e -r - -o -f - -e -x -e -m -p -t -i -o -n -s - -c -l -a -i -m -e -d - - - -W -a -g -e -s -, - -s -a -l -a -r -i -e -s -, - -t -i -p -s -, - -e -t -c -. - -A -t -t -a -c -h - -F -o -r -m -( -s -) - -W -- -2 - - - -T -a -x -a -b -l -e - -i -n -t -e -r -e -s -t - - - -T -a -x -- -e -x -e -m -p -t - -i -n -t -e -r -e -s -t -. - -D -o - -n -o -t - -i -n -c -l -u -d -e - -o -n - -l -i -n -e - -9 -a - - -O -r -d -i -n -a -r -y - -d -i -v -i -d -e -n -d -s - -1 -0 -b - - - - - -Q -u -a -l -i -f -i -e -d - -d -i -v -i -d -e -n -d -s - -( -s -e -e - -p -a -g -e - -1 -1 -) - - - - -1 - -1 - -T -a -x -a -b -l -e - -r -e -f -u -n -d -s -, - -c -r -e -d -i -t -s -, - -o -r - -o -f -f -s -e -t -s - -o -f - -s -t -a -t -e - -a -n -d - -l -o -c -a -l - -i -n -c -o -m -e - -t -a -x -e -s - -( -s -e -e - -p -a -g -e - -1 -1 -) - - - - -1 - -2 - -S -c -h -o -l -a -r -s -h -i -p - -a -n -d - -f -e -l -l -o -w -s -h -i -p - -g -r -a -n -t -s -. - -A -t -t -a -c -h - -F -o -r -m -( -s -) - -1 -0 -4 -2 -- -S - -o -r - -r -e -q -u -i -r -e -d - -s -t -a -t -e -m -e -n -t - -( -s -e -e - -p -a -g -e - -1 -1 -) - - - - -1 - -3 - -B -u -s -i -n -e -s -s - -i -n -c -o -m -e - -o -r - -( -l -o -s -s -) -. - -A -t -t -a -c -h - -S -c -h -e -d -u -l -e - -C - -o -r - -C -- -E -Z - -( -F -o -r -m - -1 -0 -4 -0 -) - - - -1 - -4 - -C -a -p -i -t -a -l - -g -a -i -n - -o -r - -( -l -o -s -s -) -. - -A -t -t -a -c -h - -S -c -h -e -d -u -l -e - -D - -( -F -o -r -m - -1 -0 -4 -0 -) - -i -f - -r -e -q -u -i -r -e -d -. - -I -f - -n -o -t - -r -e -q -u -i -r -e -d -, - -c -h -e -c -k - -h -e -r -e - - - -1 - -5 - -O -t -h -e -r - -g -a -i -n -s - -o -r - -( -l -o -s -s -e -s -) -. - -A -t -t -a -c -h - -F -o -r -m - -4 -7 -9 -7 - -1 -6 -a - -1 -6 -b - -1 -6 -a - -T -a -x -a -b -l -e - -a -m -o -u -n -t - -( -s -e -e - -p -a -g -e - -1 -2 -) - -I -R -A - -d -i -s -t -r -i -b -u -t -i -o -n -s - - - - - - - -1 -7 -a - - - - - -1 -7 -b - -1 -7 -a - -T -a -x -a -b -l -e - -a -m -o -u -n -t - -( -s -e -e - -p -a -g -e - -1 -3 -) - -P -e -n -s -i -o -n -s - -a -n -d - -a -n -n -u -i -t -i -e -s - - - - - - - - - - - -1 - -8 - -R -e -n -t -a -l - -r -e -a -l - -e -s -t -a -t -e -, - -r -o -y -a -l -t -i -e -s -, - -p -a -r -t -n -e -r -s -h -i -p -s -, - -t -r -u -s -t -s -, - -e -t -c -. - -A -t -t -a -c -h - -S -c -h -e -d -u -l -e - -E - -( -F -o -r -m - -1 -0 -4 -0 -) - -1 - -9 - -F -a -r -m - -i -n -c -o -m -e - -o -r - -( -l -o -s -s -) -. - -A -t -t -a -c -h - -S -c -h -e -d -u -l -e - -F - -( -F -o -r -m - -1 -0 -4 -0 -) - - - -2 - -0 - -U -n -e -m -p -l -o -y -m -e -n -t - -c -o -m -p -e -n -s -a -t -i -o -n - - - -2 - -1 - -O -t -h -e -r - -i -n -c -o -m -e -. - -L -i -s -t - -t -y -p -e - -a -n -d - -a -m -o -u -n -t - -( -s -e -e - -p -a -g -e - -1 -5 -) - -2 - -2 - -2 - -2 - -T -o -t -a -l - -i -n -c -o -m -e - -e -x -e -m -p -t - -b -y - -a - -t -r -e -a -t -y - -f -r -o -m - -p -a -g -e - -5 -, - -I -t -e -m - -M - - - -2 - -3 - -A -d -d - -l -i -n -e -s - -8 -, - -9 -a -, - -1 -0 -a -, - -1 -1 - -1 -5 -, - -1 -6 -b -, - -a -n -d - -1 -7 -b - -2 -1 -. - -T -h -i -s - -i -s - -y -o -u -r - -t -o -t -a -l - -e -f -f -e -c -t -i -v -e -l -y - -c -o -n -n -e -c -t -e -d - -i -n -c -o -m -e - - - -2 - -4 - -2 - -4 - -E -d -u -c -a -t -o -r - -e -x -p -e -n -s -e -s - -( -s -e -e - -p -a -g -e - -1 -5 -) - -2 - -5 - -2 - -5 - -H -e -a -l -t -h - -s -a -v -i -n -g -s - -a -c -c -o -u -n -t - -d -e -d -u -c -t -i -o -n -. - -A -t -t -a -c -h - -F -o -r -m - -8 -8 -8 -9 - -2 - -6 - -2 - -6 - -M -o -v -i -n -g - -e -x -p -e -n -s -e -s -. - -A -t -t -a -c -h - -F -o -r -m - -3 -9 -0 -3 - -2 - -7 - - - -2 - -7 - -S -e -l -f -- -e -m -p -l -o -y -e -d - -S -E -P -, - -S -I -M -P -L -E -, - -a -n -d - -q -u -a -l -i -f -i -e -d - -p -l -a -n -s - -2 - -8 - - - -2 - -8 - -S -e -l -f -- -e -m -p -l -o -y -e -d - -h -e -a -l -t -h - -i -n -s -u -r -a -n -c -e - -d -e -d -u -c -t -i -o -n - -( -s -e -e - -p -a -g -e - -1 -6 -) - - -2 - -9 - -2 - -9 - -P -e -n -a -l -t -y - -o -n - -e -a -r -l -y - -w -i -t -h -d -r -a -w -a -l - -o -f - -s -a -v -i -n -g -s - -3 - -0 - - - -3 - -0 - -S -c -h -o -l -a -r -s -h -i -p - -a -n -d - -f -e -l -l -o -w -s -h -i -p - -g -r -a -n -t -s - -e -x -c -l -u -d -e -d - -3 - -1 - - - -I -R -A - -d -e -d -u -c -t -i -o -n - -( -s -e -e - -p -a -g -e - -1 -6 -) - -3 - -1 - -3 - -2 - - - -3 - -2 - -S -t -u -d -e -n -t - -l -o -a -n - -i -n -t -e -r -e -s -t - -d -e -d -u -c -t -i -o -n - -( -s -e -e - -p -a -g -e - -1 -6 -) - -3 - -3 - - - -3 - -3 - -D -o -m -e -s -t -i -c - -p -r -o -d -u -c -t -i -o -n - -a -c -t -i -v -i -t -i -e -s - -d -e -d -u -c -t -i -o -n -. - -A -t -t -a -c -h - -F -o -r -m - -8 -9 -0 -3 - - - -3 - -4 - -A -d -d - -l -i -n -e -s - -2 -4 - -t -h -r -o -u -g -h - -3 -3 - -3 - -5 - -S -u -b -t -r -a -c -t - -l -i -n -e - -3 -4 - -f -r -o -m - -l -i -n -e - -2 -3 -. - -E -n -t -e -r - -h -e -r -e - -a -n -d - -o -n - -l -i -n -e - -3 -6 -. - -T -h -i -s - -i -s - -y -o -u -r - -a -d -j -u -s -t -e -d - -g -r -o -s -s - -i -n -c -o -m -e - - - -F -o -r - -D -i -s -c -l -o -s -u -r -e -, - -P -r -i -v -a -c -y - -A -c -t -, - -a -n -d - -P -a -p -e -r -w -o -r -k - -R -e -d -u -c -t -i -o -n - -A -c -t - -N -o -t -i -c -e -, - -s -e -e - -p -a -g -e - -3 -2 -. - -C -a -t -. - -N -o -. - -1 -1 -3 -6 -4 -D - - - - - - -s -s -e -n -i -s -u -B -/ -e -d -a -r -T - -. -S -. -U - -h -t -i -W - -d -e -t -c -e -n -n -o -C - -y -l -e -v -i -t -c -e -f -f -E - -e -m -o -c -n -I - - -. -t -n -e -m -y -a -p - -y -n -a - -, -h -c -a -t -t -a - -t -o -n - -o -d - -t -u -b - -, -e -s -o -l -c -n -E - - -e -m -o -c -n -I - -s -s -o -r -G - -d -e -t -s -u -j -d -A - - - - - - - - - - - -F -o -r -m - -1 -0 -4 -0 -N -R - -( -2 -0 -0 -7 -) - - - +
OMB No. 1545-0074 +
2007 +
+
, 20 +
+
Identifying number (see page 8) +
+
I +
Check if: +
+
ndividual +
+
Estate or Trust +
Type of entry visa (see page 8) +
䊳 +
7a +
Yourself +
+
7b +
Spouse +
+
䊳 +
+
䊳 +
+
䊳 +
+
䊳 +
+
䊳 +
+
No. of boxes checked +
on 7a and 7b +
+
No. of children on +
7c who: +
+
lived with you +
did not live with +
you due to divorce +
or separation +
+
Dependents on 7c +
not entered above +
dd numbers entered +
on lines above +
+
8 +
+
9a +
A +
1040NR +
+
Form +
Department of the Treasury +
beginning +
Internal Revenue Service +
+
Your first name and initial +
U.S. Nonresident Alien Income Tax Return +
+
For the year January 1–December 31, 2007, or other tax year +
+
, 2007, and ending +
Last name +
+
resent home address (number, street, and apt. no., or rural route). If you have a P.O. box, see page 8. +
City, town or post office, state, and ZIP code. If you have a foreign address, see page 8. +
+
Country 䊳 +
Of what country were you a citizen or national during the tax year? 䊳 +
+
+
Give address in the country where you are a permanent resident. +
Give address outside the United States to which you want any +
refund check mailed. If same as above, write “Same.” +
If same as above, write “Same.” +
+
+
P +
+
Please print or type. +
+
Also attach Form(s) 1099-R if tax was withheld. +
Attach Forms W-2 here. +
+
+
If you check box 7b, enter your spouse’s +
identifying number
䊳 +
(3) Dependent’s +
relationship +
to you +
+
(4) +
if qualifying +
child for child tax +
credit (see page 9) +
+
+
+
+
Filing Status and Exemptions for Individuals (see page 8) +
+
Filing status. Check only one box (1–6 below). +
+
1 +
Single resident of Canada or Mexico, or a single U.S. national +
+
2 +
Other single nonresident alien +
+
+
3 +
Married resident of Canada or Mexico, or a married U.S. national +
+
+
4 +
Married resident of the Republic of Korea (South Korea) +
+
+
5 +
Other married nonresident alien +
+
+
6 +
Qualifying widow(er) with dependent child (see page 9) +
+
+
Caution: Do not check box 7a if your parent (or someone else) can claim you as a dependent. +
Do not check box 7b if your spouse had any U.S. gross income. +
+
7c +
Dependents: (see page 9) +
+
(1) First name +
+
Last name +
+
(2) Dependent’s +
identifying number +
+
. +
. +
. +
. +
. +
. +
+
+
. +
. +
. +
. +
. +
. +
+
+
. +
. +
. +
. +
. +
. +
+
+
. +
. +
. +
. +
. +
. +
+
+
10a +
11 +
12 +
13 +
14 +
15 +
16b +
17b +
18 +
19 +
20 +
21 +
23 +
34 +
35
+
d +
+
+
+
+
+
+
9b +
Total number of exemptions claimed +
+
Wages, salaries, tips, etc. Attach Form(s) W-2 +
+
Taxable interest +
+
Tax-exempt interest. Do not include on line 9a +
Ordinary dividends +
10b +
+
Qualified dividends (see page 11) +
+
11 +
Taxable refunds, credits, or offsets of state and local income taxes (see page 11) +
+
12 +
Scholarship and fellowship grants. Attach Form(s) 1042-S or required statement (see page 11) +
+
13 +
Business income or (loss). Attach Schedule C or C-EZ (Form 1040) +
+
14 +
Capital gain or (loss). Attach Schedule D (Form 1040) if required. If not required, check here +
+
15 +
Other gains or (losses). Attach Form 4797 +
16a +
16b +
16a +
Taxable amount (see page 12) +
IRA distributions +
+
17a +
+
+
17b +
17a +
Taxable amount (see page 13) +
Pensions and annuities +
+
+
+
18 +
Rental real estate, royalties, partnerships, trusts, etc. Attach Schedule E (Form 1040) +
19 +
Farm income or (loss). Attach Schedule F (Form 1040) +
+
20 +
Unemployment compensation +
+
21 +
Other income. List type and amount (see page 15) +
22 +
22 +
Total income exempt by a treaty from page 5, Item M +
+
23 +
Add lines 8, 9a, 10a, 11–15, 16b, and 17b–21. This is your total effectively connected income 䊳 +
+
+
24 +
24 +
Educator expenses (see page 15) +
25 +
25 +
Health savings account deduction. Attach Form 8889 +
26 +
26 +
Moving expenses. Attach Form 3903 +
27 +
+
27 +
Self-employed SEP, SIMPLE, and qualified plans +
28 +
+
28 +
Self-employed health insurance deduction (see page 16) +
29 +
29 +
Penalty on early withdrawal of savings +
30 +
+
30 +
Scholarship and fellowship grants excluded +
31 +
+
IRA deduction (see page 16) +
31 +
32 +
+
32 +
Student loan interest deduction (see page 16) +
33 +
+
33 +
Domestic production activities deduction. Attach Form 8903 +
+
34 +
Add lines 24 through 33 +
35 +
Subtract line 34 from line 23. Enter here and on line 36. This is your adjusted gross income 䊳 +
+
+
For Disclosure, Privacy Act, and Paperwork Reduction Act Notice, see page 32. +
Cat. No. 11364D +
+
+
Income Effectively Connected With U.S. Trade/Business +
Enclose, but do not attach, any payment. +
8 +
+
9a +
b +
+
10a +
b +
+
Adjusted Gross Income +
+
+
+
+
Form 1040NR (2007) +
+
diff --git a/samples/nonfree/f1040nr.txt.ref b/samples/nonfree/f1040nr.txt.ref index d2ebfbc..20b3d80 100644 --- a/samples/nonfree/f1040nr.txt.ref +++ b/samples/nonfree/f1040nr.txt.ref @@ -6,7 +6,7 @@ OMB No. 1545-0074 Identifying number (see page 8) -I + I Check if: @@ -18,11 +18,11 @@ Type of entry visa (see page 8) 䊳 -7 a +7a Yourself -7 b +7b Spouse @@ -45,10 +45,8 @@ on 7a and 7b No. of children on 7c who: -lived with you -● - -● did not live with +● lived with you + ● did not live with you due to divorce or separation @@ -60,14 +58,13 @@ on lines above 8 -9 a +9a A 1040NR -Form - +Form Department of the Treasury beginning Internal Revenue Service @@ -92,8 +89,8 @@ Country 䊳 Of what country were you a citizen or national during the tax year? 䊳 -Give address outside the United States to which you want any Give address in the country where you are a permanent resident. +Give address outside the United States to which you want any refund check mailed. If same as above, write “Same.” If same as above, write “Same.” @@ -103,12 +100,12 @@ If same as above, write “Same.” -.epyt ro tnirp esaelP +Please print or type. -.dlehhtiw saw xat fi R-9901 )s(mroF hcatta oslA -.ereh 2-W smroF hcattA +Also attach Form(s) 1099-R if tax was withheld. +Attach Forms W-2 here. @@ -128,6 +125,10 @@ child for child tax credit (see page 9) + + + + 其 Filing Status and Exemptions for Individuals (see page 8) @@ -160,14 +161,10 @@ Qualifying widow(er) with dependent child (see page 9) Caution: Do not check box 7a if your parent (or someone else) can claim you as a dependent. Do not check box 7b if your spouse had any U.S. gross income. -7 c +7c Dependents: (see page 9) - - - - (1) First name @@ -210,27 +207,24 @@ identifying number -10a - +10a -1 1 -1 2 -1 3 -1 4 -1 5 -16b - -17b - -1 8 -1 9 -2 0 -2 1 +11 +12 +13 +14 +15 +16b +17b +18 +19 +20 +21 -2 3 +23 -3 4 -3 5 +34 +35 d @@ -243,25 +237,9 @@ d - - -䊳 - -9 b - -䊳 - -8 - -9 a -b - -10a - -b - +9b Total number of exemptions claimed @@ -271,114 +249,122 @@ Taxable interest Tax-exempt interest. Do not include on line 9a Ordinary dividends -10b - +10b Qualified dividends (see page 11) -1 1 +11 Taxable refunds, credits, or offsets of state and local income taxes (see page 11) -1 2 +12 Scholarship and fellowship grants. Attach Form(s) 1042-S or required statement (see page 11) -1 3 +13 Business income or (loss). Attach Schedule C or C-EZ (Form 1040) -1 4 +14 Capital gain or (loss). Attach Schedule D (Form 1040) if required. If not required, check here -1 5 +15 Other gains or (losses). Attach Form 4797 16a -16b -16a +16b +16a Taxable amount (see page 12) IRA distributions - - 17a -17b -17a +17b +17a Taxable amount (see page 13) Pensions and annuities - - -1 8 +18 Rental real estate, royalties, partnerships, trusts, etc. Attach Schedule E (Form 1040) -1 9 +19 Farm income or (loss). Attach Schedule F (Form 1040) -2 0 +20 Unemployment compensation -2 1 +21 Other income. List type and amount (see page 15) -2 2 -2 2 +22 +22 Total income exempt by a treaty from page 5, Item M -2 3 -Add lines 8, 9a, 10a, 11–15, 16b, and 17b–21. This is your total effectively connected income +23 +Add lines 8, 9a, 10a, 11–15, 16b, and 17b–21. This is your total effectively connected income 䊳 -2 4 -2 4 + +24 +24 Educator expenses (see page 15) -2 5 -2 5 +25 +25 Health savings account deduction. Attach Form 8889 -2 6 -2 6 +26 +26 Moving expenses. Attach Form 3903 -2 7 +27 -2 7 +27 Self-employed SEP, SIMPLE, and qualified plans -2 8 +28 -2 8 +28 Self-employed health insurance deduction (see page 16) -2 9 -2 9 +29 +29 Penalty on early withdrawal of savings -3 0 +30 -3 0 +30 Scholarship and fellowship grants excluded -3 1 +31 IRA deduction (see page 16) -3 1 -3 2 +31 +32 -3 2 +32 Student loan interest deduction (see page 16) -3 3 +33 -3 3 +33 Domestic production activities deduction. Attach Form 8903 -3 4 +34 Add lines 24 through 33 -3 5 -Subtract line 34 from line 23. Enter here and on line 36. This is your adjusted gross income +35 +Subtract line 34 from line 23. Enter here and on line 36. This is your adjusted gross income 䊳 + For Disclosure, Privacy Act, and Paperwork Reduction Act Notice, see page 32. Cat. No. 11364D -ssenisuB/edarT .S.U htiW detcennoC ylevitceffE emocnI +Income Effectively Connected With U.S. Trade/Business -.tnemyap yna ,hcatta ton od tub ,esolcnE +Enclose, but do not attach, any payment. -emocnI ssorG detsujdA +8 + +9a +b + +10a +b + + +Adjusted Gross Income + + diff --git a/samples/nonfree/f1040nr.xml.ref b/samples/nonfree/f1040nr.xml.ref index 60ba28a..6e0bbc9 100644 --- a/samples/nonfree/f1040nr.xml.ref +++ b/samples/nonfree/f1040nr.xml.ref @@ -99,9 +99,8 @@
-I - +I @@ -211,7 +210,7 @@ - + @@ -221,9 +220,8 @@ 7 - - a + @@ -248,9 +246,8 @@ 7 - - b + @@ -272,7 +269,7 @@ - + @@ -284,7 +281,7 @@ - + @@ -296,7 +293,7 @@ - + @@ -306,7 +303,7 @@ - + @@ -316,7 +313,7 @@
- + @@ -419,7 +416,9 @@ - + + + l i v @@ -438,17 +437,8 @@ - - - - - - + - - - - d @@ -624,9 +614,8 @@ 9 - - a + @@ -655,15 +644,11 @@ - + F o r m - - - - @@ -1222,7 +1207,7 @@ r y - + @@ -1303,7 +1288,7 @@ r ? - + @@ -1317,75 +1302,6 @@ - -G -i -v -e - - -a -d -d -r -e -s -s - -o -u -t -s -i -d -e - - -t -h -e - -U -n -i -t -e -d - - -S -t -a -t -e -s - -t -o - -w -h -i -c -h - - -y -o -u - -w -a -n -t - - -a -n -y - - - G i @@ -1461,6 +1377,75 @@ + +G +i +v +e + + +a +d +d +r +e +s +s + +o +u +t +s +i +d +e + + +t +h +e + +U +n +i +t +e +d + + +S +t +a +t +e +s + +t +o + +w +h +i +c +h + + +y +o +u + +w +a +n +t + + +a +n +y + + + r e @@ -1562,13 +1547,13 @@ - - + + - - + + @@ -1591,133 +1576,120 @@
-. -e -p -y -t - - -r -o - - -t -n -i -r -p - - -e -s -a -e -l -P +P +l +e +a +s +e + +p +r +i +n +t + +o +r + +t +y +p +e +. - + -. -d -l -e -h -h -t -i -w - - -s -a -w - - -x -a -t - - -f -i - - -R -- -9 -9 -0 -1 - - -) -s -( -m -r -o -F - - -h -c -a -t -t -a - - -o -s -l -A +A +l +s +o + +a +t +t +a +c +h + +F +o +r +m +( +s +) + +1 +0 +9 +9 +- +R + +i +f + +t +a +x + +w +a +s + +w +i +t +h +h +e +l +d +. -. -e -r -e -h - - -2 -- -W - - -s -m -r -o -F - - -h -c -a -t -t -A +A +t +t +a +c +h + +F +o +r +m +s + +W +- +2 + +h +e +r +e +. - + @@ -1803,7 +1775,7 @@ e r - + @@ -1946,7 +1918,21 @@ - + + + + + + + + + + + + + + + @@ -1954,7 +1940,7 @@ - + F i @@ -2717,9 +2703,8 @@ 7 - - c + @@ -2760,20 +2745,6 @@ - - - - - - - - - - - - - - ( @@ -2992,18 +2963,13 @@ - -. - - - . - -. + +. @@ -3012,8 +2978,8 @@ - -. + +. @@ -3022,8 +2988,8 @@ - - + +. @@ -3032,16 +2998,17 @@ - - - -1 -0 -a + + - + + + +1 +0 +a @@ -3050,97 +3017,80 @@ 1 - - 1 + 1 - - 2 + 1 - - 3 + 1 - - 4 + 1 - - 5 + - + 1 6 b - - - - - + 1 7 b - - - - 1 - - 8 + 1 - - 9 + 2 - - 0 + 2 - - 1 + @@ -3148,9 +3098,8 @@ 2 - - 3 + @@ -3158,17 +3107,15 @@ 3 - - 4 + 3 - - 5 + @@ -3185,42 +3132,35 @@ - - - + + + - - - + + + - - - - - - - - + - + - + @@ -3228,87 +3168,16 @@ - - - - - - - - - - + 9 - - b + - - - - - - - - - - - -8 - - - - - - - - - -9 - - -a - - - - -b - - - - - - - - - -1 -0 -a - - - - - - - - - -b - - - - - - - - - - + T o @@ -3521,14 +3390,10 @@ - + 1 0 b - - - - @@ -3587,9 +3452,8 @@ 1 - - 1 + @@ -3700,9 +3564,8 @@ 1 - - 2 + @@ -3822,9 +3685,8 @@ 1 - - 3 + @@ -3911,9 +3773,8 @@ 1 - - 4 + @@ -4036,9 +3897,8 @@ 1 - - 5 + @@ -4100,17 +3960,19 @@ - + 1 6 b + - + 1 6 a + @@ -4172,16 +4034,6 @@ - - - - - - - - - - @@ -4204,17 +4056,19 @@ - + 1 7 b + - + 1 7 a + @@ -4282,16 +4136,6 @@ - - - - - - - - - - @@ -4309,9 +4153,8 @@ 1 - - 8 + @@ -4419,9 +4262,8 @@ 1 - - 9 + @@ -4496,9 +4338,8 @@ 2 - - 0 + @@ -4539,9 +4380,8 @@ 2 - - 1 + @@ -4607,17 +4447,15 @@ 2 - - 2 + 2 - - 2 + @@ -4692,13 +4530,12 @@ 2 - - 3 + - + A d d @@ -4806,6 +4643,8 @@ o m e + + @@ -4814,19 +4653,22 @@ + + + + + 2 - - 4 + 2 - - 4 + @@ -4871,17 +4713,15 @@ 2 - - 5 + 2 - - 5 + @@ -4947,17 +4787,15 @@ 2 - - 6 + 2 - - 6 + @@ -5004,9 +4842,8 @@ 2 - - 7 + @@ -5017,9 +4854,8 @@ 2 - - 7 + @@ -5080,9 +4916,8 @@ 2 - - 8 + @@ -5093,9 +4928,8 @@ 2 - - 8 + @@ -5166,17 +5000,15 @@ 2 - - 9 + 2 - - 9 + @@ -5228,9 +5060,8 @@ 3 - - 0 + @@ -5241,9 +5072,8 @@ 3 - - 0 + @@ -5299,9 +5129,8 @@ 3 - - 1 + @@ -5347,17 +5176,15 @@ 3 - - 1 + 3 - - 2 + @@ -5368,9 +5195,8 @@ 3 - - 2 + @@ -5431,9 +5257,8 @@ 3 - - 3 + @@ -5444,9 +5269,8 @@ 3 - - 3 + @@ -5525,9 +5349,8 @@ 3 - - 4 + @@ -5564,13 +5387,12 @@ 3 - - 5 + - + S u b @@ -5679,6 +5501,8 @@ o m e + + @@ -5687,6 +5511,11 @@ + + + + + F o @@ -5807,173 +5636,214 @@ - + -s -s -e -n -i -s -u -B -/ -e -d -a -r -T - - -. -S -. -U - - -h -t -i -W - - -d -e -t -c -e -n -n -o -C - - -y -l -e -v -i -t -c -e -f -f -E - - -e -m -o -c -n -I +I +n +c +o +m +e + +E +f +f +e +c +t +i +v +e +l +y + +C +o +n +n +e +c +t +e +d + +W +i +t +h + +U +. +S +. + +T +r +a +d +e +/ +B +u +s +i +n +e +s +s - + -. -t -n -e -m -y -a -p - - -y -n -a - - -, -h -c -a -t -t -a - - -t -o -n - - -o -d - - -t -u -b - - -, -e -s -o -l -c -n -E +E +n +c +l +o +s +e +, + +b +u +t + +d +o + +n +o +t + +a +t +t +a +c +h +, + +a +n +y + +p +a +y +m +e +n +t +. - + + +8 + + + + + + + + + +9 +a + + + + + +b + + + + + + + + + +1 +0 +a + + + + + +b + + + + + + + + + + -e -m -o -c -n -I - - -s -s -o -r -G - - -d -e -t -s -u -j -d -A +A +d +j +u +s +t +e +d + +G +r +o +s +s + +I +n +c +o +m +e - - - - - - - - - - - - - - - + - + + + + + + + + + + + + + + + + + + + + + + F o @@ -6240,14 +6110,14 @@ + + - - + + - - @@ -6272,38 +6142,33 @@ - - - - - - + - + - + - + - + - + + + + + + + + - - - - - - - - + @@ -6311,11 +6176,13 @@ - + - + - + + + @@ -6323,10 +6190,7 @@ - - - - + diff --git a/samples/nonfree/i1040nr.html.ref b/samples/nonfree/i1040nr.html.ref index 530b77e..fda6c83 100644 --- a/samples/nonfree/i1040nr.html.ref +++ b/samples/nonfree/i1040nr.html.ref @@ -3,5685 +3,192 @@ - - -P -A -G -E -R -/ -S -G -M -L - -P -a -g -e - -1 - -o -f - -4 -8 - - -_ -_ -_ -_ -_ -_ -_ -_ - - -L -e -a -d -p -c -t -: - -0 -% - - -D -T -D - -I -N -S -T -R -0 -4 - - -P -t -. - -s -i -z -e -: - -9 -. -5 - -D -r -a -f -t - -U -s -e -r -i -d -: - -( -I -n -i -t -. - -& - -d -a -t -e -) - -F -i -l -e -i -d -: - -D -: -\ -U -S -E -R -S -\ -8 -f -l -l -b -\ -d -o -c -u -m -e -n -t -s -\ -e -p -i -c -f -i -l -e -s -\ -2 -0 -0 -7 -I -n -s -t -r -u -c -t -i -o -n -s -1 -0 -4 -0 -N -R -. -s -g -m - -7 -: -4 -8 - -- - - -6 -- -D -E -C -- -2 -0 -0 -7 - -I -n -s -t -r -u -c -t -i -o -n -s - -f -o -r - -F -o -r -m - -1 -0 -4 -0 -N -R - - - -O -k - -t -o - -P -r -i -n -t - - -T -h -e - -t -y -p -e - -a -n -d - -r -u -l -e - -a -b -o -v -e - -p -r -i -n -t -s - -o -n - -a -l -l - -p -r -o -o -f -s - -i -n -c -l -u -d -i -n -g - -d -e -p -a -r -t -m -e -n -t -a -l - -r -e -p -r -o -d -u -c -t -i -o -n - -p -r -o -o -f -s -. - -M -U -S -T - -b -e - -r -e -m -o -v -e -d - -b -e -f -o -r -e - -p -r -i -n -t -i -n -g -. - - -2 -0 -0 -7 - -I -n -s -t -r -u -c -t -i -o -n -s - -f -o -r - -F -o -r -m - -1 -0 -4 -0 -N -R - -U -. -S -. - -N -o -n -r -e -s -i -d -e -n -t - -A -l -i -e -n - -I -n -c -o -m -e - -T -a -x - -R -e -t -u -r -n - - -D -e -p -a -r -t -m -e -n -t - -o -f - -t -h -e - -T -r -e -a -s -u -r -y - -I -n -t -e -r -n -a -l - -R -e -v -e -n -u -e - -S -e -r -v -i -c -e - - -r -e -t -i -r -e -m -e -n -t - -p -l -a -n - -a -n -d - -y -o -u -r - -2 -0 -0 -8 - -m -o -d -i -f -i -e -d - -A -G -I - -i -s - -l -e -s -s - -t -h -a -n - -$ -6 -3 -, -0 -0 -0 - -( -$ -1 -0 -5 -, -0 -0 -0 -) - -i -f - -a - -q -u -a -l -i -f -y -i -n -g - -w -i -d -o -w -( -e -r -) -) -. - - -Y -o -u - -m -a -y - -b -e - -a -b -l -e - -t -o - -d -e -d -u -c -t - -u -p - -t -o - -a -n - -a -d -d -i -t -i -o -n -a -l - -$ -3 -, -0 -0 -0 - -i -f - -y -o -u - -w -e -r -e - -a - -p -a -r -t -i -c -i -p -a -n -t - -i -n - -a - -4 -0 -1 -( -k -) - -p -l -a -n - -a -n -d - -y -o -u -r - -e -m -p -l -o -y -e -r - -w -a -s - -i -n - -b -a -n -k -r -u -p -t -c -y - -i -n - -a -n - -e -a -r -l -i -e -r - -y -e -a -r -. - -P -e -r -s -o -n -a -l - -e -x -e -m -p -t -i -o -n - -a -n -d - -i -t -e -m -i -z -e -d - -d -e -d -u -c -t -i -o -n - -p -h -a -s -e -o -u -t -s - -r -e -d -u -c -e -d -. - -T -a -x -p -a -y -e -r -s - -w -i -t -h - -a -d -j -u -s -t -e -d - -g -r -o -s -s - -i -n -c -o -m -e - -a -b -o -v -e - -a - -c -e -r -t -a -i -n - -a -m -o -u -n -t - -m -a -y - -l -o -s -e - -p -a -r -t - -o -f - -t -h -e -i -r - -d -e -d -u -c -t -i -o -n - -f -o -r - -p -e -r -s -o -n -a -l - -e -x -e -m -p -t -i -o -n -s - -a -n -d - -i -t -e -m -i -z -e -d - -d -e -d -u -c -t -i -o -n -s -. - -T -h -e - -a -m -o -u -n -t - -b -y - -w -h -i -c -h - -t -h -e -s -e - -d -e -d -u -c -t -i -o -n -s - -a -r -e - -r -e -d -u -c -e -d - -i -n - -2 -0 -0 -8 - -w -i -l -l - -b -e - -o -n -l -y - -1 -/ -2 - -o -f - -t -h -e - -a -m -o -u -n -t - -o -f - -t -h -e - -r -e -d -u -c -t -i -o -n - -t -h -a -t - -o -t -h -e -r -w -i -s -e - -w -o -u -l -d - -h -a -v -e - -a -p -p -l -i -e -d - -i -n - -2 -0 -0 -7 -. - -C -a -p -i -t -a -l - -g -a -i -n - -t -a -x - -r -a -t -e - -r -e -d -u -c -e -d -. - - -T -h -e - -5 -% - -c -a -p -i -t -a -l - -g -a -i -n - -t -a -x - -r -a -t -e - -i -s - -r -e -d -u -c -e -d - -t -o - -z -e -r -o -. - -T -a -x - -o -n - -c -h -i -l -d -r -e -n - -s - -i -n -c -o -m -e -. - - -F -o -r -m - -8 -6 -1 -5 - -w -i -l -l - -b -e - -r -e -q -u -i -r -e -d - -t -o - -f -i -g -u -r -e - -t -h -e - -t -a -x - -f -o -r - -t -h -e - -f -o -l -l -o -w -i -n -g - -c -h -i -l -d -r -e -n - -w -i -t -h - -i -n -v -e -s -t -m -e -n -t - -i -n -c -o -m -e - -o -f - -m -o -r -e - -t -h -a -n - -$ -1 -, -8 -0 -0 -. - -1 -. -C -h -i -l -d -r -e -n - -u -n -d -e -r - -a -g -e - -1 -8 - -a -t - -t -h -e - -e -n -d - -o -f - -2 -0 -0 -8 -. - -2 -. -T -h -e - -f -o -l -l -o -w -i -n -g - -c -h -i -l -d -r -e -n - -i -f - -t -h -e -i -r - -e -a -r -n -e -d - -i -n -c -o -m -e - -i -s - -n -o -t - -m -o -r -e - -t -h -a -n - -h -a -l -f - -t -h -e -i -r - -s -u -p -p -o -r -t -. - -a -. -C -h -i -l -d -r -e -n - -a -g -e - -1 -8 - -a -t - -t -h -e - -e -n -d - -o -f - -2 -0 -0 -8 -. - -b -. -C -h -i -l -d -r -e -n - -o -v -e -r - -a -g -e - -1 -8 - -a -n -d - -u -n -d -e -r - -a -g -e - -2 -4 - -a -t - -t -h -e - -e -n -d - -o -f - -2 -0 -0 -8 - -w -h -o - -a -r -e - -f -u -l -l -- -t -i -m -e - -s -t -u -d -e -n -t -s -. - -T -h -e - -e -l -e -c -t -i -o -n - -t -o - -r -e -p -o -r -t - -a - -c -h -i -l -d - -s - -i -n -v -e -s -t -m -e -n -t - -i -n -c -o -m -e - -o -n - -a - -p -a -r -e -n -t - -s - -r -e -t -u -r -n - -a -n -d - -t -h -e - -s -p -e -c -i -a -l - -r -u -l -e - -f -o -r - -w -h -e -n - -a - -c -h -i -l -d - -m -u -s -t - -f -i -l -e - -F -o -r -m - -6 -2 -5 -1 - -w -i -l -l - -a -l -s -o - -a -p -p -l -y - -t -o - -t -h -e - -c -h -i -l -d -r -e -n - -l -i -s -t -e -d - -a -b -o -v -e -. - -E -x -p -i -r -i -n -g - -t -a -x - -b -e -n -e -f -i -t -s -. - -T -h -e - -f -o -l -l -o -w -i -n -g - -b -e -n -e -f -i -t -s - -a -r -e - -s -c -h -e -d -u -l -e -d - -t -o - -e -x -p -i -r -e - -a -n -d - -w -i -l -l - -n -o -t - -a -p -p -l -y - -f -o -r - -2 -0 -0 -8 -. - - -D -e -d -u -c -t -i -o -n - -f -o -r - -e -d -u -c -a -t -o -r - -e -x -p -e -n -s -e -s - -i -n - -f -i -g -u -r -i -n -g - -a -d -j -u -s -t -e -d - -g -r -o -s -s - -i -n -c -o -m -e -. - - -T -h -e - -e -x -c -l -u -s -i -o -n - -f -r -o -m - -i -n -c -o -m -e - -o -f - -q -u -a -l -i -f -i -e -d - -c -h -a -r -i -t -a -b -l -e - -d -e -d -u -c -t -i -o -n -s -. - - -C -r -e -d -i -t - -f -o -r - -n -o -n -b -u -s -i -n -e -s -s - -e -n -e -r -g -y - -p -r -o -p -e -r -t -y -. - - -D -i -s -t -r -i -c -t - -o -f - -C -o -l -u -m -b -i -a - -f -i -r -s -t -- -t -i -m -e - -h -o -m -e -b -u -y -e -r - -c -r -e -d -i -t - -( -f -o -r - -h -o -m -e -s - -p -u -r -c -h -a -s -e -d - -a -f -t -e -r - -2 -0 -0 -7 -) -. - - -S -e -c -t -i -o -n - -r -e -f -e -r -e -n -c -e -s - -a -r -e - -t -o - -t -h -e - -I -n -t -e -r -n -a -l - -R -e -v -e -n -u -e - -C -o -d -e - -u -n -l -e -s -s - -o -t -h -e -r -w -i -s -e - -n -o -t -e -d -. - -G -e -n -e -r -a -l - -I -n -s -t -r -u -c -t -i -o -n -s - -W -h -a -t - -s - -N -e -w - -f -o -r - -2 -0 -0 -7 - -T -a -x - -b -e -n -e -f -i -t -s - -e -x -t -e -n -d -e -d -. - -T -h -e - -f -o -l -l -o -w -i -n -g - -t -a -x - -b -e -n -e -f -i -t -s - -w -e -r -e - -e -x -t -e -n -d -e -d - -t -h -r -o -u -g -h - -2 -0 -0 -7 -. - - -D -e -d -u -c -t -i -o -n - -f -o -r - -e -d -u -c -a -t -o -r - -e -x -p -e -n -s -e -s - -i -n - -f -i -g -u -r -i -n -g - -a -d -j -u -s -t -e -d - -g -r -o -s -s - -i -n -c -o -m -e -. - - -D -i -s -t -r -i -c -t - -o -f - -C -o -l -u -m -b -i -a - -f -i -r -s -t -- -t -i -m -e - -h -o -m -e -b -u -y -e -r - -c -r -e -d -i -t -. - -A -l -t -e -r -n -a -t -i -v -e - -m -i -n -i -m -u -m - -t -a -x - -( -A -M -T -) - -e -x -e -m -p -t -i -o -n - -a -m -o -u -n -t - -d -e -c -r -e -a -s -e -d -. - -T -h -e - -A -M -T - -e -x -e -m -p -t -i -o -n - -a -m -o -u -n -t - -i -s - -d -e -c -r -e -a -s -e -d - -t -o - -$ -3 -3 -, -7 -5 -0 - -( -$ -4 -5 -, -0 -0 -0 - -i -f - -a - -q -u -a -l -i -f -y -i -n -g - -w -i -d -o -w -( -e -r -) -; - -$ -2 -2 -, -5 -0 -0 - -i -f - -m -a -r -r -i -e -d - -f -i -l -i -n -g - -s -e -p -a -r -a -t -e -l -y -) -. - -A -t - -t -h -e - -t -i -m -e - -t -h -e -s -e - -i -n -s -t -r -u -c -t -i -o -n -s - -! - -w -e -n -t - -t -o - -p -r -i -n -t -, - -C -o -n -g -r -e -s -s - -w -a -s - -c -o -n -s -i -d -e -r -i -n -g - -l -e -g -i -s -l -a -t -i -o -n - -t -h -a -t - -C -A -U -T -I -O -N - -w -o -u -l -d - -i -n -c -r -e -a -s -e - -t -h -e - -a -m -o -u -n -t -s - -a -b -o -v -e -. - -T -o - -f -i -n -d - -o -u -t - -i -f - -t -h -i -s - -l -e -g -i -s -l -a -t -i -o -n - -w -a -s - -e -n -a -c -t -e -d -, - -a -n -d - -f -o -r - -m -o -r -e - -d -e -t -a -i -l -s -, - -s -e -e - -t -h -e - -I -n -s -t -r -u -c -t -i -o -n -s - -f -o -r - -F -o -r -m - -6 -2 -5 -1 -. - -I -R -A - -d -e -d -u -c -t -i -o -n - -e -x -p -a -n -d -e -d -. - -I -f - -y -o -u - -w -e -r -e - -c -o -v -e -r -e -d - -b -y - -a - -r -e -t -i -r -e -m -e -n -t - -p -l -a -n -, - -y -o -u - -m -a -y - -b -e - -a -b -l -e - -t -o - -t -a -k -e - -a -n - -I -R -A - -d -e -d -u -c -t -i -o -n - -i -f - -y -o -u -r - -2 -0 -0 -7 - -m -o -d -i -f -i -e -d - -a -d -j -u -s -t -e -d - -g -r -o -s -s - -i -n -c -o -m -e - -( -A -G -I -) - -i -s - -l -e -s -s - -t -h -a -n - -$ -6 -2 -, -0 -0 -0 - -( -$ -1 -0 -3 -, -0 -0 -0 - -i -f - -a - -q -u -a -l -i -f -y -i -n -g - -w -i -d -o -w -( -e -r -) -) -. - -Y -o -u - -m -a -y - -b -e - -a -b -l -e - -t -o - -d -e -d -u -c -t - -u -p - -t -o - -a -n - -a -d -d -i -t -i -o -n -a -l - -$ -3 -, -0 -0 -0 - -i -f - -y -o -u - -w -e -r -e - -a - -p -a -r -t -i -c -i -p -a -n -t - -i -n - -a - -4 -0 -1 -( -k -) - -p -l -a -n - -a -n -d - -y -o -u -r - -e -m -p -l -o -y -e -r - -w -a -s - -i -n - -b -a -n -k -r -u -p -t -c -y - -i -n - -a -n - -e -a -r -l -i -e -r - -y -e -a -r -. - -S -t -a -n -d -a -r -d - -m -i -l -e -a -g -e - -r -a -t -e -s -. - -T -h -e - -2 -0 -0 -7 - -r -a -t -e - -f -o -r - -b -u -s -i -n -e -s -s - -u -s -e - -o -f - -y -o -u -r - -v -e -h -i -c -l -e - -i -s - -4 -8 -1 -/ -2 - -c -e -n -t -s - -a - -m -i -l -e -. - -T -h -e - -2 -0 -0 -7 - -r -a -t -e - -f -o -r - -u -s -e - -o -f - -y -o -u -r - -v -e -h -i -c -l -e - -t -o - -m -o -v -e - -i -s - -2 -0 - -c -e -n -t -s - -a - -m -i -l -e -. - -T -h -e - -s -p -e -c -i -a -l - -r -a -t -e - -f -o -r - -c -h -a -r -i -t -a -b -l -e - -u -s -e - -o -f - -y -o -u -r - -v -e -h -i -c -l -e - -t -o - -p -r -o -v -i -d -e - -r -e -l -i -e -f - -r -e -l -a -t -e -d - -t -o - -H -u -r -r -i -c -a -n -e - -K -a -t -r -i -n -a - -h -a -s - -e -x -p -i -r -e -d -. - -E -l -e -c -t -i -v -e - -s -a -l -a -r -y - -d -e -f -e -r -r -a -l -s -. - -T -h -e - -m -a -x -i -m -u -m - -a -m -o -u -n -t - -y -o -u - -c -a -n - -d -e -f -e -r - -u -n -d -e -r - -a -l -l - -p -l -a -n -s - -i -s - -g -e -n -e -r -a -l -l -y - -l -i -m -i -t -e -d - -t -o - -$ -1 -5 -, -5 -0 -0 - -( -$ -1 -0 -, -5 -0 -0 - -i -f - -y -o -u - -o -n -l -y - -h -a -v -e - -S -I -M -P -L -E - -p -l -a -n -s -; - -$ -1 -8 -, -5 -0 -0 - -f -o -r - -s -e -c -t -i -o -n - -4 -0 -3 -( -b -) - -p -l -a -n -s - -i -f - -y -o -u - -q -u -a -l -i -f -y - -f -o -r - -t -h -e - -1 -5 -- -y -e -a -r - -r -u -l -e -) -. - -S -e -e - -t -h -e - -i -n -s -t -r -u -c -t -i -o -n -s - -f -o -r - -l -i -n -e - -8 - -o -n - -p -a -g -e - -1 -0 -. - -M -a -i -l -i -n -g - -y -o -u -r - -r -e -t -u -r -n -. - - -I -f - -y -o -u - -a -r -e - -f -i -l -i -n -g - -t -h -e - -r -e -t -u -r -n - -f -o -r - -a -n - -e -s -t -a -t -e - -o -r - -t -r -u -s -t -, - -y -o -u - -w -i -l -l - - -u -s -e - -a - -d -i -f -f -e -r -e -n -t - -a -d -d -r -e -s -s - -t -h -i -s - -y -e -a -r -. - -S -e -e - -W -h -e -r -e - -T -o - -F -i -l -e - -o -n - -p -a -g -e - -4 -. - -D -o -m -e -s -t -i -c - -p -r -o -d -u -c -t -i -o -n - -a -c -t -i -v -i -t -i -e -s - -d -e -d -u -c -t -i -o -n -. - -T -h -e - -d -e -d -u -c -t -i -o -n - -r -a -t -e - -f -o -r - -2 -0 -0 -7 - -i -s - -i -n -c -r -e -a -s -e -d - -t -o - -6 -% -. - -U -n -r -e -p -o -r -t -e -d - -s -o -c -i -a -l - -s -e -c -u -r -i -t -y - -a -n -d - -M -e -d -i -c -a -r -e - -t -a -x - -o -n - -w -a -g -e -s -. - - -I -f - -y -o -u - -a -r -e - -a -n - -e -m -p -l -o -y -e -e - -a -n -d - -y -o -u -r - -e -m -p -l -o -y -e -r - -d -i -d - -n -o -t - -w -i -t -h -h -o -l -d - -s -o -c -i -a -l - -s -e -c -u -r -i -t -y - -a -n -d - -M -e -d -i -c -a -r -e - -t -a -x -, - -s -e -e - -F -o -r -m - -8 -9 -1 -9 - -t -o - -f -i -g -u -r -e - -a -n -d - -r -e -p -o -r -t - -t -h -i -s - -t -a -x -. - -R -e -f -u -n -d -a -b -l -e - -c -r -e -d -i -t - -f -o -r - -p -r -i -o -r -- -y -e -a -r - -m -i -n -i -m -u -m - -t -a -x -. - -I -f - -y -o -u - -h -a -v -e - -a -n - -u -n -u -s -e -d - -m -i -n -i -m -u -m - -t -a -x - -c -r -e -d -i -t - -c -a -r -r -y -f -o -r -w -a -r -d - -f -r -o -m - -2 -0 -0 -4 -, - -s -e -e - -F -o -r -m - -8 -8 -0 -1 - -t -o - -f -i -n -d - -i -f - -y -o -u - -c -a -n - -t -a -k -e - -t -h -i -s - -c -r -e -d -i -t -. - -H -e -a -l -t -h - -s -a -v -i -n -g -s - -a -c -c -o -u -n -t - -( -H -S -A -) - -f -u -n -d -i -n -g - -d -i -s -t -r -i -b -u -t -i -o -n -s -. - -Y -o -u - -m -a -y - -b -e - -a -b -l -e - -t -o - -e -l -e -c -t - -t -o - -e -x -c -l -u -d -e - -f -r -o -m - -i -n -c -o -m -e - -a - -d -i -s -t -r -i -b -u -t -i -o -n - -m -a -d -e - -f -r -o -m - -y -o -u -r - -I -R -A - -t -o - -y -o -u -r - -H -S -A -. - -S -e -e - -t -h -e - -i -n -s -t -r -u -c -t -i -o -n -s - -f -o -r - -l -i -n -e -s - -1 -6 -a - -a -n -d - -1 -6 -b - -b -e -g -i -n -n -i -n -g - -o -n - -p -a -g -e - -1 -2 -. - -N -e -w - -r -e -c -o -r -d -k -e -e -p -i -n -g - -r -e -q -u -i -r -e -m -e -n -t -s - -f -o -r - -c -o -n -t -r -i -b -u -t -i -o -n -s - -o -f - -m -o -n -e -y -. - - -F -o -r - -c -h -a -r -i -t -a -b -l -e - -c -o -n -t -r -i -b -u -t -i -o -n -s - -o -f - -m -o -n -e -y -, - -r -e -g -a -r -d -l -e -s -s - -o -f - -t -h -e - -a -m -o -u -n -t -, - -y -o -u - -m -u -s -t - -m -a -i -n -t -a -i -n - -a -s - -a - -r -e -c -o -r -d - -o -f - -t -h -e - -c -o -n -t -r -i -b -u -t -i -o -n - -a - -b -a -n -k - -r -e -c -o -r -d - -( -s -u -c -h - -a -s - -a - -c -a -n -c -e -l -l -e -d - -c -h -e -c -k -) - -o -r - -a - -w -r -i -t -t -e -n - -r -e -c -o -r -d - -f -r -o -m - -t -h -e - -c -h -a -r -i -t -y -. - -T -h -e - -w -r -i -t -t -e -n - -r -e -c -o -r -d - -m -u -s -t - -i -n -c -l -u -d -e - -t -h -e - -n -a -m -e - -o -f - -t -h -e - -c -h -a -r -i -t -y -, - -d -a -t -e -, - -a -n -d - -a -m -o -u -n -t - -o -f - -t -h -e - -c -o -n -t -r -i -b -u -t -i -o -n -. - -S -e -e - -G -i -f -t -s - -t -o - -U -. -S -. - -C -h -a -r -i -t -i -e -s - -t -h -a -t - -b -e -g -i -n -s - -o -n - -p -a -g -e - -2 -6 -. - -E -x -e -m -p -t -i -o -n - -f -o -r - -h -o -u -s -i -n -g - -a - -p -e -r -s -o -n - -d -i -s -p -l -a -c -e -d - -b -y - -H -u -r -r -i -c -a -n -e - -K -a -t -r -i -n -a - -e -x -p -i -r -e -s -. - -T -h -e - -a -d -d -i -t -i -o -n -a -l - -e -x -e -m -p -t -i -o -n - -a -m -o -u -n -t - -f -o -r - -h -o -u -s -i -n -g - -a - -p -e -r -s -o -n - -d -i -s -p -l -a -c -e -d - -b -y - -H -u -r -r -i -c -a -n -e - -K -a -t -r -i -n -a - -d -o -e -s - -n -o -t - -a -p -p -l -y - -f -o -r - -2 -0 -0 -7 - -o -r - -l -a -t -e -r - -y -e -a -r -s -. - -T -e -l -e -p -h -o -n -e - -e -x -c -i -s -e - -t -a -x - -c -r -e -d -i -t -. - - -T -h -i -s - -c -r -e -d -i -t - -w -a -s - -a -v -a -i -l -a -b -l -e - -o -n -l -y - -o -n - -y -o -u -r - -2 -0 -0 -6 - -r -e -t -u -r -n -. - -I -f - -y -o -u - -f -i -l -e -d - -b -u -t - -d -i -d - -n -o -t - -r -e -q -u -e -s -t - -i -t - -o -n - -y -o -u -r - -2 -0 -0 -6 - -r -e -t -u -r -n -, - -f -i -l -e - -F -o -r -m - -1 -0 -4 -0 -X - -u -s -i -n -g - -a - -s -i -m -p -l -i -f -i -e -d - -p -r -o -c -e -d -u -r -e - -e -x -p -l -a -i -n -e -d - -i -n - -i -t -s - -i -n -s -t -r -u -c -t -i -o -n -s - -t -o - -a -m -e -n -d - -y -o -u -r - -2 -0 -0 -6 - -r -e -t -u -r -n -. - -I -f - -y -o -u - -w -e -r -e - -n -o -t - -r -e -q -u -i -r -e -d - -t -o - -f -i -l -e - -a - -2 -0 -0 -6 - -r -e -t -u -r -n -, - -s -e -e - -t -h -e - -2 -0 -0 -6 - -F -o -r -m - -1 -0 -4 -0 -E -Z -- -T -. - -W -h -a -t - -s - -N -e -w - -f -o -r - -2 -0 -0 -8 - -I -R -A - -d -e -d -u -c -t -i -o -n - -e -x -p -a -n -d -e -d -. - -Y -o -u - -m -a -y - -b -e - -a -b -l -e - -t -o - -d -e -d -u -c -t - -u -p - -t -o - -$ -5 -, -0 -0 -0 - -( -$ -6 -, -0 -0 -0 - -i -f - -a -g -e - -5 -0 - -o -r - -o -l -d -e -r - -a -t - -t -h -e - -e -n -d - -o -f - -t -h -e - -y -e -a -r -) -. - -Y -o -u - -m -a -y - -b -e - -a -b -l -e - -t -o - -t -a -k -e - -a -n - -I -R -A - -d -e -d -u -c -t -i -o -n - -i -f - -y -o -u - -w -e -r -e - -c -o -v -e -r -e -d - -b -y - -a - - -C -a -t -. - -N -o -. - -1 -1 -3 -6 -8 -V - +
Leadpct: 0% Pt. size: 9.5 Draft +
Userid: ________ DTD INSTR04 +
PAGER/SGML +
(Init. & date) +
Fileid: +
D:\USERS\8fllb\documents\epicfiles\2007Instructions1040NR.sgm +
Page 1 of 48 Instructions for Form 1040NR +
7:48 - 6-DEC-2007 +
Ok to Print +
The type and rule above prints on all proofs including departmental reproduction proofs. MUST be removed before printing. +
2007 +
Instructions for +
Form 1040NR +
U.S. Nonresident Alien Income Tax Return +
Department of the Treasury +
Internal Revenue Service +
use a different address this year. See +
Section references are to the Internal +
Where To File on page 4. +
Revenue Code unless otherwise noted. +
General Instructions deduction. The deduction rate for +
Domestic production activities +
2007 is increased to 6%. +
What’s New for 2007 +
Unreported social security and +
Medicare tax on wages. +
If you are +
Tax benefits extended. The following +
an employee and your employer did not +
tax benefits were extended through +
withhold social security and Medicare +
2007. +
Deduction for educator expenses in +
tax, see Form 8919 to figure and report +
this tax. +
figuring adjusted gross income. +
District of Columbia first-time +
Refundable credit for prior-year +
minimum tax. +
If you have an unused +
homebuyer credit. +
minimum tax credit carryforward from +
Alternative minimum tax (AMT) +
2004, see Form 8801 to find if you can +
exemption amount decreased. The +
take this credit. +
AMT exemption amount is decreased to +
Health savings account (HSA) +
$33,750 ($45,000 if a qualifying +
funding distributions. You may be +
widow(er); $22,500 if married filing +
able to elect to exclude from income a +
separately). +
distribution made from your IRA to your +
At the time these instructions +
HSA. See the instructions for lines 16a +
! +
went to print, Congress was +
and 16b beginning on page 12. +
considering legislation that +
CAUTION +
New recordkeeping requirements for +
would increase the amounts above. To +
contributions of money. +
For +
find out if this legislation was enacted, +
charitable contributions of money, +
and for more details, see the +
regardless of the amount, you must +
Instructions for Form 6251. +
maintain as a record of the contribution +
IRA deduction expanded. +
If you were +
a bank record (such as a cancelled +
covered by a retirement plan, you may +
check) or a written record from the +
be able to take an IRA deduction if your +
charity. The written record must include +
2007 modified adjusted gross income +
the name of the charity, date, and +
(AGI) is less than $62,000 ($103,000 if +
amount of the contribution. See
Gifts to +
a qualifying widow(er)). +
U.S. Charities that begins on page 26. +
You may be able to deduct up to an +
Exemption for housing a person +
additional $3,000 if you were a +
displaced by Hurricane Katrina +
participant in a 401(k) plan and your +
expires. The additional exemption +
employer was in bankruptcy in an +
amount for housing a person displaced +
earlier year. +
by Hurricane Katrina does not apply for +
2007 or later years. +
Standard mileage rates. The 2007 +
Telephone excise tax credit. +
rate for business use of your vehicle is +
This +
48
1/2 cents a mile. The 2007 rate for +
credit was available only on your 2006 +
use of your vehicle to move is 20 cents +
return. If you filed but did not request it +
a mile. The special rate for charitable +
on your 2006 return, file Form 1040X +
use of your vehicle to provide relief +
using a simplified procedure explained +
related to Hurricane Katrina has +
in its instructions to amend your 2006 +
expired. +
return. If you were not required to file a +
2006 return, see the 2006 Form +
Elective salary deferrals. The +
1040EZ-T. +
maximum amount you can defer under +
all plans is generally limited to $15,500 +
What’s New for 2008 +
($10,500 if you only have SIMPLE +
plans; $18,500 for section 403(b) plans +
IRA deduction expanded. You may +
if you qualify for the 15-year rule). See +
be able to deduct up to $5,000 ($6,000 +
the instructions for line 8 on page 10. +
if age 50 or older at the end of the +
Mailing your return. +
If you are filing +
year). You may be able to take an IRA +
deduction if you were covered by a +
the return for an estate or trust, you will +
Cat. No. 11368V +
retirement plan and your 2008 modified +
AGI is less than $63,000 ($105,000) if a +
qualifying widow(er)). +
You may be able to deduct up to an +
additional $3,000 if you were a +
participant in a 401(k) plan and your +
employer was in bankruptcy in an +
earlier year. +
Personal exemption and itemized +
deduction phaseouts reduced. +
Taxpayers with adjusted gross income +
above a certain amount may lose part +
of their deduction for personal +
exemptions and itemized deductions. +
The amount by which these deductions +
are reduced in 2008 will be only
1/2 of +
the amount of the reduction that +
otherwise would have applied in 2007. +
Capital gain tax rate reduced. +
The +
5% capital gain tax rate is reduced to +
zero. +
Tax on children’s income. +
Form +
8615 will be required to figure the tax +
for the following children with +
investment income of more than +
$1,800. +
1. Children under age 18 at the end +
of 2008. +
2. The following children if their +
earned income is not more than half +
their support. +
a. Children age 18 at the end of +
2008. +
b. Children over age 18 and under +
age 24 at the end of 2008 who are +
full-time students. +
The election to report a child’s +
investment income on a parent’s return +
and the special rule for when a child +
must file Form 6251 will also apply to +
the children listed above. +
Expiring tax benefits. The following +
benefits are scheduled to expire and +
will not apply for 2008. +
Deduction for educator expenses in +
figuring adjusted gross income. +
The exclusion from income of +
qualified charitable deductions. +
Credit for nonbusiness energy +
property. +
District of Columbia first-time +
homebuyer credit (for homes +
purchased after 2007). +
diff --git a/samples/nonfree/i1040nr.txt.ref b/samples/nonfree/i1040nr.txt.ref index 910d782..3d8a05c 100644 --- a/samples/nonfree/i1040nr.txt.ref +++ b/samples/nonfree/i1040nr.txt.ref @@ -1,19 +1,11 @@ +Leadpct: 0% Pt. size: 9.5 ❏ Draft +Userid: ________ DTD INSTR04 PAGER/SGML -Page 1 of 48 - -________ - -Leadpct: 0% - -DTD INSTR04 - -Pt. size: 9.5 ❏ Draft -Userid: (Init. & date) Fileid: D:\USERS\8fllb\documents\epicfiles\2007Instructions1040NR.sgm +Page 1 of 48 Instructions for Form 1040NR 7:48 - 6-DEC-2007 -Instructions for Form 1040NR ❏ Ok to Print @@ -27,6 +19,122 @@ U.S. Nonresident Alien Income Tax Return Department of the Treasury Internal Revenue Service +use a different address this year. See +Section references are to the Internal +Where To File on page 4. +Revenue Code unless otherwise noted. +General Instructions deduction. The deduction rate for +Domestic production activities +2007 is increased to 6%. +What’s New for 2007 +Unreported social security and +Medicare tax on wages. + If you are +Tax benefits extended. The following +an employee and your employer did not +tax benefits were extended through +withhold social security and Medicare +2007. +• Deduction for educator expenses in +tax, see Form 8919 to figure and report +this tax. +figuring adjusted gross income. +• District of Columbia first-time +Refundable credit for prior-year +minimum tax. +If you have an unused +homebuyer credit. +minimum tax credit carryforward from +Alternative minimum tax (AMT) +2004, see Form 8801 to find if you can +exemption amount decreased. The +take this credit. +AMT exemption amount is decreased to +Health savings account (HSA) +$33,750 ($45,000 if a qualifying +funding distributions. You may be +widow(er); $22,500 if married filing +able to elect to exclude from income a +separately). +distribution made from your IRA to your +At the time these instructions +HSA. See the instructions for lines 16a +! +went to print, Congress was +and 16b beginning on page 12. +considering legislation that +CAUTION +New recordkeeping requirements for +would increase the amounts above. To +contributions of money. + For +find out if this legislation was enacted, +charitable contributions of money, +and for more details, see the +regardless of the amount, you must +Instructions for Form 6251. +maintain as a record of the contribution +IRA deduction expanded. +If you were +a bank record (such as a cancelled +covered by a retirement plan, you may +check) or a written record from the +be able to take an IRA deduction if your +charity. The written record must include +2007 modified adjusted gross income +the name of the charity, date, and +(AGI) is less than $62,000 ($103,000 if +amount of the contribution. See Gifts to +a qualifying widow(er)). +U.S. Charities that begins on page 26. +You may be able to deduct up to an +Exemption for housing a person +additional $3,000 if you were a +displaced by Hurricane Katrina +participant in a 401(k) plan and your +expires. The additional exemption +employer was in bankruptcy in an +amount for housing a person displaced +earlier year. +by Hurricane Katrina does not apply for +2007 or later years. +Standard mileage rates. The 2007 +Telephone excise tax credit. +rate for business use of your vehicle is + This +481/2 cents a mile. The 2007 rate for +credit was available only on your 2006 +use of your vehicle to move is 20 cents +return. If you filed but did not request it +a mile. The special rate for charitable +on your 2006 return, file Form 1040X +use of your vehicle to provide relief +using a simplified procedure explained +related to Hurricane Katrina has +in its instructions to amend your 2006 +expired. +return. If you were not required to file a +2006 return, see the 2006 Form +Elective salary deferrals. The +1040EZ-T. +maximum amount you can defer under +all plans is generally limited to $15,500 +What’s New for 2008 +($10,500 if you only have SIMPLE +plans; $18,500 for section 403(b) plans +IRA deduction expanded. You may +if you qualify for the 15-year rule). See +be able to deduct up to $5,000 ($6,000 +the instructions for line 8 on page 10. +if age 50 or older at the end of the +Mailing your return. + If you are filing +year). You may be able to take an IRA +deduction if you were covered by a +the return for an estate or trust, you will + +Cat. No. 11368V + retirement plan and your 2008 modified AGI is less than $63,000 ($105,000) if a qualifying widow(er)). @@ -71,8 +179,7 @@ investment income on a parent’s return and the special rule for when a child must file Form 6251 will also apply to the children listed above. -Expiring tax benefits. -The following +Expiring tax benefits. The following benefits are scheduled to expire and will not apply for 2008. • Deduction for educator expenses in @@ -85,130 +192,4 @@ property. homebuyer credit (for homes purchased after 2007). -Section references are to the Internal -Revenue Code unless otherwise noted. -General Instructions -What’s New for 2007 -Tax benefits extended. -The following -tax benefits were extended through -2007. -• Deduction for educator expenses in -figuring adjusted gross income. -• District of Columbia first-time -homebuyer credit. -Alternative minimum tax (AMT) -exemption amount decreased. -The -AMT exemption amount is decreased to -$33,750 ($45,000 if a qualifying -widow(er); $22,500 if married filing -separately). -At the time these instructions -! -went to print, Congress was -considering legislation that -CAUTION -would increase the amounts above. To -find out if this legislation was enacted, -and for more details, see the -Instructions for Form 6251. -IRA deduction expanded. -If you were -covered by a retirement plan, you may -be able to take an IRA deduction if your -2007 modified adjusted gross income -(AGI) is less than $62,000 ($103,000 if -a qualifying widow(er)). -You may be able to deduct up to an -additional $3,000 if you were a -participant in a 401(k) plan and your -employer was in bankruptcy in an -earlier year. -Standard mileage rates. -The 2007 -rate for business use of your vehicle is -481/2 cents a mile. The 2007 rate for -use of your vehicle to move is 20 cents -a mile. The special rate for charitable -use of your vehicle to provide relief -related to Hurricane Katrina has -expired. -Elective salary deferrals. -The -maximum amount you can defer under -all plans is generally limited to $15,500 -($10,500 if you only have SIMPLE -plans; $18,500 for section 403(b) plans -if you qualify for the 15-year rule). See -the instructions for line 8 on page 10. -Mailing your return. - If you are filing -the return for an estate or trust, you will - -use a different address this year. See -Where To File on page 4. -Domestic production activities -deduction. -The deduction rate for -2007 is increased to 6%. -Unreported social security and -Medicare tax on wages. - If you are -an employee and your employer did not -withhold social security and Medicare -tax, see Form 8919 to figure and report -this tax. -Refundable credit for prior-year -minimum tax. -If you have an unused -minimum tax credit carryforward from -2004, see Form 8801 to find if you can -take this credit. -Health savings account (HSA) -funding distributions. -You may be -able to elect to exclude from income a -distribution made from your IRA to your -HSA. See the instructions for lines 16a -and 16b beginning on page 12. -New recordkeeping requirements for -contributions of money. - For -charitable contributions of money, -regardless of the amount, you must -maintain as a record of the contribution -a bank record (such as a cancelled -check) or a written record from the -charity. The written record must include -the name of the charity, date, and -amount of the contribution. See Gifts to -U.S. Charities that begins on page 26. -Exemption for housing a person -displaced by Hurricane Katrina -expires. -The additional exemption -amount for housing a person displaced -by Hurricane Katrina does not apply for -2007 or later years. -Telephone excise tax credit. - This -credit was available only on your 2006 -return. If you filed but did not request it -on your 2006 return, file Form 1040X -using a simplified procedure explained -in its instructions to amend your 2006 -return. If you were not required to file a -2006 return, see the 2006 Form -1040EZ-T. -What’s New for 2008 -IRA deduction expanded. -You may -be able to deduct up to $5,000 ($6,000 -if age 50 or older at the end of the -year). You may be able to take an IRA -deduction if you were covered by a - -Cat. No. 11368V - \ No newline at end of file diff --git a/samples/nonfree/i1040nr.xml.ref b/samples/nonfree/i1040nr.xml.ref index f549584..7aad6ef 100644 --- a/samples/nonfree/i1040nr.xml.ref +++ b/samples/nonfree/i1040nr.xml.ref @@ -1,54 +1,8 @@ - - -P -A -G -E -R -/ -S -G -M -L - - - - -P -a -g -e - -1 - -o -f - -4 -8 - - - - - - -_ -_ -_ -_ -_ -_ -_ -_ - - - - - - + + L e a @@ -60,29 +14,7 @@ 0 % - - - - - - -D -T -D - -I -N -S -T -R -0 -4 - - - - - - + P t . @@ -107,7 +39,7 @@ - + U s e @@ -115,6 +47,41 @@ i d : + +_ +_ +_ +_ +_ +_ +_ +_ + +D +T +D + +I +N +S +T +R +0 +4 + + + + +P +A +G +E +R +/ +S +G +M +L @@ -212,29 +179,20 @@ - -7 -: -4 -8 - -- - - -6 -- -D -E -C -- -2 -0 -0 -7 - - - - + +P +a +g +e + +1 + +o +f + +4 +8 + I n s @@ -266,8 +224,30 @@ + +7 +: +4 +8 + +- + + +6 +- +D +E +C +- +2 +0 +0 +7 + + + - + @@ -286,7 +266,7 @@ - + T h @@ -413,7 +393,7 @@ - + 2 0 @@ -503,7 +483,7 @@ - + D e @@ -563,7 +543,3924 @@ - + + +u +s +e + +a + +d +i +f +f +e +r +e +n +t + +a +d +d +r +e +s +s + +t +h +i +s + +y +e +a +r +. + +S +e +e + + + + +S +e +c +t +i +o +n + +r +e +f +e +r +e +n +c +e +s + +a +r +e + +t +o + +t +h +e + +I +n +t +e +r +n +a +l + + + + +W +h +e +r +e + +T +o + +F +i +l +e + +o +n + +p +a +g +e + +4 +. + + + + +R +e +v +e +n +u +e + +C +o +d +e + +u +n +l +e +s +s + +o +t +h +e +r +w +i +s +e + +n +o +t +e +d +. + + + + +G +e +n +e +r +a +l + +I +n +s +t +r +u +c +t +i +o +n +s + +d +e +d +u +c +t +i +o +n +. + +T +h +e + +d +e +d +u +c +t +i +o +n + +r +a +t +e + +f +o +r + + + + +D +o +m +e +s +t +i +c + +p +r +o +d +u +c +t +i +o +n + +a +c +t +i +v +i +t +i +e +s + + + + +2 +0 +0 +7 + +i +s + +i +n +c +r +e +a +s +e +d + +t +o + +6 +% +. + + + + +W +h +a +t + +s + +N +e +w + +f +o +r + +2 +0 +0 +7 + + + + +U +n +r +e +p +o +r +t +e +d + +s +o +c +i +a +l + +s +e +c +u +r +i +t +y + +a +n +d + + + + +M +e +d +i +c +a +r +e + +t +a +x + +o +n + +w +a +g +e +s +. + + + + + +I +f + +y +o +u + +a +r +e + + + + +T +a +x + +b +e +n +e +f +i +t +s + +e +x +t +e +n +d +e +d +. + +T +h +e + +f +o +l +l +o +w +i +n +g + + + + +a +n + +e +m +p +l +o +y +e +e + +a +n +d + +y +o +u +r + +e +m +p +l +o +y +e +r + +d +i +d + +n +o +t + + + + +t +a +x + +b +e +n +e +f +i +t +s + +w +e +r +e + +e +x +t +e +n +d +e +d + +t +h +r +o +u +g +h + + + + +w +i +t +h +h +o +l +d + +s +o +c +i +a +l + +s +e +c +u +r +i +t +y + +a +n +d + +M +e +d +i +c +a +r +e + + + + +2 +0 +0 +7 +. + + + + + + +D +e +d +u +c +t +i +o +n + +f +o +r + +e +d +u +c +a +t +o +r + +e +x +p +e +n +s +e +s + +i +n + + + + +t +a +x +, + +s +e +e + +F +o +r +m + +8 +9 +1 +9 + +t +o + +f +i +g +u +r +e + +a +n +d + +r +e +p +o +r +t + + + + +t +h +i +s + +t +a +x +. + + + + +f +i +g +u +r +i +n +g + +a +d +j +u +s +t +e +d + +g +r +o +s +s + +i +n +c +o +m +e +. + + + + + + +D +i +s +t +r +i +c +t + +o +f + +C +o +l +u +m +b +i +a + +f +i +r +s +t +- +t +i +m +e + + + + +R +e +f +u +n +d +a +b +l +e + +c +r +e +d +i +t + +f +o +r + +p +r +i +o +r +- +y +e +a +r + + + + +m +i +n +i +m +u +m + +t +a +x +. + + + + +I +f + +y +o +u + +h +a +v +e + +a +n + +u +n +u +s +e +d + + + + +h +o +m +e +b +u +y +e +r + +c +r +e +d +i +t +. + + + + +m +i +n +i +m +u +m + +t +a +x + +c +r +e +d +i +t + +c +a +r +r +y +f +o +r +w +a +r +d + +f +r +o +m + + + + +A +l +t +e +r +n +a +t +i +v +e + +m +i +n +i +m +u +m + +t +a +x + +( +A +M +T +) + + + + +2 +0 +0 +4 +, + +s +e +e + +F +o +r +m + +8 +8 +0 +1 + +t +o + +f +i +n +d + +i +f + +y +o +u + +c +a +n + + + + +e +x +e +m +p +t +i +o +n + +a +m +o +u +n +t + +d +e +c +r +e +a +s +e +d +. + +T +h +e + + + + +t +a +k +e + +t +h +i +s + +c +r +e +d +i +t +. + + + + +A +M +T + +e +x +e +m +p +t +i +o +n + +a +m +o +u +n +t + +i +s + +d +e +c +r +e +a +s +e +d + +t +o + + + + +H +e +a +l +t +h + +s +a +v +i +n +g +s + +a +c +c +o +u +n +t + +( +H +S +A +) + + + + +$ +3 +3 +, +7 +5 +0 + +( +$ +4 +5 +, +0 +0 +0 + +i +f + +a + +q +u +a +l +i +f +y +i +n +g + + + + +f +u +n +d +i +n +g + +d +i +s +t +r +i +b +u +t +i +o +n +s +. + +Y +o +u + +m +a +y + +b +e + + + + +w +i +d +o +w +( +e +r +) +; + +$ +2 +2 +, +5 +0 +0 + +i +f + +m +a +r +r +i +e +d + +f +i +l +i +n +g + + + + +a +b +l +e + +t +o + +e +l +e +c +t + +t +o + +e +x +c +l +u +d +e + +f +r +o +m + +i +n +c +o +m +e + +a + + + + +s +e +p +a +r +a +t +e +l +y +) +. + + + + +d +i +s +t +r +i +b +u +t +i +o +n + +m +a +d +e + +f +r +o +m + +y +o +u +r + +I +R +A + +t +o + +y +o +u +r + + + + +A +t + +t +h +e + +t +i +m +e + +t +h +e +s +e + +i +n +s +t +r +u +c +t +i +o +n +s + + + + +H +S +A +. + +S +e +e + +t +h +e + +i +n +s +t +r +u +c +t +i +o +n +s + +f +o +r + +l +i +n +e +s + +1 +6 +a + + + + +! + + + + +w +e +n +t + +t +o + +p +r +i +n +t +, + +C +o +n +g +r +e +s +s + +w +a +s + + + + +a +n +d + +1 +6 +b + +b +e +g +i +n +n +i +n +g + +o +n + +p +a +g +e + +1 +2 +. + + + + +c +o +n +s +i +d +e +r +i +n +g + +l +e +g +i +s +l +a +t +i +o +n + +t +h +a +t + + + + +C +A +U +T +I +O +N + + + + +N +e +w + +r +e +c +o +r +d +k +e +e +p +i +n +g + +r +e +q +u +i +r +e +m +e +n +t +s + +f +o +r + + + + +w +o +u +l +d + +i +n +c +r +e +a +s +e + +t +h +e + +a +m +o +u +n +t +s + +a +b +o +v +e +. + +T +o + + + + +c +o +n +t +r +i +b +u +t +i +o +n +s + +o +f + +m +o +n +e +y +. + + + + + +F +o +r + + + + +f +i +n +d + +o +u +t + +i +f + +t +h +i +s + +l +e +g +i +s +l +a +t +i +o +n + +w +a +s + +e +n +a +c +t +e +d +, + + + + +c +h +a +r +i +t +a +b +l +e + +c +o +n +t +r +i +b +u +t +i +o +n +s + +o +f + +m +o +n +e +y +, + + + + +a +n +d + +f +o +r + +m +o +r +e + +d +e +t +a +i +l +s +, + +s +e +e + +t +h +e + + + + +r +e +g +a +r +d +l +e +s +s + +o +f + +t +h +e + +a +m +o +u +n +t +, + +y +o +u + +m +u +s +t + + + + +I +n +s +t +r +u +c +t +i +o +n +s + +f +o +r + +F +o +r +m + +6 +2 +5 +1 +. + + + + +m +a +i +n +t +a +i +n + +a +s + +a + +r +e +c +o +r +d + +o +f + +t +h +e + +c +o +n +t +r +i +b +u +t +i +o +n + + + + +I +R +A + +d +e +d +u +c +t +i +o +n + +e +x +p +a +n +d +e +d +. + + + + +I +f + +y +o +u + +w +e +r +e + + + + +a + +b +a +n +k + +r +e +c +o +r +d + +( +s +u +c +h + +a +s + +a + +c +a +n +c +e +l +l +e +d + + + + +c +o +v +e +r +e +d + +b +y + +a + +r +e +t +i +r +e +m +e +n +t + +p +l +a +n +, + +y +o +u + +m +a +y + + + + +c +h +e +c +k +) + +o +r + +a + +w +r +i +t +t +e +n + +r +e +c +o +r +d + +f +r +o +m + +t +h +e + + + + +b +e + +a +b +l +e + +t +o + +t +a +k +e + +a +n + +I +R +A + +d +e +d +u +c +t +i +o +n + +i +f + +y +o +u +r + + + + +c +h +a +r +i +t +y +. + +T +h +e + +w +r +i +t +t +e +n + +r +e +c +o +r +d + +m +u +s +t + +i +n +c +l +u +d +e + + + + +2 +0 +0 +7 + +m +o +d +i +f +i +e +d + +a +d +j +u +s +t +e +d + +g +r +o +s +s + +i +n +c +o +m +e + + + + +t +h +e + +n +a +m +e + +o +f + +t +h +e + +c +h +a +r +i +t +y +, + +d +a +t +e +, + +a +n +d + + + + +( +A +G +I +) + +i +s + +l +e +s +s + +t +h +a +n + +$ +6 +2 +, +0 +0 +0 + +( +$ +1 +0 +3 +, +0 +0 +0 + +i +f + + + + +a +m +o +u +n +t + +o +f + +t +h +e + +c +o +n +t +r +i +b +u +t +i +o +n +. + +S +e +e + +G +i +f +t +s + +t +o + + + + +a + +q +u +a +l +i +f +y +i +n +g + +w +i +d +o +w +( +e +r +) +) +. + + + + +U +. +S +. + +C +h +a +r +i +t +i +e +s + +t +h +a +t + +b +e +g +i +n +s + +o +n + +p +a +g +e + +2 +6 +. + + + + +Y +o +u + +m +a +y + +b +e + +a +b +l +e + +t +o + +d +e +d +u +c +t + +u +p + +t +o + +a +n + + + + +E +x +e +m +p +t +i +o +n + +f +o +r + +h +o +u +s +i +n +g + +a + +p +e +r +s +o +n + + + + +a +d +d +i +t +i +o +n +a +l + +$ +3 +, +0 +0 +0 + +i +f + +y +o +u + +w +e +r +e + +a + + + + +d +i +s +p +l +a +c +e +d + +b +y + +H +u +r +r +i +c +a +n +e + +K +a +t +r +i +n +a + + + + +p +a +r +t +i +c +i +p +a +n +t + +i +n + +a + +4 +0 +1 +( +k +) + +p +l +a +n + +a +n +d + +y +o +u +r + + + + +e +x +p +i +r +e +s +. + +T +h +e + +a +d +d +i +t +i +o +n +a +l + +e +x +e +m +p +t +i +o +n + + + + +e +m +p +l +o +y +e +r + +w +a +s + +i +n + +b +a +n +k +r +u +p +t +c +y + +i +n + +a +n + + + + +a +m +o +u +n +t + +f +o +r + +h +o +u +s +i +n +g + +a + +p +e +r +s +o +n + +d +i +s +p +l +a +c +e +d + + + + +e +a +r +l +i +e +r + +y +e +a +r +. + + + + +b +y + +H +u +r +r +i +c +a +n +e + +K +a +t +r +i +n +a + +d +o +e +s + +n +o +t + +a +p +p +l +y + +f +o +r + + + + +2 +0 +0 +7 + +o +r + +l +a +t +e +r + +y +e +a +r +s +. + + + + +S +t +a +n +d +a +r +d + +m +i +l +e +a +g +e + +r +a +t +e +s +. + +T +h +e + +2 +0 +0 +7 + + + + +T +e +l +e +p +h +o +n +e + +e +x +c +i +s +e + +t +a +x + +c +r +e +d +i +t +. + + + + +r +a +t +e + +f +o +r + +b +u +s +i +n +e +s +s + +u +s +e + +o +f + +y +o +u +r + +v +e +h +i +c +l +e + +i +s + + + + + +T +h +i +s + + + + +4 +8 +1 +/ +2 + +c +e +n +t +s + +a + +m +i +l +e +. + +T +h +e + +2 +0 +0 +7 + +r +a +t +e + +f +o +r + + + + +c +r +e +d +i +t + +w +a +s + +a +v +a +i +l +a +b +l +e + +o +n +l +y + +o +n + +y +o +u +r + +2 +0 +0 +6 + + + + +u +s +e + +o +f + +y +o +u +r + +v +e +h +i +c +l +e + +t +o + +m +o +v +e + +i +s + +2 +0 + +c +e +n +t +s + + + + +r +e +t +u +r +n +. + +I +f + +y +o +u + +f +i +l +e +d + +b +u +t + +d +i +d + +n +o +t + +r +e +q +u +e +s +t + +i +t + + + + +a + +m +i +l +e +. + +T +h +e + +s +p +e +c +i +a +l + +r +a +t +e + +f +o +r + +c +h +a +r +i +t +a +b +l +e + + + + +o +n + +y +o +u +r + +2 +0 +0 +6 + +r +e +t +u +r +n +, + +f +i +l +e + +F +o +r +m + +1 +0 +4 +0 +X + + + + +u +s +e + +o +f + +y +o +u +r + +v +e +h +i +c +l +e + +t +o + +p +r +o +v +i +d +e + +r +e +l +i +e +f + + + + +u +s +i +n +g + +a + +s +i +m +p +l +i +f +i +e +d + +p +r +o +c +e +d +u +r +e + +e +x +p +l +a +i +n +e +d + + + + +r +e +l +a +t +e +d + +t +o + +H +u +r +r +i +c +a +n +e + +K +a +t +r +i +n +a + +h +a +s + + + + +i +n + +i +t +s + +i +n +s +t +r +u +c +t +i +o +n +s + +t +o + +a +m +e +n +d + +y +o +u +r + +2 +0 +0 +6 + + + + +e +x +p +i +r +e +d +. + + + + +r +e +t +u +r +n +. + +I +f + +y +o +u + +w +e +r +e + +n +o +t + +r +e +q +u +i +r +e +d + +t +o + +f +i +l +e + +a + + + + +2 +0 +0 +6 + +r +e +t +u +r +n +, + +s +e +e + +t +h +e + +2 +0 +0 +6 + +F +o +r +m + + + + +E +l +e +c +t +i +v +e + +s +a +l +a +r +y + +d +e +f +e +r +r +a +l +s +. + +T +h +e + + + + +1 +0 +4 +0 +E +Z +- +T +. + + + + +m +a +x +i +m +u +m + +a +m +o +u +n +t + +y +o +u + +c +a +n + +d +e +f +e +r + +u +n +d +e +r + + + + +a +l +l + +p +l +a +n +s + +i +s + +g +e +n +e +r +a +l +l +y + +l +i +m +i +t +e +d + +t +o + +$ +1 +5 +, +5 +0 +0 + + + + +W +h +a +t + +s + +N +e +w + +f +o +r + +2 +0 +0 +8 + + + + +( +$ +1 +0 +, +5 +0 +0 + +i +f + +y +o +u + +o +n +l +y + +h +a +v +e + +S +I +M +P +L +E + + + + +p +l +a +n +s +; + +$ +1 +8 +, +5 +0 +0 + +f +o +r + +s +e +c +t +i +o +n + +4 +0 +3 +( +b +) + +p +l +a +n +s + + + + +I +R +A + +d +e +d +u +c +t +i +o +n + +e +x +p +a +n +d +e +d +. + +Y +o +u + +m +a +y + + + + +i +f + +y +o +u + +q +u +a +l +i +f +y + +f +o +r + +t +h +e + +1 +5 +- +y +e +a +r + +r +u +l +e +) +. + +S +e +e + + + + +b +e + +a +b +l +e + +t +o + +d +e +d +u +c +t + +u +p + +t +o + +$ +5 +, +0 +0 +0 + +( +$ +6 +, +0 +0 +0 + + + + +t +h +e + +i +n +s +t +r +u +c +t +i +o +n +s + +f +o +r + +l +i +n +e + +8 + +o +n + +p +a +g +e + +1 +0 +. + + + + +i +f + +a +g +e + +5 +0 + +o +r + +o +l +d +e +r + +a +t + +t +h +e + +e +n +d + +o +f + +t +h +e + + + + +M +a +i +l +i +n +g + +y +o +u +r + +r +e +t +u +r +n +. + + + + + +I +f + +y +o +u + +a +r +e + +f +i +l +i +n +g + + + + +y +e +a +r +) +. + +Y +o +u + +m +a +y + +b +e + +a +b +l +e + +t +o + +t +a +k +e + +a +n + +I +R +A + + + + +d +e +d +u +c +t +i +o +n + +i +f + +y +o +u + +w +e +r +e + +c +o +v +e +r +e +d + +b +y + +a + + + + +t +h +e + +r +e +t +u +r +n + +f +o +r + +a +n + +e +s +t +a +t +e + +o +r + +t +r +u +s +t +, + +y +o +u + +w +i +l +l + + + + + + +C +a +t +. + +N +o +. + +1 +1 +3 +6 +8 +V + + + + + r e @@ -677,7 +4574,7 @@ - + Y o @@ -1959,7 +5856,7 @@ - + E x p @@ -1982,10 +5879,7 @@ t s . - - - - + T h e @@ -2358,3952 +6252,6 @@ - - -S -e -c -t -i -o -n - -r -e -f -e -r -e -n -c -e -s - -a -r -e - -t -o - -t -h -e - -I -n -t -e -r -n -a -l - - - - -R -e -v -e -n -u -e - -C -o -d -e - -u -n -l -e -s -s - -o -t -h -e -r -w -i -s -e - -n -o -t -e -d -. - - - - -G -e -n -e -r -a -l - -I -n -s -t -r -u -c -t -i -o -n -s - - - - -W -h -a -t - -s - -N -e -w - -f -o -r - -2 -0 -0 -7 - - - - -T -a -x - -b -e -n -e -f -i -t -s - -e -x -t -e -n -d -e -d -. - - - - -T -h -e - -f -o -l -l -o -w -i -n -g - - - - -t -a -x - -b -e -n -e -f -i -t -s - -w -e -r -e - -e -x -t -e -n -d -e -d - -t -h -r -o -u -g -h - - - - -2 -0 -0 -7 -. - - - - - - -D -e -d -u -c -t -i -o -n - -f -o -r - -e -d -u -c -a -t -o -r - -e -x -p -e -n -s -e -s - -i -n - - - - -f -i -g -u -r -i -n -g - -a -d -j -u -s -t -e -d - -g -r -o -s -s - -i -n -c -o -m -e -. - - - - - - -D -i -s -t -r -i -c -t - -o -f - -C -o -l -u -m -b -i -a - -f -i -r -s -t -- -t -i -m -e - - - - -h -o -m -e -b -u -y -e -r - -c -r -e -d -i -t -. - - - - -A -l -t -e -r -n -a -t -i -v -e - -m -i -n -i -m -u -m - -t -a -x - -( -A -M -T -) - - - - -e -x -e -m -p -t -i -o -n - -a -m -o -u -n -t - -d -e -c -r -e -a -s -e -d -. - - - - -T -h -e - - - - -A -M -T - -e -x -e -m -p -t -i -o -n - -a -m -o -u -n -t - -i -s - -d -e -c -r -e -a -s -e -d - -t -o - - - - -$ -3 -3 -, -7 -5 -0 - -( -$ -4 -5 -, -0 -0 -0 - -i -f - -a - -q -u -a -l -i -f -y -i -n -g - - - - -w -i -d -o -w -( -e -r -) -; - -$ -2 -2 -, -5 -0 -0 - -i -f - -m -a -r -r -i -e -d - -f -i -l -i -n -g - - - - -s -e -p -a -r -a -t -e -l -y -) -. - - - - -A -t - -t -h -e - -t -i -m -e - -t -h -e -s -e - -i -n -s -t -r -u -c -t -i -o -n -s - - - - -! - - - - -w -e -n -t - -t -o - -p -r -i -n -t -, - -C -o -n -g -r -e -s -s - -w -a -s - - - - -c -o -n -s -i -d -e -r -i -n -g - -l -e -g -i -s -l -a -t -i -o -n - -t -h -a -t - - - - -C -A -U -T -I -O -N - - - - -w -o -u -l -d - -i -n -c -r -e -a -s -e - -t -h -e - -a -m -o -u -n -t -s - -a -b -o -v -e -. - -T -o - - - - -f -i -n -d - -o -u -t - -i -f - -t -h -i -s - -l -e -g -i -s -l -a -t -i -o -n - -w -a -s - -e -n -a -c -t -e -d -, - - - - -a -n -d - -f -o -r - -m -o -r -e - -d -e -t -a -i -l -s -, - -s -e -e - -t -h -e - - - - -I -n -s -t -r -u -c -t -i -o -n -s - -f -o -r - -F -o -r -m - -6 -2 -5 -1 -. - - - - -I -R -A - -d -e -d -u -c -t -i -o -n - -e -x -p -a -n -d -e -d -. - - - - -I -f - -y -o -u - -w -e -r -e - - - - -c -o -v -e -r -e -d - -b -y - -a - -r -e -t -i -r -e -m -e -n -t - -p -l -a -n -, - -y -o -u - -m -a -y - - - - -b -e - -a -b -l -e - -t -o - -t -a -k -e - -a -n - -I -R -A - -d -e -d -u -c -t -i -o -n - -i -f - -y -o -u -r - - - - -2 -0 -0 -7 - -m -o -d -i -f -i -e -d - -a -d -j -u -s -t -e -d - -g -r -o -s -s - -i -n -c -o -m -e - - - - -( -A -G -I -) - -i -s - -l -e -s -s - -t -h -a -n - -$ -6 -2 -, -0 -0 -0 - -( -$ -1 -0 -3 -, -0 -0 -0 - -i -f - - - - -a - -q -u -a -l -i -f -y -i -n -g - -w -i -d -o -w -( -e -r -) -) -. - - - - -Y -o -u - -m -a -y - -b -e - -a -b -l -e - -t -o - -d -e -d -u -c -t - -u -p - -t -o - -a -n - - - - -a -d -d -i -t -i -o -n -a -l - -$ -3 -, -0 -0 -0 - -i -f - -y -o -u - -w -e -r -e - -a - - - - -p -a -r -t -i -c -i -p -a -n -t - -i -n - -a - -4 -0 -1 -( -k -) - -p -l -a -n - -a -n -d - -y -o -u -r - - - - -e -m -p -l -o -y -e -r - -w -a -s - -i -n - -b -a -n -k -r -u -p -t -c -y - -i -n - -a -n - - - - -e -a -r -l -i -e -r - -y -e -a -r -. - - - - -S -t -a -n -d -a -r -d - -m -i -l -e -a -g -e - -r -a -t -e -s -. - - - - -T -h -e - -2 -0 -0 -7 - - - - -r -a -t -e - -f -o -r - -b -u -s -i -n -e -s -s - -u -s -e - -o -f - -y -o -u -r - -v -e -h -i -c -l -e - -i -s - - - - -4 -8 -1 -/ -2 - -c -e -n -t -s - -a - -m -i -l -e -. - -T -h -e - -2 -0 -0 -7 - -r -a -t -e - -f -o -r - - - - -u -s -e - -o -f - -y -o -u -r - -v -e -h -i -c -l -e - -t -o - -m -o -v -e - -i -s - -2 -0 - -c -e -n -t -s - - - - -a - -m -i -l -e -. - -T -h -e - -s -p -e -c -i -a -l - -r -a -t -e - -f -o -r - -c -h -a -r -i -t -a -b -l -e - - - - -u -s -e - -o -f - -y -o -u -r - -v -e -h -i -c -l -e - -t -o - -p -r -o -v -i -d -e - -r -e -l -i -e -f - - - - -r -e -l -a -t -e -d - -t -o - -H -u -r -r -i -c -a -n -e - -K -a -t -r -i -n -a - -h -a -s - - - - -e -x -p -i -r -e -d -. - - - - -E -l -e -c -t -i -v -e - -s -a -l -a -r -y - -d -e -f -e -r -r -a -l -s -. - - - - -T -h -e - - - - -m -a -x -i -m -u -m - -a -m -o -u -n -t - -y -o -u - -c -a -n - -d -e -f -e -r - -u -n -d -e -r - - - - -a -l -l - -p -l -a -n -s - -i -s - -g -e -n -e -r -a -l -l -y - -l -i -m -i -t -e -d - -t -o - -$ -1 -5 -, -5 -0 -0 - - - - -( -$ -1 -0 -, -5 -0 -0 - -i -f - -y -o -u - -o -n -l -y - -h -a -v -e - -S -I -M -P -L -E - - - - -p -l -a -n -s -; - -$ -1 -8 -, -5 -0 -0 - -f -o -r - -s -e -c -t -i -o -n - -4 -0 -3 -( -b -) - -p -l -a -n -s - - - - -i -f - -y -o -u - -q -u -a -l -i -f -y - -f -o -r - -t -h -e - -1 -5 -- -y -e -a -r - -r -u -l -e -) -. - -S -e -e - - - - -t -h -e - -i -n -s -t -r -u -c -t -i -o -n -s - -f -o -r - -l -i -n -e - -8 - -o -n - -p -a -g -e - -1 -0 -. - - - - -M -a -i -l -i -n -g - -y -o -u -r - -r -e -t -u -r -n -. - - - - - -I -f - -y -o -u - -a -r -e - -f -i -l -i -n -g - - - - -t -h -e - -r -e -t -u -r -n - -f -o -r - -a -n - -e -s -t -a -t -e - -o -r - -t -r -u -s -t -, - -y -o -u - -w -i -l -l - - - - - - -u -s -e - -a - -d -i -f -f -e -r -e -n -t - -a -d -d -r -e -s -s - -t -h -i -s - -y -e -a -r -. - -S -e -e - - - - -W -h -e -r -e - -T -o - -F -i -l -e - -o -n - -p -a -g -e - -4 -. - - - - -D -o -m -e -s -t -i -c - -p -r -o -d -u -c -t -i -o -n - -a -c -t -i -v -i -t -i -e -s - - - - -d -e -d -u -c -t -i -o -n -. - - - - -T -h -e - -d -e -d -u -c -t -i -o -n - -r -a -t -e - -f -o -r - - - - -2 -0 -0 -7 - -i -s - -i -n -c -r -e -a -s -e -d - -t -o - -6 -% -. - - - - -U -n -r -e -p -o -r -t -e -d - -s -o -c -i -a -l - -s -e -c -u -r -i -t -y - -a -n -d - - - - -M -e -d -i -c -a -r -e - -t -a -x - -o -n - -w -a -g -e -s -. - - - - - -I -f - -y -o -u - -a -r -e - - - - -a -n - -e -m -p -l -o -y -e -e - -a -n -d - -y -o -u -r - -e -m -p -l -o -y -e -r - -d -i -d - -n -o -t - - - - -w -i -t -h -h -o -l -d - -s -o -c -i -a -l - -s -e -c -u -r -i -t -y - -a -n -d - -M -e -d -i -c -a -r -e - - - - -t -a -x -, - -s -e -e - -F -o -r -m - -8 -9 -1 -9 - -t -o - -f -i -g -u -r -e - -a -n -d - -r -e -p -o -r -t - - - - -t -h -i -s - -t -a -x -. - - - - -R -e -f -u -n -d -a -b -l -e - -c -r -e -d -i -t - -f -o -r - -p -r -i -o -r -- -y -e -a -r - - - - -m -i -n -i -m -u -m - -t -a -x -. - - - - -I -f - -y -o -u - -h -a -v -e - -a -n - -u -n -u -s -e -d - - - - -m -i -n -i -m -u -m - -t -a -x - -c -r -e -d -i -t - -c -a -r -r -y -f -o -r -w -a -r -d - -f -r -o -m - - - - -2 -0 -0 -4 -, - -s -e -e - -F -o -r -m - -8 -8 -0 -1 - -t -o - -f -i -n -d - -i -f - -y -o -u - -c -a -n - - - - -t -a -k -e - -t -h -i -s - -c -r -e -d -i -t -. - - - - -H -e -a -l -t -h - -s -a -v -i -n -g -s - -a -c -c -o -u -n -t - -( -H -S -A -) - - - - -f -u -n -d -i -n -g - -d -i -s -t -r -i -b -u -t -i -o -n -s -. - - - - -Y -o -u - -m -a -y - -b -e - - - - -a -b -l -e - -t -o - -e -l -e -c -t - -t -o - -e -x -c -l -u -d -e - -f -r -o -m - -i -n -c -o -m -e - -a - - - - -d -i -s -t -r -i -b -u -t -i -o -n - -m -a -d -e - -f -r -o -m - -y -o -u -r - -I -R -A - -t -o - -y -o -u -r - - - - -H -S -A -. - -S -e -e - -t -h -e - -i -n -s -t -r -u -c -t -i -o -n -s - -f -o -r - -l -i -n -e -s - -1 -6 -a - - - - -a -n -d - -1 -6 -b - -b -e -g -i -n -n -i -n -g - -o -n - -p -a -g -e - -1 -2 -. - - - - -N -e -w - -r -e -c -o -r -d -k -e -e -p -i -n -g - -r -e -q -u -i -r -e -m -e -n -t -s - -f -o -r - - - - -c -o -n -t -r -i -b -u -t -i -o -n -s - -o -f - -m -o -n -e -y -. - - - - - -F -o -r - - - - -c -h -a -r -i -t -a -b -l -e - -c -o -n -t -r -i -b -u -t -i -o -n -s - -o -f - -m -o -n -e -y -, - - - - -r -e -g -a -r -d -l -e -s -s - -o -f - -t -h -e - -a -m -o -u -n -t -, - -y -o -u - -m -u -s -t - - - - -m -a -i -n -t -a -i -n - -a -s - -a - -r -e -c -o -r -d - -o -f - -t -h -e - -c -o -n -t -r -i -b -u -t -i -o -n - - - - -a - -b -a -n -k - -r -e -c -o -r -d - -( -s -u -c -h - -a -s - -a - -c -a -n -c -e -l -l -e -d - - - - -c -h -e -c -k -) - -o -r - -a - -w -r -i -t -t -e -n - -r -e -c -o -r -d - -f -r -o -m - -t -h -e - - - - -c -h -a -r -i -t -y -. - -T -h -e - -w -r -i -t -t -e -n - -r -e -c -o -r -d - -m -u -s -t - -i -n -c -l -u -d -e - - - - -t -h -e - -n -a -m -e - -o -f - -t -h -e - -c -h -a -r -i -t -y -, - -d -a -t -e -, - -a -n -d - - - - -a -m -o -u -n -t - -o -f - -t -h -e - -c -o -n -t -r -i -b -u -t -i -o -n -. - -S -e -e - -G -i -f -t -s - -t -o - - - - -U -. -S -. - -C -h -a -r -i -t -i -e -s - -t -h -a -t - -b -e -g -i -n -s - -o -n - -p -a -g -e - -2 -6 -. - - - - -E -x -e -m -p -t -i -o -n - -f -o -r - -h -o -u -s -i -n -g - -a - -p -e -r -s -o -n - - - - -d -i -s -p -l -a -c -e -d - -b -y - -H -u -r -r -i -c -a -n -e - -K -a -t -r -i -n -a - - - - -e -x -p -i -r -e -s -. - - - - -T -h -e - -a -d -d -i -t -i -o -n -a -l - -e -x -e -m -p -t -i -o -n - - - - -a -m -o -u -n -t - -f -o -r - -h -o -u -s -i -n -g - -a - -p -e -r -s -o -n - -d -i -s -p -l -a -c -e -d - - - - -b -y - -H -u -r -r -i -c -a -n -e - -K -a -t -r -i -n -a - -d -o -e -s - -n -o -t - -a -p -p -l -y - -f -o -r - - - - -2 -0 -0 -7 - -o -r - -l -a -t -e -r - -y -e -a -r -s -. - - - - -T -e -l -e -p -h -o -n -e - -e -x -c -i -s -e - -t -a -x - -c -r -e -d -i -t -. - - - - - -T -h -i -s - - - - -c -r -e -d -i -t - -w -a -s - -a -v -a -i -l -a -b -l -e - -o -n -l -y - -o -n - -y -o -u -r - -2 -0 -0 -6 - - - - -r -e -t -u -r -n -. - -I -f - -y -o -u - -f -i -l -e -d - -b -u -t - -d -i -d - -n -o -t - -r -e -q -u -e -s -t - -i -t - - - - -o -n - -y -o -u -r - -2 -0 -0 -6 - -r -e -t -u -r -n -, - -f -i -l -e - -F -o -r -m - -1 -0 -4 -0 -X - - - - -u -s -i -n -g - -a - -s -i -m -p -l -i -f -i -e -d - -p -r -o -c -e -d -u -r -e - -e -x -p -l -a -i -n -e -d - - - - -i -n - -i -t -s - -i -n -s -t -r -u -c -t -i -o -n -s - -t -o - -a -m -e -n -d - -y -o -u -r - -2 -0 -0 -6 - - - - -r -e -t -u -r -n -. - -I -f - -y -o -u - -w -e -r -e - -n -o -t - -r -e -q -u -i -r -e -d - -t -o - -f -i -l -e - -a - - - - -2 -0 -0 -6 - -r -e -t -u -r -n -, - -s -e -e - -t -h -e - -2 -0 -0 -6 - -F -o -r -m - - - - -1 -0 -4 -0 -E -Z -- -T -. - - - - -W -h -a -t - -s - -N -e -w - -f -o -r - -2 -0 -0 -8 - - - - -I -R -A - -d -e -d -u -c -t -i -o -n - -e -x -p -a -n -d -e -d -. - - - - -Y -o -u - -m -a -y - - - - -b -e - -a -b -l -e - -t -o - -d -e -d -u -c -t - -u -p - -t -o - -$ -5 -, -0 -0 -0 - -( -$ -6 -, -0 -0 -0 - - - - -i -f - -a -g -e - -5 -0 - -o -r - -o -l -d -e -r - -a -t - -t -h -e - -e -n -d - -o -f - -t -h -e - - - - -y -e -a -r -) -. - -Y -o -u - -m -a -y - -b -e - -a -b -l -e - -t -o - -t -a -k -e - -a -n - -I -R -A - - - - -d -e -d -u -c -t -i -o -n - -i -f - -y -o -u - -w -e -r -e - -c -o -v -e -r -e -d - -b -y - -a - - - - - - -C -a -t -. - -N -o -. - -1 -1 -3 -6 -8 -V - - - - @@ -6326,39 +6274,24 @@ - - - - - - - - - - + + - - - - - + - - + + - - - - - - - - + + + + + diff --git a/samples/nonfree/kampo.html.ref b/samples/nonfree/kampo.html.ref index 5f14784..d6ec1fd 100644 --- a/samples/nonfree/kampo.html.ref +++ b/samples/nonfree/kampo.html.ref @@ -3,2769 +3,109 @@ - - - - -Ÿ -˜ -ž - - - - - - - - - - - - - - - - - - - - -œ - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -使 - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - +
平成 ™— ™œ 日 金曜日 +
官 +
報 +
›Ÿ˜ž 号 +
› +
政令第百四十九号 +
道路交通法施行令の一部を改正する政令 +
内閣は
道路交通法の一部を改正する法律平成十九年法律第九十号の一部の施行に伴い並び +
に道路交通法昭和三十五年法律第百五号第四条第一項及び第四項第五条第一項第三十九条第 +
一項第五十一条第九項同条第二十二項同法第七十二条の二第三項及び第七十五条の八第二項に +
おいて準用する場合を含む。)、第五十一条の三第一項第六十三条の四第一項第二号第七十一条の +
三第二項ただし書第七十一条の六第一項第九十条第一項ただし書第百条の二第一項本文及び第 +
四号第百二条の二並びに第百二十五条第一項及び第三項の規定に基づきこの政令を制定する。 +
道路交通法施行令昭和三十五年政令第二百七十号の一部を次のように改正する。 +
第一条の二第四項第三号中一・五メトル一メトルに改め同条第五項第三号中第 +
六十三条の四第一項第六十三条の四第一項第一号に改める。 +
第二条第一項の表の青色の灯火の項第三号中含む。)」含む青色の灯火の矢印の項を除き、 +
「 +
歩行者は進行することができること。 +
以下この条において同じ。)に改め同表中 +
歩行者は道路の横断を始めてはならずまた道 +
横断を終わるか又は横断をやめて引き返さなけれ +
路を横断している歩行者はすみやかにその +
ばならないこと
。 +
を +
る普通自転車をいう以下この条及び第二十六条第三 +
進をし
又は左折することができること。 +
また道路を横断している歩行者は速やかにその +
さなければならないこと
。 +
道路の横断を始めてはならないこと。 +
。 +
道路の横断を始めてはならないこと。 +
」 +
歩行者は道路を横断してはならないこと。 +
「 +
一 歩行者は進行することができること。 +
二 普通自転車法第六十三条の三に規定す +
号において同じ。)横断歩道において直 +
」 +
一 歩行者は道路の横断を始めてはならず、 +
横断を終わるか又は横断をやめて引き返 +
二 横断歩道を進行しようとする普通自転車 +
一 歩行者は道路を横断してはならないこ +
二 横断歩道を進行しようとする普通自転車 +
に改め同条第四項の表の人の形の記号を有 +
する青色の灯火の項第二号中直進右折しようとして右折する地点まで直進しその地点において +
右折することを含む。)直進をしに改める。 +
第三条の二第一項中行なわせる行わせる、「次の各号に次に、「こえないを +
超えないに改め第十号を第十二号とし第四号から第九号までを二号ずつ繰り下げ第三号を +
第四号とし同号の次に次の一号を加える。 +
五 法第二十五条の二第二項の道路標識等 +
第三条の二第一項第二号の次に次の一号を加える
。 +
三 法第十三条第二項の道路標識等 +
第十三条第一項中第一号の五を第一号の六とし
第一号の四の次に次の一号を加える。 +
一の五 医療機関が傷病者の緊急搬送をしようとする都道府県又は市町村の要請を受けて当該 +
傷病者が医療機関に緊急搬送をされるまでの間における応急の治療を行う医師を当該傷病者の所 +
在する場所にまで運搬するために使用する自動車 +
第十六条中第二号を削り第三号を第二号とする。 +
第十六条の二及び第十六条の三中第五十一条第十一項第五十一条第十二項に改める。 +
第十六条の五中第五十一条第二十項第五十一条第二十一項に改める。 +
第十七条中第五十一条第二十一項第五十一条第二十二項に改め、「「とあるのは前 +
号の公示に係る積載物のうち特に貴重と認められるものについては同号同条第三号中を削 +
。 +
第十七条の二を次のように改める。 +
委託することのできない事務) +
第十七条の二 法第五十一条の三第一項の政令で定めるものは次に掲げるとおりとする。 +
一 法第五十一条第五項の規定による車両の移動の決定 +
二 法第五十一条第六項同条第二十二項において準用する場合を含む。)の規定により保管した車 +
積載物を含む以下この条において同じ。)の返還の決定 +
三 法第五十一条第七項同条第二十二項において読み替えて準用する場合を含む。)又は第八項の +
規定による告知 +
四 法第五十一条第九項
同条第二十二項において読み替えて準用する場合を含む。)の規定による +
公示 +
五 法第五十一条第十項
同条第二十二項において準用する場合を含む。)の規定による公示の日付 +
及び内容の公表 +
六 法第五十一条第十二項
同条第二十二項において読み替えて準用する場合を含む。)の規定によ +
る車両の売却の決定 +
七 法第五十一条第十三項
同条第二十二項において準用する場合を含む。)規定による車両の廃 +
棄の決定 +
八 法第五十一条第十六項
同条第二十二項において読み替えて準用する場合を含む。)の規定によ +
る命令 +
九 法第五十一条第十七項
同条第二十二項において準用する場合を含む。)規定による督促 +
十 法第五十一条第十八項同条第二十二項において準用する場合を含む。)規定による徴収 +
十一 法第五十一条第二十一項の規定による登録の嘱託 +
第十七条の三を削り第十七条の四を第十七条の三とし第十七条の五から第十七条の八までを一 +
条ずつ繰り上げる。 +
第二十二条第一号中乗車装置以下下にこの条においてを加える。 +
第二十四条の二中第二十六条第二十五条の二に改める。 +
第二十六条を第二十五条の二とし第三章中同条の次に次の一条を加える。 +
普通自転車により歩道を通行することができる者) +
第二十六条 法第六十三条の四第一項第二号の政令で定める者は次に掲げるとおりとする。 +
一 児童及び幼児 +
二 七十歳以上の者 +
三 普通自転車により安全に車道を通行す
ることに支障を生ずる程度の身体の障害として内閣府令 +
で定めるものを有する者 +
第二十六条の三の二第一項第四号中
次項第三号次項第四号に改め同項第七号中次項 +
第六号次項第七号に改め同条第二項第七号中の横以外に改同号を同項第八 +
号とし同項第六号中の横以外改め同号を同項第七号とし同項第五号中の横を +
以外に改め同号を同項第六号とし項第四号中の横以外に改同号を同項第五 +
号とし同項第三号中の横以外改め同号を同項第四号とし同項第二号中の横を +
以外に改め同号を同項第三号とし項第一号中の横以外に改同号を同項第二 +
号とし同項に第一号として次の一号を加え。 +
diff --git a/samples/nonfree/kampo.txt.ref b/samples/nonfree/kampo.txt.ref index 646e2d1..0096131 100644 --- a/samples/nonfree/kampo.txt.ref +++ b/samples/nonfree/kampo.txt.ref @@ -1,12 +1,12 @@ -第 ›Ÿ˜ž 号 - -› +平成 ™— 年 › 月 ™œ 日 金曜日 官 報 -平成 ™— 年 › 月 ™œ 日 金曜日 +第 ›Ÿ˜ž 号 + +› 政令第百四十九号 道路交通法施行令の一部を改正する政令 diff --git a/samples/nonfree/kampo.xml.ref b/samples/nonfree/kampo.xml.ref index 116f16e..907ee55 100644 --- a/samples/nonfree/kampo.xml.ref +++ b/samples/nonfree/kampo.xml.ref @@ -1,57 +1,22 @@ - - - - - -Ÿ -˜ -ž - - - - - - - - - - - - - - - - - - - - - - - - - - - - + - - + + - + - -œ + +œ @@ -62,6 +27,41 @@ + + + + + + + + + + + + + + + + + + + +Ÿ +˜ +ž + + + + + + + + + + + + + @@ -3136,16 +3136,16 @@ - - - - + - - + + - + + + + diff --git a/samples/nonfree/naacl06-shinyama.html.ref b/samples/nonfree/naacl06-shinyama.html.ref index 346ff53..77690be 100644 --- a/samples/nonfree/naacl06-shinyama.html.ref +++ b/samples/nonfree/naacl06-shinyama.html.ref @@ -3,2980 +3,81 @@ - - -P -r -e -e -m -p -t -i -v -e -I -n -f -o -r -m -a -t -i -o -n -E -x -t -r -a -c -t -i -o -n -u -s -i -n -g -U -n -r -e -s -t -r -i -c -t -e -d -R -e -l -a -t -i -o -n -D -i -s -c -o -v -e -r -y - - -Y -u -s -u -k -e -S -h -i -n -y -a -m -a - - -S -a -t -o -s -h -i -S -e -k -i -n -e - - -N -e -w -Y -o -r -k -U -n -i -v -e -r -s -i -t -y - -7 -1 -5 -, -B -r -o -a -d -w -a -y -, -7 -t -h -F -l -o -o -r - -N -e -w -Y -o -r -k -, -N -Y -, -1 -0 -0 -0 -3 - -{ -y -u -s -u -k -e -, -s -e -k -i -n -e -} -@ -c -s -. -n -y -u -. -e -d -u - - -A -b -s -t -r -a -c -t - - -W -e -a -r -e -t -r -y -i -n -g -t -o -e -x -t -e -n -d -t -h -e -b -o -u -n -d -a -r -y -o -f - -I -n -f -o -r -m -a -t -i -o -n -E -x -t -r -a -c -t -i -o -n -( -I -E -) -s -y -s -t -e -m -s -. -E -x -- - -i -s -t -i -n -g -I -E -s -y -s -t -e -m -s -r -e -q -u -i -r -e -a -l -o -t -o -f -t -i -m -e -a -n -d - -h -u -m -a -n -e -f -f -o -r -t -t -o -t -u -n -e -f -o -r -a -n -e -w -s -c -e -n -a -r -i -o -. - -P -r -e -e -m -p -t -i -v -e -I -n -f -o -r -m -a -t -i -o -n -E -x -t -r -a -c -t -i -o -n -i -s -a -n - -a -t -t -e -m -p -t -t -o -a -u -t -o -m -a -t -i -c -a -l -l -y -c -r -e -a -t -e -a -l -l -f -e -a -s -i -b -l -e - -I -E -s -y -s -t -e -m -s -i -n -a -d -v -a -n -c -e -w -i -t -h -o -u -t -h -u -m -a -n -i -n -- - -t -e -r -v -e -n -t -i -o -n -. -W -e -p -r -o -p -o -s -e -a -t -e -c -h -n -i -q -u -e -c -a -l -l -e -d - -U -n -r -e -s -t -r -i -c -t -e -d -R -e -l -a -t -i -o -n -D -i -s -c -o -v -e -r -y -t -h -a -t -d -i -s -- - -c -o -v -e -r -s -a -l -l -p -o -s -s -i -b -l -e -r -e -l -a -t -i -o -n -s -f -r -o -m -t -e -x -t -s -a -n -d - -p -r -e -s -e -n -t -s -t -h -e -m -a -s -t -a -b -l -e -s -. -W -e -p -r -e -s -e -n -t -a -p -r -e -- - -l -i -m -i -n -a -r -y -s -y -s -t -e -m -t -h -a -t -o -b -t -a -i -n -s -r -e -a -s -o -n -a -b -l -y - -g -o -o -d -r -e -s -u -l -t -s -. - - -1 -B -a -c -k -g -r -o -u -n -d - - -E -v -e -r -y -d -a -y -, -a -l -a -r -g -e -n -u -m -b -e -r -o -f -n -e -w -s -a -r -t -i -c -l -e -s -a -r -e -c -r -e -- - -a -t -e -d -a -n -d -r -e -p -o -r -t -e -d -, -m -a -n -y -o -f -w -h -i -c -h -a -r -e -u -n -i -q -u -e -. - -B -u -t - -c -e -r -t -a -i -n -t -y -p -e -s -o -f -e -v -e -n -t -s -, -s -u -c -h -a -s -h -u -r -r -i -c -a -n -e -s -o -r -m -u -r -- - -d -e -r -s -, -a -r -e -r -e -p -o -r -t -e -d -a -g -a -i -n -a -n -d -a -g -a -i -n -t -h -r -o -u -g -h -o -u -t -a -y -e -a -r -. - -T -h -e -g -o -a -l -o -f -I -n -f -o -r -m -a -t -i -o -n -E -x -t -r -a -c -t -i -o -n -, -o -r -I -E -, -i -s -t -o -r -e -- - -t -r -i -e -v -e -a -c -e -r -t -a -i -n -t -y -p -e -o -f -n -e -w -s -e -v -e -n -t -f -r -o -m -p -a -s -t -a -r -t -i -c -l -e -s - -a -n -d -p -r -e -s -e -n -t -t -h -e -e -v -e -n -t -s -a -s -a -t -a -b -l -e -w -h -o -s -e -c -o -l -u -m -n -s -a -r -e - - -l -l -e -d -w -i -t -h -a -n -a -m -e -o -f -a -p -e -r -s -o -n -o -r -c -o -m -p -a -n -y -, -a -c -c -o -r -d -- - -H -o -w -e -v -e -r -, -e -x -i -s -t -i -n -g -I -E - -i -n -g -t -o -i -t -s -r -o -l -e -i -n -t -h -e -e -v -e -n -t -. - -t -e -c -h -n -i -q -u -e -s -r -e -q -u -i -r -e -a -l -o -t -o -f -h -u -m -a -n -l -a -b -o -r -. - -F -i -r -s -t -, -y -o -u - -h -a -v -e -t -o -s -p -e -c -i -f -y -t -h -e -t -y -p -e -o -f -i -n -f -o -r -m -a -t -i -o -n -y -o -u -w -a -n -t -a -n -d - -c -o -l -l -e -c -t -a -r -t -i -c -l -e -s -t -h -a -t -i -n -c -l -u -d -e -t -h -i -s -i -n -f -o -r -m -a -t -i -o -n -. - -T -h -e -n -, - -y -o -u -h -a -v -e -t -o -a -n -a -l -y -z -e -t -h -e -a -r -t -i -c -l -e -s -a -n -d -m -a -n -u -a -l -l -y -c -r -a -f -t - -a -s -e -t -o -f -p -a -t -t -e -r -n -s -t -o -c -a -p -t -u -r -e -t -h -e -s -e -e -v -e -n -t -s -. -M -o -s -t -e -x -i -s -t -- - -i -n -g -I -E -r -e -s -e -a -r -c -h -f -o -c -u -s -e -s -o -n -r -e -d -u -c -i -n -g -t -h -i -s -b -u -r -d -e -n -b -y - -h -e -l -p -i -n -g -p -e -o -p -l -e -c -r -e -a -t -e -s -u -c -h -p -a -t -t -e -r -n -s -. - -B -u -t -e -a -c -h -t -i -m -e - -y -o -u -w -a -n -t -t -o -e -x -t -r -a -c -t -a -d -i -f -f -e -r -e -n -t -k -i -n -d -o -f -i -n -f -o -r -m -a -t -i -o -n -, - -y -o -u -n -e -e -d -t -o -r -e -p -e -a -t -t -h -e -w -h -o -l -e -p -r -o -c -e -s -s -: -s -p -e -c -i -f -y -a -r -t -i -- - - -c -l -e -s -a -n -d -a -d -j -u -s -t -i -t -s -p -a -t -t -e -r -n -s -, -e -i -t -h -e -r -m -a -n -u -a -l -l -y -o -r -s -e -m -i -- - -a -u -t -o -m -a -t -i -c -a -l -l -y -. - -T -h -e -r -e -i -s -a -b -i -t -o -f -a -d -a -n -g -e -r -o -u -s -p -i -t -f -a -l -l - -h -e -r -e -. -F -i -r -s -t -, -i -t -i -s -h -a -r -d -t -o -e -s -t -i -m -a -t -e -h -o -w -g -o -o -d -t -h -e -s -y -s -- - -t -e -m -c -a -n -b -e -a -f -t -e -r -m -o -n -t -h -s -o -f -w -o -r -k -. -F -u -r -t -h -e -r -m -o -r -e -, -y -o -u - -m -i -g -h -t -n -o -t -k -n -o -w -i -f -t -h -e -t -a -s -k -i -s -e -v -e -n -d -o -a -b -l -e -i -n -t -h -e - -r -s -t - -p -l -a -c -e -. - -K -n -o -w -i -n -g -w -h -a -t -k -i -n -d -o -f -i -n -f -o -r -m -a -t -i -o -n -i -s -e -a -s -i -l -y - -o -b -t -a -i -n -e -d -i -n -a -d -v -a -n -c -e -w -o -u -l -d -h -e -l -p -r -e -d -u -c -e -t -h -i -s -r -i -s -k -. - -A -n -I -E -t -a -s -k -c -a -n -b -e -d -e - -n -e -d -a -s - -n -d -i -n -g -a -r -e -l -a -t -i -o -n - -a -m -o -n -g -s -e -v -e -r -a -l -e -n -t -i -t -i -e -s -i -n -v -o -l -v -e -d -i -n -a -c -e -r -t -a -i -n -t -y -p -e -o -f - -e -v -e -n -t -. - -F -o -r -e -x -a -m -p -l -e -, -i -n -t -h -e -M -U -C -- -6 -m -a -n -a -g -e -m -e -n -t - -s -u -c -c -e -s -s -i -o -n -s -c -e -n -a -r -i -o -, -o -n -e -s -e -e -k -s -a -r -e -l -a -t -i -o -n -b -e -t -w -e -e -n - -C -O -M -P -A -N -Y -, -P -E -R -S -O -N -a -n -d -P -O -S -T -i -n -v -o -l -v -e -d -w -i -t -h -h -i -r -- - -i -n -g -/ - -r -i -n -g -e -v -e -n -t -s -. - -F -o -r -e -a -c -h -r -o -w -o -f -a -n -e -x -t -r -a -c -t -e -d -t -a -- - -b -l -e -, -y -o -u -c -a -n -a -l -w -a -y -s -r -e -a -d -i -t -a -s - -C -O -M -P -A -N -Y -h -i -r -e -d - -( -o -r - -r -e -d -) -P -E -R -S -O -N -f -o -r -P -O -S -T -. - -T -h -e -r -e -l -a -t -i -o -n -b -e -t -w -e -e -n - -t -h -e -s -e -e -n -t -i -t -i -e -s -i -s -r -e -t -a -i -n -e -d -t -h -r -o -u -g -h -o -u -t -t -h -e -t -a -b -l -e -. -T -h -e -r -e - -a -r -e -m -a -n -y -e -x -i -s -t -i -n -g -w -o -r -k -s -o -n -o -b -t -a -i -n -i -n -g -e -x -t -r -a -c -t -i -o -n -p -a -t -- - -t -e -r -n -s -f -o -r -p -r -e -- -d -e - -n -e -d -r -e -l -a -t -i -o -n -s -( -R -i -l -o -f -f -, -1 -9 -9 -6 -; -Y -a -n -g -a -r -- - -b -e -r -e -t -a -l -. -, -2 -0 -0 -0 -; -A -g -i -c -h -t -e -i -n -a -n -d -G -r -a -v -a -n -o -, -2 -0 -0 -0 -; -S -u -d -o - -e -t -a -l -. -, -2 -0 -0 -3 -) -. - -U -n -r -e -s -t -r -i -c -t -e -d -R -e -l -a -t -i -o -n -D -i -s -c -o -v -e -r -y -i -s -a -t -e -c -h -n -i -q -u -e -t -o - -a -u -t -o -m -a -t -i -c -a -l -l -y -d -i -s -c -o -v -e -r -s -u -c -h -r -e -l -a -t -i -o -n -s -t -h -a -t -r -e -p -e -a -t -e -d -l -y - -a -p -p -e -a -r -i -n -a -c -o -r -p -u -s -a -n -d -p -r -e -s -e -n -t -t -h -e -m -a -s -a -t -a -b -l -e -, -w -i -t -h - -a -b -s -o -l -u -t -e -l -y -n -o -h -u -m -a -n -i -n -t -e -r -v -e -n -t -i -o -n -. -U -n -l -i -k -e -m -o -s -t -e -x -- - -i -s -t -i -n -g -I -E -r -e -s -e -a -r -c -h -, -a -u -s -e -r -d -o -e -s -n -o -t -s -p -e -c -i -f -y -t -h -e -t -y -p -e - -o -f -a -r -t -i -c -l -e -s -o -r -i -n -f -o -r -m -a -t -i -o -n -w -a -n -t -e -d -. -I -n -s -t -e -a -d -, -a -s -y -s -t -e -m - -t -r -i -e -s -t -o - -n -d -a -l -l -t -h -e -k -i -n -d -s -o -f -r -e -l -a -t -i -o -n -s -t -h -a -t -a -r -e -r -e -p -o -r -t -e -d - -m -u -l -t -i -p -l -e -t -i -m -e -s -a -n -d -c -a -n -b -e -r -e -p -o -r -t -e -d -i -n -t -a -b -u -l -a -r -f -o -r -m -. - -T -h -i -s -t -e -c -h -n -i -q -u -e -w -i -l -l -o -p -e -n -u -p -t -h -e -p -o -s -s -i -b -i -l -i -t -y -o -f -t -r -y -- - -i -n -g -n -e -w -I -E -s -c -e -n -a -r -i -o -s -. -F -u -r -t -h -e -r -m -o -r -e -, -t -h -e -s -y -s -t -e -m -i -t -s -e -l -f - -c -a -n -b -e -u -s -e -d -a -s -a -n -I -E -s -y -s -t -e -m -, -s -i -n -c -e -a -n -o -b -t -a -i -n -e -d -r -e -- - -l -a -t -i -o -n -i -s -a -l -r -e -a -d -y -p -r -e -s -e -n -t -e -d -a -s -a -t -a -b -l -e -. -I -f -t -h -i -s -s -y -s -t -e -m - -w -o -r -k -s -t -o -a -c -e -r -t -a -i -n -e -x -t -e -n -t -, -t -u -n -i -n -g -a -n -I -E -s -y -s -t -e -m -b -e -- - -c -o -m -e -s -a -s -e -a -r -c -h -p -r -o -b -l -e -m -: -a -l -l -t -h -e -t -a -b -l -e -s -a -r -e -a -l -r -e -a -d -y - -b -u -i -l -t - -p -r -e -e -m -p -t -i -v -e -l -y -. - -A -u -s -e -r -o -n -l -y -n -e -e -d -s -t -o -s -e -a -r -c -h - -f -o -r -a -r -e -l -e -v -a -n -t -t -a -b -l -e -. -
Page: 1
+
Preemptive Information Extraction using Unrestricted Relation Discovery +
Yusuke Shinyama +
Satoshi Sekine +
New York University +
715, Broadway, 7th Floor +
New York, NY, 10003 +
{yusuke,sekine}@cs.nyu.edu +
Abstract +
We are trying to extend the boundary of +
Information Extraction (IE) systems. Ex- +
isting IE systems require a lot of time and +
human effort to tune for a new scenario. +
Preemptive Information Extraction is an +
attempt to automatically create all feasible +
IE systems in advance without human in- +
tervention. We propose a technique called +
Unrestricted Relation Discovery that dis- +
covers all possible relations from texts and +
presents them as tables. We present a pre- +
liminary system that obtains reasonably +
good results. +
1 Background +
Every day, a large number of news articles are cre- +
ated and reported, many of which are unique. But +
certain types of events, such as hurricanes or mur- +
ders, are reported again and again throughout a year. +
The goal of Information Extraction, or IE, is to re- +
trieve a certain type of news event from past articles +
and present the events as a table whose columns are +
filled with a name of a person or company, accord- +
ing to its role in the event. However, existing IE +
techniques require a lot of human labor. First, you +
have to specify the type of information you want and +
collect articles that include this information. Then, +
you have to analyze the articles and manually craft +
a set of patterns to capture these events. Most exist- +
ing IE research focuses on reducing this burden by +
helping people create such patterns. But each time +
you want to extract a different kind of information, +
you need to repeat the whole process: specify arti- +
cles and adjust its patterns, either manually or semi- +
automatically. There is a bit of a dangerous pitfall +
here. First, it is hard to estimate how good the sys- +
tem can be after months of work. Furthermore, you +
might not know if the task is even doable in the first +
place. Knowing what kind of information is easily +
obtained in advance would help reduce this risk. +
An IE task can be defined as finding a relation +
among several entities involved in a certain type of +
event. For example, in the MUC-6 management +
succession scenario, one seeks a relation between +
COMPANY, PERSON and POST involved with hir- +
ing/firing events. For each row of an extracted ta- +
ble, you can always read it as “COMPANY hired +
(or fired) PERSON for POST.” The relation between +
these entities is retained throughout the table. There +
are many existing works on obtaining extraction pat- +
terns for pre-defined relations (Riloff, 1996; Yangar- +
ber et al., 2000; Agichtein and Gravano, 2000; Sudo +
et al., 2003). +
Unrestricted Relation Discovery is a technique to +
automatically discover such relations that repeatedly +
appear in a corpus and present them as a table, with +
absolutely no human intervention. Unlike most ex- +
isting IE research, a user does not specify the type +
of articles or information wanted. Instead, a system +
tries to find all the kinds of relations that are reported +
multiple times and can be reported in tabular form. +
This technique will open up the possibility of try- +
ing new IE scenarios. Furthermore, the system itself +
can be used as an IE system, since an obtained re- +
lation is already presented as a table. If this system +
works to a certain extent, tuning an IE system be- +
comes a search problem: all the tables are already +
built “preemptively.” A user only needs to search +
for a relevant table. +
Page: 1
diff --git a/samples/nonfree/naacl06-shinyama.txt.ref b/samples/nonfree/naacl06-shinyama.txt.ref index 7ebbcfa..fd6b7e1 100644 --- a/samples/nonfree/naacl06-shinyama.txt.ref +++ b/samples/nonfree/naacl06-shinyama.txt.ref @@ -28,46 +28,37 @@ good results. 1 Background Every day, a large number of news articles are cre- -ated and reported, many of which are unique. -But +ated and reported, many of which are unique. But certain types of events, such as hurricanes or mur- ders, are reported again and again throughout a year. The goal of Information Extraction, or IE, is to re- trieve a certain type of news event from past articles and present the events as a table whose columns are filled with a name of a person or company, accord- -However, existing IE -ing to its role in the event. -techniques require a lot of human labor. -First, you +ing to its role in the event. However, existing IE +techniques require a lot of human labor. First, you have to specify the type of information you want and -collect articles that include this information. -Then, +collect articles that include this information. Then, you have to analyze the articles and manually craft a set of patterns to capture these events. Most exist- ing IE research focuses on reducing this burden by -helping people create such patterns. -But each time +helping people create such patterns. But each time you want to extract a different kind of information, you need to repeat the whole process: specify arti- cles and adjust its patterns, either manually or semi- -automatically. -There is a bit of a dangerous pitfall +automatically. There is a bit of a dangerous pitfall here. First, it is hard to estimate how good the sys- tem can be after months of work. Furthermore, you might not know if the task is even doable in the first -place. -Knowing what kind of information is easily +place. Knowing what kind of information is easily obtained in advance would help reduce this risk. An IE task can be defined as finding a relation among several entities involved in a certain type of -event. -For example, in the MUC-6 management +event. For example, in the MUC-6 management succession scenario, one seeks a relation between COMPANY, PERSON and POST involved with hir- -ing/firing events. -For each row of an extracted ta- +ing/firing events. For each row of an extracted ta- ble, you can always read it as “COMPANY hired (or fired) PERSON for POST.” The relation between these entities is retained throughout the table. There diff --git a/samples/nonfree/naacl06-shinyama.xml.ref b/samples/nonfree/naacl06-shinyama.xml.ref index de702fd..1433404 100644 --- a/samples/nonfree/naacl06-shinyama.xml.ref +++ b/samples/nonfree/naacl06-shinyama.xml.ref @@ -871,7 +871,7 @@
- + a t e @@ -916,10 +916,7 @@ u e . - - - - + B u t @@ -1260,31 +1257,7 @@ - -H -o -w -e -v -e -r -, - -e -x -i -s -t -i -n -g - -I -E - - - - + i n g @@ -1314,10 +1287,31 @@ n t . + +H +o +w +e +v +e +r +, + +e +x +i +s +t +i +n +g + +I +E - + t e c @@ -1358,10 +1352,7 @@ o r . - - - - + F i r @@ -1431,7 +1422,7 @@ - + c o l @@ -1479,10 +1470,7 @@ o n . - - - - + T h e @@ -1658,7 +1646,7 @@ - + h e l @@ -1695,10 +1683,7 @@ n s . - - - - + B u t @@ -1886,7 +1871,7 @@ - + a u t @@ -1901,10 +1886,7 @@ l y . - - - - + T h e @@ -2112,17 +2094,14 @@ - + p l a c e . - - - - + K n o @@ -2325,17 +2304,14 @@ - + e v e n t . - - - - + F o r @@ -2475,7 +2451,7 @@ - + i n g @@ -2493,10 +2469,7 @@ t s . - - - - + F o r diff --git a/samples/nonfree/nlp2004slides.html.ref b/samples/nonfree/nlp2004slides.html.ref index 808ba80..7fb0ccd 100644 --- a/samples/nonfree/nlp2004slides.html.ref +++ b/samples/nonfree/nlp2004slides.html.ref @@ -3,92 +3,13 @@ - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -C -o -m -p -u -t -e -r - -S -c -i -e -n -c -e - -D -e -p -a -r -t -m -e -n -t - -N -e -w - -Y -o -r -k - -U -n -i -v -e -r -s -i -t -y - +
コンパラブルな新聞記事からの +
固有表現の発見 +
新山 祐介 +
関根 聡 +
Computer Science Department +
New York University +
-
Page: 1
diff --git a/samples/simple1.html.ref b/samples/simple1.html.ref index 4309995..0325185 100644 --- a/samples/simple1.html.ref +++ b/samples/simple1.html.ref @@ -3,65 +3,13 @@ - - -H -e -l -l -o - - - -W -o -r -l -d - - -H -e -l -l -o - - - -W -o -r -l -d - - -H -e -l -l -o - - - -W -o -r -l -d - - -H -e -l -l -o - - - -W -o -r -l -d -
Page: 1
+
Hello +
World +
Hello +
World +
H e l l o +
W o r l d +
H e l l o +
W o r l d +
Page: 1
diff --git a/samples/simple3.html.ref b/samples/simple3.html.ref index 176bf8f..1ebbf45 100644 --- a/samples/simple3.html.ref +++ b/samples/simple3.html.ref @@ -3,42 +3,9 @@ - - -H -e -l -l -o -H -e -l -l -o - - - - - - - - - - - - -W - - -W -o -r -l -d - -o -r -l -d -
Page: 1
+
HelloHello +
あいうえおあいうえお W +
World +
orld +
Page: 1
diff --git a/tools/pdf2html.cgi b/tools/pdf2html.cgi index 3f75229..bb21221 100755 --- a/tools/pdf2html.cgi +++ b/tools/pdf2html.cgi @@ -1,4 +1,4 @@ -#!/usr/bin/python2 -O +#!/usr/bin/python -O # # pdf2html.cgi - Gateway script for converting PDF into HTML. # @@ -42,7 +42,7 @@ def url(base, **kw): ## convert ## class FileSizeExceeded(ValueError): pass -def convert(outfp, infp, path, codec='utf-8', +def convert(infp, outfp, path, codec='utf-8', maxpages=0, maxfilesize=0, pagenos=None, html=True): # save the input file. @@ -76,22 +76,22 @@ def convert(outfp, infp, path, codec='utf-8', class WebApp(object): TITLE = 'pdf2html demo' - APPPATH = '/' # absolute URL path to this application. - MAXFILESIZE = 5000000 # set to zero if unlimited. + MAXFILESIZE = 10000000 # set to zero if unlimited. MAXPAGES = 10 # set to zero if unlimited. - def __init__(self, infp=sys.stdin, outfp=sys.stdout, codec='utf-8'): + def __init__(self, infp=sys.stdin, outfp=sys.stdout, environ=os.environ, + codec='utf-8', apppath='/'): + self.infp = infp self.outfp = outfp self.codec = codec - self.remote_addr = os.environ.get('REMOTE_ADDR') - self.path_info = os.environ.get('PATH_INFO') - self.method = os.environ.get('REQUEST_METHOD', 'GET').upper() - self.server = os.environ.get('SERVER_SOFTWARE', '') - self.logpath = os.environ.get('LOG_PATH', './var/log') - self.tmpdir = os.environ.get('TEMP', './var/') + self.apppath = apppath + self.remote_addr = environ.get('REMOTE_ADDR') + self.path_info = environ.get('PATH_INFO') + self.method = environ.get('REQUEST_METHOD', 'GET').upper() + self.server = environ.get('SERVER_SOFTWARE', '') + self.tmpdir = environ.get('TEMP', './var/') self.content_type = 'text/html; charset=%s' % codec - self.cur_time = time.time() - self.form = cgi.FieldStorage(infp) + self.logger = logging.getLogger() return def put(self, *args): @@ -130,7 +130,7 @@ class WebApp(object): self.put( '%s\n' % q(self.TITLE), '

%s


\n' % q(self.TITLE), - '
\n' % q(self.APPPATH), + '\n' % q(self.apppath), '

Upload PDF File: \n', '  Page numbers (comma-separated):\n', '\n', @@ -145,49 +145,54 @@ class WebApp(object): ) return - def run(self, argv): - logging.basicConfig(level=logging.INFO, - format='%(asctime)s %(levelname)s %(message)s', - filename=self.logpath, filemode='a') - if self.path_info != self.APPPATH: + def setup(self): + if not os.path.isdir(self.tmpdir): + self.logger.error('no tmpdir') + status = 304 + elif self.path_info != self.apppath: + status = 404 + else: + status = 200 + self._status = status + return status + + def run(self): + form = cgi.FieldStorage(self.infp) + if self._status != 200: self.http_404() return - if not os.path.isdir(self.tmpdir): - logging.error('no tmpdir') - self.bummer('error') - return if (self.method != 'POST' or - 'c' not in self.form or - 'f' not in self.form): + 'c' not in form or + 'f' not in form): self.coverpage() return - item = self.form['f'] + item = form['f'] if not (item.file and item.filename): self.coverpage() return - cmd = self.form.getvalue('c') + cmd = form.getvalue('c') html = (cmd == 'Convert to HTML') pagenos = [] - if 'p' in self.form: - for m in re.finditer(r'\d+', self.form.getvalue('p')): + if 'p' in form: + for m in re.finditer(r'\d+', form.getvalue('p')): try: pagenos.append(int(m.group(0))) except ValueError: pass - logging.info('received: host=%s, name=%r, pagenos=%r' % - (self.remote_addr, item.filename, pagenos)) + self.logger.info('received: host=%s, name=%r, pagenos=%r' % + (self.remote_addr, item.filename, pagenos)) h = abs(hash((random.random(), self.remote_addr, item.filename))) - tmppath = os.path.join(self.tmpdir, '%08x%08x.pdf' % (self.cur_time, h)) + tmppath = os.path.join(self.tmpdir, '%08x%08x.pdf' % (time.time(), h)) try: if not html: self.content_type = 'text/plain; charset=%s' % self.codec self.http_200() try: - convert(sys.stdout, item.file, tmppath, pagenos=pagenos, codec=self.codec, + convert(item.file, sys.stdout, tmppath, pagenos=pagenos, codec=self.codec, maxpages=self.MAXPAGES, maxfilesize=self.MAXFILESIZE, html=html) except Exception, e: self.put('

Sorry, an error has occured: %s' % q(repr(e))) - logging.error('convert: %r: path=%r: %s' % (e, tmppath, traceback.format_exc())) + self.logger.error('convert: %r: path=%r: %s' % (e, tmppath, traceback.format_exc())) finally: try: os.remove(tmppath) @@ -197,4 +202,7 @@ class WebApp(object): # main -if __name__ == '__main__': sys.exit(WebApp().run(sys.argv)) +if __name__ == '__main__': + app = WebApp() + app.setup() + sys.exit(app.run())