Applying animation in xamarin.forms - xamarin

Is there any way I can implement the animation like
https://codemyui.com/circular-water-fill-loading-animation/ in Xamarin.forms?

Is there any way I can implement the animation like ...
The short answer is; Yes.
The longer answer; It depends upon what you really need, only you can answer that.
A "quick way" (at least for me) is to use the Xamarin.Forms' WebView and embed the html/svg/css/JScript into native application projects and setup a javascript interface to control the percentage completion (the water.style.transform element).
https://developer.xamarin.com/samples/xamarin-forms/WorkingWithWebview/
You could, of course, re-implement it using something like SkiaSharp, Lottie, etc and create a cross-platform Forms' control, or implement it as a "native" control on each platform.
Note: I'm a big fan of Lottie and would personally take that approach, but they do not support native UWP. Currently supported is iOS, Android, Web.
I edited the colors, etc. on that PEN sample you linked to and added the html/js/css to a Forms' solution, setup a JS interface and the results work in a Forms' WebView (iOS' UIWebView and Android's WebView, did not test UWP Edge, but it should work fine):

The Lottie is my preferred, but you can use a animation with the Nuget XamAnimation. It most hard to create but it's so good too.

Related

GUI style for windows Qt application

How can i achieve this kind of look and feel with colored buttons and rounded corners in dialogs for a windows application?
i dont think it can be done using MFC , will wxWidgets or Qt help ? or any other platform?
You can design whatever the look & feel you are pursuing using QSS. Why don't you take a look at Qt Documentation ? There are plenty of examples & guidance available.
Stylesheet Examples
Stylesheet Reference
Stylesheet Syntax
Customizing Qt Widgets Using Stylesheets
But at times, you will need to override a control to achieve your goal. Like in this question. But I think your required look can be achieved via QSS alone.
The easiest and fastest way to achieve the same UI accross different platforms is to implement it in QML with Qt. Unlike widgets that get automatically styled appropriate to the underlying platform style, QML is entirely platform-independent. You could probably style regular widgets with CSS, or even by reimplementing drawing manually with arbitrary UI API, but it will not be nearly as easy.
It is easy to achieve such a look and feel with any GUI framework.
Choose the framework you are most comfortable with, RTFM, roll up your sleeves and get started.
On any framework you will find methods to draw bitmaps of any color and shape and to handle mouse clicks on them. What more do you need?
This is what GUI frameworks DO! They also provide a default set of widgets for the bone lazy and the conventional. You aren't one of those people. are you?

Designing Android UI and Implementation Using Fireworks

I want to learn designing android UI and implementation to android apps. I found one video tutorial on the web but It seems only how to design. I don't know how to use it on apps.
Video Tutorial
How can I use custom UI design on my android app ? I'm using fireworks for design. For example, simple design:
How can I use this on my app ? (I know it looks terrible but I just want to learn how to do it.)
Simply creating a UI in fireworks won't be enough. You'll need to split it into multiple components, and the construct it within your app using XML or Java.
The Android developer site has a good set of documentation and guides on doing this.
Searching on Google will also give you lots of tutorials for the different UI elements and how to style them.
Your layout will require a tabbed Activity (or an ActionBar with tabs), a TextView and a Switch, from what I can see.

MvvmCross vnext : monodroid use a VideoView inside a plugin

I was playing with Xamarin Mobile api MediaPicker which uses MediaRecorder with monodroid to make a plugin to record a video.
Android must preview the video inside a VideoView. This restriction applies to wp7 and ios too for privacy.
So, I need to get the VideoView (or Rectangle in wp7) from my custom view and setPreviewDisplay to this VideoView in my plugin (or init MediaPicker with this VideoView).
What is the best way to implement my portable plugin which requires UI element ?
Thanks in advance for your help.
What is the best way to implement my portable plugin which requires UI element ?
I guess my first question is "do you need a portable plugin?"
What is the interface that you actually need at the ViewModel layer or lower?
My guess is that the cross-platform interface that the ViewModel will see might contain just:
some control commands (things like start/stop)
some summary information - e.g. video length
a file access layer - this may be as little as a file path?
If that's the case, then I'd probably implement most of the logic within Controls/Views/UIViews in the UIs, and would then bind the relevant commands and values to those ViewModel properties.
So I wouldn't personally implement this as a plugin at all!
I've previously done a couple of apps which use video views - one for video capture (Android only), one for bar code scanning.
I found that the basic available samples worked quite well. However, once I started trying to extend them, then they became quickly fragile, they were hard to get working and they were quite frustrating to develop!
I would genuinely recommend starting your current develop as UI View code. After you've got it working, then you might find a nice way to split up the control and interface into a plugin - but I suspect that this won't be where most of your time is spent.
e.g. for my next QR code app, I plan to use the separate UI controls in https://github.com/Redth/ZxingSharp.Mobile - at the ViewModel level, I can hopefully just expose some sort of Command which acts on the decoded QR strings.

