[Mono-osx] [Mono-mac] Rulers Sample

Miguel de Icaza miguel at novell.com
Sun Nov 14 19:24:20 EST 2010


Hello Kenneth,

    Thanks for this sample!

     I have integrated it now into the build.   I strongly typed the
ModifierFlags, and also made some style changes to match the rest of the
MonoMac binding.

Miguel

On Sun, Nov 14, 2010 at 3:44 AM, kjpou1 <kjpou at pt.lu> wrote:

>
> Hello everyone
>
> Attached is another sample:
>
> http://mono.1490590.n4.nabble.com/file/n3041551/Rulers.zip Rulers.zip
>
> This one has a little more meat to it than the other two I posted:
>
> ScrollView with custom views
> Mouse Interaction and Dragging objects around
> Ruler Lines and views
> Custom ruler units.
> Autoscroll events
> Menu items:  Lock, Zoom In, Zoom Out and Nestle.
> Some graphics stuff as well to draw the rectangles
>
> Here is the diff to make it run:
>
> http://mono.1490590.n4.nabble.com/file/n3041551/nsruler.diff nsruler.diff
>
> Kenneth
>
>
>
> -------------------------------------
> Here is a summary of the diffs:
> -------------------------------------
>
> NSView
>
> Change case of ConvertXXXToYYYYY
> and ConvertXXXXFromYYYY
>
> NSScrollView
>
>         [Export ("hasVerticalRuler")]
>        bool HasVerticalRuler { get; set; }
>
>        [Export ("hasHorizontalRuler")]
>        bool HasHorizontalRuler { get; set; }
>
>        [Export ("rulersVisible")]
>        bool RulersVisible { get; set; }
>
>        [Export ("horizontalRulerView")]
>        NSRulerView HorizontalRulerView { get; set; }
>
>        [Export ("verticalRulerView")]
>        NSRulerView VerticalRulerView { get; set; }
>
> NSRulerView
>
>    add NullAllowed
>
>        [Export ("markers"), NullAllowed]
>        NSRulerMarker [] Markers { get; set; }
>
> NSColor
>
>   Added Static to black color so it could be referenced in programs.
>
>        [Static]
>        [Export ("blackColor")]
>        NSColor Black { get; }
>
>
> NSGraphics
>
>        [DllImport (Constants.AppKitLibrary, EntryPoint="NSRectClip")]
>        public extern static void RectClip (RectangleF rect);
>
>        [DllImport (Constants.AppKitLibrary, EntryPoint="NSFrameRect")]
>        public extern static void FrameRect (RectangleF rect);
>
>        [DllImport (Constants.AppKitLibrary,
> EntryPoint="NSFrameRectWithWidth")]
>        public extern static void FrameRectWithWidth (RectangleF rect, float
> frameWidth);
>
>
> --
> View this message in context:
> http://mono.1490590.n4.nabble.com/Mono-mac-Rulers-Sample-tp3041551p3041551.html
> Sent from the Mono - OSX mailing list archive at Nabble.com.
> _______________________________________________
> Mono-osx mailing list
> Mono-osx at lists.ximian.com
> http://lists.ximian.com/mailman/listinfo/mono-osx
>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://lists.ximian.com/pipermail/mono-osx/attachments/20101114/1245c852/attachment.html 


More information about the Mono-osx mailing list