Results 1 to 18 of 18
  1. #1
    GabrielBB is offline Java<33
    Join Date
    Oct 2012
    Location
    Santo Domingo, Dominican Republic
    Posts
    8
    Rep Power
    0

    Red face How to insert Images/emoticons in a Chat Application

    I was making a chat, its cool , works great :) , but i want it to show images in the chat window too, appending them . Such as emoticons. I want to know what component i need to use , i saw something about Document Context blabla once, but it was kinda confusing , and i feel like theres gotta be a easier way of doing it . Thank you for reading this . (English is not my main language, Excuse Grammatical faults )
    Last edited by DarrylBurke; 10-06-2012 at 07:30 AM. Reason: Removed annoying size 5 font

  2. #2
    Norm's Avatar
    Norm is online now Moderator
    Join Date
    Jun 2008
    Location
    Eastern Florida
    Posts
    16,571
    Rep Power
    23

    Default Re: How to insert Images/emoticons in a Chat Application

    i want it to show images in the chat window
    What class are you using to display the window? Does that class have ways of displaying images at user specified locations?
    I think the JEditorPane class uses HTML to control what is displayed and could be useful.
    If you don't understand my response, don't ignore it, ask a question.

  3. #3
    GabrielBB is offline Java<33
    Join Date
    Oct 2012
    Location
    Santo Domingo, Dominican Republic
    Posts
    8
    Rep Power
    0

    Default Re: How to insert Images/emoticons in a Chat Application

    Thanks for answer... Sorry for not replying :/ , yeah im using JEditorPane , adding the text like this - jep.setText(jep.getText() + "new string"); - but yeah im gonna try that with HTML :D

  4. #4
    GabrielBB is offline Java<33
    Join Date
    Oct 2012
    Location
    Santo Domingo, Dominican Republic
    Posts
    8
    Rep Power
    0

    Default Re: How to insert Images/emoticons in a Chat Application

    YAYY, thanks for the suggestion , it worked :D

    chat.setContentType("text/html");
    chat.setText("<IMG SRC=\"pic.png>\"");

    Now i can make my CHAT with emoticooons *_*

  5. #5
    ibrahimabba is offline Member
    Join Date
    Jan 2013
    Posts
    8
    Rep Power
    0

    Default Re: How to insert Images/emoticons in a Chat Application

    Quote Originally Posted by Norm View Post
    What class are you using to display the window? Does that class have ways of displaying images at user specified locations?
    I think the JEditorPane class uses HTML to control what is displayed and could be useful.
    actually i want use emoticons in my chat application....but i dont know how to use it and i dont know the codes..please can you help me?

  6. #6
    Norm's Avatar
    Norm is online now Moderator
    Join Date
    Jun 2008
    Location
    Eastern Florida
    Posts
    16,571
    Rep Power
    23

    Default Re: How to insert Images/emoticons in a Chat Application

    Have you tried the class I mentioned? I think it will allow displaying images in with text.
    If you don't understand my response, don't ignore it, ask a question.

  7. #7
    ibrahimabba is offline Member
    Join Date
    Jan 2013
    Posts
    8
    Rep Power
    0

    Default Re: How to insert Images/emoticons in a Chat Application

    i'm not using JEditorPane, i'm using netbeans n also my chat system has voice call...so i try to put empticons but cannot

  8. #8
    Norm's Avatar
    Norm is online now Moderator
    Join Date
    Jun 2008
    Location
    Eastern Florida
    Posts
    16,571
    Rep Power
    23

    Default Re: How to insert Images/emoticons in a Chat Application

    JEditorPane, i'm using netbeans
    JEditorPane is a java class used in building a Swing GUI
    netbeans is an IDE for creating source files
    If you don't understand my response, don't ignore it, ask a question.

  9. #9
    ibrahimabba is offline Member
    Join Date
    Jan 2013
    Posts
    8
    Rep Power
    0

    Default Re: How to insert Images/emoticons in a Chat Application

    pls can u help me do emoticons or i should send my work(chat application) so that u can be able to help me if possible..

  10. #10
    Norm's Avatar
    Norm is online now Moderator
    Join Date
    Jun 2008
    Location
    Eastern Florida
    Posts
    16,571
    Rep Power
    23

    Default Re: How to insert Images/emoticons in a Chat Application

    Where do you want to display the icon images? In what GUI class?
    If you don't understand my response, don't ignore it, ask a question.

  11. #11
    DarrylBurke's Avatar
    DarrylBurke is offline Member
    Join Date
    Sep 2008
    Location
    Madgaon, Goa, India
    Posts
    11,189
    Rep Power
    19

    Default Re: How to insert Images/emoticons in a Chat Application

    Quote Originally Posted by ibrahimabba View Post
    pls can u help me do emoticons or i should send my work(chat application) so that u can be able to help me if possible..
    This is a technical forum, not SMS chat. Please spell words in full. "You" not "u" and "please" not "pls"

    db
    If you're forever cleaning cobwebs, it's time to get rid of the spiders.

  12. #12
    ibrahimabba is offline Member
    Join Date
    Jan 2013
    Posts
    8
    Rep Power
    0

    Default Re: How to insert Images/emoticons in a Chat Application

    Quote Originally Posted by Norm View Post
    Where do you want to display the icon images? In what GUI class?
    in Jframe..

  13. #13
    ibrahimabba is offline Member
    Join Date
    Jan 2013
    Posts
    8
    Rep Power
    0

    Default Re: How to insert Images/emoticons in a Chat Application

    Quote Originally Posted by Norm View Post
    Have you tried the class I mentioned? I think it will allow displaying images in with text.
    i put the jeditor pane, i doubled click on the editor pane but does not allow me to put the codes...so how to insert the codes under jeditor pane?

  14. #14
    DarrylBurke's Avatar
    DarrylBurke is offline Member
    Join Date
    Sep 2008
    Location
    Madgaon, Goa, India
    Posts
    11,189
    Rep Power
    19

    Default Re: How to insert Images/emoticons in a Chat Application

    Quote Originally Posted by ibrahimabba View Post
    how to insert the codes under jeditor pane?
    Did you try going through the tutorial linked from the JEditorPane API?

    db
    If you're forever cleaning cobwebs, it's time to get rid of the spiders.

  15. #15
    ibrahimabba is offline Member
    Join Date
    Jan 2013
    Posts
    8
    Rep Power
    0

    Default Re: How to insert Images/emoticons in a Chat Application

    where can i get the tutorial for jeditor pane?

  16. #16
    DarrylBurke's Avatar
    DarrylBurke is offline Member
    Join Date
    Sep 2008
    Location
    Madgaon, Goa, India
    Posts
    11,189
    Rep Power
    19

    Default Re: How to insert Images/emoticons in a Chat Application

    Quote Originally Posted by ibrahimabba View Post
    where can i get the tutorial for jeditor pane?
    I already told you that.

    db
    If you're forever cleaning cobwebs, it's time to get rid of the spiders.

  17. #17
    ibrahimabba is offline Member
    Join Date
    Jan 2013
    Posts
    8
    Rep Power
    0

    Default Re: How to insert Images/emoticons in a Chat Application

    No you didn't tell me that..

  18. #18
    ibrahimabba is offline Member
    Join Date
    Jan 2013
    Posts
    8
    Rep Power
    0

    Default Chat Application using Java

    Hello does any one knows how to do video chat using java programming with netbeans?

Similar Threads

  1. Chat application
    By naveenpaul1987 in forum New To Java
    Replies: 1
    Last Post: 03-15-2012, 01:34 PM
  2. Simple RMI chat application
    By usmangt in forum New To Java
    Replies: 3
    Last Post: 09-27-2010, 07:37 AM
  3. Chat application with RMI
    By dhaval.rajput.p in forum Advanced Java
    Replies: 0
    Last Post: 07-11-2009, 10:12 AM
  4. Replies: 2
    Last Post: 11-21-2008, 05:59 PM
  5. Help in Chat application
    By zocky in forum Networking
    Replies: 0
    Last Post: 11-08-2007, 07:19 PM

Tags for this Thread

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •