aboutsummaryrefslogtreecommitdiff
path: root/chinese
diff options
context:
space:
mode:
authorRene Ladan <rene@FreeBSD.org>2020-01-27 15:34:18 +0000
committerRene Ladan <rene@FreeBSD.org>2020-01-27 15:34:18 +0000
commitaa2769119334a5045d38419995aca597ea24b1f1 (patch)
tree46f389d2a7bc016aa58737ba87b33fe1dfdfd3fe /chinese
parentad735287aef46d649c1c08ea3d049288113148cb (diff)
downloadports-aa2769119334a5045d38419995aca597ea24b1f1.tar.gz
ports-aa2769119334a5045d38419995aca597ea24b1f1.zip
Remove expired ports:
2020-01-27 accessibility/py-papi: Unmaintained, uses EOLed python27 2020-01-27 archivers/py-czipfile: Unmaintained, uses EOLed python27 2020-01-27 audio/boodler: Unmaintained, uses EOLed python27 2020-01-27 audio/dir2ogg: Unmaintained, uses EOLed python27 2020-01-27 audio/jokosher: Unmaintained, uses EOLed python27 2020-01-27 audio/mpdbrowser: Unmaintained, uses EOLed python27 2020-01-27 audio/nekobee: Unmaintained, uses EOLed python27 2020-01-27 audio/patchage: Unmaintained, uses EOLed python27 2020-01-27 audio/py-ao: Unmaintained, uses EOLed python27 2020-01-27 audio/py-id3: Unmaintained, uses EOLed python27 2020-01-27 audio/py-shout: Unmaintained, uses EOLed python27 2020-01-27 audio/py-speex: Unmaintained, uses EOLed python27 2020-01-27 audio/pytone: Unmaintained, uses EOLed python27 2020-01-27 audio/solfege: Unmaintained, uses EOLed python27 2020-01-27 audio/trommler: Unmaintained, uses EOLed python27 2020-01-27 benchmarks/pybench: Unmaintained, uses EOLed python27 2020-01-27 biology/pycogent: Unmaintained, uses EOLed python27 2020-01-27 biology/unanimity: Unmaintained, uses EOLed python27 2020-01-27 cad/pythoncad: Unmaintained, uses EOLed python27 2020-01-27 chinese/bg5pdf: Unmaintained, uses EOLed python27 2020-01-27 comms/py-libimobiledevice: Unmaintained, uses EOLed python27 2020-01-27 converters/py-bcode: Unmaintained, uses EOLed python27 2020-01-27 converters/py-iconv: Unmaintained, uses EOLed python27 2020-01-27 converters/py-zfec: Unmaintained, uses EOLed python27 2020-01-27 databases/gadfly: Unmaintained, uses EOLed python27 2020-01-27 databases/metakit: Unmaintained, uses EOLed python27 2020-01-27 databases/openark-kit: Unmaintained, uses EOLed python27 2020-01-27 databases/py-MySQLdb55: Unmaintained, uses EOLed python27 2020-01-27 databases/py-MySQLdb56: Unmaintained, uses EOLed python27 2020-01-27 databases/py-forgetsql: Unmaintained, uses EOLed python27 2020-01-27 databases/py-oops: Unmaintained, uses EOLed python27 2020-01-27 databases/py-rrdtool_lgpl: Unmaintained, uses EOLed python27 2020-01-27 deskutils/conkyemail: No longer maintained by upstream 2020-01-27 deskutils/cycle: Unmaintained, uses EOLed python27 2020-01-27 deskutils/everygui: Unmaintained, uses EOLed python27 2020-01-27 deskutils/ganyremote: Unmaintained, uses EOLed python27 2020-01-27 deskutils/pypanel: Unmaintained, uses EOLed python27 2020-01-27 deskutils/taskcoach: Unmaintained, uses EOLed python27 2020-01-27 deskutils/tel: Unmaintained, uses EOLed python27 2020-01-27 deskutils/tnote: Unmaintained, uses EOLed python27 2020-01-27 deskutils/vnc2flv: Unmaintained, uses EOLed python27 2020-01-27 deskutils/wammu: Unmaintained, uses EOLed python27 2020-01-27 devel/bbfreeze: Unmaintained, uses EOLed python27 2020-01-27 devel/bzr-builder: Unmaintained, uses EOLed python27 2020-01-27 devel/bzr-colo: Unmaintained, uses EOLed python27 2020-01-27 devel/bzr-externals: Unmaintained, uses EOLed python27 2020-01-27 devel/bzr-git: Unmaintained, uses EOLed python27 2020-01-27 devel/bzr-gtk: Unmaintained, uses EOLed python27 2020-01-27 devel/bzr-loom: Unmaintained, uses EOLed python27 2020-01-27 devel/bzr-pipeline: Unmaintained, uses EOLed python27 2020-01-27 devel/bzr-rewrite: Unmaintained, uses EOLed python27 2020-01-27 devel/bzr-scmproj: Unmaintained, uses EOLed python27 2020-01-27 devel/bzr-stats: Unmaintained, uses EOLed python27 2020-01-27 devel/bzr-svn: Unmaintained, uses EOLed python27 2020-01-27 devel/bzr-upload: Unmaintained, uses EOLed python27 2020-01-27 devel/ditrack: Unmaintained, uses EOLed python27 2020-01-27 devel/drpython: Unmaintained, uses EOLed python27 2020-01-27 devel/epydoc: Unmaintained, uses EOLed python27 2020-01-27 devel/fb303: Unmaintained, uses EOLed python27 2020-01-27 devel/fnorb: Unmaintained, uses EOLed python27 2020-01-27 devel/gazpacho: Unmaintained, uses EOLed python27 2020-01-27 devel/libmpsse: Unmaintained, uses EOLed python27 2020-01-27 devel/open-usp-tukubai: Unmaintained, uses EOLed python27 2020-01-27 devel/phpbt: Unmaintained, uses EOLed python27 2020-01-27 devel/py-anonfunc: Unmaintained, uses EOLed python27 2020-01-27 devel/py-bison: Unmaintained, uses EOLed python27 2020-01-27 devel/py-fortran: Unmaintained, uses EOLed python27 2020-01-27 devel/py-grouch: Unmaintained, uses EOLed python27 2020-01-27 devel/py-mwlib.rl: Unmaintained, uses EOLed python27 2020-01-27 devel/py-nagioscheck: Unmaintained, uses EOLed python27 2020-01-27 devel/py-ncurses: Unmaintained, uses EOLed python27 2020-01-27 devel/py-ocempgui: Unmaintained, uses EOLed python27 2020-01-27 devel/py-palm: Unmaintained, uses EOLed python27 2020-01-27 devel/py-pyechonest: Unmaintained, uses EOLed python27 2020-01-27 devel/py-resourcepackage: Unmaintained, uses EOLed python27 2020-01-27 devel/py-rlcompleter2: Unmaintained, uses EOLed python27 2020-01-27 devel/py-spark: Unmaintained, uses EOLed python27 2020-01-27 devel/py-xoltar-toolkit: Unmaintained, uses EOLed python27 2020-01-27 devel/py-zkpython: Unmaintained, uses EOLed python27 2020-01-27 devel/pychecker: Unmaintained, uses EOLed python27 2020-01-27 devel/pymacs: Unmaintained, uses EOLed python27 2020-01-27 devel/trac-bitten: Unmaintained, uses EOLed python27 2020-01-27 devel/wxGlade: Unmaintained, uses EOLed python27 2020-01-27 emulators/catapult: Unmaintained, uses EOLed python27 2020-01-27 emulators/dynagui: Unmaintained, uses EOLed python27 2020-01-27 finance/mybudget: Unmaintained, uses EOLed python27 2020-01-27 finance/sabernetdcs-client: Unmaintained, uses EOLed python27 2020-01-27 games/4stattack: Unmaintained, uses EOLed python27 2020-01-27 games/barbie_seahorse_adventures: Unmaintained, uses EOLed python27 2020-01-27 games/battletanks: Unmaintained, uses EOLed python27 2020-01-27 games/bombz: Unmaintained, uses EOLed python27 2020-01-27 games/bouncy: Unmaintained, uses EOLed python27 2020-01-27 games/bubbros: Unmaintained, uses EOLed python27 2020-01-27 games/childsplay: Unmaintained, uses EOLed python27 2020-01-27 games/crossfire-server: Unmaintained, uses EOLed python27 2020-01-27 games/duckmaze: Unmaintained, uses EOLed python27 2020-01-27 games/farblazer: Unmaintained, uses EOLed python27 2020-01-27 games/gbottler: Unmaintained, uses EOLed python27 2020-01-27 games/glchess: Unmaintained, uses EOLed python27 2020-01-27 games/gretools: Unmaintained, uses EOLed python27 2020-01-27 games/kye: Unmaintained, uses EOLed python27 2020-01-27 games/liquidwar: Unmaintained, uses EOLed python27 2020-01-27 games/mopesnake: Unmaintained, uses EOLed python27 2020-01-27 games/nelly: Unmaintained, uses EOLed python27 2020-01-27 games/oneisenough: Unmaintained, uses EOLed python27 2020-01-27 games/ptkei: Unmaintained, uses EOLed python27 2020-01-27 games/py-poker-eval: Unmaintained, uses EOLed python27 2020-01-27 games/pycadia: Unmaintained, uses EOLed python27 2020-01-27 games/pydance: Unmaintained, uses EOLed python27 2020-01-27 games/pysycache: Unmaintained, uses EOLed python27 2020-01-27 games/pythonchess: Unmaintained, uses EOLed python27 2020-01-27 games/pytowerdefense: Unmaintained, uses EOLed python27 2020-01-27 games/rtb: Unmaintained, uses EOLed python27 2020-01-27 games/schiff: Unmaintained, uses EOLed python27 2020-01-27 games/schwarzweiss: Unmaintained, uses EOLed python27 2020-01-27 games/secrettower: Unmaintained, uses EOLed python27 2020-01-27 games/slune: Unmaintained, uses EOLed python27 2020-01-27 games/super_mario_bros_python: Unmaintained, uses EOLed python27 2020-01-27 games/tuxfighter: Unmaintained, uses EOLed python27 2020-01-27 games/twitch: Unmaintained, uses EOLed python27 2020-01-27 games/vegastrike: Unmaintained, uses EOLed python27 2020-01-27 games/zephulor: Unmaintained, uses EOLed python27 2020-01-27 graphics/boxer: Unmaintained, uses EOLed python27 2020-01-27 graphics/electrix: Unmaintained, uses EOLed python27 2020-01-27 graphics/exact-image: Unmaintained, uses EOLed python27 2020-01-27 graphics/gnofract4d: Unmaintained, uses EOLed python27 2020-01-27 graphics/gsculpt: Unmaintained, uses EOLed python27 2020-01-27 graphics/imgtops: Unmaintained, uses EOLed python27 2020-01-27 graphics/imgv: Unmaintained, uses EOLed python27 2020-01-27 graphics/lcms-python: Unmaintained, uses EOLed python27 2020-01-27 graphics/mirage: Unmaintained, uses EOLed python27 2020-01-27 graphics/partio: Unmaintained, uses EOLed python27 2020-01-27 graphics/py-exif: Unmaintained, uses EOLed python27 2020-01-27 graphics/py-gd: Unmaintained, uses EOLed python27 2020-01-27 graphics/py-paint: Unmaintained, uses EOLed python27 2020-01-27 graphics/pygts: Unmaintained, uses EOLed python27 2020-01-27 graphics/pysvg: Unmaintained, uses EOLed python27 2020-01-27 irc/py-supybot-plugins: Unmaintained, uses EOLed python27 2020-01-27 japanese/kana-no-quiz: Unmaintained, uses EOLed python27 2020-01-27 lang/py-prolog: Unmaintained, uses EOLed python27 2020-01-27 lang/sdcc: Unmaintained, uses EOLed python27 2020-01-27 mail/archivemail: Unmaintained, uses EOLed python27 2020-01-27 mail/mailfmt: Unmaintained, uses EOLed python27 2020-01-27 mail/py-libgmail: Unmaintained, uses EOLed python27 2020-01-27 mail/py-ppolicy: Unmaintained, uses EOLed python27 2020-01-27 mail/rss2email2: Unmaintained, uses EOLed python27 2020-01-27 mail/svnmailer: Unmaintained, uses EOLed python27 2020-01-27 math/biggles: Unmaintained, uses EOLed python27 2020-01-27 math/py-gato: Unmaintained, uses EOLed python27 2020-01-27 math/py-gnuplot: Unmaintained, uses EOLed python27 2020-01-27 math/py-mathdom: Unmaintained, uses EOLed python27 2020-01-27 math/py-probstat: Unmaintained, uses EOLed python27 2020-01-27 math/py-rpy: Unmaintained, uses EOLed python27 2020-01-27 misc/gnome-osd: Unmaintained, uses EOLed python27 2020-01-27 misc/gonvert: Unmaintained, uses EOLed python27 2020-01-27 misc/metalink-editor: Unmaintained, uses EOLed python27 2020-01-27 misc/py-YABT: Unmaintained, uses EOLed python27 2020-01-27 misc/xdg-menu: Unmaintained, uses EOLed python27 2020-01-27 multimedia/devede: Unmaintained, uses EOLed python27 2020-01-27 multimedia/gdvrecv: Unmaintained, uses EOLed python27 2020-01-27 multimedia/mmpython: Unmaintained, uses EOLed python27 2020-01-27 multimedia/pymp: Unmaintained, uses EOLed python27 2020-01-27 net/gtknetcat: Unmaintained, uses EOLed python27 2020-01-27 net/ntlmaps: Unmaintained, uses EOLed python27 2020-01-27 net/polyorb: Unmaintained, uses EOLed python27 2020-01-27 net/py-zsi: Unmaintained, uses EOLed python27 2020-01-27 net/pythondirector: Unmaintained, uses EOLed python27 2020-01-27 net/sippy_b2bua: Unmaintained, uses EOLed python27 2020-01-27 net-im/py-jabber: Unmaintained, uses EOLed python27 2020-01-27 net-im/py-jabberbot: Unmaintained, uses EOLed python27 2020-01-27 net-im/py-libturpial: Unmaintained, uses EOLed python27 2020-01-27 net-im/py-xmpppy-irc: Unmaintained, uses EOLed python27 2020-01-27 net-mgmt/pdagent-integrations: Unmaintained, uses EOLed python27 2020-01-27 net-p2p/tribler: Unmaintained, uses EOLed python27 2020-01-27 news/papercut: Unmaintained, uses EOLed python27 2020-01-27 print/pkipplib: Unmaintained, uses EOLed python27 2020-01-27 print/pkpgcounter: Unmaintained, uses EOLed python27 2020-01-27 print/ttfquery: Unmaintained, uses EOLed python27 2020-01-27 science/gwyddion: Unmaintained, uses EOLed python27 2020-01-27 science/psychopy: Unmaintained, uses EOLed python27 2020-01-27 science/py-hcluster: Unmaintained, uses EOLed python27 2020-01-27 science/py-pyteomics.biolccc: Unmaintained, uses EOLed python27 2020-01-27 science/pycdf: Unmaintained, uses EOLed python27 2020-01-27 security/blindelephant: Unmaintained, uses EOLed python27 2020-01-27 security/cfv: Unmaintained, uses EOLed python27 2020-01-27 security/fsh: Unmaintained, uses EOLed python27 2020-01-27 security/gcipher: Unmaintained, uses EOLed python27
Notes
Notes: svn path=/head/; revision=524263
Diffstat (limited to 'chinese')
-rw-r--r--chinese/Makefile1
-rw-r--r--chinese/bg5pdf/Makefile48
-rw-r--r--chinese/bg5pdf/distinfo2
-rw-r--r--chinese/bg5pdf/files/gbpdf299
-rw-r--r--chinese/bg5pdf/pkg-descr7
-rw-r--r--chinese/bg5pdf/pkg-plist6
6 files changed, 0 insertions, 363 deletions
diff --git a/chinese/Makefile b/chinese/Makefile
index 828bc909120a..16ed1ec17824 100644
--- a/chinese/Makefile
+++ b/chinese/Makefile
@@ -12,7 +12,6 @@
SUBDIR += auto-cn-l10n
SUBDIR += auto-tw-l10n
SUBDIR += autoconvert
- SUBDIR += bg5pdf
SUBDIR += big5width
SUBDIR += bitchx
SUBDIR += brise
diff --git a/chinese/bg5pdf/Makefile b/chinese/bg5pdf/Makefile
deleted file mode 100644
index 7ca9480543d8..000000000000
--- a/chinese/bg5pdf/Makefile
+++ /dev/null
@@ -1,48 +0,0 @@
-# Created by: Shen Chuan-Hsing
-# $FreeBSD$
-
-PORTNAME= bg5pdf
-PORTVERSION= 1.0.0
-PORTREVISION= 8
-CATEGORIES= chinese print
-MASTER_SITES= LOCAL/chinsan
-
-MAINTAINER= ports@FreeBSD.org
-COMMENT= Convert Chinese-Big5 encoded files to PDF, using PDFlib
-
-DEPRECATED= Unmaintained, uses EOLed python27
-EXPIRATION_DATE= 2020-01-27
-
-LICENSE= GPLv2
-
-LIB_DEPENDS= libpdf.so:print/pdflib
-
-USES= python:2.7 shebangfix
-SHEBANG_FILES= bg5pdf gbpdf
-python_OLD_CMD= "/usr/bin/env /usr/bin/python"
-
-CFLAGS+= -fPIC
-WRKSRC= ${WRKDIR}/${PORTNAME}
-
-OPTIONS_DEFINE= EXAMPLES
-
-post-extract:
- @${CP} ${FILESDIR}/gbpdf ${WRKSRC}
-
-do-build:
- ${CC} ${CFLAGS} -shared ${WRKSRC}/bg5pdflib.c -I${PREFIX}/include \
- -I${PYTHON_INCLUDEDIR} -L${PREFIX}/lib -lpdf -o ${WRKSRC}/bg5pdflib.so
-
-do-install:
- @${MKDIR} ${STAGEDIR}${PYTHON_SITELIBDIR}
- ${INSTALL_LIB} ${WRKSRC}/bg5pdflib.so ${STAGEDIR}${PYTHON_SITELIBDIR}
- ${INSTALL_SCRIPT} ${WRKSRC}/bg5pdf ${STAGEDIR}${PREFIX}/bin
- ${INSTALL_SCRIPT} ${WRKSRC}/gbpdf ${STAGEDIR}${PREFIX}/bin
-
-do-install-EXAMPLES-on:
- @${MKDIR} ${STAGEDIR}${EXAMPLESDIR}
- ${INSTALL_DATA} ${WRKSRC}/test.big5 ${STAGEDIR}${EXAMPLESDIR}
- ${INSTALL_DATA} ${WRKSRC}/test.big5.pdf ${STAGEDIR}${EXAMPLESDIR}
- ${INSTALL_SCRIPT} ${WRKSRC}/genTest.py ${STAGEDIR}${EXAMPLESDIR}
-
-.include <bsd.port.mk>
diff --git a/chinese/bg5pdf/distinfo b/chinese/bg5pdf/distinfo
deleted file mode 100644
index 735aab164ed0..000000000000
--- a/chinese/bg5pdf/distinfo
+++ /dev/null
@@ -1,2 +0,0 @@
-SHA256 (bg5pdf-1.0.0.tar.gz) = 624b4dbfa54ae8f409b581991493473f8442f1403602a7432c0db479ec1a13ee
-SIZE (bg5pdf-1.0.0.tar.gz) = 55208
diff --git a/chinese/bg5pdf/files/gbpdf b/chinese/bg5pdf/files/gbpdf
deleted file mode 100644
index 802a3a6a350b..000000000000
--- a/chinese/bg5pdf/files/gbpdf
+++ /dev/null
@@ -1,299 +0,0 @@
-#!/usr/bin/env python
-
-"""
-Bg5pdf is a simple wrapper for wrapping big5 encoding text file into
-PDF file by using PDFlib. The output of this program does not contain
-embedding fonts. You have to download Acrobat Acroread Asianfont pack
-to view and print the output file. This wrapper does not provide any
-formatting function except simple line wrapping. If you need
-sophisticated formatting, you should try CJK-LaTex or other equivalent
-tools.
-
-Information about PDFlib can be found at http://www.pdflib.com.
-You might need it if you need to compile bg5pdflib module which
-is used by gbpdf.
-
-You can download Acrobat Acroread Asianfont Pack at
-http://www.adobe.com/products/acrobat/acrrasianfontpack.html
-
-============================================================================
-
-Copyright (C) 2001 by Chen-Shan Chin
-gbpdf ver. 1.0 Date:Jun 3 2001
-
- This program is free software; you can redistribute it and/or modify
- it under the terms of the GNU General Public License as published by
- the Free Software Foundation; either version 2 of the License, or any
- later version. This program is distributed in the hope that it will
- be useful, but WITHOUT ANY WARRANTY; without even implied warranty of
- MERCHANTABILITY of FITTNESS
-
- FOR A PARTICULAR PURPOSE. See the GNU General Public License for more
- details.
-
- You should have received a copy of the GNU General Public License
- along with this program; if not, write to the Free Sofeware
- Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA
-
-"""
-
-import getopt
-from string import *
-from sys import *
-from bg5pdflib import *
-#If you want to use python binding (pdflib_py.so) coming with PDFlib,
-#remark the above line and unmark the next line.
-#from pdflib_py import *
-
-
-False = 0
-True = 1
-
-ASCII = 0
-GB2312 = 1
-
-
-def renderer(doc, fn):
- p = PDF_new()
- if PDF_open_file(p, fn) == -1:
- print "Couldn't open PDF file '%s'\n" % fn
- exit(2)
- PDF_set_info(p, "Author", "gbpdf")
- PDF_set_info(p, "Creator", "gbpdf")
- PDF_set_info(p, "Title", "%s" % fn)
- cfname = doc.fontName
- cEncoding = doc.encoding
- fontSize = doc.fontSize
- topM = 792.0 / 11.0
- leftM = 792.0 / 11.0
-
- PDF_begin_page(p, 612, 792)
- font = PDF_findfont(p, cfname, cEncoding, 0)
- PDF_setfont(p, font, fontSize)
- mode = GB2312
- y = 0
- pageN = 1
- for l in doc.parsedLines:
- if len(l) == 0:
- y = y + fontSize
- continue
- x = 0.0
- PDF_set_text_pos(p, leftM + x, 792 - topM -y)
- curStr = ""
- for pos in range(len(l)):
- ch = l[pos]
- if ch[0] != mode:
- if len(curStr) != 0:
- if mode == GB2312:
- font = PDF_findfont(p, cfname, cEncoding, 0)
- PDF_setfont(p, font, fontSize)
- PDF_show(p, curStr)
- else:
- font = PDF_findfont(p, "Courier", "host", 0)
- PDF_setfont(p, font, fontSize)
- PDF_show(p, curStr)
- mode = ch[0]
- curStr = ch[1]
- else:
- curStr = curStr + ch[1]
-
- if len(curStr) != 0:
- if mode == 1:
- font = PDF_findfont(p, cfname, cEncoding, 0)
- PDF_setfont(p, font, fontSize)
- PDF_show(p, curStr)
- else:
- font = PDF_findfont(p, "Courier", "host", 0)
- PDF_setfont(p, font, fontSize)
- PDF_show(p, curStr)
-
- y = y + fontSize + doc.lineSpacing
- if y > 792 - 2* topM:
- font = PDF_findfont(p, "Helvetica-Oblique", "host", 0)
- PDF_setfont(p, font, 12)
- PDF_show_xy(p,"Converted to PDF by gbpdf", 400, 750)
- PDF_show_xy(p,"file name: %s--Page %d" % (doc.infileName, pageN), 60,750)
- PDF_setlinewidth(p,2)
- PDF_moveto(p, 50, 740)
- PDF_lineto(p, 562, 740)
- PDF_stroke(p)
- PDF_end_page(p)
- pageN = pageN + 1
- PDF_begin_page(p, 612, 792)
- font = PDF_findfont(p, cfname, cEncoding, 0)
- PDF_setfont(p, font, fontSize)
- mode = GB2312
- y = 0
- font = PDF_findfont(p, "Helvetica-Oblique", "host", 0)
- PDF_setfont(p, font, 12)
- PDF_show_xy(p,"Converted to PDF by gbpdf", 400, 750);
- PDF_show_xy(p,"file name: %s--Page %d" % (doc.infileName, pageN), 60,750)
- PDF_setlinewidth(p,2)
- PDF_moveto(p, 50, 740)
- PDF_lineto(p, 562, 740)
- PDF_stroke(p)
- PDF_end_page(p)
- PDF_close(p)
- PDF_delete(p)
-
-class document:
- infileName = ""
- fontSize = 12;
- fontNames = ["STSong-Light"]
- fontName = fontNames[0]
- encodings = ["GBK-EUC-H"]
- encoding = encodings[0]
- wrapped = False
- numOfChr = 55 #number of character per line for wrapping text
- parsedLines=[]
- lineSpacing = 2
-
- def getChr(self, st, i):
- if i + 1 < len(st) and\
- (ord(st[i]) >= 161 and ord(st[i]) <= 249) and \
- ((ord(st[i+1]) >=64 and ord(st[i+1]) <=126) or \
- (ord(st[i+1]) >=161 and ord(st[i+1]) <=254)) : # bg5_c
- cnchr = st[i:i+2]
- return (cnchr, 2)
- else:
- cnchr = st[i]
- return (cnchr, 1)
-
- def setFontSize(self, fs):
- self.fontSize = fs
-
- def setFont(self, fn):
- if not fn in self.fontNames:
- raise FontError
- else:
- self.fontName = fn
-
- def setWrapped(self, yn, nc):
- if yn > 0:
- self.wrapped = True
- self.numOfChr = nc
-
- def setLineSpacing(self, ls):
- self.lineSpacing = ls
-
- def setFontSize(self, fs):
- self.fontSize = fs
-
- def parseFile(self, filename):
- self.infileName = filename
- try:
- f = open(filename,"r");
- except IOError:
- print 'can not open file: "%s"' % filename
- exit(2)
- for line in f.readlines():
- line = rstrip(line)
- #if line[-1] == '\n':
- # line = line[:-1]
- if len(line) == 0:
- self.parsedLines.append([])
- continue
- pline = []
- pos = 0
- cpos = 0
- line_len = len(line)
- while 1:
- (chrx, inc) = self.getChr(line, pos)
- pos = pos + inc
- cpos = cpos + inc
- if inc == 2:
- pline.append([GB2312, chrx])
- else:
- pline.append([ASCII, chrx])
- if pos >= line_len:
- break
- if (self.wrapped == True) and ((cpos + 2) >= self.numOfChr):
- cpos = 0
- self.parsedLines.append(pline)
- pline = []
- self.parsedLines.append(pline)
-
-def usage():
- print "usage: gbpdf [option] inputfile outfile"
- print "d: integer, s:string"
- print "-w d, --wrap=d: wrapping line up to d ASCII characters (Each GB2312 character"
- print " occupis two ASCII character spaces.)"
- print "-s d, --size=d: set the size of font (default: 11)"
- print "-f s, --font=s: set font (default: 'Msung-Light')"
- print "-l d, --linespacing=d: set spacing between line (default:2)"
- print "--inputfile=s: input file name"
- print "--outputfile=s: outfile name (default: inputfile.pdf)"
- print "--showfonts: show avaiable fonts"
-
-getopt.GetoptError = getopt.error
-
-def main():
- try:
- opts, args =\
- getopt.getopt(argv[1:],
- "w:s:f:l:",
- ["size=",
- "font=",
- "linespacing=",
- "inputfile=",
- "outputfile=",
- "wrap=",
- "showfonts"])
- except getopt.error:
- usage()
- exit(2)
-
- #print opts, args
-
- doc = document()
- doc.setFont(doc.fontNames[0])
- doc.setWrapped(False, 0)
- doc.setLineSpacing(2)
- doc.setFontSize(11)
-
- infile = ""
- outfile = ""
-
- for opt in opts:
- if opt[0] == "--size" or opt[0] == "-s":
- doc.setFontSize(atof(opt[1]))
- continue
- if opt[0] == "--font" or opt[0] == "-f":
- doc.setFont(opt[1])
- continue
- if opt[0] == "--wrap" or opt[0] == "-w":
- doc.setWrapped(True, atoi(opt[1]))
- continue
- if opt[0] == "--linespacing" or opt[0] == "-l":
- doc.setLineSpacing(atof(opt[1]))
- if opt[0] == "--inputfile":
- infile = opt[1]
- continue
- if opt[0] == "--outfile":
- outfile = opt[1]
- continue
- if opt[0] == "--showfonts":
- print "Avaiable Fonts:"
- for f in doc.fontNames:
- print f
- exit(2)
-
- if len(args) == 2:
- infile = args[0]
- outfile = args[1]
- elif len(args) == 1:
- infile = args[0]
-
- if infile == "":
- print "no input file name"
- exit(2)
-
- if outfile == "":
- outfile = infile+".pdf"
-
- doc.parseFile(infile)
- renderer(doc,outfile)
- print "Output File is %s" % outfile
-
-if __name__ == "__main__":
- main()
diff --git a/chinese/bg5pdf/pkg-descr b/chinese/bg5pdf/pkg-descr
deleted file mode 100644
index 87549108d372..000000000000
--- a/chinese/bg5pdf/pkg-descr
+++ /dev/null
@@ -1,7 +0,0 @@
-bg5pdf is a simple wrapper for wrapping Big5 encoding text file into
-PDF file by using PDFlib. The output of this program does not contain
-embedding fonts. You have to download Acrobat Acroread Asianfont pack
-to view and print the output file. This wrapper does not provide any
-formatting function except simple line wrapping. If you need
-sophisticated formatting, you should try CJK-LaTex or other equivalent
-tools.
diff --git a/chinese/bg5pdf/pkg-plist b/chinese/bg5pdf/pkg-plist
deleted file mode 100644
index 3200f4a68408..000000000000
--- a/chinese/bg5pdf/pkg-plist
+++ /dev/null
@@ -1,6 +0,0 @@
-bin/bg5pdf
-bin/gbpdf
-%%PYTHON_SITELIBDIR%%/bg5pdflib.so
-%%PORTEXAMPLES%%%%EXAMPLESDIR%%/genTest.py
-%%PORTEXAMPLES%%%%EXAMPLESDIR%%/test.big5
-%%PORTEXAMPLES%%%%EXAMPLESDIR%%/test.big5.pdf