ÔÚlinuxÏÂʹÓÃgtkµÄgdk
aishen944-163.com
תÌùÇë×¢Ã÷³ö´¦£¬Ð»Ð»£¡£¡
Æäʵ͸Ã÷ÌùͼµÄÔÀí¾ÍÊǽøÐÐxorÔËË㣬
»ù±¾¹«Ê½£ºA xor A = 0 A xor 0 = A A xor A xor B = B
¼ÙÈçÏÖÔÚÓÐÁ½ÕÅͼƬ£¬Ò»ÕÅÊÇÎÒÃÇÒª¶ÔÆä½øÐÐÌùͼµÄͼƬA£¬ ÁíÍâÒ»ÕÅÊÇÒª±»ÌùͼµÄͼƬB
1£¬ ¸´ÖÆͼƬBµÄÒ»·Ý¿½±´ÎªC
2£¬ ½«CÖÐÖ¸¶¨µÄ±³¾°É«±äΪȫ°×(0xffffff)£¬ÆäËûÑÕÉ«±äΪȫºÚ(0x00)
3, ÒÀ´ÎÖ´ÐÐÈçÏÂÔËËã:
A xor B
A and C
A xor B
¶ÔÓÚCÖеİ×É«Ö´ÐÐÔËËãºóµÄ½á¹ûÈçÏÂ:
((A xor B) and 0xfffffff) xor B = A xor B xor B = A
¶ÔÓÚCÖеĺÚÉ«Ö´ÐÐÔËËãºóµÄ½á¹ûÈçÏÂ:
((A xor B) and 0x0000) xor B = 0 xor B = B
ÒÔÏÂÊÇ´úÂëʵÀý£¬Àý×ÓÖÐÓõ½µÄÁ½ÕÅͼƬÔÚÕâÀ
#include <cairo.h>
#include <gdk-pixbuf/gdk-pixbuf.h>
#include <gtk/gtk.h>
static GdkPixbuf *bkpixbuf;
static GdkPixbuf *footballpixbuf;
static gboolean
on_expose_event (GtkWidget * widget,
GdkEventExpose * event, gpointer data)
{
cairo_t *cr;
cr = gdk_cairo_create (widget->window);
gdk_cairo_set_source_pixbuf(cr, bkpixbuf, 0, 0);
cairo_paint(cr);
cairo_destroy (cr);
return FALSE;
}
gboolean blttransparent(GdkPixbuf *dest, const GdkPixbuf *src, gint destx, gint desty, guint transcolor) {
GdkPixbuf *maskpixbuf = NULL; /* ÃÉ°å */
guchar *p = NULL, *dp = NULL, *sp = NULL;
gint x = 0, y = 0, i = 0;
/* ¼ì²éÄ¿µÄÇøÓò */
if(destx + gdk_pixbuf_get_width(src) >= gdk_pixbuf_get_width(dest) ||
desty + gdk_pixbuf_get_height(src) >= gdk_pixbuf_get_height(dest)) { /* ³¬³öÄ¿µÄ´óС, ʲôҲ²»×ö */
return TRUE;
}
/* ¼ì²éÑÕÉ«²ÉÑùÊý */
if(gdk_pixbuf_get_bits_per_sample(dest) != 8 ||
gdk_pixbuf_get_bits_per_sample(src) != 8) { // Ö»
Ïà¹ØÎĵµ£º
windowsÖ÷»úºÍLinuxÐéÄâ»úÉèÖÃÎļþ¼Ð¹²Ïí
µÚÒ»²½£º´ò¿ªÐéÄâ»ú µãvm-----install vmtools
µÚ¶þ²½£º¿ªÊ¼ÐéÄâ»úLinux
ÔÚÖն˼üÈëÒ»ÏÂÃüÁî
cp /mnt/cdrom/VMwareTools-6.0.0-45731.tar.gz /usr/tmp
cd /usr/tmp
tar xzvf VMwareTools-6.0.0-45731.tar.gz
cd vmware-tools-distrib
./vmware-install.pl
һ·»Ø³µ£¬µÈ¿´µ ......
-------------------------------------------------------------------------------------------------------
By:yuyongbao
QQ:673360056
£±¡¢ linuxϹ²ÏíÎļþ¡£°²×°smbserver¡£È»ºóÔÚ¡¶ÏµÍ³ÉèÖá·Öдò¿ª¡¶·þÎñÆ÷ÉèÖ᷵ġ¶smb¡¡server¡··þÎñÆ÷£¬ÊäÈëÏà¹Ø·¾¶¼´¿É¡£È»ºóÔÚwindowÖУ¬Ê¹ÓÃÍøÂçÁÚ¾Ó²éÕÒlinux¡££¨×¢ ......
-------------------------------------------------------------------------------------------------------
//By:yuyongbao
//QQ:673360056
LinuxÏÂÓÃBusy BoxÖÆ×÷RamdiskÈ«¹ý³Ì
1 ½¨Á¢¸ùÎļþϵͳ½á¹¹
#mkdir rootfs
#cd rootfs
#mkdir bin dev etc lib proc sbin tmp usr var
#chmod 1777 tmp
#mk ......
<!--
@page { margin: 2cm }
P { margin-bottom: 0.21cm }
-->
Linux
ÊÀ½çºÜ¾«²Ê£¬ÁîÈËÑÛ»¨çÔÂÒ¡£½üÆÚÒÔÀ´£¬¸÷ÖÖÇáÐÍ
Linux
°æ±¾²»¶ÏµÇ̨ÁÁÏ֪࣬ÃûµÄ
Puppy
£¨Ð¡¹·Ö®Ãû£©±ãÊÇÒ»Àý¡£ºÎ¹Ê£¿
......
ÎÒÃÇÖªµÀ£¬´ÓCMOSÖжÁ³öÀ´µÄϵͳʱ¼ä²¢²»ÊÇtime_tÀàÐÍ£¬¶øÊÇÀàËÆÓÚstruct tmÄÇÑù£¬ÄêÔÂÈÕʱ·ÖÃëÊÇ·Ö¿ª´æ´¢µÄ¡£
ÄÇô£¬Òª°ÑËüת»¯ÎªÏµÍ³±ãÓÚ´¦ÀíµÄtime_tÀàÐÍ£¬¾ÍÐèÒªËã·¨½øÐÐת»»¡£
ÎÒÃǶ¼ÖªµÀÎÒÃǵĹ«Àú»¹ÊDZȽϸ´Ôӵģ¬ÓдóÔÂСÔ£¬ÓÐÈòÄê·ÇÈòÄ꣬´¦ÀíÆðÀ´»áºÜÂé·³¡£
&n ......