Kovid Goyal
4f90110a7c
Fix ghosting when using background_tint under GNOME+Wayland
...
The problem was that on Wayland if the buffer contains pixels with alpha
< 1 they are blended with something, even if the window is opaque. Under
mutter that something was the previous frame, under sway it was the
background/whatever is under the window.
So when blending the tint color, use a blend mode that results in opaque
pixels.
Fixes #5605
2022-10-19 19:02:05 +05:30
Kovid Goyal
28c616d3ff
Move blend mode selection into draw_tint
2022-10-19 17:13:46 +05:30
Kovid Goyal
ae8f3de070
Allow centering the background image
...
Fixes #5525
2022-10-04 08:26:28 +05:30
Kovid Goyal
c8d18ffe26
Add a note about yet another gnome bug
2022-10-03 22:06:00 +05:30
Kovid Goyal
4d80427908
Wayland: Fix background image scaling using tiled mode on high DPI screens
2022-10-03 21:49:52 +05:30
Kovid Goyal
cf22729dfa
Fix background_tint not applying to window margins and padding
...
Fixes #3933
2022-10-03 21:39:57 +05:30
Kovid Goyal
f9b35c71d7
Another place to use NUM_UNDERLINE_STYLES
2022-02-04 14:16:31 +05:30
Joseph Adams
a2c4f830b3
Enable use of higher options for underlining text.
...
In `Colored and styled underlines` it's proposed that the SGR codes
\e[4:4m and \e[4:5m are used to add a dotted or dashed underline to the
rendering context respectively. This commit prepares the necessary
changes to add the two additional underline style, while still rendering
them as a normal underline and curly underline.
2022-01-13 17:27:02 +01:00
Kovid Goyal
79ec8b60b9
Fix visual select window sometimes showing stale window titles
2021-12-31 21:08:20 +05:30
pagedown
60839cdb47
DRYer: Use gl_size to convert coordinates
2021-12-31 09:04:47 +08:00
Kovid Goyal
a867b4444d
Clamp border rects to pixels
...
This uses the same co-ord calculation for border rects as for text
cells. DRYer and avoids borders and blank rects being drawn at haf pixel
offsets.
2021-12-31 06:20:57 +05:30
Kovid Goyal
072fe91518
...
2021-12-30 20:44:30 +05:30
Kovid Goyal
07e6171dc5
DRYer
2021-12-30 20:32:17 +05:30
Kovid Goyal
9a80fcee37
Ensure sizes for window number decorations are correct
2021-12-30 19:05:06 +05:30
Kovid Goyal
f6b748712c
Clamp positions of window numbers/titles to nearest pixel
...
Avoids jaggies in rendering
2021-12-26 11:05:16 +05:30
Kovid Goyal
6e351cd945
Restore ability to use foreground color unchanged for selections
2021-12-06 05:23:41 +05:30
Kovid Goyal
759feac95b
Make the gl pixel clamping functions more widely available
2021-12-05 18:16:36 +05:30
Kovid Goyal
a7eb9850b7
clamp logo position to nearest pixel
2021-12-05 15:53:20 +05:30
Kovid Goyal
f01446ff25
...
2021-12-05 13:26:06 +05:30
Kovid Goyal
525a32be51
better conversion of logo width/height to gl values
...
Map the naive value back to an integer using the same algorithm as for
the scissor test and adjust the value if they dont match
2021-12-05 13:21:04 +05:30
Kovid Goyal
73386bd67f
Use scissor limits as pixel extents in cell render data
...
More accurate since that is the actual content area
2021-12-05 13:04:43 +05:30
Kovid Goyal
d1cf88e942
Make the window geometry in pixels available in CellRenderData
2021-12-05 12:29:33 +05:30
Kovid Goyal
2546afb7aa
Use a struct to pass around cell render data
2021-12-05 11:57:22 +05:30
Kovid Goyal
bca3179a6d
Forgot that draw_cells() is called with a NULL window when drawing the tab bar
...
Fixes #4317
2021-12-05 07:44:51 +05:30
Kovid Goyal
b36d8d6469
Fix logo rendering under wayland, which requires premult
2021-12-04 12:50:48 +05:30
Kovid Goyal
42a2493286
Fade the window logo by a configurable amount
2021-12-03 18:05:59 +05:30
Kovid Goyal
6f48dda8b9
Fix storage of window logos
...
Store by id not pointer since the pointers are not stable. And use two
hash maps by path and by id for fast lookup.
2021-12-03 17:43:45 +05:30
Kovid Goyal
b8b495ac31
Fix text not rendered when showing window logo
2021-12-03 13:54:28 +05:30
Kovid Goyal
757c7900d9
Dont draw the window logo during a live resize
2021-12-03 13:20:57 +05:30
Kovid Goyal
3d2877eeb9
More work on per window logo
2021-12-03 13:19:10 +05:30
Kovid Goyal
e04919098f
Start work on a per window logo
2021-12-02 11:14:17 +05:30
Kovid Goyal
5d05aeaace
...
2021-12-02 07:28:27 +05:30
Kovid Goyal
ef07e2941c
Fix clamping of background image
2021-12-01 20:12:31 +05:30
Kovid Goyal
0c3a8dadf6
bg uniforms should be reset when options are reloaded
2021-12-01 16:43:15 +05:30
Kovid Goyal
d9c400ac32
Forgot to recalculate height_gl leading to vertically stretched characters for window numbers
2021-11-04 08:53:17 +05:30
Kovid Goyal
477baf390b
DRYer
2021-11-03 09:32:49 +05:30
pagedown
ce36b09593
Visible bell color falls back to default fg when selection bg is none
2021-11-03 10:07:57 +08:00
pagedown
b4a6ed8d8f
Allows the visual bell color to be configured
2021-11-02 19:38:36 +08:00
Kovid Goyal
588313b9ac
Dont re-render window chars unless needed
2021-11-01 20:38:19 +05:30
Kovid Goyal
9517c3500d
Allow visually selecting upto 36 windows
...
Also dont draw the window title if the window is too small
2021-11-01 10:46:54 +05:30
Kovid Goyal
1b8978fede
Implement rendering of ASCII char with FreeType
2021-11-01 10:17:26 +05:30
Kovid Goyal
5796cbc040
Remove the seven segment shader
2021-11-01 08:42:02 +05:30
Kovid Goyal
49726384f7
Start work on rendering visual select numbers using fonts instead of seven segment display
2021-11-01 08:40:03 +05:30
Kovid Goyal
e7386735f4
Make code to load alpha mask texture re-useable
2021-11-01 07:29:04 +05:30
Kovid Goyal
ddfa653197
resizing size text should be drawn with the current foreground color
2021-11-01 07:19:17 +05:30
itepechi
9289c2de69
Refactor background_image_anchor for cleaner code
2021-10-30 04:34:33 +09:00
itepechi
dac1612cb0
Calculate background image position on the GPU
2021-10-30 04:34:33 +09:00
itepechi
87d79c7415
Change the naming of directions in option background_image_anchor for consistency
...
Replaced cardinal directions with "relative" directions.
2021-10-30 04:34:33 +09:00
itepechi
86d7aaa03a
Add clamped to option background_image_layout
2021-10-30 04:34:33 +09:00
itepechi
cae31ab336
Read/Write bganchor directly from the options' state
...
Slight performance improvement, maybe?
Also, `kitty/graphics.h` has been reverted to the original version;
this version would be better in that aspect too.
2021-10-30 04:34:32 +09:00