MCPcopy Create free account
hub / github.com/FlaxEngine/FlaxEngine / HitTestText

Function HitTestText

Source/Engine/Render2D/Font.h:446–449  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

444 /// <param name="layout">The text layout properties.</param>
445 /// <returns>The selected character position index (can be equal to text length if location is outside of the layout rectangle).</returns>
446 API_FUNCTION() int32 HitTestText(const StringView& text, API_PARAM(Ref) const TextRange& textRange, const Float2& location, API_PARAM(Ref) const TextLayoutOptions& layout)
447 {
448 return HitTestText(textRange.Substring(text), location, layout);
449 }
450
451 /// <summary>
452 /// Calculates hit character index at given location.

Callers 4

CharIndexAtPointMethod · 0.85
FindLineDownCharMethod · 0.85
FindLineUpCharMethod · 0.85
OnKeyDownMethod · 0.85

Calls 2

SubstringMethod · 0.80
TextLayoutOptionsClass · 0.70

Tested by

no test coverage detected