]> gerrit.simantics Code Review - simantics/platform.git/blob - bundles/org.eclipse.swt.win32.win32.x86_64/src/org/eclipse/swt/custom/StyledTextLineSpacingProvider.java
430a77d6b4151e707896d44eebc2b2a558a5c7d9
[simantics/platform.git] / bundles / org.eclipse.swt.win32.win32.x86_64 / src / org / eclipse / swt / custom / StyledTextLineSpacingProvider.java
1 /**
2  *  Copyright (c) 2017 Angelo ZERR.
3  *
4  *  This program and the accompanying materials
5  *  are made available under the terms of the Eclipse Public License 2.0
6  *  which accompanies this distribution, and is available at
7  *  https://www.eclipse.org/legal/epl-2.0/
8  *
9  *  SPDX-License-Identifier: EPL-2.0
10  *
11  *  Contributors:
12  *  Angelo Zerr <angelo.zerr@gmail.com> - Customize different line spacing of StyledText - Bug 522020
13  */
14 package org.eclipse.swt.custom;
15
16 /**
17  * Line spacing provider used to customize different line spacing for some lines
18  * of {@link StyledText}
19  *
20  * @since 3.107
21  */
22 @FunctionalInterface
23 public interface StyledTextLineSpacingProvider {
24
25         /**
26          * Returns the line spacing of the given line index and null otherwise. In this
27          * case, it will use the {@link StyledText#getLineSpacing()}.
28          *
29          * @param lineIndex
30          *            line index.
31          * @return the line spacing of the given line index and null otherwise. In this
32          *         case, it will use the {@link StyledText#getLineSpacing()}.
33          * @since 3.107
34          */
35         Integer getLineSpacing(int lineIndex);
36
37 }