473,599 Members | 3,160 Online
Bytes | Software Development & Data Engineering Community
+ Post

Home Posts Topics Members FAQ

dislin titlin and string decode

Hello!

I have an unespectedn result with dislin titlin

dislin.metafl ('WMF')
dislin.disini ()

.....
a="Andrés or Ramón"
dislin.titlin (a.encode("Lati n-1"), 1)
# not error raised, is ok
.....

dislin.disfin ()
In the output file all is ok but the title is

Andr s or Ram n

Thanks in advance!

May 19 '07 #1
3 2217
the code is:

#!/usr/bin/env python

def try_dislin():
....import dislin
....dislin.meta fl ('WMF')
....dislin.errd ev ('FILE')
....dislin.disi ni ()
....dislin.errm od('PROTOCOL',' ON')
....dislin.hwfo nt ()
....dislin.page ra ()
....dislin.pagf ll (255)

....dislin.colo r('BLACK')
....dislin.axsp os (500, 1600)
....dislin.axsl en (2200, 1200)
....
....dislin.name ...('x','X')
....dislin.name ...('y','Y')
....
....dislin.tick s (10, 'X')
....dislin.tick s (10, 'Y')

....dislin.labe ls ('FLOAT','X')
....dislin.labe ls ('FLOAT','Y')

....dislin.incm rk(1)
....dislin.hsym bl (15)
....dislin.chac od('STANDARD')
....dislin.polc rv('LINEAR')

....x=[1.,2.,3.]
....y=[1.,2.,3.]
..........
....a=unicode(" Ramón y Andrés",'Latin-1')
....dislin.titl in (a.encode('Lati n-1'), 1)
....
....min_x_axis= 1.
....max_x_axis= 3.
....min_y_axis= 1.
....max_y_axis= 3....
....
....xstep=(max_ x_axis - min_x_axis)/10.
....ystep=(max_ y_axis - min_y_axis)/10.
....dislin.graf (min_x_axis,max _x_axis,min_x_a xis,xstep \
.......,min_y_a xis,max_y_axis, min_y_axis,yste p)
....
....dislin.titl e()
....

....dislin.curv e(x,y, len(x))

....dislin.colo r ('foreground')
....dislin.dash ...()
....dislin.xaxg it ()
....dislin.disf in ()
try_dislin()
print 'end'

May 19 '07 #2
On 19 mayo, 12:56, luis <soli...@gmail. comwrote:
Hello!

I have an unespectedn result with dislin titlin

dislin.metafl ('WMF')
dislin.disini ()

....
a="Andrés or Ramón"
dislin.titlin (a.encode("Lati n-1"), 1)
# not error raised, is ok
....

dislin.disfin ()

In the output file all is ok but the title is

Andr s or Ram n

Thanks in advance!
The problem was the value of dislin.chacod. This must be 'ISO1' not
the default ('STANDAR')

May 19 '07 #3
En Sat, 19 May 2007 18:28:51 -0300, luis <so*****@gmail. comescribió:
The problem was the value of dislin.chacod. This must be 'ISO1' not
the default ('STANDAR')
I used to use DISLIN some time ago, but now I use PyChart most of the
time. Its convoluted interfase (mostly due to Fortran support, I guess)
makes it rather "ugly" to use from Python. (And has a very strange
licence, btw.)

--
Gabriel Genellina

May 19 '07 #4

This thread has been closed and replies have been disabled. Please start a new discussion.

Similar topics

