2 * Copyright (C) 2007 EDIT
3 * European Distributed Institute of Taxonomy
4 * http://www.e-taxonomy.eu
6 * The contents of this file are subject to the Mozilla Public License Version 1.1
7 * See LICENSE.TXT at the top of this package for the full license terms.
9 package eu
.etaxonomy
.taxeditor
.editor
.view
.descriptive
;
11 import org
.eclipse
.jface
.viewers
.ColumnLabelProvider
;
12 import org
.eclipse
.jface
.viewers
.DelegatingStyledCellLabelProvider
.IStyledLabelProvider
;
13 import org
.eclipse
.jface
.viewers
.StyledString
;
15 import eu
.etaxonomy
.taxeditor
.model
.DescriptionHelper
;
18 * <p>DescriptiveLabelProvider class.</p>
23 public class DescriptiveLabelProvider
extends ColumnLabelProvider
implements IStyledLabelProvider
{
26 public String
getText(Object element
) {
27 return DescriptionHelper
.getLabel(element
);
31 * @see org.eclipse.jface.viewers.DelegatingStyledCellLabelProvider.IStyledLabelProvider#getStyledText(java.lang.Object)
34 public StyledString
getStyledText(Object element
) {
35 return new StyledString(getText(element
), StyledString
.QUALIFIER_STYLER
);