Package net.minecraft.client
Class StringSplitter.WidthLimitedCharSink
java.lang.Object
net.minecraft.client.StringSplitter.WidthLimitedCharSink
- All Implemented Interfaces:
FormattedCharSink
- Enclosing class:
StringSplitter
-
Field Summary
Fields -
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionboolean
Accepts a single code point from aFormattedCharSequence
.int
void
-
Field Details
-
maxWidth
private float maxWidth -
position
private int position
-
-
Constructor Details
-
WidthLimitedCharSink
public WidthLimitedCharSink(float pMaxWidth)
-
-
Method Details
-
accept
Accepts a single code point from aFormattedCharSequence
.- Specified by:
accept
in interfaceFormattedCharSink
- Parameters:
pPositionInCurrentSequence
- Contains the relative position of the character in the current sub-sequence. If multiple formatted char sequences have been combined, this value will reset to0
after each sequence has been fully consumed.- Returns:
true
to accept more characters,false
to stop traversing the sequence.
-
getPosition
public int getPosition() -
resetPosition
public void resetPosition()
-