From c087af96c05ca43bc393036dcf3ffa5bebd9b694 Mon Sep 17 00:00:00 2001 From: atef Date: Fri, 30 Jun 2023 10:30:50 +0200 Subject: [PATCH] Create an overload of CenterHorizantal --- csharp/Lib/Utils/TextBlock.cs | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) diff --git a/csharp/Lib/Utils/TextBlock.cs b/csharp/Lib/Utils/TextBlock.cs index dc7fcb924..f7720d224 100644 --- a/csharp/Lib/Utils/TextBlock.cs +++ b/csharp/Lib/Utils/TextBlock.cs @@ -112,7 +112,7 @@ public class TextBlock return new TextBlock(alignedLines); } - public static TextBlock CenterHorizontal(params Object[] things) + public static TextBlock CenterHorizontal(IReadOnlyList things) { var lines = things .SelectMany(GetLines) @@ -127,6 +127,10 @@ public class TextBlock return new TextBlock(alignedLines); } + public static TextBlock CenterHorizontal(params Object[] things) + { + return CenterHorizontal((IReadOnlyList)things); + } public static TextBlock AlignTop(params Object[] things) {