Questions tagged [custom-renderer]

Custom Renderers let developers 'override' the default native rendering behaviour in Xamarin.Forms.

From the docs:

Xamarin.Forms user interfaces are rendered using the native controls of the target platform, allowing Xamarin.Forms applications to retain the appropriate look and feel for each platform. Custom Renderers let developers 'override' this process to customize their Xamarin.Forms code on each platform.

375 questions
20
votes
3 answers

Xamarin.Forms 2.5.0 and Context

Today I updated to Xamarin.Forms 2.5.0 and saw, that I get the following warnings: From the Android sub-project: Warning CS0618 'Forms.Context' is obsolete: 'Context is obsolete as of version 2.5. Please use a local context instead.' How…
testing
  • 17,950
  • 38
  • 208
  • 373
15
votes
3 answers

How to add a border to your Xamarin Form Label?

Hello fellow Xamarin Forms users, I already found out that borders on a label are not supported out of the box by Xamarin Froms. So after some searching is still have no clue how to make it possible. Is it possible to add a border using the custom…
Diceble
  • 611
  • 1
  • 5
  • 22
13
votes
2 answers

Force redraw of Xamarin.Forms View with custom renderer

I have a visual element MyButton with a custom renderer implemented for iOS. Shared: namespace RendererTest { public class MyButton: Button { public Color BoundaryColor { get; set; } } public static class App { …
Falko
  • 15,326
  • 12
  • 50
  • 91
8
votes
2 answers

ForceUpdateSize ListView issue on iOS

I have a custom ListView using custom ViewCells with radio buttons. On clicking of each of the radio buttons the ListView dynamically resizes its height to hide/show a comment box. On using ForceUpdateSize in iOS platform, the ListView performance…
Apurva19
  • 95
  • 6
8
votes
3 answers

Xamarin forms Shadow on Frame in Android

The Frame class in Xamarin Forms is quite limited, and can't allow me to get a shadow behind the Frame. I've made a custom renderer for iOS using this code: public class RatingInfoFrameRenderer : FrameRenderer { protected override void…
7
votes
3 answers

Revalidating JList - custom elements

I'm using a JList to hold chat data for my chat program. It uses a custom list renderer to render a custom JPanel object as the element type. This JPanel contains two JLabels (anchored to the top, for name and time), and a JTextArea (anchored to the…
Bradley Odell
  • 1,199
  • 2
  • 13
  • 26
6
votes
2 answers

Custom JSF component renderer: how to render HTML around another element

I have 2 elements, banana and an outputText, where banana is a custom JSF component and in banana renderer, I would like to generate HTML enclosing the specified element. xhtml:
Jacobski
  • 621
  • 6
  • 9
5
votes
1 answer

Creating JTable inside node of JTree

I know that this question is being asked before but I did not get proper solution. I read about outline but that was just opposite of what I want i.e. JTable inside JTree I want to display data in a JTable but it is stored as different groups,so…
Nav S
  • 155
  • 1
  • 11
5
votes
2 answers

How to add ToolbarItem on the left side of NavigationBar in Xamarin.Forms on Android?

I need to have a close button (in this particular case) on the left of Navigation Bar, as below. I need it only for popups, so there is no potential issues with other elements/navigations. There are a few suggestions in Google regarding this, but I…
Agat
  • 4,165
  • 30
  • 58
5
votes
1 answer

Xamarin.Forms: the MultiLineLabel doesn't longer work on Android

On my Xamarin.Forms project, I use a MultiLineLabel to display a title on 1 or 2 lines, depending the text length. I'm based on this blog to achieve this. So I have a MultiLineLabel control: public class MultiLineLabel : Label { private static…
Gold.strike
  • 1,002
  • 11
  • 32
5
votes
1 answer

How to set left and right padding to an entry cell in xamarin.forms

I have used custom rendering for entry cell in xamarin forms for IOS and android. How can I set left and right padding for the entry cell. My custom entry cell in PCl :
Sumeet Manghani
  • 61
  • 1
  • 1
  • 5
5
votes
2 answers

Using Google Maps on Xamarin.Forms for Android

So we need to create an app that renders a map and we are currently using Xamarin.Forms to integrate it. However, we will not use Xamarin.Forms.Maps since we have to use the Google Maps API for iOS and not its native map which is MapKit. My question…
5
votes
1 answer

Custom renderer for PrimeFaces component works fine in Tomcat, but not in Websphere

I'm using MyFaces 2.1.9 and PrimeFaces 3.5. I've implemented a custom renderer for . This works fine at home with Tomcat. But this does not work at work with Websphere. I've placed breakpoints in the custom renderer class, but they are…
KTrum
  • 1,644
  • 2
  • 18
  • 29
4
votes
1 answer

UICollectionView repeating and showing items out of order

I have build a custom renderer for UICollectionView. I have been having one issue and I ran out of ideas of possible fixes, here it is. Whenever the user scrolls the UICollectionView, the next items to be displayed in the screen are shown out of…
4
votes
2 answers

Custom search bar with rounded corner xamarin forms android

Custom searchBar renderer with Rounded corner : iOS protected override void OnElementChanged(ElementChangedEventArgs e) { base.OnElementChanged(e); var searchbar = (UISearchBar)Control; …
Riyas
  • 405
  • 1
  • 8
  • 22
1
2 3
24 25