• Post Reply Bookmark Topic Watch Topic
  • New Topic
programming forums Java Mobile Certification Databases Caching Books Engineering Micro Controllers OS Languages Paradigms IDEs Build Tools Frameworks Application Servers Open Source This Site Careers Other Pie Elite all forums
this forum made possible by our volunteer staff, including ...
Marshals:
  • Campbell Ritchie
  • Jeanne Boyarsky
  • Ron McLeod
  • Paul Clapham
  • Liutauras Vilda
Sheriffs:
  • paul wheaton
  • Rob Spoor
  • Devaka Cooray
Saloon Keepers:
  • Stephan van Hulst
  • Tim Holloway
  • Carey Brown
  • Frits Walraven
  • Tim Moores
Bartenders:
  • Mikalai Zaikin

how to append a part of text of one JTextPane to another JTextPane.

 
Ranch Hand
Posts: 88
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
> In a chatserver scenario whatever i type in my
> JTextPane must be appened to JTextPane of each and
> every window of each and every client that has logged
> on. my text is multi coloured,multi font,multi size .
> how do i go about acheiving this.

In a chatserver scenario means in a client server architecture.
 
Ranch Hand
Posts: 410
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Well you will need to figure a wait of sending that information to other machines. You could send a String object, but that would not encapsulate the formatting information. Maybe you could send a HTML string. Take a looked at the StyledDocument interface.

To send the data to other machines you could take a look at RMI or the Socket and ServerSocket classes.
 
mihir maniar
Ranch Hand
Posts: 88
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
is there a way to take a html format of the text in the JTextPane and then ne method to append that part to the text that is already there in the other JTextPane.
 
Don't get me started about those stupid light bulbs.
reply
    Bookmark Topic Watch Topic
  • New Topic