Re: Emoticon text parser
- From: "Peter Duniho" <NpOeStPeAdM@xxxxxxxxxxxxxxxx>
- Date: Thu, 20 Mar 2008 11:01:34 -0700
On Thu, 20 Mar 2008 10:40:39 -0700, Karsten Wutzke <kwutzke@xxxxxx> wrote:
how do I write a text parser that will detect many ":-)", "]:->"
strings so that they can be replaced with small icons a text
component?
That all depends on how you're formatting the text to include the icons.
But, for example, if you're using HTML in one of the Swing controls that can display HTML, you might just use the java.util.regex package useful. Just use it to do a straight search-and-replace of emoticon strings with the appropriate HTML "img" tag.
Other than that, your question is pretty broadly worded. You're either going to get a lot of replies that aren't applicable, or none at all due to the vagueness of the problem description.
Pete
.
- Follow-Ups:
- Re: Emoticon text parser
- From: Karsten Wutzke
- Re: Emoticon text parser
- References:
- Emoticon text parser
- From: Karsten Wutzke
- Emoticon text parser
- Prev by Date: Emoticon text parser
- Next by Date: events in netbeans
- Previous by thread: Emoticon text parser
- Next by thread: Re: Emoticon text parser
- Index(es):
Relevant Pages
|