I need to create a designer for Silverlight in WPF and I’m thinking of a few options
Use a WebBrowser control,
display the content there and
communicate Silverlight using the
JavaScript Bridge. Not sure if this
will be enough for the scenarios I
need to support (see below). This is what KaXaml is doing. SilverlightSpy uses a a more sophisticated WebBrowser control, but I'm not sure how they communicate with Silverlight.
Communicate using Sockets
between the Host and Silverlight.
Host the Silverlight runtime (not in
a browser), but directly using
AgCore.dll. Similar to what sllauncher does for OOB. I imagine
this is what Blend/VS are doing.
Do whatever Blend or VS are doing
which.
I obviously don’t want to go as far as VS and Blend, but I need to support drag and drop of some controls as well as grouping, changing the layout, moving controls in the design surface and obviously updating the Xaml as a result of this actions.
Any ideas, recommendations or pointers on the best way to create a Silverlight Designer in WPF?
SharpDevelop 4 has a WPF based editor for WPF and Silverlight -> http://www.icsharpcode.net/opensource/sd/
Related
I need to create a shoebox-style native Windows app in C++. A good example of such a UI would be CleanMyPC:
I've tried the various options of the MFC App wizard in Visual Studio 2019 to see what that would give, but it's either document-based (SDI), or too limited (dialog-style). The closest was an empty Win32 app, which just displays a menu bar and a blank window beneath it. At least it matches the Windows style. But that would mean using bare Win32 API, which doesn't seem like a good idea.
Can a UI like in the screenshot be created with MFC? If so, would that be a reasonable approach? Can MFC be effectively used in a non-document-style, non-dialog-style UI like this?
I understand that there's heavy customization of the controls going on in the screenshot; the question is can it be done with MFC?
It looks like the left sidebar and the right details areas could be made of customized list controls. I'll be looking into how a dialog-based sample app arranges the window, so that no document stuff is involved, but without immediate termination on a button click.
I am quite new to WP7 although have done lot of 2D games before(for BREW/J2ME).
But since in Windows phone we have the flexibility to create User Interface using XAML(through visual studio designer tools by drag/drop).
Is that really recommended or practical? I am asking because even the sample codes (provided here) doesn't have any XAML.
It really depends on your comfortably. Windows Phone 7 application can be made using the following
Silverlight for WP7 (Use this if your game is not very graphically intense)
XNA for WP7 (use this if you want to create a REAL game)
Silverlight and XNA for WP7 (use this if you would rather have all your menus using the easabilty of XAML, but still have all the gaming features XNA has)
The Microsoft provided GamestateManagementExample (http://create.msdn.com/en-US/education/catalog/sample/game_state_management) provides an easy to use alternative to baking some Silverlight into your XNA game. You can customise various options and add/remove screens really simply. You can make it look much more proffesional than using some "sprite" buttons.
I wanted to know the difference among following control and classes.
Windows Browser Control Vs CDHtmlDialog and CHtmlView.
It is visible that these things are used to add html content in UI for
windows based application.
But when we search in internet one will often confused with these things.
It would be good if some explain the usability of these Control and Classes.
The Web Browser Control is a Windows ActiveX control that is probably used by Internet Explorer itself to display HTML contents. At the very least, Web Browser Control and Internet Explorer use the same implementation for rendering HTML.
CHtmlView is a MFC - CView -derived class hosting said ActiveX control.
CHtmlDialog is a MFC - CDialog - derived class doing the same.
They are separate classes because unfortunately MFC has a "huge gap" between dialogs, views and windows.
I haven't worked significantly with either MFC class but in my understanding they don't add any functionality by themselves. You can as well host the web browser control like a normal ActiveX and use GetControlUnknown to acquire IWebBrowser interface.
The biggest problem in my experience is that DOM is only accessible after DocumentComplete, and that event won't fire before the message loop doesn't pump. This makes some operations rather painful I ended up with a custom interface queuing modifications until DOM is available.
P.S. Windows now offers the WebView2 - ActiveX control, based on Edge, as a sufficient and powerful replacement. see https://learn.microsoft.com/en-us/microsoft-edge/webview2/
I am using Expression Blend 4 with .Net 3.5
In the image below, there are options for Transition Effects and the ability to choose Easing effects for your transitions:
My Blend interface does not have these on my WPF application:
However, if I create a new application (such as a WPF Sketchflow app) these options appear just as they do in the first photo.
What determines whether or not these options appear, and how can I get them into my WPF application?
I think you need the WPF toolkit to even get this far with .NET 3.5. (WPF 3.5 lacks the VisualStateManager; the toolkit adds this missing piece.) As to why it doesn't show up, it's because it's not supported in WPF 3.5:
In V3, we added four primary enhancements in this area. The first was
EasingFunctions, which are critical to making property animations have
the right feel. We’ve got all the classics—quadratics, cubics, bounce,
elastic, etc. Plus, you can write your own EasingFunction in C# or VB
and apply it to any animation you wish. This is all supported in
Silverlight 3 and WPF 4.
When you create a new WPF Sketchflow app, it's almost certainly targeting .NET 4.0.
I have been asked to build an application where I can drag and drop few WebControls onto the WebPage designer surface.
So far I have read some articles on .NET Framework Design-Time architecture, like, MSDN Article: Hosting WinForms Designers, Developer Function Article etc.
But I can't a find a way to host WebForms designer. The only open source implementation that I could find was Mono Develop ASP.NET Visual Designer.
But in mono they have used GTK# & Gecko etc to host the designer. I can't find a way to do the same using WinForms.
Please suggest me what should I do. Give me some pointers. Should I go ahead and implement it using GTK# and Gecko?
PS: My requirement is not very huge. I need just a way to drag and drop simple web controls and save the page.
Creating a designer host and hosting the controls is easy. The hard part is the HTML design surface, to let you actually see the controls, select, drag-n-drop, resize, etc. There is nothing built into the .NET/ASP.NET framework to do this for you.
I built AspNetEdit - and pretty much abandoned it because it was too difficult to build a reliable HTML design surface designer with Mozilla/Gecko.