mirror of
https://github.com/BepInEx/mono.git
synced 2026-11-17 01:41:17 -10:00
* HtmlAnchor.cs: * HtmlButton.cs: * HtmlContainerControl.cs: * HtmlControl.cs: * HtmlForm.cs: * HtmlGenericControl.cs: * HtmlImage.cs: * HtmlInputButton.cs: * HtmlInputCheckBox.cs: * HtmlInputControl.cs: * HtmlInputFile.cs: * HtmlInputHidden.cs: * HtmlInputImage.cs: * HtmlInputRadioButton.cs: * HtmlInputText.cs: * HtmlSelect.cs: * HtmlTable.cs: * HtmlTableCell.cs: * HtmlTableRow.cs: * HtmlTextArea.cs: added almost all missing attributes. svn path=/trunk/mcs/; revision=7740
122 lines
2.8 KiB
C#
Executable File
122 lines
2.8 KiB
C#
Executable File
/* System.Web.UI.HtmlControls
|
|
* Authors
|
|
* Leen Toelen ([email protected])
|
|
*/
|
|
|
|
using System;
|
|
using System.ComponentModel;
|
|
using System.Web;
|
|
using System.Web.UI;
|
|
using System.Globalization;
|
|
|
|
namespace System.Web.UI.HtmlControls{
|
|
public class HtmlImage : HtmlControl{
|
|
|
|
public HtmlImage(): base("img"){}
|
|
|
|
protected override void RenderAttributes(HtmlTextWriter writer){
|
|
PreProcessRelativeReference(writer,"src");
|
|
base.RenderAttributes(writer);
|
|
writer.Write(" /");
|
|
}
|
|
|
|
[DefaultValue("")]
|
|
[DesignerSerializationVisibility (DesignerSerializationVisibility.Hidden)]
|
|
[WebCategory("Layout")]
|
|
public string Align{
|
|
get{
|
|
string attr = Attributes["align"];
|
|
if (attr != null){
|
|
return attr;
|
|
}
|
|
return String.Empty;
|
|
}
|
|
set{
|
|
Attributes["align"] = AttributeToString(value);
|
|
}
|
|
}
|
|
|
|
[DefaultValue("")]
|
|
[DesignerSerializationVisibility (DesignerSerializationVisibility.Hidden)]
|
|
[WebCategory("Appearance")]
|
|
public string Alt{
|
|
get{
|
|
string attr = Attributes["alt"];
|
|
if (attr != null){
|
|
return attr;
|
|
}
|
|
return String.Empty;
|
|
}
|
|
set{
|
|
Attributes["alt"] = AttributeToString(value);
|
|
}
|
|
}
|
|
|
|
[DefaultValue(0)]
|
|
[DesignerSerializationVisibility (DesignerSerializationVisibility.Hidden)]
|
|
[WebCategory("Appearance")]
|
|
public int Border{
|
|
get{
|
|
string attr = Attributes["border"];
|
|
if (attr != null){
|
|
return Int32.Parse(attr,CultureInfo.InvariantCulture);
|
|
}
|
|
return -1;
|
|
}
|
|
set{
|
|
Attributes["border"] = AttributeToString(value);
|
|
}
|
|
}
|
|
|
|
[DefaultValue(100)]
|
|
[DesignerSerializationVisibility (DesignerSerializationVisibility.Hidden)]
|
|
[WebCategory("Layout")]
|
|
public int Height
|
|
{
|
|
get {
|
|
string attr = Attributes ["height"];
|
|
if (attr != null)
|
|
return Int32.Parse (attr, CultureInfo.InvariantCulture);
|
|
|
|
return -1;
|
|
}
|
|
|
|
set { Attributes["height"] = AttributeToString (value); }
|
|
}
|
|
|
|
[DefaultValue("")]
|
|
[DesignerSerializationVisibility (DesignerSerializationVisibility.Hidden)]
|
|
[WebCategory("Behavior")]
|
|
public string Src{
|
|
get{
|
|
string attr = Attributes["src"];
|
|
if (attr != null){
|
|
return attr;
|
|
}
|
|
return String.Empty;
|
|
}
|
|
set{
|
|
Attributes["src"] = AttributeToString(value);
|
|
}
|
|
}
|
|
|
|
[DefaultValue(100)]
|
|
[DesignerSerializationVisibility (DesignerSerializationVisibility.Hidden)]
|
|
[WebCategory("Layout")]
|
|
public int Width{
|
|
get{
|
|
string attr = Attributes["width"];
|
|
if (attr != null){
|
|
return Int32.Parse(attr,CultureInfo.InvariantCulture);
|
|
}
|
|
return -1;
|
|
}
|
|
set{
|
|
Attributes["width"] = AttributeToString(value);
|
|
}
|
|
}
|
|
|
|
} // class HtmlImage
|
|
} // namespace System.Web.UI.HtmlControls
|
|
|