examples icon indicating copy to clipboard operation
examples copied to clipboard

Update examples

Open rfuest opened this issue 4 years ago • 9 comments

This issues is intended to be a general discussion of changes to the examples we might want to make for the 0.7 release.

Candidates for removal:

  • rectangle-intersection.rs Is this an example or should this be moved into debug-tools? IMO it's not a great example because it mostly contains boilerplate code to make the example interactive.

Rename:

  • pacman.rs, progress.rs and analog-clock.rs These examples don't have a prefix, but I think they belong together because they are larger examples that don't only demonstrate a single e-g feature. Perhaps we could add a demo- prefix to the names, but I'm open to better suggestions.
  • hello-world.rs? This example would also fit in the above category, but perhaps it's better to keep the name because users might look for a hello world example.
  • input-handling.rs -> simulator-input-handling.rs
  • text-fonts-signs.rs Is "signs" the correct word in this context? The docs inside the file use "extended characters", which would also be more appropriate for the filename IMO.

Missing examples:

  • Thick triangles / polylines (#7)
  • Raw image
  • embedded-text If this repo is supposed to demonstrate the whole e-g ecosystem it should also include at least one e-t example. The docs for that example could contain a link to the additional examples in the e-t repo.
  • Text alignment
  • Example that uses the return value from text.draw(...) to draw text with multiple styles
  • Simple TextRenderer implementation
  • Underline and strikethrough for MonoFontStyle

rfuest avatar Jan 27 '21 17:01 rfuest

@jamwaffles Did I miss any new features that need an example?

rfuest avatar Jan 27 '21 17:01 rfuest

Skimming the changelog, I don't think there's anything major left out. It might be neat to have a demo showing the CSS colours, but it's not that important if it's left out.

jamwaffles avatar Jan 27 '21 17:01 jamwaffles

Do you think the CSS colors should have a separate example or should we just use them in other examples to make them look nicer?

rfuest avatar Jan 27 '21 17:01 rfuest

Using them in other examples would easily be enough I think. We could also extend this to some of the doc examples in embedded-graphics/embedded-graphics to raise awareness of them a bit.

jamwaffles avatar Jan 27 '21 17:01 jamwaffles

@bugadani Could you add a nice e-t example to this repo?

rfuest avatar May 24 '21 14:05 rfuest

Definitely. Anything particular I should showcase?

bugadani avatar May 24 '21 15:05 bugadani

Definitely. Anything particular I should showcase?

No, just something that looks nice and isn't easily achievable with e-g alone.

rfuest avatar May 24 '21 16:05 rfuest

Hmm, I was going to say that I'll delay adding an example until I can tag a beta, but looking at how the master is referenced in eg-next, I might not want to wait.

Do we want examples for eg-0.6 as well?

bugadani avatar May 30 '21 18:05 bugadani

IMO it's ok to just do it for next.

jamwaffles avatar May 30 '21 18:05 jamwaffles