I am trying to show an entrybox after tapping an image.
I have this:
And I want to achieve this after tapping on the keyboard image:
The gesture is not a problem I add this lines:
keyboard.GestureRecognizer.Add(new TapGestureRecognizer((view,args) =>
{
ShowEntryBox();
})):
The problem is that I do not know how I can show the entry box, I use XAML. I tried relativelayout and I saw samples of absolutelayout but I can not achieve it.
I am using Xamarin forms to android and ios App.
Perhaps try a Grid?
In the center cell you can create two child controls:-
*) Label control.
*) Entry control.
and then give these controls each a name and set the appropriate .IsVisible value on each of these two controls accordingly, or alternatively hook the IsVisible for each of these controls into a ViewModel and set the state there instead.
Related
Using a Xamarin Forms ListView with a custom ViewCell, is it possible to have a list item expand based on an event? Please ignore the orange lines, but reference the below picture...
Regular cell not expanded
User has tapped the triple dots causing the ViewCell to expand to show additional content
Is this possible? What is the technique to make that work?
You can have containers or elements inside your viewcell whose Visibility can be controlled based on the click. You will have to re render the elements once its expanded or collapsed for the viewcell to resize. Or else you will have the Viewcell being the size it was initially rendered, but the contents inside it overflowing.
Check out the following links :
How to implement Expandable/Collapsible ListView in xamarin forms?
CollapseListView-in-xamarin.forms
ExpandableListView
I am trying to create an animation to a control.
So think of the animation and control of a now playing page on most touch screen devices. You see the control (album photo) and swipe either way and get it to slide off the screen and then the next control (album photo) slides on in its place.
I am not asking for you to code me this, but I am having trouble wrapping my head around a way that this could be done.
The control content is always changing, when you swipe one way, an image is removed from the view and then the next is added.
What you need is FlipView control which can get you the interface you described.
Here are some references:
Quickstart: Adding FlipView controls (XAML)
XAML FlipView control sample
This is my first mac application. I've written for iOS before and have been able to accomplish this same goal.
I'm trying to change the background color of a custom view. In the photo below, the two views are named view0 and view1.
Here's the code I'm trying to use to accomplish this (in the AppDelegate.m file):
- (IBAction)upPressed:(id)sender {
NSLog(#"upPressed");
self.view0.layer.backgroundColor = CGColorCreateGenericRGB(1, 0, 0, 1);
}
I'd like the color of view0 to turn red upon pressing the up button. The button click registers fine.
When I run the simulator, the views do not even show up.
Upon clicking the up button, nothing changes.
Why is this single line of code inadequate? In iOS, I was able to use a similar method of setting the background color of a view to simply make its color change.
Select the custom view and then select the 'Show View Effects Inspector' in the right pane (looks like 3 pieces of paper on top of each other in Utilities Window). Check the box next to Custom View under Core Animation Layer. This will enable the Core Animation for that view type.
I want to use ItemInfo interaction in my sencha touch charts but do not want to use modal/hideonmasktap properties concept. it should not grey out the whole background.
When i tap on chart then there should be ItemInfo interaction panel shown and if I will tap again anywhere on screen then it should be disappeared but without using that greyed out concept which comes with modal/hideonmasktap properties.
Please help.
Thanks!!
I'm wondering if in IOS is possible to customize segmented control like the attached image. I have tried to change buttons image, but the segmented control container is still visible under the customized buttons. I observed that the segmented buttons title disappears if you add button image. Custom button images must include title?
Many thanks
Just roll your own. Make three UIButtons with two images for each state and write logic to allow only one of them to be selected.