mirror of
https://github.com/gui-cs/Terminal.Gui.git
synced 2025-12-26 15:57:56 +01:00
* key down/up support * line endings? * line endings * KeyDown/Up support * line endings * line endings * Revert "Drop NuGet restore" This reverts commit5c7a0d05f0. * Revert "Revert "Drop NuGet restore"" This reverts commit2dc5fce865. * updated demo * defined styles * Smarter StatusBar bottom tracking. * Prepping for https://github.com/migueldeicaza/gui.cs/issues/376 * Oops. * Fixed StatusBar 'snap to bottom' * line endings * Revert "Fixed StatusBar 'snap to bottom'" This reverts commit9a91c957e2. * started UICatalog project * Initial working POC. * Fix newlines * merge * textalignment demo tweaks * textalignment demo tweaks * Unicode Menu Scenario * not sure why this keeps changing * re-added project to .sln file * re-enabled status bar * moved scenarios to dir * building a dim and pos demo * terminal.sln * progress...barely * fixed exit * progress with some underlying fixes to Label * added readme * fixes build issue * launch * made default colors readable on Windows * major UI Catalog upgrade * added more demos and updated readme * refactored and added more tests * added ref to Issue #437 * added OnKeyUp support to Curses and Net drivers * more tweaks - grab PR #438 first * Added a OpenSelectedItem event to the ListView #429 * updates * moved KeyUpHandler out of special ESC stuff * more tweaks & improvements * testing top window bug * supported OpenSelectedItem * lots of updates * fixed regression, fixed #444 * better button scenario * tweaks * add Ready event to Toplevel * dotfx .gitignroe * ready for ready * updated colors based on feedback; consolodated config code * tweaked readme * readme * Added Editor demonstrating TextView * Added Editor demonstrating TextView * added hexeditor scenario Co-authored-by: Miguel de Icaza <miguel@gnome.org> Co-authored-by: BDisp <bd.bdisp@gmail.com>
36 lines
1.0 KiB
C#
36 lines
1.0 KiB
C#
using Terminal.Gui;
|
||
|
||
namespace UICatalog {
|
||
[ScenarioMetadata (Name: "Unicode In Menu", Description: "Unicode menus per PR #204")]
|
||
[ScenarioCategory ("Text")]
|
||
[ScenarioCategory ("Controls")]
|
||
class UnicodeInMenu : Scenario {
|
||
public override void Setup ()
|
||
{
|
||
Top = new Toplevel (new Rect (0, 0, Application.Driver.Cols, Application.Driver.Rows));
|
||
var menu = new MenuBar (new MenuBarItem [] {
|
||
new MenuBarItem ("_Файл", new MenuItem [] {
|
||
new MenuItem ("_Создать", "Creates new file", null),
|
||
new MenuItem ("_Открыть", "", null),
|
||
new MenuItem ("Со_хранить", "", null),
|
||
new MenuItem ("_Выход", "", () => Application.RequestStop() )
|
||
}),
|
||
new MenuBarItem ("_Edit", new MenuItem [] {
|
||
new MenuItem ("_Copy", "", null),
|
||
new MenuItem ("C_ut", "", null),
|
||
new MenuItem ("_Paste", "", null)
|
||
})
|
||
});
|
||
Top.Add (menu);
|
||
|
||
Win = new Window ($"Scenario: {GetName ()}") {
|
||
X = 0,
|
||
Y = 1,
|
||
Width = Dim.Fill (),
|
||
Height = Dim.Fill ()
|
||
};
|
||
Top.Add (Win);
|
||
}
|
||
}
|
||
}
|