How to create a "chat" interface in a plugin



I would like to make a plugin. It needs a chat-like interface - there needs to be a textarea for writing messages and there needs to be an area where the messages are displayed. What would be the right user interface components for that use case?

评论操作 固定链接

Hi Damian,

There is no easy answer to this question. It depends on the chat requirements. In the simplest form, it could be JList/JBList for messages with the custom renderer rendering message information (e.g. JPanel with some JLabels). I suggest experimenting with different components and seeing what works for you.

All could be embedded in a Tool Window. See also Tool Window design hints.