Dave Jarvis' Repositories

git clone https://repo.autonoma.ca/repo/keenwrite.git

Shrink broken image placeholder

AuthorDaveJarvis <email>
Date2020-06-29 17:36:06 GMT-0700
Commit65b9407ec2dfdfa782947d13f95f700eac6c82f8
Parent507e58f
Delta27 lines added, 28 lines removed, 1-line decrease
src/main/java/com/scrivenvar/preview/SVGRasterizer.java
static {
// A FontAwesome camera icon, cleft asunder.
- final String BROKEN_IMAGE_SVG = "<svg height='79pt' viewBox='0 0 100 79' " +
- "width='100pt' xmlns='http://www.w3.org/2000/svg'><g " +
- "fill='#454545'><path d='m32.175781 46.207031c1.316407 6.023438 6" +
- ".628907 10.4375 12.847657 10.675781zm0 0'/><path d='m27.167969 40" +
- ".105469-1.195313.949219.96875.804687c.050782-.59375.125-1.175781" +
- ".226563-1.753906zm0 0'/><path d='m42.394531 3.949219-10.054687" +
- ".875c-3.105469.269531-5.71875 2.414062-6.546875 5.382812l-1.464844 5" +
- ".222657-13.660156 1.183593c-4.113281.355469-7.160157 3.949219-6" +
- ".800781 8.023438l3.910156 44.269531c.363281 4.070312 3.992187 7" +
- ".085938 8.105468 6.730469l46.832032-4.058594-12.457032-10.347656c-" +
- ".992187.253906-2.007812.453125-3.0625.542969-10.277343.890624-19" +
- ".359374-6.65625-20.261718-16.832032-.089844-1.042968-.070313-2" +
- ".070312.007812-3.082031l-.96875-.804687 1.195313-.949219c1.4375-8" +
- ".042969 8.160156-14.476563 16.765625-15.222657.835937-.074218 1" +
- ".660156-.070312 2.476562-.035156l3.726563-2.953125zm0 0'/><path " +
- "d='m40.9375 46.152344 11.859375 11.742187c.570313.070313 1.144531" +
- ".121094 1.730469.121094 7.558594 0 13.714844-6.09375 13.714844-13" +
- ".578125 0-7.480469-6.15625-13.578125-13.714844-13.578125s-13.714844 " +
- "6.097656-13.714844 13.578125c0 .582031.050781 1.152344.125 1" +
- ".714844zm0 0'/><path d='m57.953125 3.363281 4.472656 19-4.183593 2" +
- ".269531c9.007812 1.988282 15.382812 10.316407 14.554687 19.664063-" +
- ".804687 9.132813-8.207031 16.128906-17.148437 16.824219l10.453124 12" +
- ".335937 17.75 1.539063c4.113282.355468 7.742188-2.660156 8.101563-6" +
- ".734375l3.910156-44.265625c.363281-4.074219-2.683593-7.667969-6" +
- ".796875-8.023438l-13.660156-1.183594-1.480469-5.226562c-.832031-2" +
- ".96875-3.441406-5.113281-6.546875-5.382812zm0 0'/></g></svg>";
+ final String BROKEN_IMAGE_SVG = "<svg height='19pt' viewBox='0 0 25 19' " +
+ "width='25pt' xmlns='http://www.w3.org/2000/svg'><g " +
+ "fill='#454545'><path d='m8.042969 11.085938c.332031 1.445312 1" +
+ ".660156 2.503906 3.214843 2.558593zm0 0'/><path d='m6.792969 9" +
+ ".621094-.300781.226562.242187.195313c.015625-.144531.03125-.28125" +
+ ".058594-.421875zm0 0'/><path d='m10.597656.949219-2.511718.207031c-" +
+ ".777344.066406-1.429688.582031-1.636719 1.292969l-.367188 1.253906-3" +
+ ".414062.28125c-1.027344.085937-1.792969.949219-1.699219 1.925781l" +
+ ".976562 10.621094c.089844.976562.996094 1.699219 2.023438 1" +
+ ".613281l11.710938-.972656-3.117188-2.484375c-.246094.0625-.5.109375-" +
+ ".765625.132812-2.566406.210938-4.835937-1.597656-5.0625-4.039062-" +
+ ".023437-.25-.019531-.496094 0-.738281l-.242187-.195313.300781-" +
+ ".226562c.359375-1.929688 2.039062-3.472656 4.191406-3.652344.207031-" +
+ ".015625.414063-.015625.617187-.007812l.933594-.707032zm0 0'/><path " +
+ "d='m10.234375 11.070312 2.964844 2.820313c.144531.015625.285156" +
+ ".027344.433593.027344 1.890626 0 3.429688-1.460938 3.429688-3.257813" +
+ " 0-1.792968-1.539062-3.257812-3.429688-3.257812-1.890624 0-3.429687 " +
+ "1.464844-3.429687 3.257812 0 .140625.011719.277344.03125.410156zm0 " +
+ "0'/><path d='m14.488281.808594 1.117188 4.554687-1.042969.546875c2" +
+ ".25.476563 3.84375 2.472656 3.636719 4.714844-.199219 2.191406-2" +
+ ".050781 3.871094-4.285157 4.039062l2.609376 2.957032 4.4375.371094c1" +
+ ".03125.085937 1.9375-.640626 2.027343-1.617188l.976563-10.617188c" +
+ ".089844-.980468-.667969-1.839843-1.699219-1.925781l-3.414063-" +
+ ".285156-.371093-1.253906c-.207031-.710938-.859375-1.226563-1" +
+ ".636719-1.289063zm0 0'/></g></svg>";
// The width and height cannot be embedded in the SVG above because the
// path element values are relative to the viewBox dimensions.
- final int w = 150;
- final int h = 150;
+ final int w = 75;
+ final int h = 75;
Image image;