Login
Remember
Register
Twine Q&A
Questions
Unanswered
Tags
Users
Ask a Question
Code of Conduct
Ask a Question
How to resize the background image to fit the screen using CSS
0
votes
asked
Jan 12, 2018
by
SmuJamesB
(
2.7k
points)
Is it possible to automatically resize an image to fit the user's web browser's window size?
Please
log in
or
register
to answer this question.
1
Answer
0
votes
answered
Jan 12, 2018
by
Chapel
(
63.1k
points)
selected
Feb 7, 2018
by
SmuJamesB
Best answer
You can use the CSS background-size rule and set it to either contain or cover based on your needs.
Please
log in
or
register
to add a comment.
This site has been placed in read-only mode. Please use the
Interactive Fiction Community Forum
instead.
Related questions
How can I make an image in my passage resize if the size of the screen changes? Sugarcube
Sugarcube Stylesheet: ...is it possible to add text to the sidebar using CSS and if yes, then how would I approach it?
How do I combine the use of an image as a background with a white box as background to text?
How can I change the background image according to a variable?
[Sugarcube 2.0] How do I change the background image for #ui-bar from passage to passage?
Most popular tags
twine2
sugarcube2-21
sugarcube2
twine2-2-1
harlowe2-0-1
harlowe2-1-0
harlowe
sugarcube2-18
javascript
css
twine2-1-3
sugarcube
variable
variables
macro
twine
links
twine1
if
sugarcube2-28-2
harlowe2
audio
html
array
image
snowman
passages
passage
savegame
inventory
music
arrays
saves
link
time
sugarcube2-25-0
textbox
harlowe1-2-4
error
text
array-objects
set
images
2
question
sugarcube-2
code
color
sugarcube2-27
tweego
datamaps
history
background
sugarcube-2-28-2
sugarcube-2-21-0
ui-bar
sidebar
sugarcube2-25
choices
autosave
jquery
button
publish-to-file
widgets
typed
random
import
transition
loop
twine2-3-1
harlowe2-2-1
replace-macro
choice
objects
tags
harlowe3-0-2
for-macro
rpg
saving
stats
effects
save
stylesheet
click-macro
twine-2
user-input
animation
header
questions
format
object
0
ui
script
error-message
sugarcube2-21-0
sugarcube2-24-0
loadgame
twine2-2-0
adventures
...