summaryrefslogtreecommitdiff
path: root/AppPkg/Applications/Python/Python-2.7.10/Modules/cjkcodecs/emu_jisx0213_2000.h
diff options
context:
space:
mode:
authorDaryl McDaniel <edk2-lists@mc2research.org>2015-11-07 19:25:02 +0000
committerdarylm503 <darylm503@Edk2>2015-11-07 19:25:02 +0000
commit7eb75bccb5dacb658c63db1a9a980950c3d54d42 (patch)
treec65d20ea504fcb34afb6c10265f8dc60b7fb72e8 /AppPkg/Applications/Python/Python-2.7.10/Modules/cjkcodecs/emu_jisx0213_2000.h
parentc8042e10763bca064df257547d04ae3dfcdfaf91 (diff)
downloadedk2-platforms-7eb75bccb5dacb658c63db1a9a980950c3d54d42.tar.xz
AppPkg/Applications/Python/Python-2.7.10: Initial Checkin part 2/5.
The Modules directory from the cPython 2.7.10 distribution. These files are unchanged and set the baseline for subsequent commits. Contributed-under: TianoCore Contribution Agreement 1.0 Signed-off-by: Daryl McDaniel <edk2-lists@mc2research.org> git-svn-id: https://svn.code.sf.net/p/edk2/code/trunk/edk2@18738 6f19259b-4bc3-4df7-8a09-765794883524
Diffstat (limited to 'AppPkg/Applications/Python/Python-2.7.10/Modules/cjkcodecs/emu_jisx0213_2000.h')
-rw-r--r--AppPkg/Applications/Python/Python-2.7.10/Modules/cjkcodecs/emu_jisx0213_2000.h43
1 files changed, 43 insertions, 0 deletions
diff --git a/AppPkg/Applications/Python/Python-2.7.10/Modules/cjkcodecs/emu_jisx0213_2000.h b/AppPkg/Applications/Python/Python-2.7.10/Modules/cjkcodecs/emu_jisx0213_2000.h
new file mode 100644
index 0000000000..ca22858463
--- /dev/null
+++ b/AppPkg/Applications/Python/Python-2.7.10/Modules/cjkcodecs/emu_jisx0213_2000.h
@@ -0,0 +1,43 @@
+/* These routines may be quite inefficient, but it's used only to emulate old
+ * standards. */
+
+#ifndef EMULATE_JISX0213_2000_ENCODE_INVALID
+#define EMULATE_JISX0213_2000_ENCODE_INVALID 1
+#endif
+
+#define EMULATE_JISX0213_2000_ENCODE_BMP(assi, c) \
+ if (config == (void *)2000 && ( \
+ (c) == 0x9B1C || (c) == 0x4FF1 || \
+ (c) == 0x525D || (c) == 0x541E || \
+ (c) == 0x5653 || (c) == 0x59F8 || \
+ (c) == 0x5C5B || (c) == 0x5E77 || \
+ (c) == 0x7626 || (c) == 0x7E6B)) \
+ return EMULATE_JISX0213_2000_ENCODE_INVALID; \
+ else if (config == (void *)2000 && (c) == 0x9B1D) \
+ (assi) = 0x8000 | 0x7d3b; \
+
+#define EMULATE_JISX0213_2000_ENCODE_EMP(assi, c) \
+ if (config == (void *)2000 && (c) == 0x20B9F) \
+ return EMULATE_JISX0213_2000_ENCODE_INVALID;
+
+#ifndef EMULATE_JISX0213_2000_DECODE_INVALID
+#define EMULATE_JISX0213_2000_DECODE_INVALID 2
+#endif
+
+#define EMULATE_JISX0213_2000_DECODE_PLANE1(assi, c1, c2) \
+ if (config == (void *)2000 && \
+ (((c1) == 0x2E && (c2) == 0x21) || \
+ ((c1) == 0x2F && (c2) == 0x7E) || \
+ ((c1) == 0x4F && (c2) == 0x54) || \
+ ((c1) == 0x4F && (c2) == 0x7E) || \
+ ((c1) == 0x74 && (c2) == 0x27) || \
+ ((c1) == 0x7E && (c2) == 0x7A) || \
+ ((c1) == 0x7E && (c2) == 0x7B) || \
+ ((c1) == 0x7E && (c2) == 0x7C) || \
+ ((c1) == 0x7E && (c2) == 0x7D) || \
+ ((c1) == 0x7E && (c2) == 0x7E))) \
+ return EMULATE_JISX0213_2000_DECODE_INVALID;
+
+#define EMULATE_JISX0213_2000_DECODE_PLANE2(assi, c1, c2) \
+ if (config == (void *)2000 && (c1) == 0x7D && (c2) == 0x3B) \
+ (assi) = 0x9B1D;