1

Android has a clipChildren method for allowing the contents of a view to overflow the view's containing area. I'd like to set this to false since it seems to be set to true by default. I'm trying to access the native android view and set this using the following in nativescript:

var view = topmost().currentPage.content.getViewById('viewname');
view.android.setClipChildren(false);

But this doesn't seem to be working.

1 Answer 1

1

I have tested your case and to make it work I have just changed the way I am calling my current page

var page = args.object;
var grid = page.getViewById('viewname');

grid.android.setClipChildren(false);

console.log('grid clipChildren: ' + grid.android.getClipChildren()); // returns false

Sign up to request clarification or add additional context in comments.

1 Comment

Thanks. This will help get me in the right direction. I'm using angular2 with nativescipt though and I haven't figured out how to attach a method to when an element loads (to then get the args parameter), but once I figure that out, this will help.

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Start asking to get answers

Find the answer to your question by asking.

Ask question

Explore related questions

See similar questions with these tags.