Advertisement

Results for "Author: option explicit"

7_2009-2012 #235986
MorphBorder v1.00 - Gradient Border UserControl AND Class

(Added MorphBorder *Class* 09 Mar 2006) MorphBorder is a simple usercontrol that allows you to frame other controls with an attractive gradient border. Just drop it on the form, and point it to any control (intrinsic or usercontrol) that has the following exposed properties: .hDC, ScaleMode, ScaleHeight, ScaleWidth, and AutoRedraw. Also contains a class that does the same thing. I recommend the class although they should both work fine. See demo project for usage particulars. As always, constructive feedback welcome, votes appreciated.

7_2009-2012 #235987
MorphDisplay v1.11 - LED / LCD Digital Display Control

(29 Apr 2007 - Minor tweaks; removed MatrixDisplay control for later repost) An ownerdrawn digital display usercontrol that uses shaped regions to form hexagonal, trapezoidal or rectangular LED/LCD digit segments. Control can be used for calculator displays, displaying time, or as a simple counter. Just about every conceivable aspect of this control can be customized via a multitude of properties. Main and exponent digits are separately configurable. Properties for segment height and width, intersegment gap, and interdigit gap allow you to size, position and space digits exactly the way you want. Support for thousands and decimal separators. Thousands and decimal separators can be defined as a comma or period so that international standards can be maintained. Thousands grouping can also be adjusted according to international preference. Background can be gradient or bitmap. Background bitmap can be tiled or stretched. All colors are also fully user-definable. Negative numbers can be displayed in a different color than positive. Digit segments can have a 3D gradient added to them if desired. Corners can be individually rounded for a different look. A simulated digit burn-in display mode is also available if desired. A Filament option allows digits to be displayed as wireframed, rather than solid. Exponent display can be disabled if you wish to use this as a simple counter. Six basic themes are included that show various display styles. Since there's ~40 properties that make up one theme, it is a very good idea to make a theme out of a combination of properties that works well in a particular application. Inspired by LaVolpe's "Shaped Regions" project at txtCodeId=58562. As always, constructive feedback is welcome, and votes are always appreciated.

7_2009-2012 #235988
MorphListBox 1.21 - Graphical Listbox UserControl

(Added .Sort method) A purely graphical replacement/enhancement for the VB single-column listbox control. Standard vertical listbox behavior is consistently emulated, with the exception of a couple intricacies of list item selection in .MultiSelect = Extended mode. Control features an integrated graphical vertical scrollbar. Custom .FindIndex and .MouseOverIndex methods. Background can be a gradient or bitmap. Small bitmaps can be tiled or stretched to fit the display area. Each listitem can have an associated icon displayed next to it. Eight gradient color schemes can be selected via the .Theme property. Unicode display supported. Drag and drop capability incorporated. Numeric list sorting option. .DisplayFrom method allows you to display any part of the list through code. .RightToLeft allows smooth, natural operation for those whose written language goes from right to left. Loads lists several times faster than traditional VB listbox, depending on your system. Due to size of control, this is best used as a compiled .OCX. As always, constructive feedback welcome, votes appreciated.

7_2009-2012 #235989
Pixel Code Generator

This small, almost totally useless project scans all the pixels in a bitmap stored in a picturebox and generates SetPixelV code to replicate that bitmap. Automatically generates For loop code if enough consecutive pixels are identical to exceed a FORLOOP_THRESHOLD value. Generated code is written to the clipboard for pasting into other projects. Why did I do something so useless, you ask? Well, as many of you know, my hobby at PSC is inflicting usercontrols on you. I prefer things like checkmarks for checkboxes drawn by code as opposed to being stored in imagelists or the like. I don't like dependencies of any kind in controls. So, I draw them using LineTo or SetPixelV. The problem is, I can't even draw a stick figure. I see these nice custom checkmarks in web sites and I couldn't replicate them, so I wrote this. As far as I know checkmarks aren't copyrighted, so hopefully this wouldn't be considered stealing! To use, just use your favorite screen grabber to grab the checkmark or whatever, then MS Paint or whatever to save just the area you want to disk. (You may want to edit colors, or resize, or some such.) Place this bitmap in Picture1 and run the program. Stop the program, and paste the newly generated code into the "Redraw" sub. Run again and click the button under Picture2. Voila! You can tweak the code to take out parts you don't want fairly easily. Only try this with SMALL (32x32 size or less) bitmaps. I tried with larger bitmaps and while the code generates properly, the code for even a smaller photgraph can easily exceed 10,000 lines. A VB procedure can't be larger than 64K. I included a small calculator icon example with the code already loaded into the Redraw routine to get you started. I wouldn't even use this for something the size of the calculator icon but did it just to give you the idea. I'm sure this could be optimized (especially the string concatenation) but it runs great on small bitmaps and I'm not going to endlessly tweak this. Let the flames begin :-)

7_2009-2012 #235990
MorphPicViewer v1.01 - Large Image Navigation Usercontrol

(24 Mar 2007 - Added .ColorAtCursor property) I've seen a lot of projects on PSC for scrolling large images and with the exception of Carles P.V.'s excellent submission at txtCodeId=30414, they all seem to involve slapping a couple of scrollbars on a VB PictureBox. Navigating large images by fumbling with scrollbars is very awkward, for me anyway. So just for fun (I have no use for this) I cooked up this little beastie. Its ClickNavigation feature provides a much faster [is 'instantly' fast enough for you? ;)], more natural way to navigate large images than anything I've seen so far on PSC. Features include: - Image display in either Normal or Stretched (display-to-fit) modes. - Aspect ratio may be optionally maintained in Stretched viewing mode. - Two image navigation modes are available for viewing large images - ClickNavigation and DragNavigation. ClickNavigation is a unique feature that displays entire image when the Ctrl key is held down, maintaining aspect ratio if mandated by the .KeepAspectRatio property. A rectangle outlines the portion of the image that's currently being displayed in Normal mode. Clicking on the image moves the rectangle, and when Normal view is reestablished by releasing Ctrl, the view is changed to the new coordinates. DragNavigation (which Carles features in his submission also) allows user to simply drag the image around in Normal mode until the desired area is in view. - Any portion of image can also be displayed via code using the .DisplayImage method, supplying the X and Y coordinates of the upper left hand corner of the image portion you wish to display. - Control can be used as a simple PictureBox replacement; image navigation can be disabled for straightforward image display (although image stretching and aspect ratio features are always available). Control is also a container as is the standard VB PictureBox. As always, constructive feedback is always welcome, and votes are always appreciated.

Languages
Top Categories
Global Discovery