Skip to content

Commit 751cfe7

Browse files
committed
add docs for rc1 experimental apis
1 parent 7dc3398 commit 751cfe7

12 files changed

+356
-93
lines changed

xml/System.Windows.Forms/Application.xml

Lines changed: 39 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -252,9 +252,14 @@
252252
<ReturnType>System.Windows.Forms.SystemColorMode</ReturnType>
253253
</ReturnValue>
254254
<Docs>
255-
<summary>To be added.</summary>
255+
<summary>Gets the default color mode (dark mode) for the application.</summary>
256256
<value>To be added.</value>
257-
<remarks>To be added.</remarks>
257+
<remarks>
258+
<para>
259+
This is the <see cref="P:System.Windows.Forms.Application.SystemColorMode" />; which either has been set by <see cref="M:System.Windows.Forms.Application.SetColorMode(System.Windows.Forms.SystemColorMode)" /> or its default value <see cref="F:System.Windows.Forms.SystemColorMode.Classic" />.
260+
If it has been set to <see cref="F:System.Windows.Forms.SystemColorMode.System" />, then the actual color mode is determined by the system settings (which can be retrieved by the static (shared in VB) <see cref="P:System.Windows.Forms.Application.SystemColorMode" /> property.
261+
</para>
262+
</remarks>
258263
</Docs>
259264
</Member>
260265
<Member MemberName="CommonAppDataPath">
@@ -982,9 +987,11 @@
982987
<ReturnType>System.Boolean</ReturnType>
983988
</ReturnValue>
984989
<Docs>
985-
<summary>To be added.</summary>
990+
<summary>
991+
Gets a value indicating whether the application is running in a dark system color context.
992+
</summary>
986993
<value>To be added.</value>
987-
<remarks>To be added.</remarks>
994+
<remarks>In a high contrast mode, this will always return <see langword="false" /></remarks>
988995
</Docs>
989996
</Member>
990997
<Member MemberName="LeaveThreadModal">
@@ -1811,9 +1818,25 @@
18111818
<Parameter Name="systemColorMode" Type="System.Windows.Forms.SystemColorMode" Index="0" FrameworkAlternate="windowsdesktop-9.0" />
18121819
</Parameters>
18131820
<Docs>
1814-
<param name="systemColorMode">To be added.</param>
1815-
<summary>To be added.</summary>
1816-
<remarks>To be added.</remarks>
1821+
<param name="systemColorMode">The application's default color mode (dark mode) to set.</param>
1822+
<summary>Sets the default color mode (dark mode) for the application.</summary>
1823+
<remarks>
1824+
<para>
1825+
You should use this method to set the default color mode (dark mode) for the application. Set it, before creating any UI elements, to ensure that the correct color mode
1826+
is used. You can set it to dark mode (<see cref="F:System.Windows.Forms.SystemColorMode.Dark" />), light mode (<see cref="F:System.Windows.Forms.SystemColorMode.Classic" />)
1827+
or to the system setting (<see cref="F:System.Windows.Forms.SystemColorMode.System" />).
1828+
</para>
1829+
<para>
1830+
If you set it to <see cref="F:System.Windows.Forms.SystemColorMode.System" />, the actual color mode is determined by the Windows system settings. If the system setting is changed,
1831+
the application will not automatically adapt to the new setting.
1832+
</para>
1833+
<para>
1834+
Note that the dark color mode is only available from Windows 11 on or later versions. If the system is set to a high contrast mode, the dark mode is not available.
1835+
</para>
1836+
<para>
1837+
<b>Note for Visual Basic:</b> If you are using the Visual Basic Application Framework, you should set the color mode by handling the Application Events (see "WindowsFormsApplicationBase.ApplyApplicationDefaults").
1838+
</para>
1839+
</remarks>
18171840
</Docs>
18181841
</Member>
18191842
<Member MemberName="SetCompatibleTextRenderingDefault">
@@ -2226,9 +2249,16 @@ The high DPI mode is set once per process. For more information about setting th
22262249
<ReturnType>System.Windows.Forms.SystemColorMode</ReturnType>
22272250
</ReturnValue>
22282251
<Docs>
2229-
<summary>To be added.</summary>
2252+
<summary>Gets the system color mode setting of the OS system environment.</summary>
22302253
<value>To be added.</value>
2231-
<remarks>To be added.</remarks>
2254+
<remarks>
2255+
<para>
2256+
The color setting is determined based on the operating system version and its system settings. It returns <see cref="F:System.Windows.Forms.SystemColorMode.Dark" /> if the dark mode is enabled in the system settings,
2257+
<see cref="F:System.Windows.Forms.SystemColorMode.Classic" /> if the color mode equals the light, standard color setting.
2258+
</para>
2259+
<para>SystemColorMode is supported on Windows 11 or later versions.</para>
2260+
<para>SystemColorModes is not supported, if the Windows OS <c>High Contrast Mode</c> has been enabled in the system settings.</para>
2261+
</remarks>
22322262
</Docs>
22332263
</Member>
22342264
<Member MemberName="ThreadException">

xml/System.Windows.Forms/ButtonBase.xml

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1040,6 +1040,7 @@ For example, consider a button control whose <xref:System.Windows.Forms.ImageLis
10401040
<exception cref="T:System.ArgumentOutOfRangeException">
10411041
<paramref name="value" /> is less than -1.</exception>
10421042
<altmember cref="T:System.Windows.Forms.ImageList" />
1043+
<inheritdoc cref="P:System.Windows.Forms.ButtonBase.ImageKey" />
10431044
</Docs>
10441045
</Member>
10451046
<Member MemberName="ImageKey">

xml/System.Windows.Forms/ButtonRenderer.xml

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -110,6 +110,7 @@
110110
111111
]]></format>
112112
</remarks>
113+
<inheritdoc cref="M:System.Windows.Forms.ButtonRenderer.DrawButton(System.Drawing.Graphics,System.Drawing.Rectangle,System.String,System.Drawing.Font,System.Windows.Forms.TextFormatFlags,System.Drawing.Image,System.Drawing.Rectangle,System.Boolean,System.Windows.Forms.VisualStyles.PushButtonState)" />
113114
</Docs>
114115
</Member>
115116
<Member MemberName="DrawButton">
@@ -154,6 +155,7 @@
154155
155156
]]></format>
156157
</remarks>
158+
<inheritdoc cref="M:System.Windows.Forms.ButtonRenderer.DrawButton(System.Drawing.Graphics,System.Drawing.Rectangle,System.String,System.Drawing.Font,System.Windows.Forms.TextFormatFlags,System.Drawing.Image,System.Drawing.Rectangle,System.Boolean,System.Windows.Forms.VisualStyles.PushButtonState)" />
157159
</Docs>
158160
</Member>
159161
<Member MemberName="DrawButton">
@@ -202,6 +204,7 @@
202204
203205
]]></format>
204206
</remarks>
207+
<inheritdoc cref="M:System.Windows.Forms.ButtonRenderer.DrawButton(System.Drawing.Graphics,System.Drawing.Rectangle,System.String,System.Drawing.Font,System.Windows.Forms.TextFormatFlags,System.Drawing.Image,System.Drawing.Rectangle,System.Boolean,System.Windows.Forms.VisualStyles.PushButtonState)" />
205208
</Docs>
206209
</Member>
207210
<Member MemberName="DrawButton">
@@ -277,6 +280,7 @@
277280
278281
]]></format>
279282
</remarks>
283+
<inheritdoc cref="M:System.Windows.Forms.ButtonRenderer.DrawButton(System.Drawing.Graphics,System.Drawing.Rectangle,System.String,System.Drawing.Font,System.Windows.Forms.TextFormatFlags,System.Drawing.Image,System.Drawing.Rectangle,System.Boolean,System.Windows.Forms.VisualStyles.PushButtonState)" />
280284
</Docs>
281285
</Member>
282286
<Member MemberName="DrawButton">
@@ -341,6 +345,7 @@
341345
342346
]]></format>
343347
</remarks>
348+
<inheritdoc cref="M:System.Windows.Forms.ButtonRenderer.DrawButton(System.Drawing.Graphics,System.Drawing.Rectangle,System.String,System.Drawing.Font,System.Windows.Forms.TextFormatFlags,System.Drawing.Image,System.Drawing.Rectangle,System.Boolean,System.Windows.Forms.VisualStyles.PushButtonState)" />
344349
</Docs>
345350
</Member>
346351
<Member MemberName="DrawButton">
@@ -414,6 +419,7 @@
414419
415420
]]></format>
416421
</remarks>
422+
<inheritdoc cref="M:System.Windows.Forms.ButtonRenderer.DrawButton(System.Drawing.Graphics,System.Drawing.Rectangle,System.String,System.Drawing.Font,System.Windows.Forms.TextFormatFlags,System.Drawing.Image,System.Drawing.Rectangle,System.Boolean,System.Windows.Forms.VisualStyles.PushButtonState)" />
417423
</Docs>
418424
</Member>
419425
<Member MemberName="DrawButton">

