954,157 Members — Technology Publication meets Social Media
Username:
Password:
Lost login information?
Have something to say? Contribute New Article Reply to this Article

Superscribe and subscribe

Well my question is obvious.
I want to ask is it possible to write superscribe or subscribes in python ?
thanks!

pywriter
Junior Poster
115 posts since Sep 2008
Reputation Points: 13
Solved Threads: 0
 

Look here and see if it helps:

http://www.daniweb.com/forums/thread133360.html

if that isn't what you are looking for, maybe you can clarify what you are trying to do? is this going to be CLI or are you wanting to put something on a GUI?

tyincali
Light Poster
45 posts since Oct 2008
Reputation Points: 31
Solved Threads: 7
 

Hey thanks but in fact that wasn't what i wanted but very near
in fact i want to write a power for a number and as i know it must be superscript and no other choice.
again thanks!

pywriter
Junior Poster
115 posts since Sep 2008
Reputation Points: 13
Solved Threads: 0
 

Hey i tried "\xb" but it printed a black circle with a white question mark in it
and i'm using the python that is installed in ubuntu by default(i forgot to say)
thanks

pywriter
Junior Poster
115 posts since Sep 2008
Reputation Points: 13
Solved Threads: 0
 

Your question is not at all obvious. Where are you trying to write a superscript ? in a terminal ? a Tkinter canvas ? a printer ? a pdf document ? This is the main problem.

Gribouillis
Posting Maven
Moderator
2,781 posts since Jul 2008
Reputation Points: 1,024
Solved Threads: 691
 

In a terminal but if any of them is easier i will be happy to try
thanks

pywriter
Junior Poster
115 posts since Sep 2008
Reputation Points: 13
Solved Threads: 0
 

The thing about outputting super/subscript in term is that it will vary from system to system. Experiment with the '\x##' replacing ## with any hex number from 01 to FF. Eventually you will find the characters you want to use.

this will print a list of every character for you:

nums = ['0', '1', '2', '3', '4', '5', '6', '7', '8', '9', 'a', 'b', 'c', 'd', 'e', 'f']

for a in nums:
	for b in nums:
		exec("print '\\\\x"+a+b+": \\x"+a+b+"'")
tyincali
Light Poster
45 posts since Oct 2008
Reputation Points: 31
Solved Threads: 7
 

Hey tyincali i tried yours(including code tage containings),too.
but again no answer.
hey don't you think my problem is from my python or maybe linux?
i have problem in packages,too.

pywriter
Junior Poster
115 posts since Sep 2008
Reputation Points: 13
Solved Threads: 0
 

This article has been dead for over three months

Post: Markdown Syntax: Formatting Help
You