CS411 Midterm Short Notes and Question and Answers
CS411 Midterm Short Notes and Question and Answers
CS411 Midterm Short Notes and Question and Answers
<1>
<StakPanelstackpanel = new StakePanel>
button.widh = 50;</StakPanelstackpanel = new StakePanel>
</1>
<2>
<StakPanelstackpanel = new StakePanel>
button.Hight = 70
</StakPanelstackpanel = new StakePanel>
</2>
<3>
<StakPanelstackpanel = new StakePanel>
button.HOrizontelAlligenemtn = right;
</StakPanelstackpanel = new StakePanel>
</3>
<4>
<StakPanelstackpanel = new StakePanel>
stakepanel.child.add(button);
</StakPanelstackpanel = new StakePanel>
</4>
</root>
20 Name the Properties Supported by Scale Transform, write their default values?
WPF is not designed for any significant game programming, other than, say, a simple card
came.
DirectX is designed with the intention of allowing you to create a 3D user interface into
your game.
33 When two or more independent grids need to be synchronized, then how can we
synchronize them?
Ans. Sharedsizegroup is used to synchronized when they are docked.
34 What is the biggest feature of dependency property?
Ans. Its built-in ability to provide change notification.
35 What is the purpose of using xaml extensions?
Ans. To extend the expressiveness of XAML.
36 WPF combines the best attribute of some systems. write the names of three?
Ans. WPF aims to combine the best attributes of systems such as:
- DirectX (3D and hardware acceleration),
- Windows Forms (developer productivity),
- Adobe Flash (powerful animation support)
- HTML (declarative markup)
37 What is the purpose of WPF 2D transform classes?
Ans. To rotate, scale, move (translate), and skew FrameworkElement objects.
38 For which class WPF are derived?
Ans. using System.Windows;
39 Why C# let us Develop devices resulation independent graphics?
Ans. C# enable us to develop device independent graphics so that same application/ GUI have
same aspect ratio and appearance on all kind of displays. e.g. Windows phone, Windows PC
etc.
40 Which term is used to refer to an object that derives from "UIElement" or
"FrameworkElement"?
Ans. Uielement is the base class for all 2D visual objects. System.Windows.UIElement
Frameworkelement is the base class that adds support for styles, data binding, resources etc.
System.Windows.FrameworkElement
41 Name the three routed strategies?
Tunneling—The event is first raised on the root, then on each element down the tree
Ans. until the source element is reached (or until event is marked as handled).
Bubbling—The event is first raised on the source element, then on each element up the
tree until the root is reached (or until the event is marked as handled).
Direct—The event is only raised on the source element. Only source element is given
the chance to invoke handlers in response.
43 Why "Grid" panel is the best choice for most complex layout scenarios?
Ans. The grid is a layout panel that arranges its child controls in a tabular structure of rows and
columns. Its functionality is similar to the HTML table but more flexible. A cell can contain
multiple controls, they can span over multiple cells and even overlap themselves.
44 Why C# let us Develop devices resolution independent graphics?
Ans. Fortunately for us, C# makes it very easy. The File class, from the Syste.IO namespace
comes with pretty much everything we could possibly want, making it very easy to do simple
reading and writing of a file.
File.ReadAllText
File.WriteAllText Also AppendAllText
45 What happens when an event is moved up?
Ans. It's actually called bubbling in routed events.
Bubbling—The event is first raised on the source element, then on each element up the tree
until the root is reached (or until the event is marked as handled).
46 Why events are used in pairs? explain with example?
Ans. In VPL, a program is created by assembling pairs of one event and one or more action blocks.
For example, a pair composed of a button event and a motors action tells the robot to move
when a button is touched on the robot.
Little Research is Required at Your End as Some of the Answers are Not Absolutely Perfect