• Home
  • History
  • Annotate
  • Raw
  • Download
  • only in /macosx-10.10.1/emacs-93/emacs/src/

Lines Matching +defs:display +defs:color

128    display. */
132 /* This is display since Mac does not support multiple ones. */
276 #define CG_SET_FILL_COLOR(context, color) \
278 RED_FROM_ULONG (color) / 255.0f, \
279 GREEN_FROM_ULONG (color) / 255.0f, \
280 BLUE_FROM_ULONG (color) / 255.0f, 1.0f)
283 #define CG_SET_FILL_COLOR_MAYBE_WITH_CGCOLOR(context, color, cg_color) \
288 CG_SET_FILL_COLOR (context, color); \
291 #define CG_SET_FILL_COLOR_MAYBE_WITH_CGCOLOR(context, color, cg_color) \
295 #define CG_SET_FILL_COLOR_MAYBE_WITH_CGCOLOR(context, color, cg_color) \
296 CG_SET_FILL_COLOR (context, color)
306 #define CG_SET_STROKE_COLOR(context, color) \
308 RED_FROM_ULONG (color) / 255.0f, \
309 GREEN_FROM_ULONG (color) / 255.0f, \
310 BLUE_FROM_ULONG (color) / 255.0f, 1.0f)
313 #define CG_SET_STROKE_COLOR_MAYBE_WITH_CGCOLOR(context, color, cg_color) \
318 CG_SET_STROKE_COLOR (context, color); \
321 #define CG_SET_STROKE_COLOR_MAYBE_WITH_CGCOLOR(context, color, cg_color) \
325 #define CG_SET_STROKE_COLOR_MAYBE_WITH_CGCOLOR(context, color, cg_color) \
326 CG_SET_STROKE_COLOR (context, color)
447 /* X display function emulation */
450 XFreePixmap (display, pixmap)
451 Display *display; /* not used */
513 XDrawLine (display, p, gc, x1, y1, x2, y2)
514 Display *display;
755 XCreatePixmap (display, w, width, height, depth)
756 Display *display; /* not used */
784 XCreatePixmapFromBitmapData (display, w, data, width, height, fg, bg, depth)
785 Display *display; /* not used */
799 gc = XCreateGC (display, w, 0, NULL);
801 pixmap = XCreatePixmap (display, w, width, height, depth);
808 XSetForeground (display, gc, fg);
809 XSetBackground (display, gc, bg);
853 PaintRect (&r); /* using foreground color of gc */
885 FrameRect (&r); /* using foreground color of gc */
1602 color mapping in CopyBits. Otherwise, it will be slow. */
1617 XChangeGC (display, gc, mask, xgcv)
1618 Display *display;
1624 XSetForeground (display, gc, xgcv->foreground);
1626 XSetBackground (display, gc, xgcv->background);
1628 XSetFont (display, gc, xgcv->font);
1635 XCreateGC (display, d, mask, xgcv)
1636 Display *display;
1654 XChangeGC (display, gc, mask, xgcv);
1663 XFreeGC (display, gc)
1664 Display *display;
1685 XGetGCValues (display, gc, mask, xgcv)
1686 Display *display;
1703 XSetForeground (display, gc, color)
1704 Display *display;
1706 unsigned long color;
1708 if (gc->xgcv.foreground != color)
1710 gc->xgcv.foreground = color;
1711 gc->fore_color.red = RED16_FROM_ULONG (color);
1712 gc->fore_color.green = GREEN16_FROM_ULONG (color);
1713 gc->fore_color.blue = BLUE16_FROM_ULONG (color);
1720 if (color == 0)
1744 XSetBackground (display, gc, color)
1745 Display *display;
1747 unsigned long color;
1749 if (gc->xgcv.background != color)
1751 gc->xgcv.background = color;
1752 gc->back_color.red = RED16_FROM_ULONG (color);
1753 gc->back_color.green = GREEN16_FROM_ULONG (color);
1754 gc->back_color.blue = BLUE16_FROM_ULONG (color);
1761 if (color == 0)
1785 XSetFont (display, gc, font)
1786 Display *display;
1797 mac_set_clip_rectangles (display, gc, rectangles, n)
1798 Display *display;
1841 mac_reset_clip_rectangles (display, gc)
1842 Display *display;
1852 XSetWindowBackground (display, w, color)
1853 Display *display;
1855 unsigned long color;
1865 bg_color.red = RED16_FROM_ULONG (color);
1866 bg_color.green = GREEN16_FROM_ULONG (color);
1867 bg_color.blue = BLUE16_FROM_ULONG (color);
1892 /* Flush display of frame F, or of all frames if F is null. */
2038 display W's cursor if CURSOR_ON_P is non-zero.
2045 support. Such windows don't have a cursor, so don't display it
2179 window W. ROW is the glyph row for which to display the bitmap; it
2190 Display *display = FRAME_MAC_DISPLAY (f);
2240 XGetGCValues (display, face->gc, GCForeground, &gcv);
2241 XSetForeground (display, face->gc,
2253 XSetForeground (display, face->gc, gcv.foreground);
2256 mac_reset_clip_rectangles (display, face->gc);
2551 Glyph display
2631 XChangeGC (s->display, FRAME_MAC_DISPLAY_INFO (s->f)->scratch_cursor_gc,
2635 = XCreateGC (s->display, s->window, mask, &xgcv);
2681 XChangeGC (s->display, FRAME_MAC_DISPLAY_INFO (s->f)->scratch_cursor_gc,
2685 = XCreateGC (s->display, s->window, mask, &xgcv);
2764 mac_set_clip_rectangles (s->display, s->gc, rects, n);
2814 /* Fill rectangle X, Y, W, H with background color of glyph string S. */
2846 XSetFillStyle (s->display, s->gc, FillOpaqueStippled);
2847 XFillRectangle (s->display, s->window, s->gc, s->x,
2851 XSetFillStyle (s->display, s->gc, FillSolid);
3014 /* Look for a frame with that top-level widget. Allocate the color
3028 /* Allocate the color COLOR->pixel on the screen and display of
3030 allocated, try the nearest color available. Value is non-zero
3034 x_alloc_nearest_color_for_widget (widget, cmap, color)
3037 XColor *color;
3040 return x_alloc_nearest_color (f, cmap, color);
3048 /* Allocate the color COLOR->pixel on SCREEN of DISPLAY, colormap
3049 CMAP. If an exact match can't be allocated, try the nearest color
3051 color allocated. */
3054 x_alloc_nearest_color (f, cmap, color)
3057 XColor *color;
3059 Display *display = FRAME_X_DISPLAY (f);
3063 gamma_correct (f, color);
3064 rc = XAllocColor (display, cmap, color);
3068 to try to get the next closest color. The algorithm used is
3070 color matching with StaticColor visuals. */
3073 int ncells = XDisplayCells (display, XScreenNumberOfScreen (screen));
3078 XQueryColors (display, cmap, cells, ncells);
3082 long dred = (color->red >> 8) - (cells[i].red >> 8);
3083 long dgreen = (color->green >> 8) - (cells[i].green >> 8);
3084 long dblue = (color->blue >> 8) - (cells[i].blue >> 8);
3094 color->red = cells[nearest].red;
3095 color->green = cells[nearest].green;
3096 color->blue = cells[nearest].blue;
3097 rc = XAllocColor (display, cmap, color);
3102 register_color (color->pixel);
3109 /* Allocate color PIXEL on frame F. PIXEL must already be allocated.
3111 get color reference counts right. */
3118 XColor color;
3120 color.pixel = pixel;
3122 XQueryColor (FRAME_X_DISPLAY (f), FRAME_X_COLORMAP (f), &color);
3123 XAllocColor (FRAME_X_DISPLAY (f), FRAME_X_COLORMAP (f), &color);
3128 return color.pixel;
3132 /* Allocate color PIXEL on display DPY. PIXEL must already be allocated.
3134 get color reference counts right. */
3142 XColor color;
3144 color.pixel = pixel;
3146 XQueryColor (dpy, cmap, &color);
3147 XAllocColor (dpy, cmap, &color);
3152 return color.pixel;
3158 /* Brightness beyond which a color won't have its highlight brightness
3162 brightening an object's color by a constant scale factor, but this
3167 The value here is set so that the default menu-bar/mode-line color
3172 /* Allocate a color which is lighter or darker than *COLOR by FACTOR
3173 or DELTA. Try a color with RGB values multiplied by FACTOR first.
3174 If this produces the same color as COLOR, try a color where all RGB
3175 values have DELTA added. Return the allocated color in *COLOR.
3176 DISPLAY is the X display, CMAP is the colormap to operate on.
3180 mac_alloc_lighter_color (f, color, factor, delta)
3182 unsigned long *color;
3194 new = RGB_TO_ULONG (min (0xff, (int) (factor * RED_FROM_ULONG (*color))),
3195 min (0xff, (int) (factor * GREEN_FROM_ULONG (*color))),
3196 min (0xff, (int) (factor * BLUE_FROM_ULONG (*color))));
3199 bright = (2 * RED_FROM_ULONG (*color) + 3 * GREEN_FROM_ULONG (*color)
3200 + BLUE_FROM_ULONG (*color)) / 6;
3208 /* How far below the limit this color is (0 - 1, 1 being darker). */
3214 new = RGB_TO_ULONG (max (0, min (0xff, (int) (RED_FROM_ULONG (*color)) - min_delta)),
3215 max (0, min (0xff, (int) (GREEN_FROM_ULONG (*color)) - min_delta)),
3216 max (0, min (0xff, (int) (BLUE_FROM_ULONG (*color)) - min_delta)));
3218 new = RGB_TO_ULONG (max (0, min (0xff, (int) (min_delta + RED_FROM_ULONG (*color)))),
3219 max (0, min (0xff, (int) (min_delta + GREEN_FROM_ULONG (*color)))),
3220 max (0, min (0xff, (int) (min_delta + BLUE_FROM_ULONG (*color)))));
3223 if (new == *color)
3224 new = RGB_TO_ULONG (max (0, min (0xff, (int) (delta + RED_FROM_ULONG (*color)))),
3225 max (0, min (0xff, (int) (delta + GREEN_FROM_ULONG (*color)))),
3226 max (0, min (0xff, (int) (delta + BLUE_FROM_ULONG (*color)))));
3231 if (new == *color)
3234 *color = new;
3240 /* Set up the foreground color for drawing relief lines of glyph
3242 with which lines will be drawn. Use a color that is FACTOR or
3244 in S->f->output_data.x->relief_background. If such a color cannot
3264 /* Allocate new color. */
3294 unsigned long color;
3297 color = s->face->box_color;
3301 color = IMAGE_BACKGROUND (s->img, s->f, 0);
3306 /* Get the background color of the face. */
3307 XGetGCValues (s->display, s->gc, GCBackground, &xgcv);
3308 color = xgcv.background;
3312 || color != di->relief_background)
3314 di->relief_background = color;
3402 XGetGCValues (s->display, s->gc, GCForeground, &xgcv);
3403 XSetForeground (s->display, s->gc, s->face->box_color);
3404 mac_set_clip_rectangles (s->display, s->gc, clip_rect, 1);
3424 XSetForeground (s->display, s->gc, xgcv.foreground);
3425 mac_reset_clip_rectangles (s->display, s->gc);
3617 XSetFillStyle (s->display, s->gc, FillOpaqueStippled);
3618 XFillRectangle (s->display, s->window, s->gc, x, y, w, h);
3619 XSetFillStyle (s->display, s->gc, FillSolid);
3735 mac_set_clip_rectangles (s->display, gc, &r, 1);
3741 XSetFillStyle (s->display, gc, FillOpaqueStippled);
3742 XFillRectangle (s->display, s->window, gc, x, y, w, h);
3743 XSetFillStyle (s->display, gc, FillSolid);
3882 XGetGCValues (s->display, s->gc, GCForeground, &xgcv);
3883 XSetForeground (s->display, s->gc, s->face->underline_color);
3886 XSetForeground (s->display, s->gc, xgcv.foreground);
3901 XGetGCValues (s->display, s->gc, GCForeground, &xgcv);
3902 XSetForeground (s->display, s->gc, s->face->overline_color);
3905 XSetForeground (s->display, s->gc, xgcv.foreground);
3921 XGetGCValues (s->display, s->gc, GCForeground, &xgcv);
3922 XSetForeground (s->display, s->gc, s->face->strike_through_color);
3925 XSetForeground (s->display, s->gc, xgcv.foreground);
3935 mac_reset_clip_rectangles (s->display, s->gc);
3938 /* Shift display to make room for inserted glyphs. */
4199 /* Scroll part of the display as described by RUN. */
4209 /* Get frame-relative bounding box of the text display area of W,
4411 the appropriate X display info. */
4568 *FP should be a frame which indicates which display to ask about.
4606 /* Clear the mouse-moved flag for every frame on this display. */
5046 /* If the display is already accurate, do nothing. */
5071 /* Clip the end position, just for display. */
5270 display the scroll bar thumb. */
5495 /* If we're dragging the bar, display it. */
5598 clipped to the interior of the window dedicated to text display,
5650 background color, which can cause the cursor box to be invisible. */
5708 /* If the glyph's background equals the color we normally draw
5709 the bar cursor in, the bar cursor in its normal color is
5710 invisible. Use the glyph's foreground color instead in this
5888 x_error_catcher (display, error)
5898 x_error_quitter (display, error)
5899 x_error_handler (display, error)
5900 x_io_error_quitter (display)
5947 /* Now make the frame display the given font. */
6010 xim_instantiate_callback (display, client_data, call_data)
6408 the frame's display structures. If we were made
7928 consult the first display in x_display_list. MAXNAMES sets a limit
10274 previous events may change some states about display. */
10478 /* HasDepth returns true if it is possible to have a 32 bit display,
11682 error ("Sorry, this version can only handle one display");
11718 /* Put this display on the chain. */
11734 /* Get rid of display DPYINFO, assuming all frames are already gone. */
11742 /* Discard this display from x_display_name_list and x_display_list.
12167 doc: /* Overlay used to display Mac TSM active input area. */);