HN user

yonilevy

396 karma

https://yoni.ninja/

Posts14
Comments59
View on HN

I do something similar, but my flow is around feature branches: I create a branch, dumping TODOs in the code as I work out the feature, then progressively fix them before merging the branch. Wrote a little script to highlight TODOs created in current branch (vs base) if anyone's interested: https://github.com/yonilevy/branchtodo

Coincidently I just started working on a drawing app, specifically an iPad app with figure drawing as the main use case. If you could share more details on the kind of drawing you'd like to allow it'd be easier to help. In general, as others said, there's a big difference between vector and raster based drawing apps. In vector drawings, you need to capture the mouse/pen/touch input and fit the points to a bezier curve (google "An algorithm for automatically fitting digitized curves"). Then you have a bunch of bezier-curve objects and draw them to the screen, any 2D graphics library will support this. Raster based drawings are more tricky, you usually paint with a brush, which is a bitmap that gets blended to the existing drawing, possibly affected by the input (pressure, angle, etc.). Here your focus is on performing graphics operations efficiently, as there are many of them per second, and they should appear to occur in real-time. A GPU is very helpful to this kind of drawing.

Another big aspect of this sort of app is undo/redo support. Again it's gonna be different between vector and raster, but I find that in any undo-supporting app, figuring out how the undo mechanism will work can guide the rest of the software design quite effectively, so give that a thought.

If you're willing to share more details here I could probably help more concretely.

SwiftUI 7 years ago

This looks fantastic, congrats! Any word on whether 3rd party IDEs will be able to integrate the live-preview functionality? (AppCode user)

This question seems to pop on HN every other month. I very much share the frustration- after trying every product under the sun I always end up coming back to Sketch, which is suboptimal to say the least. I tried to think what is it about Sketch (which isn't meant for diagraming) that makes it the best tool for the job, this is what i came up with: (1) it's native/fast (2) keyboard shortcuts (3) simple shapes / no "component overload" (4) pretty results. So for fun (and profit) I decided to write my own diagraming tool, with those points in mind. It's Mac only, very much work-in-progress and built specifically to replace Sketch in my workflow. If anyone's interested (in working on this, testing, whatever) - hit me up at my username here @ gmail.

As a heavy IntelliJ user - I use the function keys all the time. Some examples: F1: show file in project view, F2/Shift F2: next/previous error, Ctrl+F2: stop process, F3/Shift F3: find next/previous, F6: move/rename, different F7 variations: find usages, F9/F10: run/debug options, also F8-F10 - step over/into/out/continue, F12 - toggle maximize editor, etc.

I don't understand what I'm supposed to do with a touchbar, or how to otherwise remap all of these shortcuts... Sticking to my 2015 MBP for now, but I really hope Apple get their act together and release a developer-friendly model (because otherwise I'm a huge fan).

Out of curiosity- why is detection of fake videos a hard problem? It sounds like a classification problem that a simple NN with enough data would be able to solve(?)

Kinda related, I want an app that takes a picture of a hand drawn diagram and converts that to SVG (or whatever format I could later edit digitally). That would be a great way to bootstrap a large diagram, as it seems all diagram editors lose to pen & paper.

The best "demonstration" of a Zero-Knowledge proof I've heard is this:

Suppose you and a friend are looking for Waldo in a "Where's Waldo?" book page. You found Waldo first, and would like to prove that, but you don't want to ruin the fun for your friend-- you shouldn't provide any information that would take away from their challenge of finding Waldo themselves. How would you do that?

<Take a minute to think about it>

You take a cardboard several times larger than the "Where's Waldo" frame, and cut a hole the size of Waldo's head right in the middle of it. You then place the book on one side of the cardboard so that the only thing visible from the other side is Waldo's head. You show it to your friend. Notice you have proven you know the solution to "Where's Waldo" without revealing any information about the problem which they haven't known before. That to my understanding is the core concept of ZK proofs.

It didn't alter history. No transactions were reverted. It changed the rules by moving ETH from the attacker-owned contract address to a new contract address from which DAO investors could withdraw their funds. You might say that's semantics but in this technical context it's important, had the HF suggested altering history it would have gained less support IMO.

With Etherum's social consensus, you have to re-choose your platform every time someone creates an alternate history.

IIUC to get to the "every time" you're talking about just once, more money would need to be invested by attackers than it would cost to 51% attack bitcoin.