|
From: <ai...@us...> - 2010-10-08 17:54:29
|
Revision: 11251
http://plplot.svn.sourceforge.net/plplot/?rev=11251&view=rev
Author: airwin
Date: 2010-10-08 17:54:23 +0000 (Fri, 08 Oct 2010)
Log Message:
-----------
For unicode-aware devices follow what is done for the Hershey case
(pldeco in src/plsym.c) for epsilon, theta, and phi. This means the
#ge, #gh, and #gf escapes give users the Greek lunate epsilon, the
ordinary Greek lower case theta (as opposed to the Greek symbol theta
= script theta), and the Greek symbol phi for Unicode fonts just like
has occurred since the dawn of PLplot history (I checked 5.1.0) for
the Hershey font case.
Modified Paths:
--------------
trunk/src/plcore.c
Modified: trunk/src/plcore.c
===================================================================
--- trunk/src/plcore.c 2010-10-08 17:45:46 UTC (rev 11250)
+++ trunk/src/plcore.c 2010-10-08 17:54:23 UTC (rev 11251)
@@ -11,7 +11,7 @@
* Copyright (C) 2004, 2005 Rafael Laboissiere
* Copyright (C) 2004, 2006 Andrew Ross
* Copyright (C) 2004 Andrew Roach
- * Copyright (C) 2005, 2006, 2007, 2008, 2009 Alan W. Irwin
+ * Copyright (C) 2005-2010 Alan W. Irwin
* Copyright (C) 2005 Thomas J. Duck
*
* This file is part of PLplot.
@@ -804,7 +804,18 @@
{
if ( ig >= 24 )
ig = ig + 100 - 24;
- idx = plhershey2unicode( ig + 527 );
+ ig = ig + 527;
+ // Follow pldeco in plsym.c which for
+ // lower case epsilon, theta, and phi
+ // substitutes (684, 685, and 686) for
+ // (631, 634, and 647)
+ if ( ig == 631 )
+ ig = 684;
+ else if ( ig == 634 )
+ ig = 685;
+ else if ( ig == 647 )
+ ig = 686;
+ idx = plhershey2unicode( ig );
unicode_buffer[j++] = \
(PLUNICODE) hershey_to_unicode_lookup_table[idx].Unicode;
i += 2;
@@ -1004,7 +1015,18 @@
{
if ( ig >= 24 )
ig = ig + 100 - 24;
- idx = plhershey2unicode( ig + 527 );
+ ig = ig + 527;
+ // Follow pldeco in plsym.c which for
+ // lower case epsilon, theta, and phi
+ // substitutes (684, 685, and 686) for
+ // (631, 634, and 647)
+ if ( ig == 631 )
+ ig = 684;
+ else if ( ig == 634 )
+ ig = 685;
+ else if ( ig == 647 )
+ ig = 686;
+ idx = plhershey2unicode( ig );
i += 2;
skip = 1; /* skip is set if we have copied something
* into the unicode table */
This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site.
|