Re: [mono-android] How to open the Layout Designer in VS 2010 ?
Yes, this looks like a bug. I'll check what's wrong. El 27/04/2012, a las 11:57, Narcís Calvet escribió: > Hello, > > This is failing for me. I'm using VS2010 for writting code and Monodevelop > for the layout files. My project references a M4A Android Class Library > project so that it has no "Resources" folder and no layouts. When I try to > open a layout I created with Monodevelop, in the project I'm working with, I > get this error message in VS2010: > > "Could not find a part of the path 'PathToMyReferencedProject\Resources\'." > > So I manually created "Resources" folder with "Drawable", "Layout" and > "Values" folders on the referenced project. Now the layout files try to load > but end up with this message: > > "The layout could not be loaded. Layout resource could not be found." > > I guess that's because Resource.Designer.cs (automatically generated file) is > missing in that project. I wonder why a referenced Class Library project > would need all this when layouts are in another application project and not > using any resource from that project. Am I doing anything wrong or is there > way to fix that in VS2010? All this works fine in Monodevelop. > > Thanks in advance. > > > Best Regards, > > Narcís Calvet > Steema Software > http://www.steema.com > http://twitter.com/SteemaSoftware > https://www.facebook.com/SteemaSoftware > > > -Original Message- > From: monodroid-boun...@lists.ximian.com > [mailto:monodroid-boun...@lists.ximian.com] On Behalf Of Atsushi Eno > Sent: divendres, 27 / abril / 2012 08:35 > To: Discussions related to Mono for Android > Subject: Re: [mono-android] How to open the Layout Designer in VS 2010 ? > > On VS 2010, create a new project, open Resources/layout/Main.axml and see if > it shows up for you. > > Any android layout resource XML file under that layout directory should open > the designer (no new project is actually required). > > Atsushi Eno > > > moelski wrote: >> Hi @all, >> >> maybe I´m blinded but where / how can I open the new Layout Editor in >> VS 2010? >> Installed the latest Alpha but can´t find it >> >> Dominik >> >> -- >> View this message in context: >> http://mono-for-android.1047100.n5.nabble.com/How-to-open-the-Layout-D >> esigner-in-VS-2010-tp5669287p5669287.html >> Sent from the Mono for Android mailing list archive at Nabble.com. >> ___ >> Monodroid mailing list >> Monodroid@lists.ximian.com >> >> UNSUBSCRIBE INFORMATION: >> http://lists.ximian.com/mailman/listinfo/monodroid > > ___ > Monodroid mailing list > Monodroid@lists.ximian.com > > UNSUBSCRIBE INFORMATION: > http://lists.ximian.com/mailman/listinfo/monodroid > > > ___ > Monodroid mailing list > Monodroid@lists.ximian.com > > UNSUBSCRIBE INFORMATION: > http://lists.ximian.com/mailman/listinfo/monodroid ___ Monodroid mailing list Monodroid@lists.ximian.com UNSUBSCRIBE INFORMATION: http://lists.ximian.com/mailman/listinfo/monodroid
Re: [mono-android] How to open the Layout Designer in VS 2010 ?
Do those files have a .xml or .axml extension? El 27/04/2012, a las 12:35, martze escribió: > I'm also having issues with the designer. > For some files i can choose whether to open it with designer or show code, > for some only the designer is opened, and for others only code works. > > -- > View this message in context: > http://mono-for-android.1047100.n5.nabble.com/How-to-open-the-Layout-Designer-in-VS-2010-tp5669287p5669934.html > Sent from the Mono for Android mailing list archive at Nabble.com. > ___ > Monodroid mailing list > Monodroid@lists.ximian.com > > UNSUBSCRIBE INFORMATION: > http://lists.ximian.com/mailman/listinfo/monodroid ___ Monodroid mailing list Monodroid@lists.ximian.com UNSUBSCRIBE INFORMATION: http://lists.ximian.com/mailman/listinfo/monodroid
Re: [mono-android] design view <--> source view
Yes, that's planned. El 27/04/2012, a las 15:11, Wally McClure escribió: > It would be nice to have a button that allowed for the quick and easy change > from design view to source view and back again while in VS. I realize that I > can open the file in a different editor, but this would be helpful. > > Wally > ___ > Monodroid mailing list > Monodroid@lists.ximian.com > > UNSUBSCRIBE INFORMATION: > http://lists.ximian.com/mailman/listinfo/monodroid ___ Monodroid mailing list Monodroid@lists.ximian.com UNSUBSCRIBE INFORMATION: http://lists.ximian.com/mailman/listinfo/monodroid
Re: [mono-android] controls in the toolbox
El 27/04/2012, a las 15:43, Wally McClure escribió: > I see that there are a number of controls in the toolbox in the designer in > VS. Questions: > Are the controls filtered in anyway? For example, is there a way to only > show controls that are suitable for Honeycomb and later? I see that there is > a place where I select which standard look to give the controls in the > designer (ICS, Honeycomb, Gingerbread, Froyo, ). Can that be used in > anyway to filter these controls somehow? I tried to change the Android > version level settings in the project properties and the android manifest > file, closed and reloaded the solution, and I found that the toolbox didn't > change the controls inside of it. Toolbox filtering is not yet supported in the VS add-in. In MonoDevelop, the toolbox shows the widgets supported by the target api level of the project. > I am guessing that the controls that are loaded are based on a defined set of > controls somewhere. There are some that are missing. Is there anyway to add > to the controls displayed in the toolbox? I did a right click on the toolbox > and tried to "chose items" but did not see anything besides the standard .NET > items. Is a way coming to add controls to the toolbox? Support for customizing the toolbox is something planed for future versions. The control list comes from a file available in the Android SDK, and is specific to the target platform. > I haven't tried this, but what happens if I have a control that isn't listed > in the toolbox that I use in a layout? If it is a standard Android widget, it may be rendered properly, depending if the android sdk can handle it or not. Otherwise it will be shown as a grey box. Lluis. ___ Monodroid mailing list Monodroid@lists.ximian.com UNSUBSCRIBE INFORMATION: http://lists.ximian.com/mailman/listinfo/monodroid
Re: [mono-android] arrows in the designer
You can click on the arrows to set the layout_width or layout_height to wrap_content or match_parent. This probably needs a tooltip. Lluis. El 27/04/2012, a las 17:12, Wally McClure escribió: > What are the arrows in the table layout that is in the attached file? The > circle allows me to drag and expand the margin, but the arrow is a little > confusing to me. > > Wally > ___ > Monodroid mailing list > Monodroid@lists.ximian.com > > UNSUBSCRIBE INFORMATION: > http://lists.ximian.com/mailman/listinfo/monodroid ___ Monodroid mailing list Monodroid@lists.ximian.com UNSUBSCRIBE INFORMATION: http://lists.ximian.com/mailman/listinfo/monodroid
Re: [mono-android] intellisense in the layout editor
Added to the TODO list. El 04/05/2012, a las 19:00, Wally McClure escribió: > I love the layout editor in 4.1.1. I was just experimenting on the mac. I > was wondering if there might be some way to get the intellisense to select > the appropriate string resource. I see that I would have to know the > resource name to get it. > > Wally > PM.png>___ > Monodroid mailing list > Monodroid@lists.ximian.com > > UNSUBSCRIBE INFORMATION: > http://lists.ximian.com/mailman/listinfo/monodroid ___ Monodroid mailing list Monodroid@lists.ximian.com UNSUBSCRIBE INFORMATION: http://lists.ximian.com/mailman/listinfo/monodroid
Re: [mono-android] Designer Error
Looks like the layout file contains invalid xml. Make sure the initial processing instruction (the tag) is the first one in the file, and that there is no whitespace before it. El 15/05/2012, a las 19:46, José M. Rivera escribió: > I am getting the following error when trying to open a layout (.axml) with > the new Designer: "The layout could not be loaded: PI must not start with > xml (position:unknown @1:5 in java.IO.InputStreamReader@17766806)" > > Any help? > > ___ > Monodroid mailing list > Monodroid@lists.ximian.com > > UNSUBSCRIBE INFORMATION: > http://lists.ximian.com/mailman/listinfo/monodroid ___ Monodroid mailing list Monodroid@lists.ximian.com UNSUBSCRIBE INFORMATION: http://lists.ximian.com/mailman/listinfo/monodroid
Re: [mono-android] Visual Studio 2010 crashes when opening a new or existing Mono for Android project after upgrade to 4.2.1
This will be fixed in the next release. As a workaroud, try adding the java bin directory (the one that contains the 'java' command) to the PATH. El 15/05/2012, a las 22:47, Saeid Yazdani escribió: > Ok, I'll wait for an update :P For reference, I think this is the error I got > from visual studio debugger: > > System.NullReferenceException was unhandled > Message=Object reference not set to an instance of an object. > Source=Xamarin.AndroidDesigner > StackTrace: > at > Xamarin.AndroidDesigner.JavaProcessConnection.OnConnected(IAsyncResult res) > at System.Net.LazyAsyncResult.Complete(IntPtr userToken) > at System.Net.ContextAwareResult.CompleteCallback(Object state) > at System.Threading.ExecutionContext.Run(ExecutionContext > executionContext, ContextCallback callback, Object state, Boolean > ignoreSyncCtx) > at System.Threading.ExecutionContext.Run(ExecutionContext > executionContext, ContextCallback callback, Object state) > at System.Net.ContextAwareResult.Complete(IntPtr userToken) > at System.Net.LazyAsyncResult.ProtectedInvokeCallback(Object result, > IntPtr userToken) > at > System.Net.Sockets.BaseOverlappedAsyncResult.CompletionPortCallback(UInt32 > errorCode, UInt32 numBytes, NativeOverlapped* nativeOverlapped) > at > System.Threading._IOCompletionCallback.PerformIOCompletionCallback(UInt32 > errorCode, UInt32 numBytes, NativeOverlapped* pOVERLAP) > InnerException: > > > -- > View this message in context: > http://mono-for-android.1047100.n5.nabble.com/Visual-Studio-2010-crashes-when-opening-a-new-or-existing-Mono-for-Android-project-after-upgrade-to-1-tp5709541p5709784.html > Sent from the Mono for Android mailing list archive at Nabble.com. > ___ > Monodroid mailing list > Monodroid@lists.ximian.com > > UNSUBSCRIBE INFORMATION: > http://lists.ximian.com/mailman/listinfo/monodroid ___ Monodroid mailing list Monodroid@lists.ximian.com UNSUBSCRIBE INFORMATION: http://lists.ximian.com/mailman/listinfo/monodroid
Re: [mono-android] Designer Error
I am unable to reproduce this problem. Can you send me a sample layout (+included files) I could use to reproduce the error? El 15/05/2012, a las 21:02, NebulaSleuth escribió: > I had the same problem. It was because my design file used an > statement. > > It appears that the designer doesn't like it, or has a problem resolving the > path. This is unfortunate because I use them whenever I have a > element. That way my xml isn't so messy. > > > something like: > >android:id="@+id/flMainFlipper" >android:layout_width="fill_parent" >android:layout_height="fill_parent"> >android:id="@+id/view1" >layout="@layout/view1" /> >android:id="@+id/view2" >layout="@layout/view2" /> > > > Hope this helps. It was my cause for that same error. > > Anyone have a solution to this? > > -- > View this message in context: > http://mono-for-android.1047100.n5.nabble.com/Designer-Error-tp5709771p5709774.html > Sent from the Mono for Android mailing list archive at Nabble.com. > ___ > Monodroid mailing list > Monodroid@lists.ximian.com > > UNSUBSCRIBE INFORMATION: > http://lists.ximian.com/mailman/listinfo/monodroid ___ Monodroid mailing list Monodroid@lists.ximian.com UNSUBSCRIBE INFORMATION: http://lists.ximian.com/mailman/listinfo/monodroid
Re: [mono-android] Designer Error
Are you using Windows or Mac? MonoDevelop or Visual Studio? El 16/05/2012, a las 18:07, José M. Rivera escribió: > > Lluis Sanchez Gual wrote >> >> I am unable to reproduce this problem. Can you send me a sample layout >> (+included files) I could use to reproduce the error? >> > > http://mono-for-android.1047100.n5.nabble.com/file/n5709822/tittle_header.axml > tittle_header.axml > http://mono-for-android.1047100.n5.nabble.com/file/n5709822/PolicyCollection.axml > PolicyCollection.axml > > I am still trying to get it to work but it only works when I remove the > tag. > > -- > View this message in context: > http://mono-for-android.1047100.n5.nabble.com/Designer-Error-tp5709771p5709822.html > Sent from the Mono for Android mailing list archive at Nabble.com. > ___ > Monodroid mailing list > Monodroid@lists.ximian.com > > UNSUBSCRIBE INFORMATION: > http://lists.ximian.com/mailman/listinfo/monodroid ___ Monodroid mailing list Monodroid@lists.ximian.com UNSUBSCRIBE INFORMATION: http://lists.ximian.com/mailman/listinfo/monodroid
Re: [mono-android] Designer Error
The problem seems to be with files which have a byte order mark. MonoDevelop creates new files without a BOM, and that's why it then works. At least I know what's the issue now. El 17/05/2012, a las 05:08, NebulaSleuth escribió: > > Lluis Sanchez Gual wrote >> >> >>> I am unable to reproduce this problem. Can you send me a sample layout >>> (+included files) I could use to reproduce the error? >>> >> > > So I was going to give you an example, but I wanted to simply it first. So > what I found was very strange indeed. > > If I created a NEW layout using "rightclick on layout->add->new > item->Android Layout" and then copied the contents from an included layout > that didn't work, and then changed the include to refer to the new file. > Voila it started to work. > > The contents of the new file are identical to the original file, just that > it is a different file. If I change the include to point back to the old > file, it fails again. > > So I suspect, if I give you the files, it will probably work for you. > > The project was converted from a Mono 4.0.6 project, so it might have > something to do with it. Not sure what is confusing it, but there is a > workaround. :) > > I also am using VS2010 on Win7 x64. > > > > > > -- > View this message in context: > http://mono-for-android.1047100.n5.nabble.com/Designer-Error-tp5709771p5709841.html > Sent from the Mono for Android mailing list archive at Nabble.com. > ___ > Monodroid mailing list > Monodroid@lists.ximian.com > > UNSUBSCRIBE INFORMATION: > http://lists.ximian.com/mailman/listinfo/monodroid ___ Monodroid mailing list Monodroid@lists.ximian.com UNSUBSCRIBE INFORMATION: http://lists.ximian.com/mailman/listinfo/monodroid
Re: [mono-android] Designer Error
I can confirm that this is a limitation in the Android SDK. Eclipse suffers the same problem, it can't handle layout files which have a BOM. I'm going to add a check for this specific issue and show a more meaningful error message when it happens. To fix it you can just remote the header in the included file, or you can remove the BOM by opening the file with the hex editor (Open With->Hex Editor) and deleting the first 3 bytes. Lluis. El 17/05/2012, a las 09:27, Lluis Sanchez Gual escribió: > The problem seems to be with files which have a byte order mark. MonoDevelop > creates new files without a BOM, and that's why it then works. At least I > know what's the issue now. > > > El 17/05/2012, a las 05:08, NebulaSleuth escribió: > >> >> Lluis Sanchez Gual wrote >>> >>> >>>> I am unable to reproduce this problem. Can you send me a sample layout >>>> (+included files) I could use to reproduce the error? >>>> >>> >> >> So I was going to give you an example, but I wanted to simply it first. So >> what I found was very strange indeed. >> >> If I created a NEW layout using "rightclick on layout->add->new >> item->Android Layout" and then copied the contents from an included layout >> that didn't work, and then changed the include to refer to the new file. >> Voila it started to work. >> >> The contents of the new file are identical to the original file, just that >> it is a different file. If I change the include to point back to the old >> file, it fails again. >> >> So I suspect, if I give you the files, it will probably work for you. >> >> The project was converted from a Mono 4.0.6 project, so it might have >> something to do with it. Not sure what is confusing it, but there is a >> workaround. :) >> >> I also am using VS2010 on Win7 x64. >> >> >> >> >> >> -- >> View this message in context: >> http://mono-for-android.1047100.n5.nabble.com/Designer-Error-tp5709771p5709841.html >> Sent from the Mono for Android mailing list archive at Nabble.com. >> ___ >> Monodroid mailing list >> Monodroid@lists.ximian.com >> >> UNSUBSCRIBE INFORMATION: >> http://lists.ximian.com/mailman/listinfo/monodroid > ___ Monodroid mailing list Monodroid@lists.ximian.com UNSUBSCRIBE INFORMATION: http://lists.ximian.com/mailman/listinfo/monodroid
Re: [mono-android] designer object selection
You can use the document outline pad to see the widget hierarchy and select any widget you want. In MonoDevelop, click on View->Pads->Document Outline In Visual studio, View->Other Windows->Document Outline El 22/05/2012, a las 12:12, Goncalo Oliveira escribió: > Hi, > > When having two overlapping objects, I can only select the one on top. Is > there a way to select the underlying one instead? > > Cheers, > > > -- > Gonçalo Oliveira > ___ > Monodroid mailing list > Monodroid@lists.ximian.com > > UNSUBSCRIBE INFORMATION: > http://lists.ximian.com/mailman/listinfo/monodroid ___ Monodroid mailing list Monodroid@lists.ximian.com UNSUBSCRIBE INFORMATION: http://lists.ximian.com/mailman/listinfo/monodroid
Re: [mono-android] VS designer id property
I can't reproduce this problem. Do you have more detail about the exception you are getting? If the exception is shown in a dialog it should have a details section with the whole stack trace. El 28/05/2012, a las 13:10, Goncalo Oliveira escribió: > No answer on this? > > On 22 May 2012 12:18, Goncalo Oliveira wrote: > When setting the id property for an object I get the error "Property value is > not valid" along with the detail "Object reference not set to an instance of > an object". > I tried setting something like "@+id/myid"; maybe in the designer the syntax > is different? > > -- > Gonçalo Oliveira > > > > -- > Gonçalo Oliveira > ___ > Monodroid mailing list > Monodroid@lists.ximian.com > > UNSUBSCRIBE INFORMATION: > http://lists.ximian.com/mailman/listinfo/monodroid ___ Monodroid mailing list Monodroid@lists.ximian.com UNSUBSCRIBE INFORMATION: http://lists.ximian.com/mailman/listinfo/monodroid
Re: [mono-android] Designer element preview when out of view
Right now it is not possible to scroll in the designer. This will be supported in future releases. El 28/05/2012, a las 15:48, Goncalo Oliveira escribió: > Hi, > > When creating a layout with some length (with a scrollview), if we focus an > element that is out of the visibility bounds, there is no visual preview > reflected. > All we get is the blue selection frame that shows itself out of bounds. Is > there a way to get the content to scroll? Shouldn't the preview host scroll > into view? > > Cheers, > > > -- > Gonçalo Oliveira > ___ > Monodroid mailing list > Monodroid@lists.ximian.com > > UNSUBSCRIBE INFORMATION: > http://lists.ximian.com/mailman/listinfo/monodroid ___ Monodroid mailing list Monodroid@lists.ximian.com UNSUBSCRIBE INFORMATION: http://lists.ximian.com/mailman/listinfo/monodroid
Re: [mono-android] Opening Main.axml in designer
That's not possible right now, but in the next Mono for Android release the designer will allow editing the XML just like in MonoDevelop (without code completion thought). El 05/06/2012, a las 07:40, Matthew Leibowitz escribió: > Visual studio has two buttons that are used to switch between the > winforms/wpf designer view and the code view. > Is there a way the could make the designer or the xml code open using these > buttons? > > On Jun 5, 2012 7:28 AM, "Miljenko Cvjetko" wrote: > Hi > > You need to go again: Open with +/ Android Designer and it seems like it > remembers last view type. > > I think this was already reported... > > regards > > mel > On 2012.06.05 00:23, AndyFraser wrote: > I wanted to view the XML for Main.axml as text in Visual Studio 2010 so right > clicked on the file and chose Open with... I chose XML (Text) Editor and was > able to see and edit the file. However, now when I double click on > Main.axml, the file is always opened in text mode even though it still says > that Android Designer is the default. Even if I select Android Designer > (Default) and click the Set as Default button, it keeps opening in text > mode. Is this a known issue ? > > Andy > > -- > View this message in context: > http://mono-for-android.1047100.n5.nabble.com/Opening-Main-axml-in-designer-tp5710134.html > Sent from the Mono for Android mailing list archive at Nabble.com. > ___ > Monodroid mailing list > Monodroid@lists.ximian.com > > UNSUBSCRIBE INFORMATION: > http://lists.ximian.com/mailman/listinfo/monodroid > > > -- > Miljenko Cvjetko dipl.ing. ET >Direktor/CEO >Projektant rješenja/Solution Architect >Razvojni programer/Senior developer >Voditelj projekta/Project Manager > > IX južna obala 13 > Kajzerica Zagreb > T: 385 1 777 > M: 385 91 557 447 3 > F: 385 1 7779556 > e: mcvje...@holisticware.net > w: http://www.holisticware.net > > ___ > Monodroid mailing list > Monodroid@lists.ximian.com > > UNSUBSCRIBE INFORMATION: > http://lists.ximian.com/mailman/listinfo/monodroid > ___ > Monodroid mailing list > Monodroid@lists.ximian.com > > UNSUBSCRIBE INFORMATION: > http://lists.ximian.com/mailman/listinfo/monodroid ___ Monodroid mailing list Monodroid@lists.ximian.com UNSUBSCRIBE INFORMATION: http://lists.ximian.com/mailman/listinfo/monodroid