Coder Social home page Coder Social logo

Comments (4)

xyb3rt avatar xyb3rt commented on July 17, 2024

I'm not sure how I should handle multile file path arguments to external scripts/commands.

The first possible approach is to have only one 'it_' command for everything. This command could then use the environment variables SXIV_IMG and SXIV_SEL_IMGS (or something like that) to refer to the current image or all selected images. This would be powerful but maybe error-prone, because the latter variable would be empty, if no images are selected.

The second approach is to have a new 'it_' command next to it_open_with & it_shell_cmd which only differs from it_shell_cmd in using SXIV_SEL_IMGS instead of SXIV_IMG.

For both approaches one more problem has to be solved: How to select multiple images? In image mode a selected image could be marked with a special character in the title string. But I'm not sure what easy (easy as in easy to do with pure Xlib) approach should be taken to mark selected images in thumbnail mode.

Any ideas?

from sxiv.

baskerville avatar baskerville commented on July 17, 2024

Bert Münnich a écrit :

I'm not sure how I should handle multile file path arguments to external scripts/commands.

The first possible approach is to have only one 'it_' command for everything. This command could then use the environment variables SXIV_IMG and SXIV_SEL_IMGS (or something like that) to refer to the current image or all selected images. This would be powerful but maybe error-prone, because the latter variable would be empty, if no images are selected.

The second approach is to have a new 'it_' command next to it_open_with & it_shell_cmd which only differs from it_shell_cmd in using SXIV_SEL_IMGS instead of SXIV_IMG.

I'm not sure neither.
I think I prefer the first approach.

For both approaches one more problem has to be solved: How to select multiple images? In image mode a selected image could be marked with a special character in the title string. But I'm not sure what easy (easy as in easy to do with pure Xlib) approach should be taken to mark selected images in thumbnail mode.

Any ideas?

Maybe the simplest solution would be to draw a border (with configurable color) around each selected image?
Also, if the current image is part of a selection, its border could be drawn with a bicolor dashed stroke.

from sxiv.

baskerville avatar baskerville commented on July 17, 2024

Any ideas?

In fact, I think the elegant way of representing the selection visually
would be to draw the perimeter of the selected region and not every
border of every selected image but I don't think it would be easy to do.

I'm not sure if this feature is really important after all.

from sxiv.

xyb3rt avatar xyb3rt commented on July 17, 2024

Seems not important enough to me. I will not implement this.

from sxiv.

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.