File: test-entry.cs

package info (click to toggle)
clutter-sharp 1.0.0~alpha3~git20090817.r1.349dba6-8
  • links: PTS, VCS
  • area: main
  • in suites: jessie, jessie-kfreebsd, wheezy
  • size: 4,104 kB
  • ctags: 2,193
  • sloc: xml: 23,456; cs: 9,946; sh: 3,393; perl: 1,213; makefile: 270; awk: 50; sed: 13
file content (38 lines) | stat: -rw-r--r-- 815 bytes parent folder | download
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
using System;

using Clutter;

namespace ClutterTest
{
	public class TestEntry
	{
		static Color stage_color = new Color (0x00, 0x00, 0x00, 0xff);
		static Color entry_color = new Color (0x33, 0xdd, 0xff, 0xff);
		static Entry entry;

	 	public static void Main ()
		{
		 	ClutterRun.Init ();

			Stage stage = Stage.Default;
			stage.SetSize (800, 600);
			stage.Color = stage_color;
			stage.Title = "ClutterEntry Test";

			entry = new Entry ("Sans 14", 
	                	"Type something, be sure to use the " +
	   	        	"left/right arrow keys to move the "  +
	            	        "cursor position.");

			entry.Color = entry_color;
			entry.SetSize (600, 50);
			entry.SetPosition (100, 100);

			stage.KeyFocus = entry;
			stage.AddActor (entry);
			stage.ShowAll ();

			ClutterRun.Main ();
		}
	} 
}