|
发表于 2004-7-7 21:58:40
|
显示全部楼层
以前安装一个鼠标指针主题的时候从readme文件里学到的,这里把原文贴出来共享一下:
<---TUTORIAL FOR MAKE XCURSOR THEMES.--->
<---By ThEOnE @ kde-look--->
<[email protected]>
_______________________________________________________________________________________
| |
| First that all i want tell you that this is anything that i've learned |
| inspecting in some xcursor themes like jaguarx, and others. |
| |
| I hope that you could apologize me for my bad english but i do this |
| because i want share every one thing that i know with the Linux |
| comunity for the development of the same. |
| |
| For make a xcursor themes we need some things before begin: |
| |
| First that all you need a png format images (the cursor images) that you could make |
| with any graphic program (i personally prefer The Gimp). |
| |
| You could make sequences of images like a gif file, this is for animated cursors. |
| |
| OK when you have a cursor images we must proced with the next process for make |
| the xcursors. |
| |
|_____________________________________________________________________________________|
--------------------------------------------------------------------------------------
1) The Config file:
This file must have some information about the xcursor. The general structure of the config files are:
[size] [x_cordinate_cursor] [y_cordinate_cursor] [direction_of_image_file] [refresh_task_of_xcursor]
This is a example of the content of a config file:
34 10 4 png_images/pointer.png 1000
This is a example if you want make a animated xcursor :
34 10 4 png_images/pointer1.png 100
34 10 4 png_images/pointer2.png 100
34 10 4 png_images/pointer3.png 100
34 10 4 png_images/pointer4.png 100
34 10 4 png_images/pointer5.png 100
OK when you have all config files for all your xcursor images we must proced with the next:
______________________________________________________________________________________________________
2) Xcursor files generation.
The command that we use is "xcursorgen"
The use of this command is the next:
xcursorgen [config_file] [destination_of_xcursor]
for every one cursor.
This is a example:
xcursorgen config1.in cursors/left_ptr
With this we make a basic xcursor file that we use commonly ...
You could make a shell script for the generation of all xcursors.
___________________________________________________________________________________________________
3) The xcursor files.
The xcursor files that you must make are the next:
arrow
based_arrow_up
bd_double_arrow
bottom_left_corner
bottom_right_corner
bottom_side
circle
copy
crossed_circle
crosshair
double_arrow
draft_large
draft_small
fd_double_arrow
fleur
h_double_arrow
hand
hand1
hand2
left_ptr
left_ptr_watch
left_side
link
question_arrow
right_ptr
right_side
sb_down_arrow
sb_h_double_arrow
sb_left_arrow
sb_right_arrow
sb_up_arrow
sb_v_double_arrow
top_left_arrow
top_left_corner
top_right_corner
top_side
v_double_arrow
watch
X_cursor
xterm
.................................................................................
: :
: NOTE: :
: :
: If you want make a completely usable theme you must make this xcursors too: :
: :
: 00008160000006810000408080010102 --> sb_v_double_arrow :
: 028006030e0e7ebffc7f7070c0600140 --> sb_h_double_arrow :
: 03b6e0fcb3499374a867c041f52298f0 --> crossed_circle :
: 08e8e1c95fe2fc01f976f1e063a24ccd --> left_ptr_watch :
: 14fef782d02440884392942c11205230 --> h_double_arrow :
: 2870a09082c103050810ffdffffe0204 --> v_double_arrow :
: 3ecb610c1bf2410f44200f48c40d3599 --> left_ptr_watch :
: 4498f0e0c1937ffe01fd06f973665830 --> fleur :
: 6407b0e94181790501fd1e167b474872 --> copy :
: 640fb0e74195791501fd1ed57b41487f --> link :
: 9d800788f1b08800ae810202380a0822 --> hand1 :
: c7088f0f3e6c8088236ef8e1e3e70000 --> top_left_corner :
: d9ce0ab605698f320427677b458ad60b --> question_arrow :
: e29285e634086352946a0e7090d73106 --> hand :
: fcf1c3c7cd4491d801f1e1c78f100000 --> top_right_corner :
: :
:...............................................................................:
If you don't make this xcursors you don't hope that your theme work well ...
You must make this xcursors with the same image that you've maked the action xcursor
for example ...
xcursorgen config1.in cursors/question_arrow
Then you must make this too:
xcursor config1.in cursors/d9ce0ab605698f320427677b458ad60b
______________________________________________________________________________________________
OK we finally must make a dir in $HOME/.icons with the name of your theme, for example:
mkdir $HOME/.icons/my_theme
Then we must put the cursors folder that we had make with all the xcursor files
in $HOME/.icons/my_theme
Then we must edit the file in $HOME/.icons/default ... in inherits part you must put
the name of your theme ... "mytheme" in this case.
.....................................................................................
: :
: NOTE: :
: :
: You could make your own shell script or edit that comes with this tutorial. :
: :
:...................................................................................:
Then ldconfig (as root).
Then logoff.
Then enjoy your own xcursor theme :-) !!
#################################################################################################
# #
# You could base in the theme that i've include in this tutorial for more comprensibility .... #
# this theme have the image files and don't have yet the xcursor files but you could do it #
# with the scripts. #
# #
# You could try this for see the results this job: #
# #
# exec "xcursor_gen.sh" (./xcursor_gen.sh) in the THEME directory of the tutorial. #
# Then exec "install_theme.sh" (./install_theme.sh) ... #
# #
# You could inspect all the files like config files, images files, and others for #
# fully understanding of this tutorial. #
# #
# #
#################################################################################################
..................................................................................................
: :
: NOTE: :
: :
: :
: This tutorial have many bugs and i hope make better with your help ... if anyone are :
: interested in make more understandbly, please send me your comments to : [email protected] :
: :
:................................................................................................: |
|