-
-
Notifications
You must be signed in to change notification settings - Fork 1k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Add background_image
#2326
Add background_image
#2326
Conversation
Sorry @kovidgoyal, I don't really understand how the Python test framework is supposed to work, it seems that by changing the available options I broke something, perhaps I failed to properly declare it in Python |
Dont worry about it I will fix it when I merge. |
FYI, I'll be reviewing (and probably merging) this over the next few days. |
Thank you :-) I will in that case not make any more commits to the branch until your first review, to give you a stable base to review. |
I have merged, with various fixes, please test to see that I have not broken anything. And if you have questions about my changes feel free to ask. |
@Luflosi I'd appreciate if you could test that background iamges work on macOS since I dont currently have access to my mac. |
Will do during the weekend. |
It might also be due to the blank rectangles Kitty draws for borders, in anticipation of having multiple visible Kitty windows in an OS window. In re JPEG, it's not that much work to support, but would require a new dependency. That might not be a problem, libjpeg is extremely common, but I figured it better to keep the code simpler by choosing one image format which implements everything supported by Kitty (alpha). |
On Sat, Feb 15, 2020 at 05:15:57PM -0800, Fredrick Brennan wrote:
It might also be due to the blank rectangles Kitty draws for borders, in anticipation of having multiple visible Kitty windows in an OS window.
It almost certainly is the borders. @Luflosi you can check by comenting
out various bits of code in borders.py
In re JPEG, it's not that much work to support, but would require a new dependency. That might not be a problem, libjpeg is extremely common, but I figured it better to keep the code simpler by choosing one image format which implements everything supported by Kitty (alpha).
I'd really rather not start depending on multiple libraries for multiple
image formats. It's not that much of a hardship to ask users to convert
images to PNG before using them as backgrounds.
|
This PR closes #163, and builds off my prior work in #2311 and 8020657, and also work by @kovidgoyal to correct my mistakes, which made this possible.
This PR has been tested both on Nvidia's proprietary OpenGL driver, and Mesa, both on Arch Linux. Sorry, I have no ability to test on OS X, (which is also an impediment to my work on FontForge, but my friends there test it for me,) but think it should work.
@kovidgoyal asked if I enjoyed the journey. I really did! Never did anything with OpenGL before this. It perhaps folly to take this on as my first OpenGL project, but hopefully users enjoy the result of much trial and error.
Scaled examples
Tiling examples