Editable ComboBox - limit the number of chars enterable?

I am using an editable comboBox. I was wondering if it would be possible to limit the number of characters the user can enter into the field. I know that for a JTextField you can set the Document to a class that will limit the number of chars but I am not sure how to do this with a ComboBox.

Thanks,

John

[324 byte] By [BaltimoreJohna] at [2007-10-2 11:02:23]
# 1
Try to implement your own ListCellRenderer and set with setCellRenderer forthe JComboBox.
miguel_villaresa at 2007-7-13 3:34:13 > top of Java-index,Desktop,Core GUI APIs...
# 2
Thanks. I figured it out. I set the ComboBoxEditor using setEditor and passed in a JTextField that had its document set in such a way as to limit the number of chars.
BaltimoreJohna at 2007-7-13 3:34:13 > top of Java-index,Desktop,Core GUI APIs...