Bug 26534 - Layout file does not show correct contents when switched to source tab
Summary: Layout file does not show correct contents when switched to source tab
Status: RESOLVED DUPLICATE of bug 26026
Alias: None
Product: Android
Classification: Xamarin
Component: Designer ()
Version: 4.20.0
Hardware: PC Mac OS
: High normal
Target Milestone: ---
Assignee: Jérémie Laval
URL:
Depends on:
Blocks:
 
Reported: 2015-01-29 04:00 UTC by Prashant Cholachagudda
Modified: 2015-03-10 17:55 UTC (History)
4 users (show)

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

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 DUPLICATE of bug 26026

Description Prashant Cholachagudda 2015-01-29 04:00:32 UTC
Layout file does not show correct contents when switched to the source tab from the desginer tab.
When we opened one of the layout file it displayed the content that
shouldn't be there. This happens when we open the file using a default "Layout Editor" option. 
However, when we open the axml file using "Source Code Editor" (or directly from the folder in windows explorer) everything is in
order.

Screenshots: http://imgur.com/a/MkJyd
Comment 1 Abhishek 2015-01-29 07:33:07 UTC
I have tried this issue and unable to reproduce the reported behavior at my end.

Steps to Reproduce:
1. Create the sample test android template.
2. Open the layout file, right click on it. Click on "Open With"-> "Layout Editor".
3. Content Page Open. Click on source and it show the source coder in proper format.
4. Open the same layout file by right click on file and select Open with-> 'Source Code Editor'
5. It shows the same source code content, not seeing any difference

screencast: http://www.screencast.com/t/y91HpjYH

I have tried it with some android sample and I have also tried it by changing the language of XS to "Polish". But still not able to reproduce this issue at my end.

If this issue exist with any specific application then Could you please provide a sample project? so that I can reproduce this issue at my end.

Environment info:

=== Xamarin Studio ===

Version 5.7.1 (build 15)
Installation UUID: 9964a087-9af9-4da0-aa20-07ca4b85f306
Runtime:
 Microsoft .NET 4.0.30319.18408
 GTK+ 2.24.22 (MS-Windows theme)
 GTK# 2.12.26

=== Xamarin.Android ===

Version: 4.20.0 (Business Edition)
Android SDK: D:\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)
  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, sharing)

=== Build Information ===

Release ID: 507010015
Git revision: ce24e991948c7f3d88b0194a14fc1996d848ef51
Build date: 2015-01-26 14:31:20-05
Xamarin addins: 6895e3222bfa6910524708aa0633ff3db99bc3a0

=== Operating System ===

Windows 6.1.7601.65536 (64-bit)
Comment 2 ltoczek 2015-01-29 09:53:01 UTC
Hi

We checked the same project on different machine and it seems it is machine related, as on another machine, there is no such error as on the second screenshot ("Connection to layout renderer failed...").

Is this problem familiar to you? It looks as if we solve that problem, the issue should go away (like I mentioned, on another problem there is no issue, so sending you the sample project will not help you in anyway).
Comment 3 Jérémie Laval 2015-03-10 17:55:12 UTC
Without logs it's hard to confirm but this is likely a dup.

The issue was mitigated in the latest 5.7 version. See KB for more information: http://kb.xamarin.com/customer/portal/articles/1897572-adjusting-java-memory-parameters-for-the-android-designer

*** This bug has been marked as a duplicate of bug 26026 ***