Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Improve resolution of screenshots #35

Closed
LinqLover opened this issue Sep 22, 2020 · 2 comments · Fixed by #137
Closed

Improve resolution of screenshots #35

LinqLover opened this issue Sep 22, 2020 · 2 comments · Fixed by #137
Assignees
Labels
discussion enhancement New feature or request

Comments

@LinqLover
Copy link
Collaborator

EPS? SVG? Need to figure out.

@LinqLover LinqLover added the enhancement New feature or request label Sep 28, 2020
@LinqLover
Copy link
Collaborator Author

Results from a first spike:

  • SVG:

    • Squeak has no built-in SVG-support
    • SVGMorph can file in/file out SVG files, but apparently cannot convert regular morphs into SVG files
      • also has limited transparency support
  • EPS:

    • Squeak has built-in EPS support (Morph>>#exportAsEPS) - however, there are some limitations:
      • default font is hardcoded to Helvetica (PostscriptCanvas class>>#fontsForDejaVuSans)
      • the wrong font leads to misplaced text selections
      • some encoding/escaping issues for window titles and special characters
      • return charet is replaced by old-fashioned arrow-up
      • apparently, EPS (in Squeak) cannot handle transparency, making shadows and transparency look awkward
      • suspicious: further encoding/escaping issues: after converting the resulting EPS into an SVG file using different services, the resulting SVG cannot be rendered in Chromium (?)

    image

In the end, I see three possible options:

  1. Write a Morphic-to-SVG converter
    • likely very (too?) expensive
    • pro: benefit for further use (SVG is a widely spread format)
  2. Fix Squeak's EPS support
    • would require further spiking
  3. Just use high-dpi screenshots (e.g., 200%)
    • since Squeak 6.0, the high-dpi mode works commonly flawless
    • need to change scale factor in SBE-Extract and adjust Morphic examples to use px/pt
      • the latter might confuse beginners
    • con: no accessible/searchable screenshots

@LinqLover
Copy link
Collaborator Author

  • Use scaling: for 300 dpi, try with 200%
  • make sure that px does not appear in samples

@LinqLover LinqLover self-assigned this Sep 28, 2022
@LinqLover LinqLover changed the title Export figures as vector graphics Improve resolution of screenshots Sep 28, 2022
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
discussion enhancement New feature or request
Projects
None yet
Development

Successfully merging a pull request may close this issue.

1 participant