Draw a circle in paint in power-automate - power-automate-desktop

I'm exploring PowerAutomate and am stuck with a relatively simple issue;
I want to click-and-drag to draw a yellow circle in Ms paint.
Currently, my flow looks like this:
start Paint ( Run application )
Select Yellow ( Click UI Element in Window)
Click mouse
Drag?
The last two points are not working / don't know how to do.
What is the best approach?

Related

How to click the overlapping shapes in react konva?

I have the shapes (Rectangle, Ellipse and Polygon) that can overlap. I want to be able to select the inner shape inside the bigger one. If the bigger one is at the top, there is no way I can select the inner shape. I can't hover over it, click it or drag it. Is there any way to solve the issue?? If we look at the figma, if the shapes or whatever are overlapping we can double click and we are able to select the inner shape. Is there any similar way to do that in react konva??
In Konva.Stage there is the getAllIntersections method which will give a list of all of the shapes at any point on the stage. From here you could make UI to show the shapes and allow the user to select the specific shape to be transformed. The shape can then be dragged or sized as needed.

Qt [PySide6] visual artefacts with custom paintEvent

I'm trying to have a custom painting of a pyqtgraph derived Plot widget (the code is found here https://github.com/danielhrisca/asammdf/blob/bfa09d0b46f1b4b98b9ad1d0a0bb90cbb876b43e/asammdf/gui/widgets/plot.py#L4271): since painting a Plot with thousands of curves is very expensive I want to store the result in a QPixmap, then if I have a cursor active (implemented using an InfiteLine (see https://github.com/pyqtgraph/pyqtgraph/blob/6ed7d4fa4762aaa895f7e9b2fb09ec6df4cc793f/pyqtgraph/graphicsItems/InfiniteLine.py#L16) I would first draw the QPixmap on the viewport then on top just the cursor item. This way moving the cursor would not trigger the repaint of all the curves.
The QPixmap looks like this
and this is what happens when I create a cursor and slide it around:
Note that at the end the plot is zoomed out, this causes the reset of the QPixmap and the "native" repaint which produces the correct image with the single vertical line of the cursor.
What could be causing this?
I found the problem to be that the paint events were set to update just certain regions of the viewport instead of the full viewport.
The fix was to set the viewport update mode to full update
self.setViewportUpdateMode(QtWidgets.QGraphicsView.FullViewportUpdate)

How can I recognise programmatically when an up/down arrow is drawn on a chart when arrow objects are hidden?

I know how to draw an object arrow on the chart, which I usually do like this:
ObjectCreate(0,"prevHigh",OBJ_ARROW_DOWN,0,Time[0],High[highestCandle]);
ObjectSetInteger(0, "prevHigh", OBJPROP_COLOR, clrRed);
Now I have an indicator which (I didn't code myself and is a .ex4 file which) draws up/down arrows on the chart as seen in the image (https://imgur.com/a/8yG0suw).
How can I when for example a Magenta down arrow has been drawn and the candle (index) at which it is drawn?
Please note that the arrows not in the list of objects on the chart
Q : "How can I recognise programmatically when an up/down arrow is drawn on a chart?"
Given the facts above, your test ought evaluate the moment the CustomIndicator ( via a published / used iCustom()-call signature ) by checking it as it goes from EMPTY_VALUE to any value != EMPTY_VALUE.
Given the CustomIndicator is a closed source ( *.ex4 ) you may need to check, if it did set its own ( hidden from our sight ) value, other than a current visible EMPTY_VALUE, yet this "re-calibration" will work, after you get a few manual tests of the CustomIndicator values for bars, that do not show any arrow - like for the 2020-Apr-08 09:30 et al v/s the displayed arrows are not the MQL4-Objects on their own, they are the closed-source CustomIndicator's SetIndexStyle() / SetIndexArrow() by-products, thus not inspectable either in the Object-List, or in the *.mq4 source-code.
Yet, detectable

Modify interaction - How to get the segment which has been hovered

I am using openlayers-3 modify interaction to edit vector layers. When a polygon/polyline is being edited, if mouse is close to a line segment, a small circle is drawn and dragging it creates a new vertex or moves an existing vertex, depending on where on the segment I was hovering.
Now, sometimes this is very difficult to understand if I am hovering on an existing vertex, or on middle of a segment. I have thought about two solutions to the problem:
Highlight the segment I am hovering with a different style so that I
can see its edges.
When hovering on an vertex, style the small
circle with a different style.
Is there a way to achieve any of the two?
It can be done changing the interaction condition like:
var selectPointerMove_Highlight = new ol.interaction.Select({
condition: ol.events.condition.pointerMove
});
map.addInteraction(selectPointerMove_Highlight);
I have an online example.

Find available grid position

I'm building a color box connecting game with objective-C and trying to figure out how to find the correct position when a block of boxes is placed incorrectly over another block of boxes.
See the attach image. In the image, you only need to move the left box one step to the right in order to connect the boxes and win.
However, if you place the left box on top of the other box (Image 2), I want to move it to the closest available free grid position.
This would be easy if the box was a simple square (a 1x1 grid, 2x2 grid, etc), but since the boxes can be complex, It's harder. There might also be a lot of boxes on the grid.
Any suggestions would be very appreciated.
If you're new to heuristics like this, just take the KISS approach.
It couldn't be easier...
The user tries the object at x,y ok?
It does not "fit" there.
So, simply "spiral" outwards, trying it in other possible places.
Just keep trying until you find one where it fits.
234
915
876
so that's like "radius 1", you see? then try "radius 2"
and so on.
It's that easy. Just keep trying until you find one that "does work".
Work from the start position outwards, so that, you find the closest one.

Resources