diff --git a/apps/app/ui-tests-app/css/label-background-image.css b/apps/app/ui-tests-app/css/label-background-image.css new file mode 100644 index 000000000..f0eab9e94 --- /dev/null +++ b/apps/app/ui-tests-app/css/label-background-image.css @@ -0,0 +1,8 @@ +Label { + background-image: url('~/ui-tests-app/pages/test2.png'); + background-repeat: no-repeat; + background-position: left; + background-size: contain; + margin: 10; + border-width: 1; +} \ No newline at end of file diff --git a/apps/app/ui-tests-app/css/label-background-image.xml b/apps/app/ui-tests-app/css/label-background-image.xml new file mode 100644 index 000000000..f918bce05 --- /dev/null +++ b/apps/app/ui-tests-app/css/label-background-image.xml @@ -0,0 +1,7 @@ + + + + \ No newline at end of file diff --git a/apps/app/ui-tests-app/css/main-page.ts b/apps/app/ui-tests-app/css/main-page.ts index 1dd8ceb1d..e4531ace5 100644 --- a/apps/app/ui-tests-app/css/main-page.ts +++ b/apps/app/ui-tests-app/css/main-page.ts @@ -24,6 +24,7 @@ export function pageLoaded(args: EventData) { examples.set("zindex", "css/zindex"); examples.set("clipPath", "css/clip-path"); examples.set("padding", "css/padding"); + examples.set("label-background-image", "css/label-background-image"); let viewModel = new SubMianPageViewModel(wrapLayout, examples); page.bindingContext = viewModel; diff --git a/apps/app/ui-tests-app/web-view/web-view-test.xml b/apps/app/ui-tests-app/web-view/web-view-test.xml index 3e5c85348..a99501128 100644 --- a/apps/app/ui-tests-app/web-view/web-view-test.xml +++ b/apps/app/ui-tests-app/web-view/web-view-test.xml @@ -3,7 +3,7 @@ - + diff --git a/apps/package.json b/apps/package.json index a6d23c7f1..c5f563c87 100644 --- a/apps/package.json +++ b/apps/package.json @@ -9,7 +9,7 @@ "version": "2.1.1" }, "tns-ios": { - "version": "2.1.0" + "version": "2.1.1" } }, "dependencies": { diff --git a/tns-core-modules/ui/styling/background.ios.ts b/tns-core-modules/ui/styling/background.ios.ts index c657a4a89..681fe027f 100644 --- a/tns-core-modules/ui/styling/background.ios.ts +++ b/tns-core-modules/ui/styling/background.ios.ts @@ -94,7 +94,7 @@ export module ios { UIGraphicsBeginImageContextWithOptions(originalImage.size, false, 0.0); var context = UIGraphicsGetCurrentContext(); CGContextSaveGState(context); - CGContextTranslateCTM(context, 0.0, originalImage.size.width); + CGContextTranslateCTM(context, 0.0, originalImage.size.height); CGContextScaleCTM(context, 1.0, -1.0); originalImage.drawInRect(CGRectMake(0, 0, originalImage.size.width, originalImage.size.height)) CGContextRestoreGState(context);