Revision 7e11e39b
Added by Katja Luther about 6 years ago
eu.etaxonomy.taxeditor.store/src/main/java/eu/etaxonomy/taxeditor/ui/element/RichTextWithLabelElement.java | ||
---|---|---|
272 | 272 |
for (IntextReference inref: inrefs){ |
273 | 273 |
|
274 | 274 |
if (inref.getTarget() == null){ |
275 |
break;
|
|
275 |
continue;
|
|
276 | 276 |
} |
277 | 277 |
|
278 |
inLineString = RichtextHelper.findInlineString(convertedString, inref.toInlineString(".*"));
|
|
279 |
innerText = RichtextHelper.findInText(inLineString, "(<cdm:.+>)(.+)(</cdm:.+>)"); |
|
278 |
inLineString = RichtextHelper.findInlineString(convertedString, inref.toInlineString("(.+?)"));
|
|
279 |
innerText = RichtextHelper.findInText(inLineString, "(<cdm:.+>)(.+?)(</cdm:.+>)");
|
|
280 | 280 |
if (innerText != null){ |
281 | 281 |
htmlString = RichtextHelper.createHtml(inref, innerText); |
282 | 282 |
}else{ |
... | ... | |
291 | 291 |
} |
292 | 292 |
|
293 | 293 |
} |
294 |
text.setText(convertedString); |
|
294 |
|
|
295 | 295 |
if(!converted){ |
296 | 296 |
System.err.println("There is a problem with the language string and an intextrefernce."); |
297 |
}else{ |
|
298 |
text.setText(convertedString); |
|
297 | 299 |
} |
298 | 300 |
|
299 | 301 |
} |
... | ... | |
341 | 343 |
htmlString = findHtmlString(text.getText(), inref); |
342 | 344 |
System.out.println("html"+htmlString); |
343 | 345 |
if (htmlString != null){ |
344 |
innerText = RichtextHelper.findInText(htmlString, "(.+>)(.*)(</span>)"); |
|
346 |
innerText = RichtextHelper.findInText(htmlString, "(.+>)(.*?)(</span>)");
|
|
345 | 347 |
inLineString = RichtextHelper.createCdmMarkUp(inref, innerText); |
346 | 348 |
|
347 | 349 |
convertedString = convertedString.replace(htmlString, inLineString); |
Also available in: Unified diff
fix problem with more than one inline reference