Routing restrictions: Fix instruction indent in RTL mode

This commit is contained in:
Jonathan G Rennison
2023-08-27 08:59:37 +01:00
parent 7d3e627687
commit e377535ea6

View File

@@ -1747,7 +1747,8 @@ static void DrawInstructionString(const TraceRestrictProgram *prog, TraceRestric
}
}
DrawString(left + indent * 16, right, y, instruction_string, selected ? TC_WHITE : TC_BLACK);
bool rtl = _current_text_dir == TD_RTL;
DrawString(left + (rtl ? 0 : ScaleGUITrad(indent * 16)), right - (rtl ? ScaleGUITrad(indent * 16) : 0), y, instruction_string, selected ? TC_WHITE : TC_BLACK);
}
/** Main GUI window class */