Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Fix ruby blueprint has select issue in the lyric editor. #2260

Merged
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Original file line number Diff line number Diff line change
Expand Up @@ -34,6 +34,9 @@ protected override SelectionHandler<RubyTag> CreateSelectionHandler()
protected override SelectionBlueprint<RubyTag> CreateBlueprintFor(RubyTag item)
=> new RubyTagSelectionBlueprint(item);

protected override IEnumerable<SelectionBlueprint<RubyTag>> SortForMovement(IReadOnlyList<SelectionBlueprint<RubyTag>> blueprints)
=> blueprints.OrderBy(b => b.Item.StartIndex);

protected partial class RubyTagSelectionHandler : LyricPropertySelectionHandler<IEditRubyModeState>
{
[Resolved]
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -126,7 +126,7 @@ static void updateDrawableRect(Drawable target, RectangleF rect)
public override bool ReceivePositionalInputAt(Vector2 screenSpacePos)
=> previewTextArea.ReceivePositionalInputAt(screenSpacePos);

public override Vector2 ScreenSpaceSelectionPoint => ScreenSpaceDrawQuad.TopLeft;
public override Vector2 ScreenSpaceSelectionPoint => previewTextArea.ScreenSpaceDrawQuad.Centre;

public override Quad SelectionQuad => previewTextArea.ScreenSpaceDrawQuad;

Expand Down