java - label.setToolTipText("
" + text.toUpperCase() + "
") 在 java SWT 中不起作用问题描述
当我的工具提示超过最大宽度例如:350 个字符时,我想在多行中显示我的工具提示。
Label label = new Label(this.wfSummaryComposite, SWT.NONE);
String text = "Text which has more than 350 characters"
label.setToolTipText("<html><p width=\"350\">" + text.toUpperCase() + "</p></html>")
我添加了这段代码,但它不起作用。