xml/System.Windows.Forms/CheckBoxRenderer.xml

Lines changed: 7 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -110,6 +110,7 @@
110110
111111
]]></format>
112112
</remarks>
113+
<inheritdoc cref="M:System.Windows.Forms.CheckBoxRenderer.DrawCheckBox(System.Drawing.Graphics,System.Drawing.Point,System.Drawing.Rectangle,System.String,System.Drawing.Font,System.Windows.Forms.TextFormatFlags,System.Drawing.Image,System.Drawing.Rectangle,System.Boolean,System.Windows.Forms.VisualStyles.CheckBoxState)" />
113114
</Docs>
114115
</Member>
115116
<Member MemberName="DrawCheckBox">
@@ -178,6 +179,7 @@
178179
179180
]]></format>
180181
</remarks>
182+
<inheritdoc cref="M:System.Windows.Forms.CheckBoxRenderer.DrawCheckBox(System.Drawing.Graphics,System.Drawing.Point,System.Drawing.Rectangle,System.String,System.Drawing.Font,System.Windows.Forms.TextFormatFlags,System.Drawing.Image,System.Drawing.Rectangle,System.Boolean,System.Windows.Forms.VisualStyles.CheckBoxState)" />
181183
</Docs>
182184
</Member>
183185
<Member MemberName="DrawCheckBox">
@@ -253,6 +255,7 @@
253255
254256
]]></format>
255257
</remarks>
258+
<inheritdoc cref="M:System.Windows.Forms.CheckBoxRenderer.DrawCheckBox(System.Drawing.Graphics,System.Drawing.Point,System.Drawing.Rectangle,System.String,System.Drawing.Font,System.Windows.Forms.TextFormatFlags,System.Drawing.Image,System.Drawing.Rectangle,System.Boolean,System.Windows.Forms.VisualStyles.CheckBoxState)" />
256259
</Docs>
257260
</Member>
258261
<Member MemberName="DrawCheckBox">
@@ -328,6 +331,7 @@
328331
329332
]]></format>
330333
</remarks>
334+
<inheritdoc cref="M:System.Windows.Forms.CheckBoxRenderer.DrawCheckBox(System.Drawing.Graphics,System.Drawing.Point,System.Drawing.Rectangle,System.String,System.Drawing.Font,System.Windows.Forms.TextFormatFlags,System.Drawing.Image,System.Drawing.Rectangle,System.Boolean,System.Windows.Forms.VisualStyles.CheckBoxState)" />
331335
</Docs>
332336
</Member>
333337
<Member MemberName="DrawCheckBox">
@@ -433,6 +437,7 @@
433437
<param name="childControl">The control whose parent's background will be drawn.</param>
434438
<summary>Draws the background of a control's parent in the specified area.</summary>
435439
<remarks>To be added.</remarks>
440+
<inheritdoc cref="M:System.Windows.Forms.ButtonRenderer.DrawParentBackground(System.Drawing.Graphics,System.Drawing.Rectangle,System.Windows.Forms.Control)" />
436441
</Docs>
437442
</Member>
438443
<Member MemberName="GetGlyphSize">
@@ -514,6 +519,7 @@
514519
<returns>
515520
<see langword="true" /> if the background of the check box has semitransparent or alpha-blended pieces; otherwise, <see langword="false" />.</returns>
516521
<remarks>To be added.</remarks>
522+
<inheritdoc cref="M:System.Windows.Forms.ButtonRenderer.IsBackgroundPartiallyTransparent(System.Windows.Forms.VisualStyles.PushButtonState)" />
517523
</Docs>
518524
</Member>
519525
<Member MemberName="RenderMatchingApplicationState">
@@ -559,6 +565,7 @@
559565
560566
]]></format>
561567
</remarks>
568+
<inheritdoc cref="P:System.Windows.Forms.ButtonRenderer.RenderMatchingApplicationState" />
562569
</Docs>
563570
</Member>
564571
</Members>

0 commit comments

Comments
 (0)