I currently implemented mouse position input and display. position data from Driver
passes to ViewPort
and to Scene
to add graph of mouse pointer. The mouse graph(arrow) pass through ViewPort and Driver, then it is rendered as a position arrow.
However, this has two problems.
the positioning arrow of mouse moves quite slowly
ViewPort doesn’t accept positioning click such as dropdown
because it clicks mouse graph instead of dropdown
, I guess.
I’d like to render the arrow only inside Driver
itself likely the red color in the image. Or Are there any means to render the arrow to resolve the above two issues?
1 Like
FYI, Scenic 0.11 (currently in beta) includes mouse cursor support on Nerves:
# Upgrading to v0.11
## Overview
Version v0.11 is a MAJOR overhaul from the top to the bottom. For the first time, Scenic feels like something approaching a 1.0 in design.
This guide is a good first pass. As you use it in the Beta, if you see things that need improving, please contribute!
* `Scenic.Cache` is gone. It is replaced by a **much** easier to use asset pipeline.
* `push_graph` is back. WHAT! Didn't it go away last time? Yes. I've been struggling with the way scene state is handled. Coupled with the scene state change (next in this list), it finally makes sense.
* State for a scene is now tracked similar to how you add state to a socket in a Phoenix Channel or a Plug conn. The state is always a `%Scene{}` object and you can assign() state into it.
* The driver engine is a complete re-write. Existing drivers that render will need to be re-written. Sorry. The good news is that they all pretty much did the same thing in generating a "script" of draw commands that was sent over to some renderer. This is now standardized and moved to the ViewPort layer. Drivers are MUCH simpler as a result and more portable.
* The ViewPort, and even the Scene engines themselves are also re-writes, but their API is very similar to the old version, so not much news there except for the way Scene state is tracked.
* There is an entirely new Script engine for generating draw scripts that can be sent to drivers. This is quite powerful
* There are numerous other additions to Scenic
* The Component primitive is used to refer to, and start components.
* The Script primitive refers to arbitrary scripts that you can send to drivers.
* The `:line_height` style now sets the spacing between lines of text. Works like CSS.
* The `:text_align` style lets you align text vertically.
This file has been truncated. show original
(although the cursor isn’t noted in the upgrade guide currently, but I just created a PR to add it)
1 Like