Growing India News, world news, nation news, our news, people's news, grow news, entertainment, fashion, movies, tech, automobile and many more..
Saturday, July 30, 2022
Show HN: TapeMeasure – Swift class for creating segmented, labeled lines in UI https://ift.tt/Q0gbhvO
Show HN: TapeMeasure – Swift class for creating segmented, labeled lines in UI TapeMeasure is a utility class, written in Swift, for generating a visual tape measure, or any other graphical elements that need layout in a measured sequence. I created this class to help with a pet project I'm working on, where I needed to generate segmented, labeled lines to use as axes on charts and graphs. It occurred to me that this seems to be a pretty common task, involving a lot of boilerplate code and tedious calculations. Why not decouple the code and move it into a dedicated class? It's self-contained, nice and simple, and easy to unit test. It can also handle a lot of tweaks to the "tape measure", such as boundary clipping and shifting offsets. It's especially good for animation, where you can just change a parameter or two during animation, and call for the re-calculated data to re-render your measured line. That makes it great for animated sliding and scaling effects. Anyway, enjoy! https://ift.tt/uhAsQLw July 29, 2022 at 11:09PM
Subscribe to:
Post Comments (Atom)
Show HN: The Cascade Graph – An interactive map of AI and energy constraints https://ift.tt/O47EcUS
Show HN: The Cascade Graph – An interactive map of AI and energy constraints Hello, I wanted to share with you all a interactive map of the ...
-
Show HN: An AI logo generator that can also generate SVG logos Hey everyone, I've spent the past 2 weeks building an AI logo generator, ...
-
Show HN: Simple Gantt Chart Software https://ift.tt/sa3dQKF May 7, 2022 at 12:39PM
-
Show HN: Jsonnet Course Online Hi HN! I'm usually a lurker here, but I wanted to share this: I'm an enthusiastic user of Jsonnet[1] ...
No comments:
Post a Comment