Add offsetX/offsetY settings, respecting backgroundImageAlignment to determine which sides of the image to apply the offset to. #3678

Open
opened 2026-01-30 23:27:08 +00:00 by claunia · 2 comments
Owner

Originally created by @michelforget on GitHub (Aug 30, 2019).

In a recent blog, your team indicated you could position a background image to your liking. Currently it appears on the very edge of the display (no gap). It would be nice to be able to specify an offsetX/offsetY setting, respecting backgroundImageAlignment to determine which sides of the image to apply the offset to, so that you could indent the image. The idea is that most people will use this to position a large-size icon somewhere in the window to make it super-obvious at a glance which shell is being displayed. Currently to get a gap you need to manually insert a gap around your image, and getting the transparency right isn't necessarily easy.

Proposed technical implementation details (optional)

Originally created by @michelforget on GitHub (Aug 30, 2019). <!-- 🚨🚨🚨🚨🚨🚨🚨🚨🚨🚨 I ACKNOWLEDGE THE FOLLOWING BEFORE PROCEEDING: 1. If I delete this entire template and go my own path, the core team may close my issue without further explanation or engagement. 2. If I list multiple bugs/concerns in this one issue, the core team may close my issue without further explanation or engagement. 3. If I write an issue that has many duplicates, the core team may close my issue without further explanation or engagement (and without necessarily spending time to find the exact duplicate ID number). 4. If I leave the title incomplete when filing the issue, the core team may close my issue without further explanation or engagement. 5. If I file something completely blank in the body, the core team may close my issue without further explanation or engagement. All good? Then proceed! --> In a recent blog, your team indicated you could position a background image to your liking. Currently it appears on the very edge of the display (no gap). It would be nice to be able to specify an offsetX/offsetY setting, respecting backgroundImageAlignment to determine which sides of the image to apply the offset to, so that you could indent the image. The idea is that most people will use this to position a large-size icon somewhere in the window to make it super-obvious at a glance which shell is being displayed. Currently to get a gap you need to manually insert a gap around your image, and getting the transparency right isn't necessarily easy. <!-- A clear and concise description of what the problem is that the new feature would solve. Describe why and how a user would use this new functionality (if applicable). --> # Proposed technical implementation details (optional) <!-- A clear and concise description of what you want to happen. -->
claunia added the Issue-FeatureHelp WantedProduct-TerminalArea-UserInterface labels 2026-01-30 23:27:08 +00:00
Author
Owner

@zadjii-msft commented on GitHub (Sep 3, 2019):

This is pretty closely related to #2370. IMO we should just do both all at the same time.

@zadjii-msft commented on GitHub (Sep 3, 2019): This is pretty closely related to #2370. IMO we should just do both all at the same time.
Author
Owner

@zadjii-msft commented on GitHub (Apr 11, 2022):

From @Dominik-H in #12771

I propose adding an option to set padding for background image in settings. While "backgroundImageAlignment" is awesome and works fine for basic image placement adding an option for user to pad their image by requested amount of pixels would allow the user to place the image in any spot in the terminal window.

I am NOT proposing removal of backgroundImageAlignment but an extension option to add padding to image position.

Proposed technical implementation details (optional)

Of course this is up to the implementation team but my proposal is to add parameter similar to the "padding" that positions the text in the terminal.

  • Name of the parameter could be "backgroundImagePadding"
  • It would accept similar options as mentioned "padding" parameter: "#", "#, #" and "#, #, #, #"
  • Default value would be "0, 0, 0, 0"
  • When both "backgroundImageAlignment" parameter and new "backgroundImagePadding" are set, the Alignment position would be taken as origin and added to the padding values which would yield new position of the image e.g.: "bottomRight" option is bottom right corner and together with padding of "0, 10, 0, 10" it would calculate position offseting the image by 10 pixels from bottom right corner in both directions.
@zadjii-msft commented on GitHub (Apr 11, 2022): _From @Dominik-H in #12771_ > I propose adding an option to set padding for background image in settings. While "backgroundImageAlignment" is awesome and works fine for basic image placement adding an option for user to pad their image by requested amount of pixels would allow the user to place the image in any spot in the terminal window. > > I am NOT proposing removal of backgroundImageAlignment but an extension option to add padding to image position. > > ## Proposed technical implementation details (optional) > Of course this is up to the implementation team but my proposal is to add parameter similar to the "padding" that positions the text in the terminal. > > * Name of the parameter could be "backgroundImagePadding" > * It would accept similar options as mentioned "padding" parameter: "#", "#, #" and "#, #, #, #" > * Default value would be "0, 0, 0, 0" > * When both "backgroundImageAlignment" parameter and new "backgroundImagePadding" are set, the Alignment position would be taken as origin and added to the padding values which would yield new position of the image e.g.: "bottomRight" option is bottom right corner and together with padding of "0, 10, 0, 10" it would calculate position offseting the image by 10 pixels from bottom right corner in both directions.
Sign in to join this conversation.
1 Participants
Notifications
Due Date
No due date set.
Dependencies

No dependencies set.

Reference: starred/terminal#3678