Scroll to navigation

XQueryColor(3X11) XLIB FUNCTIONS XQueryColor(3X11)

̾??

XQueryColor, XQueryColors, XLookupColor, XParseColor - ?????ͤ?????

????

XQueryColor(display, colormap, def_in_out)
Display *display;
Colormap colormap;
XColor *def_in_out;

XQueryColors(display, colormap, defs_in_out, ncolors)
Display *display;
Colormap colormap;
XColor defs_in_out[];
int ncolors;

Status XLookupColor(display, colormap, color_name, exact_def_return, screen_def_return)
Display *display;
Colormap colormap;
char *color_name;
XColor *exact_def_return, *screen_def_return;

Status XParseColor(display, colormap, spec, exact_def_return)
Display *display;
Colormap colormap;
char *spec;
XColor *exact_def_return;

??????

???顼?ޥåפ????ꤹ?롣
????̾????ɽ??ʸ????(?㤨?? red)?????ꤹ?롣 ????ʸ???????б????뿧?????ι?¤?Τ??֤????롣
??¤?Τǻ??ꤵ???Ƥ????ԥ????????Ф??? RGB ?ͤ????ꤹ?롣 ?ޤ??????? RGB ?ͤ??֤????롣
??¤?Τǻ??ꤵ???Ƥ????ԥ????????Ф??뿧?????ι?¤?Τ??????????ꤹ?롣 ?ޤ??????????????֤????롣
X ?????Фؤ???³?????ꤹ?롣
???Τ? RGB ?ͤ??֤????롣
???????????????? XColor ??¤?Το??????ꤹ?롣
?ϡ??ɥ????????󶡤????Ǥ??ᤤ RGB ?ͤ??֤????롣
????̾????ɽ??ʸ?????????ꤹ?롣 ??ʸ???Ⱦ?ʸ???϶??̤????ʤ???
???????ѤǤ??????Τ? RGB ?ͤ??֤????롣 ?ޤ????ե饰 DoRed, DoGreen, DoBlue ?????ꤹ?롣

????

?ؿ? XQueryColor ?? XColor ??¤?????Υԥ??????θ??ߤ? RGB ?ͤ??֤????ޤ????ե饰 DoRed, DoGreen, DoBlue ?????ꤹ?롣 ?ؿ? XQueryColors ?? XColor ??¤?Τ??줾???Υԥ????????Ф??? RGB ?ͤ??֤?????¤?Τ??줾???? DoRed, DoGreen, DoBlue ?ե饰?????ꤹ?롣

XQueryColor ?? XQueryColors ?ϥ??顼 BadColor, BadValue ?򵯤??????Ȥ????롣

XLookupColor ?ϻ??ꤷ?????顼?ޥåפ??б????륹???꡼???ǿ???̾????Ĵ?٤롣 ???δؿ??ϻ??ꤷ?????顼?ޥåפΥ????פˤĤ??ơ????Τʿ????ͤȥ????꡼ ?????󶡤????Ǥ??ᤤ?ͤ?ξ?????֤??? ????̾???Υ??󥳡??ǥ??󥰤??ۥ??ȥݡ????֥?ʸ?????󥳡??ǥ??󥰤Ǥʤ? ?????η??̤ϼ?????¸?Ǥ??롣 ??ʸ???侮ʸ???λ??Ѥ??????ʤ??? XLookupColor ?Ͽ???̾?????????Ǥ????? 0 ?Ǥʤ??ͤ??֤????????Ǥʤ??????? 0 ???֤???

?ؿ? XParseColor ?ϻ??ꤷ?????顼?ޥåפ??б????륹???꡼???˴ؤ??ƿ???̾????Ĵ?٤롣 ???δؿ??????Τʿ????ͤ??֤??? ????̾???Υ??󥳡??ǥ??󥰤??ۥ??ȥݡ????֥?ʸ?????󥳡??ǥ??󥰤Ǥʤ??? ?????硢?¹Է??̤ϼ?????¸?Ǥ??롣 ??ʸ???侮ʸ???λ??Ѥ??????ʤ??? XParseColor ?Ͽ??β??褬?Ǥ????? 0 ?Ǥʤ??ͤ??֤????Ǥ??ʤ????? 0 ???֤???

