[system-administrators-guide] Started a new chapter on the various methods for opening a graphical application. This commit includ

Pete Travis immanetize at fedoraproject.org
Sat Jul 13 22:05:49 UTC 2013


commit ae3ab63254295fdc16bdc1df7c522fefe1eb90a7
Author: Pete Travis <immanetize at fedoraproject.org>
Date:   Sat Jul 13 16:04:42 2013 -0600

    Started a new chapter on the various methods for opening a graphical application.
    This commit includes a section on opening graphical applications from the command line.

 en-US/Opening_GUI_Applications.xml    |  111 +++++++++++++++++++++++++++++++++
 en-US/System_Administrators_Guide.xml |    1 +
 2 files changed, 112 insertions(+), 0 deletions(-)
---
diff --git a/en-US/Opening_GUI_Applications.xml b/en-US/Opening_GUI_Applications.xml
new file mode 100644
index 0000000..6fe997a
--- /dev/null
+++ b/en-US/Opening_GUI_Applications.xml
@@ -0,0 +1,111 @@
+<?xml version='1.0'?>
+<!DOCTYPE chapter PUBLIC "-//OASIS//DTD DocBook XML V4.5//EN" "http://www.oasis-open.org/docbook/xml/4.5/docbookx.dtd" [
+]>
+<chapter id="ch-Opening_GUI_Applications">
+  <title>Opening Graphical Applications</title>
+  <indexterm>
+    <primary>GUI</primary>
+  </indexterm>
+  <para>
+    Fedora provides graphical applications in addition to command line utilities for configuring many features. This chapter describes methods for opening <literal>Graphical User Interface</literal>, or <firstterm>GUI</firstterm>, applications in various environments.
+  </para>
+  
+  <section id="gui-from_cli">
+    <title>Opening graphical applications from the command line</title>
+    <para>
+      Graphical applications can be launched from a terminal window or console session by simply typing the name of the application.
+      <screen>
+        [fedorauser at localhost]$ <command>firefox</command>
+      </screen>
+    </para>
+    <note>
+      <title>Binary names vs Application names</title>
+      <para>
+        Programs are opened from the command line using the file name of their <literal>binary</literal>, the executable file provided in the program's package. An entry in the desktop menu will often be named differently from the binary it executes. For example, the GNOME disk management utility appears in the menu as <application>Disks</application>, and the binary is <filename>/usr/bin/gnome-disks</filename>.
+      </para>
+    </note>
+    <para>
+      When a program is executed on the command line, the terminal is occupied until the program completes. When a graphical application is executed from the command line, the program's error output, or <literal>STDERR</literal>, is sent to the terminal window. This can be especially useful when troubleshooting.
+    </para>
+    <example>
+      <title>Viewing errors by launching graphical applications from the command line</title>
+      <screen>
+        [fedorauser at localhost]$ <command>astromenace-wrapper</command>
+	AstroMenace 1.3.1 121212
+
+	Open XML file: /home/fedorauser/.config/astromenace/amconfig.xml
+	VFS file was opened /usr/share/astromenace/gamedata.vfs
+	
+	Vendor     : OpenAL Community
+	Renderer   : OpenAL Soft
+	Version    : 1.1 ALSOFT 1.15.1
+	ALut ver   : 1.1
+
+	Font initialized: DATA/FONT/LiberationMono-Bold.ttf
+
+	Current Video Mode: 3200x1080 32bit 
+	
+	Xinerama/TwinView detected.
+	Screen count: 2
+	Screen #0: (0, 0) x (1920, 1080)
+	Screen #1: (1920, 0) x (1280, 1024)
+	
+	Supported resolutions list:
+	640x480 16bit 
+	640x480 32bit 
+	640x480 0bit 
+	768x480 16bit
+	&lt;output truncated&gt;
+      </screen>
+    </example>
+    <para>
+      To launch a graphical application, but fork the additional output into the background and return the terminal for immediate use, use the shell's <function>job control</function> feature. 
+      <screen>
+        [fedorauser at localhost]$ <command>emacs foo.txt &amp;</command>
+      </screen>
+    </para>
+    <note>
+      <title>Ending a session</title>
+      <para>
+        Applications that hold the command line prompt until they complete will close when the terminal session ends, even if they are forked into the background. 
+      </para>
+    </note>
+    <para>
+      GUI programs can also be launched on one <systemitem>TTY</systemitem> and displayed on another by specifying the <envar>DISPLAY</envar> variable. This can be useful when running multiple graphical sessions, or for troubleshooting problems with a desktop session.
+    </para>
+    <procedure>
+      <step>
+        <para>
+          Switch to another TTY using the key combination <keycombo action="press"><keycap>Ctrl</keycap><keycap>Alt</keycap><keycap>F2</keycap></keycombo> and log in. Note that consoles are available by default with <keycap>F2</keycap> through <keycap>F6</keycap>.
+        </para>
+      </step>
+      <step>
+        <para>
+          Identify the X session you want to target. The <envar>DISPLAY</envar> variable is always an integer preceded by a colon, and will be <emphasis>:0</emphasis> in most cases. Check the arguments of the currently running <application>X</application> process to verify the value. The command below shows both the <envar>DISPLAY</envar> variable as well as the TTY that <application>X</application> is running on, <literal>vt1</literal>.
+          <screen>
+            [fedorauser at localhost]$ <command>ps aux|grep /usr/bin/X</command>
+            root      1498  7.1  1.0 521396 353984 tty1    Ss+  00:04  66:34 /usr/bin/X <literal>:0 vt1</literal> -background none -nolisten tcp -auth /var/run/kdm/A:0-22Degc
+root     23874  0.0  0.0 109184   900 pts/21   S+   15:35   0:00 grep --color=auto /usr/bin/X
+          </screen>
+        </para>
+      </step>
+      <step>
+        <para>
+          Specify the <envar>DISPLAY</envar> variable when executing the program.
+          <screen>
+            [fedorauser at localhost]$ <command>gnome-shell --replace &amp;</command>
+          </screen>
+        </para>
+      </step>
+      <step>
+        <para>
+          Switch back to the TTY the graphical session is running on. Since the example above shows <application>X</application> running on <literal>vt1</literal>, pressing <keycombo><keycap>Ctrl</keycap><keycap>Alt</keycap><keycap>F1</keycap></keycombo> will return to the desktop environment.
+        </para>
+      </step>
+    </procedure>      
+  </section>
+
+</chapter>
+    
+
+ 
diff --git a/en-US/System_Administrators_Guide.xml b/en-US/System_Administrators_Guide.xml
index ecf5a1f..6ee0eef 100644
--- a/en-US/System_Administrators_Guide.xml
+++ b/en-US/System_Administrators_Guide.xml
@@ -14,6 +14,7 @@
         This part covers basic system administration tasks such as keyboard configuration, date and time configuration, installation and initial setup of an NTP server, and managing users and groups.
       </para>
     </partintro>
+    <xi:include href="Opening_GUI_Applications.xml" xmlns:xi="http://www.w3.org/2001/XInclude" />
     <xi:include href="Configuring_the_Language_and_Keyboard.xml" xmlns:xi="http://www.w3.org/2001/XInclude" />
     <xi:include href="Configuring_the_Date_and_Time.xml" xmlns:xi="http://www.w3.org/2001/XInclude" />
     <xi:include href="Configuring_NTP_using_the_Chrony_suite.xml" xmlns:xi="http://www.w3.org/2001/XInclude" />


More information about the docs-commits mailing list