So, i have tossed around a few ideas, and would like to add animated emoticons to my chat app. Currently, in AutoIT, i use an HTML page to display those when a user clicks on a static image. That, obviously, isn't ideal.
Is there a way to display all of my animated GIF's (emoticons) either via an ImageList and still have them animated say inside of a listview? ComboBox?
What would be the best way to do emoticons inside of Windows Forms (displaying)?
I think you might want to turn to WPF rather than forms: How do I get an animated gif to work in WPF?
(following comments I am adding this link to the answer as well)
If you want to use WPF in a forms enviroment, use the ElementHost tag: http://msdn.microsoft.com/en-us/library/system.windows.forms.integration.elementhost%28v=VS.90%29.aspx?appId=Dev10IDEF1&l=EN-US&k=k%28SYSTEM.WINDOWS.FORMS.INTEGRATION.CHILDCHANGEDEVENTARGS%29;k%28TargetFrameworkMoniker-%22.NETFRAMEWORK&k=VERSION=V3.5%22%29;k%28DevLang-CSHARP%29&rd=true
Related
I am aware of app bar icons and menu items in Windows phone. What I want it is an app bar similar to phone's default windows phone store where it shows up "try", "buy" and share in menu item... How can I achieve this? I looked into documentation of ApplicationBar, but it didn't help.
I want normal buttons to be inside application bar.. If that is not possible in appbar how can I mock something similar to the one which shows up in windows phone store..
Not sure that it is possible
Though, you may try to take a look at some custom appbars. For example, Cimbalino appbar is made as behavior (so it supports binding) - probably, you'd be able to set button's style either.
Hy!
I create a WPF application. I have a Windows Form element. This control displays the WebCamera picture.
I put it in canvas, 'cause I have to show the recodring time, so I also put a textblock into the canvas. My problem is that, I've already done everything with the From control, for example I set the ZIndex etc., send back, but the WebCam image always the highest lay. I cant send it behind. This element is a System.Windows.Forms.Integration.WindowsFormsHost
Can anybody help me? I hope I could write my problem understandable.
That's not possible. WindowsFormHost is HwndHost, and according to MSDN
HwndHost will appear on top of other WPF elements in the same
top-level window. However, a ToolTip or ContextMenu generated menu is
a separate top-level window, and so will behave correctly with
HwndHost.
Consider following options:
adding overlay controls to WinForms control
placing your overlay WPF controls inside a Popup window (you'll have to handle that window location manually)
look for a WPF control alternative for your WinForms control (or implement your own)
I've created an WPF based application showing me thumbnails of external windows. As an example i pick up icq, firefox and some other windows, create thumbnails of these and render them onto my WPF based application.
That works fine already and looks like this:
http://img560.imageshack.us/img560/1170/oijoijio.jpg
(Just showing one thumbnail in here, but there will be multiple in future)
The WPF application will also contain some controls to actually select the windows being "thumbnailed" and a few others.
The next step and my actual question is about how i would redirect these content being rendered into a Bitmap instead of the "WPF window" itself.
Is there a way to accomblish that goal? All the windows content (WPF containers and the drawn thumbnails) need to be rendered into a bitmap which i can display in directx window being owned by a game.
I know that it is possible todo that somehow, as a programm called overwolf also uses WPF inside of their application. They actually install device inline detours to hook into the rendering process of the game, where they render their wpf content. I am not sure if they use some kind of bitmap they render in there, or if they directly render the wpf content onto the dx-surface somehow.
Other ideas besides the bitmap based style i plan to go for are welcome aswell!
Thanks for your reading until here, and another big hug for any answer :)
Any WPF Visual object can be rendered into a bitmap using RenderTargetBitmap.
suppose i have label and button on textbox and i want that if i resize my win form then my label and button size and position will change. i got the solution in wpf but i am working with win form apps. here i am giving the url from where you can see what kind of output i am looking form. the url is http://i.stack.imgur.com/QeoVK.png. please see the image and tell me how can i implement the same output in win form apps. please help me with code snippet in c#.thanks.
You should make yourself familiar with the Anchor and Dock properties of the controls. They are great tools for this kind of work.
Note though that they will alter the size of the controls only, they will not affect font size.
consider that window forms and WPF are very different, especially about the UI management and controls nesting / UI composition.
I have seen some articles describing what you are trying to do now in windows forms, long ego, it's something called control scaling if I recall well.
Use Anchor and Dock properties for simple stuff and SizeChanged event for more complicated stuff. UI positioning API is much more limited than WPF and you will probably have to do stuff like scaling manually.
best way to show several images on a winform in c#? Datagrid?
Several PictureBoxes :-)
Left a treeview with all the images and mainform the image large? It's kinda hard to guess what you want...
My company, Atalasoft, has several win forms controls that can be used for displaying images and thumbnails.
There is a typical example of using the thumbnail control here.
It depends on how many images you want to display, do you want thumbnails or full-resolution images?
I'm going to assume that since you asked for "images", you have many images to display. As such, you'll probably be wanting to use thumbnails on that form, with a different form if you want to display the full-resolution image.
In this case, you'll want to look at the ImageList object in conjunction with the ListView object.
I used this solution in an app recently. It worked out very well.
You can try using an ImageList and binding it to a ListView. You can set the ListView to Tile View state or any other states.