您的位置:首页 > 编程语言 > Java开发

解决Ubuntu Eclipse 代码浮层黑色背景问题

2012-05-09 23:42 295 查看
解决Ubuntu
Eclipse 代码浮层黑色背景问题

# /bin/sh

# Tooltip fix

# A script to fix themes files in Ubuntu 11.10

# to have readable tooltips in applications such

# as eclipse.

# The script edits the gtk.css, settings.ini and gtkrc files

# Author: Victor Pillac

# http://victorpillac.wordpress.com
echo "Tooltip Fix Script"

echo " author: Victor Pillac [http://victorpillac.wordpress.com]"

echo " usage : tooltipfix [themeName]"

echo " where themeName is the name of the theme to fix"

echo "-----------------------------"

if [ "$(id -u)" != "0" ]; then

echo "You must be root to run this program, aborting" 1>&2

exit 1

fi

path=/usr/share/themes

theme=Ambiance

if [ $# = 1 ]; then

theme=$1

fi

echo "Fixing tooltips for theme $theme"

sed -i 's/tooltip_bg_color #000000/tooltip_bg_color #f5f5b5/g' $path/$theme/gtk-3.0/gtk.css

sed -i 's/tooltip_fg_color #ffffff/tooltip_fg_color #000000/g' $path/$theme/gtk-3.0/gtk.css

sed -i 's/tooltip_bg_color:#000000/tooltip_bg_color:#f5f5b5/g' $path/$theme/gtk-3.0/settings.ini

sed -i 's/tooltip_fg_color:#ffffff/tooltip_fg_color:#000000/g' $path/$theme/gtk-3.0/settings.ini

sed -i 's/tooltip_bg_color:#000000/tooltip_bg_color:#f5f5b5/g' $path/$theme/gtk-2.0/gtkrc

sed -i 's/tooltip_fg_color:#ffffff/tooltip_fg_color:#000000/g' $path/$theme/gtk-2.0/gtkrc

echo "Done"
内容来自用户分享和网络整理,不保证内容的准确性,如有侵权内容,可联系管理员处理 点击这里给我发消息
标签: