Questions tagged [xamarin.mac]

Xamarin.Mac is an open source library for building Cocoa applications on OSX using C# and .NET. It is based on top of the Mono framework.

Xamarin.Mac: an open source library for building Cocoa applications on OSX using C# and .NET.

You can dig into the source code and read the documentation.

584 questions
3
votes
1 answer

(How to) Copying text from an to Clipboard using NSMenuItem

I've a question about an C# application for MacOS. I have the following code (in the MainClass): NSMenuItem copyMenuItem = new NSMenuItem(title: "Copy", charCode: "c", handler: delegate { //Has to be code }); And in the page.xaml I have…
3
votes
2 answers

translate CGContext generating image method from ios to mac

Is anyone able to help me translate this method in ios to mac version? Code is written in C# in Xamarin public static UIImage GetImageFromColor(UIColor color, float borderWidth = 1.0f) { var rect = new CGRect(0.0f, 0.0f, borderWidth,…
Xiangyu
  • 37
  • 6
3
votes
1 answer

Xamarin custom controls, how do I add properties to display in the Xcode panel?

I want to implement custom controls, but the official case is too limited, I can not know more. What I want to know now is that I want to add an attribute to my control, such as Title, which must be free to fill in the Xcode control properties…
Simon
  • 438
  • 4
  • 14
3
votes
1 answer

Xamarin Macintosh Customer URL protocol handle passed parameter

I've written a Macintosh app that handles a custom protocol: CFBundleURLTypes CFBundleURLName My Cool Handler CFBundleURLSchemes
Chris
  • 650
  • 7
  • 20
3
votes
1 answer

DotNetZip Exception after Upgrading to Mono 4.8 (FileNotFoundException: I18N)

I just upgraded my Xamarin to the latest that includes the new Mono 4.8. My projects are all set to Xamarin .NET 4.5.2. I have been using Ionic DotnetZip library in this project. I am building for OSX. I checked out my code on a mac that has not…
user856232
  • 1,073
  • 2
  • 14
  • 40
3
votes
2 answers

BeginSheet doesn't show window

I have simple code : var openPanel = NSOpenPanel(); openPanel.beginSheet(this.View.Window, (obj) => { //do stuff openPanel.endSheet(this.View.Window); }); Sometime the sheet window is not shown and makes a sound like the window is busy. Is…
Nininea
  • 2,671
  • 6
  • 31
  • 57
3
votes
1 answer

Block mouse bubble in Xamarin Mac

I have created a custom NSView that i would like to place over the top of the content of a window to block any interaction while all the content is loading. The problem i was having is that i could click through the NSView to the controls below…
bizzehdee
  • 20,289
  • 11
  • 46
  • 76
3
votes
1 answer

Allow only Numbers for NsTextField input in xamarin.mac

I want to place a text field that only accepts numbers (0-9). How do I restrict a NSTextfield to allow only numbers/integers?
3
votes
0 answers

Xamarin SOAP Web Service

I created a Portable Library Project in Xamarin. I want to add web service but the framework area is closed. What is the reason for this? Is there anyone who has experienced the same problem ? Exp Url :…
3
votes
0 answers

Print PDF functionality Not worked on Latest MAC using Xamarin MAC application

We have a Print PDF document functionality in our Xamarin MAC application. Previously the print function was worked well with old MAC OS and right now we have tried to print the PDF document from the new MAC OS “Sierra” and found that it is not…
Roshil K
  • 2,583
  • 28
  • 38
3
votes
1 answer

How to show shadow or any glow effect for SKSpriteNode when it moved on screen only?

I want to show any effects or animations for my SKSpriteNode when it was dragging on screen. I gone through many sites but i didn't find relevant answer for my question.I have little bit knowledge on SKSpriteNode. Can any one guide me to solve this…
Mounika
  • 412
  • 2
  • 20
3
votes
0 answers

munmap() doesn't return pages to system on macOS Sierra

I have an application which operates with memory a lot. This app written in c# - it has mono runtime under the hood. We identfied that on Sierra the app memory constantly grows when it does consuming memory operations. Same time the issue is not…
Igor B.
  • 2,219
  • 13
  • 17
3
votes
1 answer

Xamarin studio update causing android application to crash

With a recent update of xamarin (installed xamarin android N sdk, xamarin studio 6.1 etc) my android app is crashing when the device is disconnected from the debugger. It works well when the debugger is connected to a device. I have tried with Nexus…
Makarand
  • 31
  • 3
3
votes
3 answers

Importing native methods in Xamarin.Mac

I'm looking for a way to use SCNetworkInterfaceCopyAll in my Xamarin.Mac app. I've imported it [DllImport("/System/Library/Frameworks/SystemConfiguration.framework/SystemConfiguration")] public static extern IntPtr SCNetworkInterfaceCopyAll(); Then…
Artur Shamsutdinov
  • 3,127
  • 3
  • 21
  • 39
3
votes
0 answers

Xamarin Mac Outlets null when loading custom NSTableView Cells or Views

I'm having trouble getting custom NSTableView Cells/Views in my Xamarin Mac project to work. The cells are rendered but their outlets are always null, even after AwakeFromNib. I have tried the following: NSTableCellView in Table View XIB NSView in…
tamagotchi
  • 117
  • 6