XLookupColor ?? XParseColor ?ϥ??顼 BadColor ?򵯤??????Ȥ????롣

????̾??

RGB ?ǥХ????λ????ϥץ??ե??å???``rgb:''?ˤ??äƼ??̤??졢?ʲ??Ǽ??? ??ˡ?˽?????

rgb:<red>/<green>/<blue>

<red>, <green>, <blue> := h | hh | hhh | hhhh
h := 16?ʿ?1?? (??ʸ??????ʸ???ϴط??ʤ?)

h ??4?ӥåȤ??͡? hh ??8?ӥåȤ??͡? hhh ??12?ӥåȤ??͡? hhhh ??16?ӥåȤ??ͤ򤽤줾?켨????

?????Ȥθߴ????Τ????? RGB ?ǥХ????θŤ???ˡ?⥵?ݡ??Ȥ????Ƥ??뤬?? ???????Ȥ????Ȥϴ????????ʤ??? ??ˡ?ϰʲ??Υե????ޥåȤΤ????줫?Ǥ??ꡢ??Ƭ?Υ??㡼?׵???(#)?θ??? ???λ?????³???????ΤǤ??롣

#RGB	(??4?ӥå?)
#RRGGBB	(??8?ӥå?)
#RRRGGGBBB	(??12?ӥå?)
#RRRRGGGGBBBB	(??16?ӥå?)


R, G, B ??16?ʿ???1????ɽ???? RGB?γ??ͤ?16?ӥåȤ??꾮?????ͤ????ꤵ?줿?Ȥ??ϡ????????ͤκ??????? ɽ??(???????뤬?Ѥ??????? ``rgb:'' ?ε?ˡ?Ȱۤʤ?)?? ?㤨?С?ʸ???? ``#3a7'' ?? ``#3000a0007000'' ??Ʊ???Ǥ??롣

RGB ???٤λ????ϥץ??ե??å??? ``rgbi:'' ??ǧ?????졢?ʲ??ε?ˡ?˽?????

rgbi:<red>/<green>/<blue>


red, green, blue ???ͤ? 0.0 ?ʾ? 1.0 ?ʲ?????ư?????????ͤǤ??롣 ???????????ϥե????ޥåȤϡ?????(̵???Ƥ??褤)?????ͤ?ɽ??ʸ????(???? ?????ޤ??Ǥ??ɤ?)???????դ???????ȼ?? E ???뤤?? e ?????ʤ??ؿ???ʬ(̵ ???Ƥ??褤)?ǹ????????롣

ɸ??Ū?ʥǥХ???????¸??ʸ?????????ε?ˡ???ʲ??˼?????

CIEXYZ:<X>/<Y>/<Z>
CIEuvY:<u>/<v>/<Y>
CIExyY:<x>/<y>/<Y>
CIELab:<L>/<a>/<b>
CIELuv:<L>/<u>/<v>
TekHVC:<H>/<V>/<C>


???Ƥ??? (C, H, V, X, Y, Z, a, b, u, v, y, x) ????ư???????ͤǤ??롣 ?????????ͤε?ˡ?ϡ??????뤤??????????(̵???Ƥ??褤)????????ɽ??ʸ???? (?????????ޤ??Ǥ褤)??``E'' ?? ``e'' ?θ???????????????(??????̵???Ƥ? ?褤)?ȿ?????ɽ??ʸ??????³?????п???ʬ(̵???Ƥ??褤)???鹽???????롣

?֤???

?????? Colormap ???ͤ??????????Ƥ??? Colormap ???ؤ??Ƥ??ʤ???
???ꤵ?줿???ͤˡ??ꥯ?????Ȥε????ϰϤ??ۤ??Ƥ??????Τ????롣?????????? ???????????ϰϤ????ꤵ???Ƥ??ʤ????С????????η????????????Ƥ??????Ƥ??? ?Ϥ????????롣???????Ȥ????????????Ƥ??????????Ϥ??Υ??顼?򵯤??????Ȥ? ???롣

??Ϣ????

XAllocColor(3X11), XCreateColormap(3X11), XStoreColors(3X11)
Xlib - C Language X Interface

Release 6.5 X Version 11