GithubHelp home page GithubHelp logo

Comments (7)

PandorasFox avatar PandorasFox commented on May 29, 2024

Text shadowing in cairo would be a bit tricky. I can think of a few ways to do it (every time draw_text gets invoked, there can be a check for a text.shadow option, then we can redraw the same text, shifted a bit, and all black or something), but none off the top of my head that I really like.

As for the latter, you can actually already do that - --blur and --image aren't mutually exclusive. Any image you specify will get layered over the blurred background, and you should be able to tile images with an alpha channel too. You could either just pre-gen an image that's the same dimensions as your screen geometry and is #00000033, or you could probably just do that, but 1x1 and then tell i3lock to tile it.

from i3lock-color.

bew avatar bew commented on May 29, 2024

About 1. I see your point, maybe a text outline would be enough? (something like this).

Edit: at first I was thinking about:
screenshot_20180228-010043
But if I understand correctly, this is not directly available with cairo.

About 2. Thanks for the trick! I'll try that for now.

Now I wonder if it'll be possible one day to specify N colored rectangle(s), to do this effect on some parts of the screen (e.g: where our clock is, or the bottom of the screen, ...). Should I open a new issue for this/discuss this?

from i3lock-color.

PandorasFox avatar PandorasFox commented on May 29, 2024

A text outline might sorta work, but doesn't look the best, in my opinion. If I do text shadowing, I'll want to do it the "right" way (with some blurring to smooth it out).

The rectangles would sorta possible, but again, you can pretty much preprocess it and pass it in.

If I end up doing a big rewrite to handle config files to allow for different configs for multiple screens, it'd become pretty trivial to just allow arbitrary rectangles of different color. But until then, setting it up on the CLI would be a gigantic pain, so it wouldn't be done until then.

from i3lock-color.

bew avatar bew commented on May 29, 2024

The rectangles would sorta possible, but again, you can pretty much preprocess it and pass it in.

Not so easy to preprocess I think, as you loose the variables for the placement (relative to text/indic or to the screen).

If I end up doing a big rewrite to handle config files to allow for different configs for multiple screens, it'd become pretty trivial to just allow arbitrary rectangles of different color.

Sounds good, if you need help I might be interested and give it a try 😃

But until then, setting it up on the CLI would be a gigantic pain.

With the current CLI config, I agree. I've been thinking about another way to organize the CLI args, that would allow more advanced graphic stuff (like custom text widget or rectangles) later, I'll probably open another issue about that.

from i3lock-color.

PandorasFox avatar PandorasFox commented on May 29, 2024

Anything that'd require reworking the CLI stuff will probably be dropped/ignored, since I think the better solution is to support config files. That's just inherently more flexible.

(As in, purely extending the CLI parsing isn't really what I want to do/it'll probably limit config stuff going forwards. I don't want to break compatibility multiple times, so the next break I do will be pretty big)

from i3lock-color.

PandorasFox avatar PandorasFox commented on May 29, 2024

Been playing around with this some. I dunno if there's any easy way to implement this with Cairo in a way that doesn't suck, frankly.

from i3lock-color.

PandorasFox avatar PandorasFox commented on May 29, 2024

Yeah, I'm going to close this for now since I don't think it'll really be viable with how i3lock-color works right now.

from i3lock-color.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.