介绍Fedora switchdesk Gnome如何切换到KDE桌面和桌面的互相切换

系统 Linux
如果是在字符环境下,用命令switchdesk KDE 或Fedora switchdesk Gnome可以将桌面切换成 KDE 或 Fedora Gnome的。

Fedora有很多值得学习的地方,这里我们主要介绍Fedora switchdesk Gnome和KDE桌面切换,等方面。

1.在XWindows环境中,使用Desktop switch tools来切换。

2.如果是在字符环境下,用命令switchdesk KDE 或Fedora switchdesk Gnome可以将桌面切换成 KDE 或 Fedora  Gnome的。我看了一下,这两种方式其实都是在修改$HOME下面的.Xclients-default文件。如果是Gnome, 则文件内容为 exec gnome-session 如果是KDE, 则文件内容为 exec startkde

小技巧:利用此脚本,你还可以同时在一台机子的七号及八号虚拟控制台上运行两个完全不同的X-Window  Manager。

xwin脚本清单:
#!/bin/sh
#
# xwin This script display a text menu and allow you to select
# which X-Window Manager you want to use
# Author: Lanche , < lanche@163.com >
#
# Backcup your $HOME/.xinirtc file while run this
# script first time
#
if [ -f $HOME/.xinitrc~ ];then
echo
else
cp $HOME/.xinitrc $HOME/.xinitrc~
fi
#
# Functions
#
writerc( ) {
tee $HOME/.xinitrc << RCFILE
#!/bin/sh
#
# This file writed by the xwin script
#
# Start-up items from ~/Desktop/Autostart
#
for i in \$(ls \$HOME/Desktop/Autostart/); do
if test -x \$HOME/Desktop/Autostart/\$i; then
\$HOME/Desktop/Autostart/\$i &
fi
done
#
# And launch window manager
#
RCFILE
}
#
getchose( ) {
clear
echo
echo
echo
echo
echo
echo
echo ﹥ ◆◆◆◆◆◆◆◆◆◆◆◆◆◆◆◆◆◆◆◆◆◆◆◆
echo ﹥ ◆  ◆'
echo ﹥ ◆ 你想使用哪一个窗口管理器? #'
echo ﹥ ◆ #'
echo ﹥ ◆ #'
echo ﹥ ◆ 1 --- kde #'
echo ﹥ ◆ 2 --- xfce #'
echo ﹥ ◆ 3 --- icewm #'
echo ﹥ ◆ 4 --- mlvwm #'
echo ﹥ ◆ 5 --- Fvwm95 #'
echo ﹥ ◆ 6 --- AfterStep #'
echo ﹥ ◆ #'
echo ﹥ ◆ #'
echo ﹥ ◆◆◆◆◆◆◆◆◆◆◆◆◆◆◆
echo
echo -n ﹥ 请选择:'
}
# End of Functions
#
getchose
read CHOSE
#
  #Start the selected X-window manager
#
case $CHOSE in

1) echo 'You chosed kde'
if [ -f `which kde` ];then
writerc
echo 'startkde' >> $HOME/.xinitrc
echo 'Starting kde...'
startx
else
echo 'KDE is not installed on your system!'
fi
;;

2) echo 'You chosed xfce'
if [ -f `which xfce` ];then
writerc
echo 'exec xfwm' >> $HOME/.xinitrc
echo 'Starting xfce...'
startx
else
echo 'XFCE is not installed on your system!'
fi
;;

3) echo 'You chosed icewm'
if [ -f `which icewm` ];then
writerc
echo 'xsetbg -onroot /root/wall.jpg &' >> $HOME/.xinitrc
echo 'exec icewm' >> $HOME/.xinitrc
  echo 'Starting icewm...'
startx
else
echo 'Icewm is not installed on your system!'
  fi
;;

4) echo 'You chosed mlvwm'
if [ -f `which mlvwm` ];then
writerc
  echo 'cd /usr/X11R6/lib/X11/mlvwm' >> $HOME/.xinitrc
echo 'xsetbg -onroot /usr/X11R6/lib/X11/mlvwm/mac.jpg &'>> $HOME/.xinitrc
echo 'exec mlvwm' >> $HOME/.xinitrc
echo 'Starting mlvwm...'
startx
else
echo 'Mlvwm is not installed on your system!'
fi
;;

5) echo 'You chosed fvwm95'
if [ -f `which fvwm95` ];then
writerc
echo 'exec fvwm95' >> $HOME/.xinitrc
echo 'Starting fvwm95...'
startx
else
echo 'fvwm95 is not installed on your system!'
fi
;;

6) echo 'You chosed AfterStep'
if [ -f `which afterstep` ];then
writerc
echo 'exec afterstep' >> $HOME/.xinitrc
echo 'Starting AfterStep...'
startx
else
echo 'AfterStep is not installed on your system!'
fi
;;
*)
echo 'No one was chosed.'
esac
#
exit 0
#
# End of the script
Fedora switchdesk Gnome

【编辑推荐】

  1. Linux应用:在Fedora 下安装opera浏览器
  2. fedora下bridge和nat设置(LINUX上网问题)
  3. 三世同堂:纵向对比Fedora 9/10/11
  4. 基于Linux操作系统 Fedora 11正式发布
  5. 开发者发行版:Fedora 11 Preview
责任编辑:佚名 来源: CSDN
相关推荐

2014-09-25 11:05:36

DebianGnome

2022-04-09 16:11:32

KDE Plasma桌面应用

2020-07-27 17:32:21

Fedora 33FedoraBtrfs

2021-11-22 09:56:13

FedoraLinux

2022-05-24 13:08:55

GNOMEKDELinux

2016-05-03 15:54:51

KDEGNOMEXFCE

2012-11-28 09:43:09

Fedora 18

2015-07-15 11:15:54

LinuxGNOME

2009-12-16 09:56:30

Fedora Gnom

2020-02-11 15:50:51

WindowsLinux命令行

2020-04-17 14:37:19

WindowsLinux微软

2009-12-28 09:51:17

Fedora GNOM

2017-01-09 08:48:23

GnomeGuake桌面

2012-05-18 12:00:27

Fedora 17桌面程序

2020-01-15 13:50:29

桌面快捷方式Windows 10WiFi网络

2009-12-21 13:37:00

Linux系统安装

2009-12-22 17:11:31

Fedora 8安装

2009-02-16 19:02:44

KDE桌面启动程序

2009-06-23 18:19:54

NetBeans英文界面

2009-12-10 13:27:23

GNOME桌面
点赞
收藏

51CTO技术栈公众号