2005-08-29 Mike Kestner <mkestner@novell.com>

* gtk/Widget.custom : add overloads for Modify* without a Gdk.Color
	param to reset color to default.  [Fixes #75913]


svn path=/trunk/gtk-sharp/; revision=49085
This commit is contained in:
Mike Kestner 2005-08-29 19:22:23 +00:00
parent bc1f65c821
commit e916350eff
3 changed files with 93 additions and 0 deletions

View file

@ -1,3 +1,8 @@
2005-08-29 Mike Kestner <mkestner@novell.com>
* gtk/Widget.custom : add overloads for Modify* without a Gdk.Color
param to reset color to default. [Fixes #75913]
2005-08-28 Ben Maurer <bmaurer@ximian.com>
* configure.in.in: Enable doc building without mono-tools being

View file

@ -4574,5 +4574,61 @@ Widgets are required to honor the size allocation they receive; a size request i
<remarks>Override this method in a subclass to provide a default handler for the <see cref="M:Gtk.Widget.WidgetEventAfter" /> event.</remarks>
<since version="Gtk# 2.4" />
</Docs>
</Member><Member MemberName="ModifyBase">
<MemberSignature Language="C#" Value="public void ModifyBase (Gtk.StateType state);" />
<MemberType>Method</MemberType>
<ReturnValue>
<ReturnType>System.Void</ReturnType>
</ReturnValue>
<Parameters>
<Parameter Name="state" Type="Gtk.StateType" />
</Parameters>
<Docs>
<param name="state">The state to be reset.</param>
<summary>Resets the base color to the default color.</summary>
<remarks>To set a specific color, use the overload of this method.</remarks>
</Docs>
</Member><Member MemberName="ModifyBg">
<MemberSignature Language="C#" Value="public void ModifyBg (Gtk.StateType state);" />
<MemberType>Method</MemberType>
<ReturnValue>
<ReturnType>System.Void</ReturnType>
</ReturnValue>
<Parameters>
<Parameter Name="state" Type="Gtk.StateType" />
</Parameters>
<Docs>
<param name="state">The state to be reset.</param>
<summary>Resets the background color to the default color.</summary>
<remarks>To set a specific color, use the overload of this method.</remarks>
</Docs>
</Member><Member MemberName="ModifyFg">
<MemberSignature Language="C#" Value="public void ModifyFg (Gtk.StateType state);" />
<MemberType>Method</MemberType>
<ReturnValue>
<ReturnType>System.Void</ReturnType>
</ReturnValue>
<Parameters>
<Parameter Name="state" Type="Gtk.StateType" />
</Parameters>
<Docs>
<param name="state">The state to be reset.</param>
<summary>Resets the foreground color to the default color.</summary>
<remarks>To set a specific color, use the overload of this method.</remarks>
</Docs>
</Member><Member MemberName="ModifyText">
<MemberSignature Language="C#" Value="public void ModifyText (Gtk.StateType state);" />
<MemberType>Method</MemberType>
<ReturnValue>
<ReturnType>System.Void</ReturnType>
</ReturnValue>
<Parameters>
<Parameter Name="state" Type="Gtk.StateType" />
</Parameters>
<Docs>
<param name="state">The state to be reset.</param>
<summary>Resets the text color to the default color.</summary>
<remarks>To set a specific color, use the overload of this method.</remarks>
</Docs>
</Member></Members>
</Type>

View file

@ -310,3 +310,35 @@ public Widget[] ListMnemonicLabels ()
return result;
}
[DllImport("libgtk-win32-2.0-0.dll")]
static extern void gtk_widget_modify_base (IntPtr raw, int state, IntPtr color);
public void ModifyBase (Gtk.StateType state)
{
gtk_widget_modify_base (Handle, (int) state, IntPtr.Zero);
}
[DllImport("libgtk-win32-2.0-0.dll")]
static extern void gtk_widget_modify_bg (IntPtr raw, int state, IntPtr color);
public void ModifyBg (Gtk.StateType state)
{
gtk_widget_modify_bg (Handle, (int) state, IntPtr.Zero);
}
[DllImport("libgtk-win32-2.0-0.dll")]
static extern void gtk_widget_modify_fg (IntPtr raw, int state, IntPtr color);
public void ModifyFg (Gtk.StateType state)
{
gtk_widget_modify_fg (Handle, (int) state, IntPtr.Zero);
}
[DllImport("libgtk-win32-2.0-0.dll")]
static extern void gtk_widget_modify_text (IntPtr raw, int state, IntPtr color);
public void ModifyText (Gtk.StateType state)
{
gtk_widget_modify_text (Handle, (int) state, IntPtr.Zero);
}