Bug 28537 - Drawable resources, styles, colors etc. not applied in designer
Summary: Drawable resources, styles, colors etc. not applied in designer
Status: RESOLVED INVALID
Alias: None
Product: Android
Classification: Xamarin
Component: Designer ()
Version: 4.20.0
Hardware: PC Windows
: Normal normal
Target Milestone: ---
Assignee: Jérémie Laval
URL:
Depends on:
Blocks:
 
Reported: 2015-03-30 07:06 UTC by Alex
Modified: 2017-09-12 18:30 UTC (History)
3 users (show)

Tags:
Is this bug a regression?: ---
Last known good build:


Attachments
Xamarin Studio IDE Logs (249.99 KB, application/octet-stream)
2015-03-30 09:59 UTC, Alex
Details


Notice (2018-05-24): bugzilla.xamarin.com is now in read-only mode.

Please join us on Visual Studio Developer Community and in the Xamarin and Mono organizations on GitHub to continue tracking issues. Bugzilla will remain available for reference in read-only mode. We will continue to work on open Bugzilla bugs, copy them to the new locations as needed for follow-up, and add the new items under Related Links.

Our sincere thanks to everyone who has contributed on this bug tracker over the years. Thanks also for your understanding as we make these adjustments and improvements for the future.


Please create a new report on Developer Community or GitHub with your current version information, steps to reproduce, and relevant error messages or log files if you are hitting an issue that looks similar to this resolved bug and you do not yet see a matching new report.

Related Links:
Status:
RESOLVED INVALID

Description Alex 2015-03-30 07:06:21 UTC
Since the latest update (see information below) the designer is not applying local resources anymore, the theme selector button only shows framework themes and resource selection window is just empty. Please fix, as its not usable.


=== Xamarin Studio ===

Version 5.8.1 (build 8)
Installation UUID: 6462d445-676f-48dc-8d02-deb35154603b
Runtime:
	Microsoft .NET 4.0.30319.18444
	GTK+ 2.24.22 (MS-Windows theme)
	GTK# 2.12.26

=== Xamarin.Android ===

Version: 4.20.0 (Business Edition)
Android SDK: C:\Users\aschonefeld\AppData\Local\Android\android-sdk
	Supported Android versions:
		2.1   (API level 7)
		2.2   (API level 8)
		2.3   (API level 10)
		3.1   (API level 12)
		4.0.3 (API level 15)
		4.4   (API level 19)
		5.0   (API level 21)
Java SDK: C:\Program Files\Java\jdk1.8.0_31
java version "1.8.0_31"
Java(TM) SE Runtime Environment (build 1.8.0_31-b13)
Java HotSpot(TM) 64-Bit Server VM (build 25.31-b07, mixed mode)

=== Xamarin Android Player ===

Not Installed

=== Build Information ===

Release ID: 508010008
Git revision: f8e52bf493869b6a320a95400553dc9ea8b7ef22
Build date: 2015-03-13 13:41:50-04
Xamarin addins: 84d611cc17567a68daad719327e90af06d2ae327

=== Operating System ===

Windows 6.1.7601.65536 (64-bit)
Comment 1 Ram Chandra 2015-03-30 08:27:03 UTC
I have checked this issue but I am unable to reproduce this issue.

Steps I followed:

1. I have crated an android application
2. Add a style.xml file in the "values" directory
3. Add the following code in style.xml 
   <application android:label="DemoApp" android:icon="@drawable/Icon" android:theme="@style/TestTheme" />

4. Add this theme to AndroidMainfest.xml 
5. Open the layout file in designer
6. Press the theme selector button.

When I click on theme selector button on android designer, I observed that the newly crated theme displayed in dialog window.

Screencast: http://www.screencast.com/t/pCBjssFIXbMz

Could you please provide sample application and IDE logs ? So that we can reproduce this issue at our end.

You can get IDE logs from here:
Xamarin Studio =>  Help => Open Log Directory => Ide logs(With latest timestamp) 

Environment Info:

=== Xamarin Studio ===

Version 5.8.1 (build 8)
Installation UUID: b6495454-eed9-49ee-a97b-abf8a686d664
Runtime:
 Microsoft .NET 4.0.30319.34003
 GTK+ 2.24.22 (MS-Windows theme)
 GTK# 2.12.26

=== Xamarin.Android ===

Version: 4.20.0 (Trial Edition)
Android SDK: D:\android-sdk\android-sdk
 Supported Android versions:
  2.1    (API level 7)
  2.2    (API level 8)
  2.3    (API level 10)
  3.1    (API level 12)
  4.0.3  (API level 15)
  4.3    (API level 18)
  4.4    (API level 19)
  4.4.87 (API level 20)
  5.0    (API level 21)
Java SDK: C:\Program Files (x86)\Java\jdk1.7.0_71
java version "1.7.0_71"
Java(TM) SE Runtime Environment (build 1.7.0_71-b14)
Java HotSpot(TM) Client VM (build 24.71-b01, mixed mode)

=== Xamarin Android Player ===

Version: 0.2.5
Location: C:\Program Files\Xamarin Android Player\DeviceManager.exe

=== Build Information ===

Release ID: 508010008
Git revision: f8e52bf493869b6a320a95400553dc9ea8b7ef22
Build date: 2015-03-13 13:41:50-04
Xamarin addins: 84d611cc17567a68daad719327e90af06d2ae327

=== Operating System ===

Windows 6.2.9200.0 (64-bit)
Comment 2 Alex 2015-03-30 09:59:20 UTC
Created attachment 10552 [details]
Xamarin Studio IDE Logs

IDE logs
Comment 3 Alex 2015-03-30 10:00:32 UTC
I attached the IDE logs as requested, I checked some of the warnings/errors in the log, example: 

INFO [2015-03-30 15:55:08Z]: ERROR: Bridge [resources.format] Failed to convert @color/background_menu into a drawable
INFO [2015-03-30 15:55:08Z]: ERROR: java.lang.NumberFormatException: Color value '@color/background_menu' must start with #

I double checked the value of all declared colors, all start with #
Comment 4 Alex 2015-04-09 08:14:15 UTC
Any news on this? Its getting really annoying..
Comment 5 Jon Douglas [MSFT] 2017-09-12 18:30:03 UTC
Thank you for taking the time to submit this report. After reviewing the description of this bug, we believe it no longer affects the current version of Xamarin.Android. If you are still experiencing the issue after updating your packages, please reopen this report with an attached reproduction.