Label.cs 5.8 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276
  1. //
  2. // System.Windows.Forms.Label.cs
  3. //
  4. // Author:
  5. // stubbed out by Daniel Carrera ([email protected])
  6. // implemented for Gtk+ by Rachel Hestilow ([email protected])
  7. //
  8. // (C) 2002 Ximian, Inc
  9. //
  10. namespace System.Windows.Forms {
  11. using System.Drawing;
  12. // <summary>
  13. //
  14. // </summary>
  15. public class Label : Control {
  16. public Label () : base ()
  17. {
  18. }
  19. //public virtual bool AutoSize {
  20. // get {
  21. // throw new NotImplementedException ();
  22. // }
  23. // set {
  24. // throw new NotImplementedException ();
  25. // }
  26. //}
  27. //[MonoTODO]
  28. //public FlatStyle FlatStyle {
  29. // get {
  30. // throw new NotImplementedException ();
  31. // }
  32. // set {
  33. // throw new NotImplementedException ();
  34. // }
  35. //}
  36. //[MonoTODO]
  37. //public Image Image {
  38. // get {
  39. // throw new NotImplementedException ();
  40. // }
  41. // set {
  42. // throw new NotImplementedException ();
  43. // }
  44. //}
  45. //[MonoTODO]
  46. //public ContentAlignment ImageAlign {
  47. // get {
  48. // throw new NotImplementedException ();
  49. // }
  50. // set {
  51. // throw new NotImplementedException ();
  52. // }
  53. //}
  54. //[MonoTODO]
  55. //public int ImageIndex {
  56. // get {
  57. // throw new NotImplementedException ();
  58. // }
  59. // set {
  60. // throw new NotImplementedException ();
  61. // }
  62. //}
  63. //[MonoTODO]
  64. //public ImageList ImageList {
  65. // get {
  66. // throw new NotImplementedException ();
  67. // }
  68. // set {
  69. // throw new NotImplementedException ();
  70. // }
  71. //}
  72. //[MonoTODO]
  73. //public ImeMode ImeMode {
  74. // get {
  75. // throw new NotImplementedException ();
  76. // }
  77. // set {
  78. // throw new NotImplementedException ();
  79. // }
  80. //}
  81. //[MonoTODO]
  82. //public int PreferredHeight {
  83. // get {
  84. // throw new NotImplementedException ();
  85. // }
  86. //}
  87. //[MonoTODO]
  88. //public int PreferredWidth {
  89. // get {
  90. // throw new NotImplementedException ();
  91. // }
  92. //}
  93. //[MonoTODO]
  94. //public bool TabStop {
  95. // get {
  96. // throw new NotImplementedException ();
  97. // }
  98. // set {
  99. // throw new NotImplementedException ();
  100. // }
  101. //}
  102. [MonoTODO]
  103. public virtual ContentAlignment TextAlign {
  104. get {
  105. throw new NotImplementedException ();
  106. }
  107. set {
  108. throw new NotImplementedException ();
  109. }
  110. }
  111. //[MonoTODO]
  112. //public bool UseMnemonic {
  113. // get {
  114. // throw new NotImplementedException ();
  115. // }
  116. // set {
  117. // throw new NotImplementedException ();
  118. // }
  119. //}
  120. //
  121. // --- Public Methods
  122. //
  123. //[MonoTODO]
  124. //public virtual bool Equals(object o);
  125. //{
  126. // throw new NotImplementedException ();
  127. //}
  128. //[MonoTODO]
  129. //public static bool Equals(object o1, object o2);
  130. //{
  131. // throw new NotImplementedException ();
  132. //}
  133. //[MonoTODO]
  134. //public void Select()
  135. //{
  136. // throw new NotImplementedException ();
  137. //}
  138. //[MonoTODO]
  139. //public override string ToString()
  140. //{
  141. // throw new NotImplementedException ();
  142. //}
  143. //
  144. // --- Public Events
  145. //
  146. //[MonoTODO]
  147. //public event EventHandler AutoSizeChanged {
  148. // add {
  149. // throw new NotImplementedException ();
  150. // }
  151. // remove {
  152. // throw new NotImplementedException ();
  153. // }
  154. //}
  155. //[MonoTODO]
  156. //public event EventHandler TextAlignChanged {
  157. // add {
  158. // throw new NotImplementedException ();
  159. // }
  160. // remove {
  161. // throw new NotImplementedException ();
  162. // }
  163. //}
  164. //
  165. // --- Protected Methods
  166. //
  167. //[MonoTODO]
  168. //protected Rectangle CalcImageRenderBounds( Image image, Rectangle rect, ContentAlignment align)
  169. //{
  170. // throw new NotImplementedException ();
  171. //}
  172. //[MonoTODO]
  173. //protected override AccessibleObject CreateAccessibilityInstance()
  174. //{
  175. // throw new NotImplementedException ();
  176. //}
  177. //[MonoTODO]
  178. //protected void Dispose()
  179. //{
  180. // throw new NotImplementedException ();
  181. //}
  182. //[MonoTODO]
  183. //protected override void Dispose(bool val)
  184. //{
  185. // throw new NotImplementedException ();
  186. //}
  187. //[MonoTODO]
  188. //protected void DrawImage( Graphics g, Image img, Rectangle r, ContentAlignment align)
  189. //{
  190. // throw new NotImplementedException ();
  191. //}
  192. //[MonoTODO]
  193. //protected override void OnEnabledChanged (EventArgs e)
  194. //{
  195. // throw new NotImplementedException ();
  196. //}
  197. //[MonoTODO]
  198. //protected override void OnFontChanged (EventArgs e)
  199. //{
  200. // throw new NotImplementedException ();
  201. //}
  202. //[MonoTODO]
  203. //protected override void OnPaint (PaintEventArgs e)
  204. //{
  205. // throw new NotImplementedException ();
  206. //}
  207. //[MonoTODO]
  208. //protected override void OnParentChanged (EventArgs e)
  209. //{
  210. // throw new NotImplementedException ();
  211. //}
  212. //[MonoTODO]
  213. protected override void OnTextChanged (EventArgs e)
  214. {
  215. ((Gtk.Label) Widget).Text = Text;
  216. }
  217. //[MonoTODO]
  218. //protected override void OnVisibleChanged (EventArgs e)
  219. //{
  220. // throw new NotImplementedException ();
  221. //}
  222. //[MonoTODO]
  223. //protected override bool ProcessMnemonic(char charCode)
  224. //{
  225. // throw new NotImplementedException ();
  226. //}
  227. //[MonoTODO]
  228. //protected ContentAlignment RtlTranslateAlignment( ContentAlignment alignment)
  229. //{
  230. // throw new NotImplementedException ();
  231. //}
  232. //[MonoTODO]
  233. //protected HorizontalAlignment RtlTranslateAlignment( HorizontalAlignment alignment)
  234. //{
  235. // throw new NotImplementedException ();
  236. //}
  237. //[MonoTODO]
  238. //protected virtual void Select(bool val1, bool val2)
  239. //{
  240. // throw new NotImplementedException ();
  241. //}
  242. //[MonoTODO]
  243. //protected override void SetBoundsCore( int x, int y, int width, int height BoundsSpecified specified)
  244. //{
  245. // throw new NotImplementedException ();
  246. //}
  247. //[MonoTODO]
  248. //protected void UpdateBounds()
  249. //{
  250. // throw new NotImplementedException ();
  251. //}
  252. //[MonoTODO]
  253. //protected void UpdateBounds(int b1, int b2, int b3, int b4)
  254. //{
  255. // throw new NotImplementedException ();
  256. //}
  257. //[MonoTODO]
  258. //protected override void WndProc(ref Message m)
  259. //{
  260. // throw new NotImplementedException ();
  261. //}
  262. internal override Gtk.Widget CreateWidget () {
  263. return new Gtk.Label (Text);
  264. }
  265. }
  266. }