need syntax colored text box

A

ali

i am in middle of a project where i need a JTextbox that can color what
ever code writtern in it depending on the programming language used by
the user.

is this thing available any where ?!!

or i have to do it my self

even if i have to do it my self how can i color text written in
JTextBoxes >??!!
 
P

pccslawrencechan

ali ¼g¹D¡G
thanks that will be helpful

still i would like to make it use as my plan B cause creating software
to colorize syntax of 3 or 4 programming languages will take lots of
time form me
so i still hope there is an open source ready made library somewhere on
the net
(( well so optimistic :p ))

PCCW Solutionx¤»¼Ó - Lawrence Chan (Âq¤H) ³Ì¥{­I«á¸Ü¤H³J´²,
³Ì¥{­I«á°µ¤p°Ê§@, ¤j®a¤p¤ß
 
C

Chris Uppal

ali said:
i am in middle of a project where i need a JTextbox that can color what
ever code writtern in it depending on the programming language used by
the user.

You may be able to reuse the syntax colouring and/or coloured text display from
one of the IDEs or code editors written in Java.

For instance jEdit appears (to a /very/ quick glance) to have a standalone
syntax colouring module, org.gjt.sp.jedit.syntax, and maybe too a standalone
syntax coloured text box, org.gjt.sp.jedit.textarea. See
http://www.jedit.org/api/index.html

I have no idea how suitable either of those would be for your purposes, but
they were just examples anyway. There are (many) other code editors and IDEs
out there which you could look into.

-- chris
 
A

ali

ali ¼g¹D¡G


PCCW Solutionx¤»¼Ó - Lawrence Chan (Âq¤H) ³Ì¥{­I«á¸Ü¤H³J´²,
³Ì¥{­I«á°µ¤p°Ê§@, ¤j®a¤p¤ß


sorry but what was that ??!!!
 
A

ali

Chris said:
You may be able to reuse the syntax colouring and/or coloured text display from
one of the IDEs or code editors written in Java.

For instance jEdit appears (to a /very/ quick glance) to have a standalone
syntax colouring module, org.gjt.sp.jedit.syntax, and maybe too a standalone
syntax coloured text box, org.gjt.sp.jedit.textarea. See
http://www.jedit.org/api/index.html

I have no idea how suitable either of those would be for your purposes, but
they were just examples anyway. There are (many) other code editors and IDEs
out there which you could look into.

-- chris

thanks alot i think that will be really helpfull specially the jedit,

thanks alot again
 
L

Lew

PCCW Solutionx六樓 - Lawrence Chan (濺人) 最å»èƒŒå¾Œè©±äººè›‹æ•£,
sorry but what was that ??!!!

Don't even bother answering "Lawrence Chan" spam. Whoever is behind it is an
annoying little weevil, covered in worm poop.

- Lew
 
A

ali

Chris said:
You may be able to reuse the syntax colouring and/or coloured text display from
one of the IDEs or code editors written in Java.

For instance jEdit appears (to a /very/ quick glance) to have a standalone
syntax colouring module, org.gjt.sp.jedit.syntax, and maybe too a standalone
syntax coloured text box, org.gjt.sp.jedit.textarea. See
http://www.jedit.org/api/index.html

I have no idea how suitable either of those would be for your purposes, but
they were just examples anyway. There are (many) other code editors and IDEs
out there which you could look into.

-- chris

i still want to thank you again your comment really helped after
searching and chasing the thread from Jedit

i got some nice tutorials for syntax coloring i would like to put them
here if any one need them

http://java.sun.com/products/jfc/tsc/articles/text/editor_kit/index.html
http://ostermiller.org/syntax/editor.html

also i found the API used in JEdit and Jext that is "jEdit Syntax
Package " developed by Slava Pestov
http://syntax.jedit.org/
there is a version 2.2.1 which is exactly what i need , the only
difference is it do not support clipboard operations such as copy and
paste, that is really greate i was going to start adding the copy paste
feature to it but i just checked sourceforge for this API

and i found version 2.2.2 which actually supports Copy Paste and other
clipboard operations
http://sourceforge.net/project/showfiles.php?group_id=32650&package_id=24768&release_id=105717

now i can say my project will be compeleted easily

hope this links will help any one else searching for related stuff

thanks again Chris Uppal and others
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Members online

Forum statistics

Threads
473,769
Messages
2,569,580
Members
45,053
Latest member
BrodieSola

Latest Threads

Top