Phonegap basics - designing ui for iphone and android

I'm developing an application both for Iphone and Andriod using Phonegap.
I came up with all kinds of plugins JQuery, JQTouch and more,
What is the recommended way of doing this?
Meaning-designing a generic UI (tabbars, tables, navigation bars etc') for both Iphone,Android that will "feel" native?
Thanks,
Asaf
If you want your application to look as native as possible I'd try jQuery Mobile.
The documentation is brilliant and all of elements look native to the iPhone. It's also incredibly easy and quick to build up your UI as all of the design and colour scheme has already been done.
I've used this in an Android application that I've made and I've so far received very positive reviews.
You may also want to look out for Kendo UI which is out this month! Again, very similar to what jQuery mobile is about with a few exceptions. It has great support for graphs and data, and promotes native Android look and feel.
Sencha Touch has just released version 2 and it is a good JS toolkit as well.
I feel I have to put my hat in the ring for jQTouch. Although the version downloadable from their site is a bit oldish, if you get it from GitHub it is currently maintained and works well on both iOS and Android. https://github.com/senchalabs/jQTouch
Also, if you want the fixed headers or footers with scrollable elements in-between, DataZombie's fork of jQTouch includes iScroll which does a great job of this. https://github.com/DataZombies/jQTouch
I am also in the process of developing a theme for jQTouch that will allow apps on Android to feel quite a bit more "native" than the other js kits as they all seem to have a very iOS-cenrtic navigation style (e.g.: back buttons on toolbars instead of relying on the hardware back button, etc). Even if you don't want to wait for my theme, making your own is pretty easy on jQTouch. I would not call myself a designer and I managed. ;)
Feel free to choose one of the other answers, but keep jQTouch in mind. I tried and tried other JavaScript frameworks and it was the only one that made it possible to look good on both platforms.
jQuery Mobile works awesomely.. and with the theme roller coming soon it will be pretty good.
Kendo Mobile UI - Pre release rip.. I have a working Eclispe project here.. markup is identical to jQuery mobile.. but this is faster, nice native looking apps. Take a look

Custom UI design in Sencha and othere touch frameworks

Can someone please guide me regarding which touch framework (javascript) I should use to make a tablet app? I am new to this area and I am looking for something which allows me to play with my own UI design comfortably.
I went through sencha as I heard its apt for a tablet app environment but I am (sorry, it might sound odd) not able to make out whether I can use my own UI design to make app in sencha. Or any other framework (stable) allows to use custom UI design?
There aren't any major differences between handsets and tablets, except for the screen size. For example, what you would show in a handset in one long scrolling screen, would be shown in a split-screen on a tablet (I am concentrating on the user-experience here).
Split-screen support in still rare in the jscript frameworks, since webkit browsers didn't fully support scrolling only parts of a page (i.e. an iframe or overflow:scroll divs), this support is only now starting to get materialized with iOS5 (Android already had this since 2.2, but it never worked right).
There have been other jscript solutions (like iScroll), but being client code they are not always bringing the full "experience" to the client.
The JQuery-Mobile docs have a version under testing, you can try that in a tablet/handset to see the differences.
Regarding your "own UI design", if you mean colors/icons/buttons that's possible on any framework. Where the problems start is when you want to create custom layouts, and each framework provides partial support depending on what exactly you want to achieve.
In general, I'd say Sencha totally separates you from HTML design - you build everything using JSON controls and it has an extensive events/rendering code (of course you can write your own controls), whereas frameworks like JQuery mobile work directly on the HTML (you specify data-* attributes for the details) and renders it almost the same (ok, it does adds wrapping layers, but in general it's still pure HTML).
As always, "it depends" on what you want to achieve and what you are ready to give up... ;-)
Sencha Touch (our framework) is particularly well suited to tablet apps because it has an implementation of multiple scrollable areas that works on older iOS and RIM devices, not just iOS5. But, the intention with Sencha Touch is that you create your app using the built-in UI components (carousels, momentum lists, tabs, etc.) or, if you have unique UI elements, then you will need to extend an existing component or build a custom component. If you're expecting to be able to slap some of your own HTML into innerHTML or even a Touch xTemplate, then you will be setting yourself up for failure. But the good news is that there are tutorials on doing your own components, and there are plenty of apps that you can look at the source of, in order to guide your development. Lots of people have built apps with custom UI's
You need some level of JavaScript experience to use Sencha Touch, so if you're coming from a non-JavaScript web design background, you'll have to get down the JavaScript learning curve first.

Resources