From f57113564828e525185043b6ccad50a2b982335b Mon Sep 17 00:00:00 2001 From: Patrick Kelly Date: Mon, 3 Feb 2020 10:37:01 -0500 Subject: [PATCH 1/3] Update Process.xml Added clarification about MainWindowTitle on Unix, with respect to https://github.com/dotnet/runtime/issues/31658 --- xml/System.Diagnostics/Process.xml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/xml/System.Diagnostics/Process.xml b/xml/System.Diagnostics/Process.xml index 3db41397e01..327b84d0bfb 100644 --- a/xml/System.Diagnostics/Process.xml +++ b/xml/System.Diagnostics/Process.xml @@ -2530,7 +2530,7 @@ The calling process is a member of the associated process' descendant tree. is zero), is an empty string (""). If you have just started a process and want to use its main window title, consider using the method to allow the process to finish starting, ensuring that the main window handle has been created. Otherwise, the system throws an exception. + A process has a main window associated with it only if the process has a graphical interface. If the associated process does not have a main window (so that is zero), is an empty string (""). On Unix platforms, this will always be an empty string (""). If you have just started a process and want to use its main window title, consider using the method to allow the process to finish starting, ensuring that the main window handle has been created. Otherwise, the system throws an exception. > [!NOTE] > The main window is the window that currently has the focus; note that this might not be the primary window for the process. You must use the method to refresh the object to get the current main window handle if it has changed. From e22edda008771f9d28fb95a731627947b0a6d752 Mon Sep 17 00:00:00 2001 From: Patrick Kelly Date: Mon, 3 Feb 2020 10:43:55 -0500 Subject: [PATCH 2/3] Update xml/System.Diagnostics/Process.xml Co-Authored-By: Stephen Toub --- xml/System.Diagnostics/Process.xml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/xml/System.Diagnostics/Process.xml b/xml/System.Diagnostics/Process.xml index 327b84d0bfb..ad7fc5ad199 100644 --- a/xml/System.Diagnostics/Process.xml +++ b/xml/System.Diagnostics/Process.xml @@ -2530,7 +2530,7 @@ The calling process is a member of the associated process' descendant tree. is zero), is an empty string (""). On Unix platforms, this will always be an empty string (""). If you have just started a process and want to use its main window title, consider using the method to allow the process to finish starting, ensuring that the main window handle has been created. Otherwise, the system throws an exception. + A process has a main window associated with it only if the process has a graphical interface. If the associated process does not have a main window (so that is zero), or if the system can't determine that there's a main window (such as may be the case on some Unix platforms), is an empty string (""). If you have just started a process and want to use its main window title, consider using the method to allow the process to finish starting, ensuring that the main window handle has been created. Otherwise, the system throws an exception. > [!NOTE] > The main window is the window that currently has the focus; note that this might not be the primary window for the process. You must use the method to refresh the object to get the current main window handle if it has changed. From d6eabd3085307cbb42ef28e2105af8c77f796e5e Mon Sep 17 00:00:00 2001 From: Patrick Kelly Date: Sun, 9 Feb 2020 17:10:01 -0800 Subject: [PATCH 3/3] Update xml/System.Diagnostics/Process.xml Co-Authored-By: Dan Moseley --- xml/System.Diagnostics/Process.xml | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/xml/System.Diagnostics/Process.xml b/xml/System.Diagnostics/Process.xml index ad7fc5ad199..61d45896c26 100644 --- a/xml/System.Diagnostics/Process.xml +++ b/xml/System.Diagnostics/Process.xml @@ -2530,7 +2530,9 @@ The calling process is a member of the associated process' descendant tree. is zero), or if the system can't determine that there's a main window (such as may be the case on some Unix platforms), is an empty string (""). If you have just started a process and want to use its main window title, consider using the method to allow the process to finish starting, ensuring that the main window handle has been created. Otherwise, the system throws an exception. + A process has a main window associated with it only if the process has a graphical interface. If the associated process does not have a main window (so that is zero), or if the system can't determine that there's a main window (such as may be the case on some Unix platforms), is an empty string (""). + + If you have just started a process and want to use its main window title, consider using the method to allow the process to finish starting, ensuring that the main window handle has been created. Otherwise, the system throws an exception. > [!NOTE] > The main window is the window that currently has the focus; note that this might not be the primary window for the process. You must use the method to refresh the object to get the current main window handle if it has changed.