fontSize=14
fontFamily="Arial"
#variables are expanded inside double quotes
style1="font-size: $fontSize;font-family: \"$fontFamily\""
#style1 is "font-size: 14;font-family: "Arial""
#braces mark where the name ends, $(( )) puts in the result of arithmetic
style2="font-size: $((fontSize / 2))px;font-family: \"${fontFamily}\""
#style2 is "font-size: 7px;font-family: "Arial""
#bash has no fractional numbers: bc computes them,
#printf -v formats into a variable, like format() in Python
half=$(bc <<< "scale=1; $fontSize / 2")
printf -v style3 'font-size: %.1f;font-family: "%s"' "$half" "$fontFamily"
#style3 is "font-size: 7.0;font-family: "Arial""
#nothing is expanded inside single quotes
plain='font-size: $fontSize'
#plain is "font-size: $fontSize"
echo "style1 is $style1"
echo "style2 is $style2"
echo "style3 is $style3"
echo "plain is $plain"