Fossil

Check-in [7e97f4999b]
Login

Check-in [7e97f4999b]

Many hyperlinks are disabled.
Use anonymous login to enable hyperlinks.

Overview
Comment:Minor style tweaks to the open-in-pikchrshow links. No functional changes.
Downloads: Tarball | ZIP archive
Timelines: family | ancestors | descendants | both | omit-cr
Files: files | file ages | folders
SHA3-256: 7e97f4999b16ab756d20ae283186e258041615074ac1f7dd0c7ffa7c9ee415d7
User & Date: stephan 2024-10-12 23:08:18.519
Context
2024-10-14
01:10
Cherry-pick the show-in-pikchrview feature that was added to the omit-cr branch. ... (check-in: 521da5cd31 user: drh tags: trunk)
2024-10-13
00:50
Add a small bottom margin to the open-in-pikchr links so that the links in pikchr's own user manual don't crowd up directly next to immediately-following pikchrs. It's still a bit tight, but any more margin and it's too much when the following element is _not_ a pikchr. We could maybe solve this better by moving the link to the top of the picture instead of the bottom? ... (check-in: c0f192102a user: stephan tags: omit-cr)
2024-10-12
23:08
Minor style tweaks to the open-in-pikchrshow links. No functional changes. ... (check-in: 7e97f4999b user: stephan tags: omit-cr)
22:18
Add a 'title' attribute to the new open-in-pikchrshow links, which serves as a tooltip in desktop browsers. ... (check-in: 4f6282357c user: stephan tags: omit-cr)
Changes
Unified Diff Ignore Whitespace Patch
Changes to src/default.css.
1705
1706
1707
1708
1709
1710
1711
1712
1713






1714
1715
1716
1717
1718
1719
1720
div.pikchr-src > pre {
  /*Source code for a pikchr*/
  box-sizing: border-box;
  text-align: left;
}
div.pikchr-src > span {
  /*Wrapper for a link to open a pikchr in /pikchrshow*/
  margin-top: 0.8em;
  font-size: 80%;






}
/* The .source-inline class tells the .source class that the
   source view, when enabled, should be "inline" (same position
   as the graphic), else the sources are shifted to the left as
   if they were "plain text". */
div.pikchr-wrapper.center:not(.source),
div.pikchr-wrapper.center.source.source-inline{







|
|
>
>
>
>
>
>







1705
1706
1707
1708
1709
1710
1711
1712
1713
1714
1715
1716
1717
1718
1719
1720
1721
1722
1723
1724
1725
1726
div.pikchr-src > pre {
  /*Source code for a pikchr*/
  box-sizing: border-box;
  text-align: left;
}
div.pikchr-src > span {
  /*Wrapper for a link to open a pikchr in /pikchrshow*/
  margin-top: 0.5em;
  font-size: 85%;
}
div.pikchr-src > span::before {
  content: "[";
}
div.pikchr-src > span::after {
  content: "]";
}
/* The .source-inline class tells the .source class that the
   source view, when enabled, should be "inline" (same position
   as the graphic), else the sources are shifted to the left as
   if they were "plain text". */
div.pikchr-wrapper.center:not(.source),
div.pikchr-wrapper.center.source.source-inline{
Changes to src/pikchrshow.c.
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
        }
        if(PIKCHR_PROCESS_SRC & pikFlags){
          static int counter = 0;
          ++counter;
          blob_appendf(pOut, "<div class='pikchr-src'>"
                       "<pre id='pikchr-src-%d'>%h</pre>"
                       "<span class='hidden'>"
                       "[<a href='%R/pikchrshow?fromSession' "
                       "class='pikchr-src-pikchrshow' target='_new-%d' "
                       "data-pikchrid='pikchr-src-%d' "
                       "title='Open this pikchr in /pikchrshow'"
                       ">&rarr; /pikchrshow</a>]</span>"
                       "</div>\n",
                       counter, blob_str(&bIn), counter, counter);
        }
        if(PIKCHR_PROCESS_DIV & pikFlags){
          blob_append(pOut, "</div>\n", 7);
        }
      }else{







|



|







210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
        }
        if(PIKCHR_PROCESS_SRC & pikFlags){
          static int counter = 0;
          ++counter;
          blob_appendf(pOut, "<div class='pikchr-src'>"
                       "<pre id='pikchr-src-%d'>%h</pre>"
                       "<span class='hidden'>"
                       "<a href='%R/pikchrshow?fromSession' "
                       "class='pikchr-src-pikchrshow' target='_new-%d' "
                       "data-pikchrid='pikchr-src-%d' "
                       "title='Open this pikchr in /pikchrshow'"
                       ">&rarr; /pikchrshow</a></span>"
                       "</div>\n",
                       counter, blob_str(&bIn), counter, counter);
        }
        if(PIKCHR_PROCESS_DIV & pikFlags){
          blob_append(pOut, "</div>\n", 7);
        }
      }else{