SuspendLayout using C1 FlexGrid for WPF - c1flexgrid

I'm facing performance problem with C1 FlexGrid for WPF, on other third party I've always the SuspendLayout method to disable the layout update while performing operations on the grid... is there any way I can perform this with FlexGrid?

SuspendLayout is a WinForms concept. You cannot, in good sense, apply the same for a WPF control. In WPF you don't do the rendering yourself, but rather compose nodes that you will put in a visual tree, and rendering would be handled behind the scene.
Rick Sladkey's answer to How can I suspend and resume layout in WPF?

Related

JavaFX: use only one scene or multiple scenes to build UI with static and dynamic content?

cheers,
i am fairly new to JavaFX2. I already did some research about the basic principles: Stages that contain Scenes. Scenes in turn can be switched. But only switching parts of scene does not seem to be common usage.
My Problem:
I am trying to create an application with a titlepane (containing a lable and some buttons) and a Pane containing further dynamic content. The titlepane will stay there throughout the whole lifecycle.
Now i am confused about what is the best way to achieve such a layout. I found some ideas like here to make my root layout a Borderpane and switch its center. In that case i would end up with only one scene. But i am not shure if that´s how it should be done.
Any help and ideas on this topic is very appreciated.
cheers tobi
P.S.: i am using FXML files to create my layout and Controller to handle each view.
Well there is this question: Loading new fxml in the same scene, which is (perhaps) a duplicate of yours. I wouldn't call the solution there a "best practice", but it is likely decent enough for a smallish app. The answer provides a small framework for swapping fxml controlled content panes in and out of a portion of the main scene.
Similar is Angela's Managing Multiple Scenes.
More comprehensive solutions are things like Gluon Desktop (which I haven't used) or afterburner.fx.
For an actual non-trivial application, look at the SceneBuilder application, which is probably the best "best practice" reference you could find for a decent sized JavaFX application. But, as it is non-trivial, understanding its architecture is likely non-trivial too.

How To create Responsive Layout

I am new to android and i dont know how to make responsive layout which can be
display equal in all devices,please help me out by providing some code for that.
All android resources are correctly scaled for whatever device you put them on.
However, you may want completely different or just slight different layouts (even though the scaling is handled perfectly) for the purpose of functionality.
For this, you'll need to use the android resource systems constraints and most likely fragments.
Fragments are covered in the following link
http://developer.android.com/guide/components/fragments.html

Animated sprites using Awe6 game framework

I am looking for a way to have an animated character in my game. I would like to have a running animation loop when he is running, a jump animation when he jumps etc.
Does the awe6 framework provide anything like this? Maybe using spritesheets, or separate images for each frame.
If I have to use my own system, are there any popular libraries that can help do this, and that work well with awe6? And how would I use it with the framework?
awe6 is not something that works out of the box but rather an architecture for you to build on. It is not designed to fill your requirements without work from you and requires you to have at least a good understanding to integrate another framework/target runtime for what you want. They do have a wiki however you can start with http://code.google.com/p/awe6/wiki/QuickStart
There are many popular frameworks out there that have a lower barrier to entry, such as haxepunk.com, haxeflixel.com, https://github.com/aduros/flambe they all have their own strengths/weaknesses etc for you to decide on and can all easily complete your requests.

Is there a visual two-dimensional code editor?

Let me explain what I mean by "two-dimensional code editor": imagine of using Inkscape or Gimp in a big canvas (say infinite). The "T - add text" tool is used to write the code. Additionally, all function definitions will be framed and links will connect the called functions.
In other words: you have a very large sheet of (virtual) paper where you can write.
It would be really useful. I don't want to write code as a long list of lines, especially now that big monitors are cheaper.
Is such a code editor out there?
What's your opinion? Would you use a 2d code editor?
I've written 3 or 4 visual editors and my second one worked like this, that was for java and c++ (never published, though I did use it for some published research work)
I still don't like much to write my code 'as a long list of lines'. My point is, after trying a system like this, I tried a windowed system (class outlines in windows, right click to open code editors), then a tree based system...
in the long run (I wrote several apps using all of those), the tree based system with non overlapping windows felt at once most scalable (to different monitor sizes) and foremost, most productive, because dragging the text boxes and links and/or windows in the first version was necessary, without adding much to the programming experience, so it felt wasteful.
If you want to try some of this stuff out, you can google antegram for java (java only) antegram for web (javascript/php/actionscript) and ee-ide (on oogtech.org). I'm not sure if I could dig up the original c++/java textbox + links editor (which could collapse graphs as well, and had an infinite canvas, so pretty close to what you describe).
I'm not working on this as much as I used to as few programmers ever seemed to like it except me, but if you like working the tree way, or feel like adding stuff for your own purposes, ee-ide would be the way to go, as it's nicely modular and easy to extend compared to the rest.
On the commercial side, you can configure visual studio to work with UML-like diagrams. I have a feel it might be a little too heavy (although it's definitely more coding than UML oriented), but I'm not sure, I haven't really tried yet.
This probably doesn't answer your question exactly, but anyway.
Have a look at the NodeBox beta . It is a visual programming environment mostly for creating generative graphics. You can program and edit the nodes with python code, connect and reuse them in multiple ways. (Windows and Mac OS)
Also worth mentioning (in terms of concept) is Field . It is for programming performances and arranges bits of code on a stage/timeline. Very interesting but also very confusing. (Mac OS only)
Third one is vvvv. It is used a lot by graphical artists to create realtime 3d visuals. Node based. (Windows only)
NodeBox and Field are open-source, so if you are looking to create something yourself you can see how it's done there.
Check this out. I came across it today and remembered this question.
Code Bubbles
Developers spend significant time
reading and navigating code fragments
spread across multiple locations. The
file-based nature of contemporary IDEs
makes it prohibitively difficult to
create and maintain a simultaneous
view of such fragments. We propose a
novel user interface metaphor for code
understanding and maintanence based on
collections of lightweight, editable
fragments called bubbles, which form
concurrently visible working sets.
The essential goal of this project is
to make it easier for developers to
see many fragments of code (or other
information) at once without having to
navigate back and forth. Each of these
fragments is shown in a bubble.
A bubble is a fully editable and
interactive view of a fragment such as
a method or collection of member
variables. Bubbles, in contrast to
windows, have minimal border
decoration, avoid clipping their
contents by using automatic code
reflow and elision, and do not overlap
but instead push each other out of the
way. Bubbles exist in a large,
pannable 2-D virtual space where a
cluster of bubbles comprises a
concurrently visible working set.
Bubbles support a lightweight grouping
mechanism, and further support
connections between them.
A quantiative user study indicates
that Code Bubbles increased
performance significantly for two
controlled code understanding tasks. A
qualitative user study with 23
professional developers indicates
substantial interest and enthusiasm
for the approach, despite the radical
departure from what developers are
used to.
http://www.cs.brown.edu/people/acb/codebubbles_site.htm
At one point, LabView had a programming mode like this. You connected program blocks together in a graphical way.
It's been so long since I've used LabView that I don't know if it is still the same.
For me, the MVVM pattern means that there's no code behind the UI controls anyway. The logic is all in a class with properties.
The properties use WPF databinding to update the UI controls. For example, on the form or window, page, whatever, MySearchButton.IsEnabled is bound to ViewModel.MySearchButtonIsEnabled property. So the app logic runs in the ViewModel class and just sets its own properties and the UI updates automatically.
Although this is specific to MS WPF the pattern actually stems from SmallTalk and is found across the development field as MVP. Without WPF one would need to write the databinding or 'presenter' logic, which is common.
This means the UI can be torn off and a new one pasted-in really quickly and with little code knowledge from the UI guy - who, in an ideal world, is a crack creative guy that drives a 70s Citroen.
So my point is that, although it sounds like a neat innovation, a 2D editor like this would be assisting a coding style that is no longer considered optimal.

High speed WPF plotting control

I currently have a Win32 application (developed in C++ Builder/VCL) which I am redesigning from the ground up for WPF 4.
One of the core functions in the app is drawing engineering/scientific plots. I love the control I'm using now (iocomp Plot Pack - excellent product with phone support!), but they don't have a WPF version and don't seem interested in creating one. They do have ActiveX and WinForms versions available, but I'd rather stick with a pure WPF solution if possible.
The single most important plot feature for my app is speed. I currently plots up to a million points of double data at a time, and accomplishes this in a couple of seconds. As my app evolves the data sets will expand in size. Of course there are other features I need as well: multiple traces (channels), rubber band zooming, annotations, user definable filled areas and so forth.
Now on to my questions:
1) Is there a WPF control which will provide me the speed I'm looking for?
2) Will I be able to host the ActiveX (preferred as it's faster) or WinForms versions in a WPF window without sacrificing plot functionality such as interactivity?
3) If I must use an ActiveX or WinForm control, can this be done in such a way that the plot control looks 'right', as if it were a native part of the WPF control set rather than something we had to 'beat to fit and paint to match' as we used to say in the Navy.
4) Are there examples of using non-trivial ActiveX controls in WPF applications?
Thanks!
One of the ways to do this is to include a windows forms host in the WPF app to host the plot. More info can be found at
http://msdn.microsoft.com/en-us/library/ms751761.aspx
To the WindowFormsHost the plot control is to be added in the code behind (a good place is the windows load function).
Do note that the .Net framework for this should be set to .Net 4 and NOT .Net 4 (Client Profile).
Have you looked into a custom WPF control?
Have a look into WPF Control Template.
I am looking for exactly what you are looking for. I have a prototype application done in Labview and now migrating to WPF; and I have to live up to Labviews speed and flexibility of graph plots.
Have you had any luck finding anything that comes close to your needs? I looked into Telerik and DxCharts Infragistics... they tend to be more geared towards small data plots and are focused more on the ease of use than the performance side of things.
I guess our best hope might be to go for something like http://dynamicdatadisplay.codeplex.com/ and make it work for our situations. It is going to require some work though.

Resources