2
1937
by: Gaubitzer Erwin | last post by:
Hi everybody I want to recompile the DISLIN graphics module for Python under Linux, because I think it is one of the best graphics libraries at present. The included module was for version 2.0 and I want it for 2.2 or maybe 2.3. The problem is, that I use the small make_py script which only calls the gcc compiler CC="gcc -fPIC -c -O" PYTH_INC="/usr/local/include/python2.0"
1
1607
by: Karin Lagesen | last post by:
I have a lot of data that I am going to plot and put on a web server. Since there is a lot of it, I was planning to script it all using python. I have looked around and it seems to me that dislin is good for doing the plots. However, I cannot seem to find the file/package/?? that I need to do the following statement: from dislin import * which the dislin python manual describes.
2
1987
by: Tom Richardson | last post by:
If anyone has any experience using the graphics package DISLIN with Python, I'd appreciate some help. I am trying to use the function tifmod to change the resolution of a tif graphics file. Either I am using it incorrectly, or I don't understand what it is supposed to do. If I use tifmod(N,'INCH','RESOLUTION')
5
2130
by: eesun | last post by:
Hi, I've downloaded the dislin package for the scientific plotting. And I have already created the application window with Tkinter (menu, canvas, status bar..). I want to integrate the Dislin plotting into the Tkinter application. For ex: show the dislin result on the Tkinter Canvas. Anyone can help? thx
6
2652
by: Richard | last post by:
I am going to need to plot some data and formula results from Python. A few years ago I used gnuplot (not from Python) and was wondering which Python plotting module I should use (learn)? I have seen DISLIN mentioned on "onlamp.com" and see that gnuplot has a python module wrapper. Any suggestions on Python plotting modules? (DISLIN or gnuplot.py or ????) Thanks
1
2197
by: pwhbeck | last post by:
Linux SUSE 10.1 Python 2.5 Dislin 9.1 Download dislin 9.1, change to directory dislin-9.1/python Change make_py to: elif test $1 = lnx ; then CC="gcc -fPIC -c -O" PYTH_INC="/usr/local/include/python2.5" PYTH_CONF="/usr/local/lib/python2.5/config"
1
1762
by: adolfo | last post by:
I am at the very beginning of the DISLIN 9.3 Manual: 1.4 Quickplots Some quickplots are added to the DISLIN module which are collections of DISLIN routines for displaying data with one command. For example, the function ’plot’ displays two-dimensional curves. Example: from Numeric import * from dislin import * x = arange (100, typecode=Float32) plot (x, sin (x/5)) disfin ()
3
2528
by: adolfo | last post by:
*** I thought I posted this subject 45 min ago but it does not show so something went wrong and it does not show up. Excuse me if I repeat myself *** DISLIN 9.3 old manual problems I just installed DISLIN 9.3 for python (DISPY is installed too) and I am up to: 1.4 Quickplots
0
1925
by: Helmut Michels | last post by:
Dear C/C++ programmers, I am pleased to announce version 9.4 of the data plotting software DISLIN. DISLIN is a high-level and easy to use plotting library for displaying data as curves, bar graphs, pie charts, 3D-colour plots, surfaces, contours and maps. Several output formats are supported such as X11, VGA, PostScript, PDF, CGM, WMF, HPGL, TIFF, GIF, PNG, BMP and SVG.
0
7992
marktang
by: marktang | last post by:
ONU (Optical Network Unit) is one of the key components for providing high-speed Internet services. Its primary function is to act as an endpoint device located at the user's premises. However, people are often confused as to whether an ONU can Work As a Router. In this blog post, we’ll explore What is ONU, What Is Router, ONU & Router’s main usage, and What is the difference between ONU and Router. Let’s take a closer look ! Part I. Meaning of...
0
7904
by: Hystou | last post by:
Most computers default to English, but sometimes we require a different language, especially when relocating. Forgot to request a specific language before your computer shipped? No problem! You can effortlessly switch the default language on Windows 10 without reinstalling. I'll walk you through it. First, let's disable language synchronization. With a Microsoft account, language settings sync across devices. To prevent any complications,...
0
8398
Oralloy
by: Oralloy | last post by:
Hello folks, I am unable to find appropriate documentation on the type promotion of bit-fields when using the generalised comparison operator "<=>". The problem is that using the GNU compilers, it seems that the internal comparison operator "<=>" tries to promote arguments from unsigned to signed. This is as boiled down as I can make it. Here is my compilation command: g++-12 -std=c++20 -Wnarrowing bit_field.cpp Here is the code in...
0
8400
jinu1996
by: jinu1996 | last post by:
In today's digital age, having a compelling online presence is paramount for businesses aiming to thrive in a competitive landscape. At the heart of this digital strategy lies an intricately woven tapestry of website design and digital marketing. It's not merely about having a website; it's about crafting an immersive digital experience that captivates audiences and drives business growth. The Art of Business Website Design Your website is...
1
8051
by: Hystou | last post by:
Overview: Windows 11 and 10 have less user interface control over operating system update behaviour than previous versions of Windows. In Windows 11 and 10, there is no way to turn off the Windows Update option using the Control Panel or Settings app; it automatically checks for updates and installs any it finds, whether you like it or not. For most users, this new feature is actually very convenient. If you want to control the update process,...
0
6725
agi2029
by: agi2029 | last post by:
Let's talk about the concept of autonomous AI software engineers and no-code agents. These AIs are designed to manage the entire lifecycle of a software development project—planning, coding, testing, and deployment—without human intervention. Imagine an AI that can take a project description, break it down, write the code, debug it, and then launch it, all on its own.... Now, this would greatly impact the work of software developers. The idea...
1
5850
isladogs
by: isladogs | last post by:
The next Access Europe User Group meeting will be on Wednesday 1 May 2024 starting at 18:00 UK time (6PM UTC+1) and finishing by 19:30 (7.30PM). In this session, we are pleased to welcome a new presenter, Adolph Dupré who will be discussing some powerful techniques for using class modules. He will explain when you may want to use classes instead of User Defined Types (UDT). For example, to manage the data in unbound forms. Adolph will...
0
3940
by: adsilva | last post by:
A Windows Forms form does not have the event Unload, like VB6. What one acts like?
0
1250
bsmnconsultancy
by: bsmnconsultancy | last post by:
In today's digital era, a well-designed website is crucial for businesses looking to succeed. Whether you're a small business owner or a large corporation in Toronto, having a strong online presence can significantly impact your brand's success. BSMN Consultancy, a leader in Website Development in Toronto offers valuable insights into creating effective websites that not only look great but also perform exceptionally well. In this comprehensive...

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.