mirror of
				https://github.com/nsnail/spectre.console.git
				synced 2025-11-04 18:40:50 +08:00 
			
		
		
		
	Add JSON text renderer (#1086)
* Add JsonText widget to render highlighted JSON Closes #1051
This commit is contained in:
		@@ -34,9 +34,9 @@ namespace Generator.Commands.Samples
 | 
			
		||||
            console.Write(
 | 
			
		||||
                new Panel(
 | 
			
		||||
                    new Padder(new Rows(
 | 
			
		||||
                        new TextPath("/This/Is/A/Long/Path/That/Will/Be/Truncated.txt").LeftAligned(),
 | 
			
		||||
                        new TextPath("/This/Is/A/Long/Path/That/Will/Be/Truncated.txt").LeftJustified(),
 | 
			
		||||
                        new TextPath("/This/Is/A/Long/Path/That/Will/Be/Truncated.txt").Centered(),
 | 
			
		||||
                        new TextPath("/This/Is/A/Long/Path/That/Will/Be/Truncated.txt").RightAligned()), new Padding(0,1)))
 | 
			
		||||
                        new TextPath("/This/Is/A/Long/Path/That/Will/Be/Truncated.txt").RightJustified()), new Padding(0,1)))
 | 
			
		||||
                .BorderStyle(new Style(foreground: Color.Grey))
 | 
			
		||||
                .Header("Alignment"));
 | 
			
		||||
        }
 | 
			
		||||
 
 | 
			
		||||
		Reference in New Issue
	
	Block a user