Image positioning via the IUP library - c

Image (label) positioning cannot be set when using the IUP library. The documentation says that there is such a possibility, but for some reason the positioning does not work.

Related

How can I use the Win32 toolbar standard bitmaps outside of a toolbar?

The Win32 API provides a standard toolbar control and you can use standard bitmaps to differentiate the buttons.
https://learn.microsoft.com/en-us/windows/win32/controls/toolbar-standard-button-image-index-values
How can I use these standard icons outside of a toolbar? Or maybe, are there other standard icons with a file, a folder, etc?
Ok so thanks to IInspectable I looked into using TB_GETIMAGELIST to get a handle to the image list that the toolbar uses and with
ImageList_GetIcon
you can get an HICON from the imagelist and an index.

CodeName One Animation Questions . . .!

Is codenameone support add flash file.
Is codenameone support add Gif Image programmatically.
how to use create Graphics object.
Codename One or any modern mobile doesn't support adding flash files as those aren't designed for the mobile world.
You can add a gif image by using the "Add Animation" option in the designer tool and then using the getImage(String) method of the Resources object. That means you can't download an arbitrary gif off the internet but you can convert it to a res file and download that dynamically.
You can get a graphics object either by overriding paint(Graphics), implementing a painter etc. or by getGraphics on a mutable image see more here.

pywinauto - testing file icon overlays

I am looking for a good method for testing icon overlays of a file.
For example, Dropbox has different icon overlays for synced/syncing files etc.
I am currently using pyautogui's locateOnScreen() function, with a dictionary containing screenshots of all icon overlays types.
But using this approach, I need to have screenshots for every OS(different resolution, UI) and also tests are a little unstable.
NOTE: The tests will be cross platform(Mac and Windows)
Is there any other method besides image recognition that can be used for testing file icon overlays?

Implementing true Pinch and Zoom in the OxyPlot 2D library with MonoTouch

For plotting graphs I used the coreplot library for a while in my MonoTouch based iPhone app, but with iOS 6.0 the already annoying binding problems become so many that I decided to drop it for a library natively written in C#.
Searching around I found the excellent OxyPlot 2D library, and more specifically the MonoTouch port made by dvkwong.
The library works fine and has tons of useful features, but its output is just a rendered bitmap UIImage.
This means that I need to add myself the pinch and zoom features to the library.
The current implementation, based on the dvkwong preliminary example, uses the UIScrollView to zoom and unzoom the resulting bitmap image added to a simple subview.
This is not a good solution because when zooming the aliasing of the bitmap is made visible , and if the resolution is increased the text fonts becomes unreadable because are not optimized for the current zoom resolution.
I need to render the image each time at the correct resolution, without using UIScrollView but just overriding the DrawRect() call in a custom UIView.
But how to reproduce the the pinch-zoom gesture of Apple UIScrollView and draw the correct subrect of the OxyPlot plot model?
I tried to implement this method suggested here:
position the pinched view between the two fingers
But it doesn't work because I need to know the sub rect to draw, not applying a transformation matrix. Also there is no "draw sub rect" method in the OxyPlot library, so I need to set a cliprect in the image context and drawing a bigger image first and then clipping it. This is clearly too slow, because at some zoom levels the image can become huge (and I need the user to be able to zoom indefinitely on any part of the graph).
Any help is appreciated.
Thanks in advance.
I solved the problem myself.
I've created another MonoTouch port of the OxyPlot 2D library, this time supporting both Pan & Pinch-Zoom gestures. I've also added iPad support.
Now we have a native C# plot library for MonoTouch.
You can download it under the MIT Licence here:
https://github.com/Emasoft/OxyPlot.2DGraphLib.MonoTouch

State-of-the-art for embedding scriptable, interactive SVG in Gtk+ applications?

I'm interested in writing a Gtk application that uses an embedded SVG canvas for graphics, and I'm wondering what the current state-of-the-art is for using SVG in Gtk. I know that it's possible to embed Webkit inside of Gtk, and so that seems like one approach, but I would like to add interactivity to DOM elements in the embedded SVG canvas using C instead of JavaScript, and I'm not sure if the embedded Webkit exposes its DOM APIs to the embedding C context. I'm wondering if there might be a better approach. The last article I was able to find on the subject was from 2004: http://www.osnews.com/story/6460
librsvg is the preferred way to draw SVG into GTK+ widgets. However, to my knowledge, it doesn't support any kind of interactivity (only drawing).
Regarding WebKit, it does expose the DOM through webkit_web_view_get_dom_document. Have a look at the WebKitGtk tests for some examples.
I don't think that SVG itself is available. But Gtk+ has several Canvas widgets that resemble the idea of SVG (actually, they're not Canvas widgets but Scene Graph widgets). Clutter is one of such widgets.

Resources