diff --git a/Samples/Sample.Android/Sample.Android.csproj b/Samples/Sample.Android/Sample.Android.csproj
index b0c9c7d8b..f49a95f30 100644
--- a/Samples/Sample.Android/Sample.Android.csproj
+++ b/Samples/Sample.Android/Sample.Android.csproj
@@ -93,8 +93,8 @@
1.3.0.4
-
- 1.6.0
+
+ 1.6.0--date20220814-0324.git-7f6e466
\ No newline at end of file
diff --git a/Samples/Sample.Forms/Sample.Forms.Android/Sample.Forms.Android.csproj b/Samples/Sample.Forms/Sample.Forms.Android/Sample.Forms.Android.csproj
index dcacc25c9..2f64f9406 100644
--- a/Samples/Sample.Forms/Sample.Forms.Android/Sample.Forms.Android.csproj
+++ b/Samples/Sample.Forms/Sample.Forms.Android/Sample.Forms.Android.csproj
@@ -57,8 +57,8 @@
-
-
+
+
diff --git a/Samples/Sample.Forms/Sample.Forms.Tizen/Sample.Forms.Tizen.csproj b/Samples/Sample.Forms/Sample.Forms.Tizen/Sample.Forms.Tizen.csproj
index 096c1beef..f014e56cb 100644
--- a/Samples/Sample.Forms/Sample.Forms.Tizen/Sample.Forms.Tizen.csproj
+++ b/Samples/Sample.Forms/Sample.Forms.Tizen/Sample.Forms.Tizen.csproj
@@ -26,7 +26,7 @@
Runtime
-
+
diff --git a/Samples/Sample.Forms/Sample.Forms.UWP/Sample.Forms.UWP.csproj b/Samples/Sample.Forms/Sample.Forms.UWP/Sample.Forms.UWP.csproj
index b2d104021..e721916e5 100644
--- a/Samples/Sample.Forms/Sample.Forms.UWP/Sample.Forms.UWP.csproj
+++ b/Samples/Sample.Forms/Sample.Forms.UWP/Sample.Forms.UWP.csproj
@@ -143,9 +143,9 @@
-
+
-
+
diff --git a/Samples/Sample.Forms/Sample.Forms.iOS/Sample.Forms.iOS.csproj b/Samples/Sample.Forms/Sample.Forms.iOS/Sample.Forms.iOS.csproj
index a574c9e5f..a01d25a2c 100644
--- a/Samples/Sample.Forms/Sample.Forms.iOS/Sample.Forms.iOS.csproj
+++ b/Samples/Sample.Forms/Sample.Forms.iOS/Sample.Forms.iOS.csproj
@@ -126,8 +126,8 @@
-
-
+
+
diff --git a/Samples/Sample.Forms/Sample.Forms/Sample.Forms.csproj b/Samples/Sample.Forms/Sample.Forms/Sample.Forms.csproj
index 8eaf1848a..f1908af59 100644
--- a/Samples/Sample.Forms/Sample.Forms/Sample.Forms.csproj
+++ b/Samples/Sample.Forms/Sample.Forms/Sample.Forms.csproj
@@ -11,8 +11,8 @@
-
-
+
+
diff --git a/Samples/Sample.Uwp/Sample.Uwp.csproj b/Samples/Sample.Uwp/Sample.Uwp.csproj
index e72e127c4..6fa8261f3 100644
--- a/Samples/Sample.Uwp/Sample.Uwp.csproj
+++ b/Samples/Sample.Uwp/Sample.Uwp.csproj
@@ -160,8 +160,8 @@
6.2.11
-
- 1.6.0
+
+ 1.6.0--date20220814-0324.git-7f6e466
diff --git a/Samples/Sample.iOS/Sample.iOS.csproj b/Samples/Sample.iOS/Sample.iOS.csproj
index 067d3945a..80f0837f8 100644
--- a/Samples/Sample.iOS/Sample.iOS.csproj
+++ b/Samples/Sample.iOS/Sample.iOS.csproj
@@ -103,8 +103,8 @@
-
- 1.6.0
+
+ 1.6.0--date20220814-0324.git-7f6e466
diff --git a/ZXing.Net.Mobile.Forms/Platform.gtk.cs b/ZXing.Net.Mobile.Forms/Platform.gtk.cs
new file mode 100644
index 000000000..30e15dbb0
--- /dev/null
+++ b/ZXing.Net.Mobile.Forms/Platform.gtk.cs
@@ -0,0 +1,12 @@
+using System;
+
+namespace ZXing.Net.Mobile.Forms.GTK
+{
+ public class Platform
+ {
+ public static void Init ()
+ {
+ ZXing.Net.Mobile.Forms.GTK.ZXingBarcodeImageViewRenderer.Init();
+ }
+ }
+}
\ No newline at end of file
diff --git a/ZXing.Net.Mobile.Forms/ZXing.Net.Mobile.Forms.csproj b/ZXing.Net.Mobile.Forms/ZXing.Net.Mobile.Forms.csproj
index 4dc57699e..c8288ef10 100644
--- a/ZXing.Net.Mobile.Forms/ZXing.Net.Mobile.Forms.csproj
+++ b/ZXing.Net.Mobile.Forms/ZXing.Net.Mobile.Forms.csproj
@@ -1,6 +1,6 @@
- netstandard2.0;Xamarin.iOS10;Xamarin.Mac20;MonoAndroid10.0;tizen40
+ netstandard2.0;Xamarin.iOS10;Xamarin.Mac20;MonoAndroid10.0;tizen40;net461
$(TargetFrameworks);uap10.0.16299;
ZXing.Net.Mobile.Forms
ZXing.Net.Mobile.Forms
@@ -69,7 +69,7 @@
-
+
@@ -86,9 +86,23 @@
+
+
+
+ ..\ZXing.Net.Mobile\GTK\Libs\gtk-sharp\gtk-sharp-2.0\glib-sharp.dll
+
+
+ ..\ZXing.Net.Mobile\GTK\Libs\gtk-sharp\gtk-sharp-2.0\gtk-sharp.dll
+
+
+ ..\ZXing.Net.Mobile\GTK\Libs\gtk-sharp\gtk-sharp-2.0\gdk-sharp.dll
+
+
+
+
-
-
+
+
diff --git a/ZXing.Net.Mobile.Forms/ZXingBarcodeImageViewRenderer.gtk.cs b/ZXing.Net.Mobile.Forms/ZXingBarcodeImageViewRenderer.gtk.cs
new file mode 100644
index 000000000..e4482f232
--- /dev/null
+++ b/ZXing.Net.Mobile.Forms/ZXingBarcodeImageViewRenderer.gtk.cs
@@ -0,0 +1,73 @@
+using System;
+using System.ComponentModel;
+using Xamarin.Forms;
+using Xamarin.Forms.Platform.GTK;
+using ZXing.Net.Mobile.Forms;
+using ZXing.Net.Mobile.Forms.GTK;
+using ZXing.Net.Mobile.GTK;
+using Image = Gtk.Image;
+
+[assembly:ExportRenderer(typeof(ZXingBarcodeImageView), typeof(ZXingBarcodeImageViewRenderer))]
+namespace ZXing.Net.Mobile.Forms.GTK
+{
+ public class ZXingBarcodeImageViewRenderer : ViewRenderer
+ {
+ public static void Init()
+ {
+ var temp = DateTime.Now;
+ }
+
+ ZXingBarcodeImageView formsView;
+ Image gtkImage;
+
+ protected override void OnElementPropertyChanged(object sender, PropertyChangedEventArgs e)
+ {
+ // in GTK there are a way to many properties that are changed compared to other platforms
+ if (e.PropertyName == ZXingBarcodeImageView.BarcodeValueProperty.PropertyName ||
+ e.PropertyName == ZXingBarcodeImageView.BarcodeFormatProperty.PropertyName ||
+ e.PropertyName == ZXingBarcodeImageView.BarcodeOptionsProperty.PropertyName)
+ {
+ Regenerate();
+ }
+
+ base.OnElementPropertyChanged(sender, e);
+ }
+
+ protected override void OnElementChanged(ElementChangedEventArgs e)
+ {
+ formsView = Element;
+
+ if (gtkImage == null)
+ {
+ gtkImage = new Image();
+
+ base.SetNativeControl(gtkImage);
+ }
+
+ Regenerate();
+
+ base.OnElementChanged(e);
+ }
+
+ void Regenerate ()
+ {
+ if (formsView != null && formsView.BarcodeValue != null)
+ {
+ var writer = new ZXing.Net.Mobile.GTK.BarcodeWriter();
+
+ if (formsView != null && formsView.BarcodeOptions != null)
+ writer.Options = formsView.BarcodeOptions;
+ if (formsView != null && formsView.BarcodeFormat != null)
+ writer.Format = formsView.BarcodeFormat;
+
+ var value = formsView != null ? formsView.BarcodeValue : string.Empty;
+
+ Device.BeginInvokeOnMainThread(() =>
+ {
+ var pixBuf = writer.Write(value);
+ gtkImage.Pixbuf = pixBuf;
+ });
+ }
+ }
+ }
+}
diff --git a/ZXing.Net.Mobile/GTK/BarcodeWriter.gtk.cs b/ZXing.Net.Mobile/GTK/BarcodeWriter.gtk.cs
new file mode 100644
index 000000000..d5c7100d8
--- /dev/null
+++ b/ZXing.Net.Mobile/GTK/BarcodeWriter.gtk.cs
@@ -0,0 +1,13 @@
+using Gdk;
+
+namespace ZXing.Net.Mobile.GTK
+{
+ public class BarcodeWriter : BarcodeWriter, IBarcodeWriter
+ {
+ public BarcodeWriter()
+ {
+ Renderer = new BitmapRenderer();
+ }
+ }
+}
+
diff --git a/ZXing.Net.Mobile/GTK/BitmapRenderer.gtk.cs b/ZXing.Net.Mobile/GTK/BitmapRenderer.gtk.cs
new file mode 100644
index 000000000..928e53bf0
--- /dev/null
+++ b/ZXing.Net.Mobile/GTK/BitmapRenderer.gtk.cs
@@ -0,0 +1,52 @@
+using Cairo;
+using Gdk;
+using ZXing.Common;
+using ZXing.Rendering;
+
+namespace ZXing.Net.Mobile.GTK
+{
+ public class BitmapRenderer : IBarcodeRenderer
+ {
+ public Pixbuf Render(BitMatrix matrix, BarcodeFormat format, string content)
+ {
+ var black = new Cairo.Color(0, 0, 0);
+ var white = new Cairo.Color(1, 1, 1);
+ using (var surface = new ImageSurface(Format.RGB24, matrix.Width, matrix.Height))
+ {
+ using (var cr = new Context(surface))
+ {
+ for (var x = 0; x < matrix.Width; x++)
+ {
+ for (var y = 0; y < matrix.Height; y++)
+ {
+ SetSourceColor(cr, matrix[x, y] ? black : white);
+ cr.MoveTo(x, y);
+ cr.LineTo(x + 1, y);
+ cr.Stroke();
+ }
+ }
+
+ const int onlyBitsPerSampleValueSupportedByGdk = 8;
+ return new Pixbuf(surface.Data,
+ Colorspace.Rgb,
+ true,
+ onlyBitsPerSampleValueSupportedByGdk,
+ matrix.Width,
+ matrix.Height,
+ surface.Stride);
+ }
+ }
+ }
+
+ private void SetSourceColor(Context context, Cairo.Color color)
+ {
+ context.SetSourceRGB(color.R, color.G, color.B);
+ }
+
+ public Pixbuf Render(BitMatrix matrix, BarcodeFormat format, string content, EncodingOptions options)
+ {
+ return Render(matrix, format, content);
+ }
+ }
+}
+
diff --git a/ZXing.Net.Mobile/GTK/Libs/OpenTK/OpenTK.dll b/ZXing.Net.Mobile/GTK/Libs/OpenTK/OpenTK.dll
new file mode 100755
index 000000000..74955bafb
Binary files /dev/null and b/ZXing.Net.Mobile/GTK/Libs/OpenTK/OpenTK.dll differ
diff --git a/ZXing.Net.Mobile/GTK/Libs/OpenTK/OpenTK.dll.config b/ZXing.Net.Mobile/GTK/Libs/OpenTK/OpenTK.dll.config
new file mode 100755
index 000000000..7098d39e9
--- /dev/null
+++ b/ZXing.Net.Mobile/GTK/Libs/OpenTK/OpenTK.dll.config
@@ -0,0 +1,25 @@
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
diff --git a/ZXing.Net.Mobile/GTK/Libs/OpenTK/README.txt b/ZXing.Net.Mobile/GTK/Libs/OpenTK/README.txt
new file mode 100755
index 000000000..6ff2316b4
--- /dev/null
+++ b/ZXing.Net.Mobile/GTK/Libs/OpenTK/README.txt
@@ -0,0 +1 @@
+https://github.com/opentk/opentk
\ No newline at end of file
diff --git a/ZXing.Net.Mobile/GTK/Libs/gtk-sharp/Mono.Cairo/Mono.Cairo.dll b/ZXing.Net.Mobile/GTK/Libs/gtk-sharp/Mono.Cairo/Mono.Cairo.dll
new file mode 100755
index 000000000..924785a5e
Binary files /dev/null and b/ZXing.Net.Mobile/GTK/Libs/gtk-sharp/Mono.Cairo/Mono.Cairo.dll differ
diff --git a/ZXing.Net.Mobile/GTK/Libs/gtk-sharp/Mono.Posix/Mono.Posix.dll b/ZXing.Net.Mobile/GTK/Libs/gtk-sharp/Mono.Posix/Mono.Posix.dll
new file mode 100755
index 000000000..83fff4608
Binary files /dev/null and b/ZXing.Net.Mobile/GTK/Libs/gtk-sharp/Mono.Posix/Mono.Posix.dll differ
diff --git a/ZXing.Net.Mobile/GTK/Libs/gtk-sharp/README.txt b/ZXing.Net.Mobile/GTK/Libs/gtk-sharp/README.txt
new file mode 100755
index 000000000..b49a3bc47
--- /dev/null
+++ b/ZXing.Net.Mobile/GTK/Libs/gtk-sharp/README.txt
@@ -0,0 +1 @@
+https://github.com/mono/gtk-sharp
\ No newline at end of file
diff --git a/ZXing.Net.Mobile/GTK/Libs/gtk-sharp/gtk-sharp-2.0/atk-sharp.dll b/ZXing.Net.Mobile/GTK/Libs/gtk-sharp/gtk-sharp-2.0/atk-sharp.dll
new file mode 100755
index 000000000..9f3ac86b6
Binary files /dev/null and b/ZXing.Net.Mobile/GTK/Libs/gtk-sharp/gtk-sharp-2.0/atk-sharp.dll differ
diff --git a/ZXing.Net.Mobile/GTK/Libs/gtk-sharp/gtk-sharp-2.0/atk-sharp.dll.config b/ZXing.Net.Mobile/GTK/Libs/gtk-sharp/gtk-sharp-2.0/atk-sharp.dll.config
new file mode 100644
index 000000000..f6d925fa8
--- /dev/null
+++ b/ZXing.Net.Mobile/GTK/Libs/gtk-sharp/gtk-sharp-2.0/atk-sharp.dll.config
@@ -0,0 +1,4 @@
+
+
+
+
diff --git a/ZXing.Net.Mobile/GTK/Libs/gtk-sharp/gtk-sharp-2.0/atk-sharp.pdb b/ZXing.Net.Mobile/GTK/Libs/gtk-sharp/gtk-sharp-2.0/atk-sharp.pdb
new file mode 100755
index 000000000..c2bce621f
Binary files /dev/null and b/ZXing.Net.Mobile/GTK/Libs/gtk-sharp/gtk-sharp-2.0/atk-sharp.pdb differ
diff --git a/ZXing.Net.Mobile/GTK/Libs/gtk-sharp/gtk-sharp-2.0/gdk-sharp.dll b/ZXing.Net.Mobile/GTK/Libs/gtk-sharp/gtk-sharp-2.0/gdk-sharp.dll
new file mode 100755
index 000000000..5c799afa2
Binary files /dev/null and b/ZXing.Net.Mobile/GTK/Libs/gtk-sharp/gtk-sharp-2.0/gdk-sharp.dll differ
diff --git a/ZXing.Net.Mobile/GTK/Libs/gtk-sharp/gtk-sharp-2.0/gdk-sharp.dll.config b/ZXing.Net.Mobile/GTK/Libs/gtk-sharp/gtk-sharp-2.0/gdk-sharp.dll.config
new file mode 100644
index 000000000..8c16b10dd
--- /dev/null
+++ b/ZXing.Net.Mobile/GTK/Libs/gtk-sharp/gtk-sharp-2.0/gdk-sharp.dll.config
@@ -0,0 +1,6 @@
+
+
+
+
+
+
diff --git a/ZXing.Net.Mobile/GTK/Libs/gtk-sharp/gtk-sharp-2.0/gdk-sharp.pdb b/ZXing.Net.Mobile/GTK/Libs/gtk-sharp/gtk-sharp-2.0/gdk-sharp.pdb
new file mode 100755
index 000000000..813ff10ef
Binary files /dev/null and b/ZXing.Net.Mobile/GTK/Libs/gtk-sharp/gtk-sharp-2.0/gdk-sharp.pdb differ
diff --git a/ZXing.Net.Mobile/GTK/Libs/gtk-sharp/gtk-sharp-2.0/glade-sharp.dll b/ZXing.Net.Mobile/GTK/Libs/gtk-sharp/gtk-sharp-2.0/glade-sharp.dll
new file mode 100755
index 000000000..58248a0ea
Binary files /dev/null and b/ZXing.Net.Mobile/GTK/Libs/gtk-sharp/gtk-sharp-2.0/glade-sharp.dll differ
diff --git a/ZXing.Net.Mobile/GTK/Libs/gtk-sharp/gtk-sharp-2.0/glade-sharp.dll.config b/ZXing.Net.Mobile/GTK/Libs/gtk-sharp/gtk-sharp-2.0/glade-sharp.dll.config
new file mode 100644
index 000000000..27ab53d2a
--- /dev/null
+++ b/ZXing.Net.Mobile/GTK/Libs/gtk-sharp/gtk-sharp-2.0/glade-sharp.dll.config
@@ -0,0 +1,3 @@
+
+
+
diff --git a/ZXing.Net.Mobile/GTK/Libs/gtk-sharp/gtk-sharp-2.0/glade-sharp.pdb b/ZXing.Net.Mobile/GTK/Libs/gtk-sharp/gtk-sharp-2.0/glade-sharp.pdb
new file mode 100755
index 000000000..3329a768a
Binary files /dev/null and b/ZXing.Net.Mobile/GTK/Libs/gtk-sharp/gtk-sharp-2.0/glade-sharp.pdb differ
diff --git a/ZXing.Net.Mobile/GTK/Libs/gtk-sharp/gtk-sharp-2.0/glib-sharp.dll b/ZXing.Net.Mobile/GTK/Libs/gtk-sharp/gtk-sharp-2.0/glib-sharp.dll
new file mode 100755
index 000000000..0c5171b90
Binary files /dev/null and b/ZXing.Net.Mobile/GTK/Libs/gtk-sharp/gtk-sharp-2.0/glib-sharp.dll differ
diff --git a/ZXing.Net.Mobile/GTK/Libs/gtk-sharp/gtk-sharp-2.0/glib-sharp.dll.config b/ZXing.Net.Mobile/GTK/Libs/gtk-sharp/gtk-sharp-2.0/glib-sharp.dll.config
new file mode 100644
index 000000000..0af11ac99
--- /dev/null
+++ b/ZXing.Net.Mobile/GTK/Libs/gtk-sharp/gtk-sharp-2.0/glib-sharp.dll.config
@@ -0,0 +1,5 @@
+
+
+
+
+
diff --git a/ZXing.Net.Mobile/GTK/Libs/gtk-sharp/gtk-sharp-2.0/glib-sharp.pdb b/ZXing.Net.Mobile/GTK/Libs/gtk-sharp/gtk-sharp-2.0/glib-sharp.pdb
new file mode 100755
index 000000000..e21bdee54
Binary files /dev/null and b/ZXing.Net.Mobile/GTK/Libs/gtk-sharp/gtk-sharp-2.0/glib-sharp.pdb differ
diff --git a/ZXing.Net.Mobile/GTK/Libs/gtk-sharp/gtk-sharp-2.0/gtk-dotnet.dll b/ZXing.Net.Mobile/GTK/Libs/gtk-sharp/gtk-sharp-2.0/gtk-dotnet.dll
new file mode 100755
index 000000000..5fe8fd462
Binary files /dev/null and b/ZXing.Net.Mobile/GTK/Libs/gtk-sharp/gtk-sharp-2.0/gtk-dotnet.dll differ
diff --git a/ZXing.Net.Mobile/GTK/Libs/gtk-sharp/gtk-sharp-2.0/gtk-dotnet.dll.config b/ZXing.Net.Mobile/GTK/Libs/gtk-sharp/gtk-sharp-2.0/gtk-dotnet.dll.config
new file mode 100644
index 000000000..ee8038e57
--- /dev/null
+++ b/ZXing.Net.Mobile/GTK/Libs/gtk-sharp/gtk-sharp-2.0/gtk-dotnet.dll.config
@@ -0,0 +1,3 @@
+
+
+
diff --git a/ZXing.Net.Mobile/GTK/Libs/gtk-sharp/gtk-sharp-2.0/gtk-dotnet.pdb b/ZXing.Net.Mobile/GTK/Libs/gtk-sharp/gtk-sharp-2.0/gtk-dotnet.pdb
new file mode 100755
index 000000000..849fc794a
Binary files /dev/null and b/ZXing.Net.Mobile/GTK/Libs/gtk-sharp/gtk-sharp-2.0/gtk-dotnet.pdb differ
diff --git a/ZXing.Net.Mobile/GTK/Libs/gtk-sharp/gtk-sharp-2.0/gtk-sharp.dll b/ZXing.Net.Mobile/GTK/Libs/gtk-sharp/gtk-sharp-2.0/gtk-sharp.dll
new file mode 100755
index 000000000..09ebb10e5
Binary files /dev/null and b/ZXing.Net.Mobile/GTK/Libs/gtk-sharp/gtk-sharp-2.0/gtk-sharp.dll differ
diff --git a/ZXing.Net.Mobile/GTK/Libs/gtk-sharp/gtk-sharp-2.0/gtk-sharp.dll.config b/ZXing.Net.Mobile/GTK/Libs/gtk-sharp/gtk-sharp-2.0/gtk-sharp.dll.config
new file mode 100644
index 000000000..7468e04bf
--- /dev/null
+++ b/ZXing.Net.Mobile/GTK/Libs/gtk-sharp/gtk-sharp-2.0/gtk-sharp.dll.config
@@ -0,0 +1,7 @@
+
+
+
+
+
+
+
diff --git a/ZXing.Net.Mobile/GTK/Libs/gtk-sharp/gtk-sharp-2.0/pango-sharp.dll b/ZXing.Net.Mobile/GTK/Libs/gtk-sharp/gtk-sharp-2.0/pango-sharp.dll
new file mode 100755
index 000000000..5fc3867e7
Binary files /dev/null and b/ZXing.Net.Mobile/GTK/Libs/gtk-sharp/gtk-sharp-2.0/pango-sharp.dll differ
diff --git a/ZXing.Net.Mobile/GTK/Libs/gtk-sharp/gtk-sharp-2.0/pango-sharp.dll.config b/ZXing.Net.Mobile/GTK/Libs/gtk-sharp/gtk-sharp-2.0/pango-sharp.dll.config
new file mode 100644
index 000000000..81777bc8a
--- /dev/null
+++ b/ZXing.Net.Mobile/GTK/Libs/gtk-sharp/gtk-sharp-2.0/pango-sharp.dll.config
@@ -0,0 +1,6 @@
+
+
+
+
+
+
diff --git a/ZXing.Net.Mobile/GTK/Libs/gtk-sharp/gtk-sharp-2.0/pango-sharp.pdb b/ZXing.Net.Mobile/GTK/Libs/gtk-sharp/gtk-sharp-2.0/pango-sharp.pdb
new file mode 100755
index 000000000..524a7e2f2
Binary files /dev/null and b/ZXing.Net.Mobile/GTK/Libs/gtk-sharp/gtk-sharp-2.0/pango-sharp.pdb differ
diff --git a/ZXing.Net.Mobile/GTK/Libs/webkit-sharp/README.txt b/ZXing.Net.Mobile/GTK/Libs/webkit-sharp/README.txt
new file mode 100755
index 000000000..dc5848e2e
--- /dev/null
+++ b/ZXing.Net.Mobile/GTK/Libs/webkit-sharp/README.txt
@@ -0,0 +1 @@
+https://github.com/mono/webkit-sharp
\ No newline at end of file
diff --git a/ZXing.Net.Mobile/GTK/Libs/webkit-sharp/webkit-sharp.dll b/ZXing.Net.Mobile/GTK/Libs/webkit-sharp/webkit-sharp.dll
new file mode 100755
index 000000000..46646ba82
Binary files /dev/null and b/ZXing.Net.Mobile/GTK/Libs/webkit-sharp/webkit-sharp.dll differ
diff --git a/ZXing.Net.Mobile/GTK/Libs/webkit-sharp/webkit-sharp.dll.config b/ZXing.Net.Mobile/GTK/Libs/webkit-sharp/webkit-sharp.dll.config
new file mode 100755
index 000000000..438480176
--- /dev/null
+++ b/ZXing.Net.Mobile/GTK/Libs/webkit-sharp/webkit-sharp.dll.config
@@ -0,0 +1,5 @@
+
+
+
+
+
diff --git a/ZXing.Net.Mobile/GTK/MobileBarcodeScanner.gtk.cs b/ZXing.Net.Mobile/GTK/MobileBarcodeScanner.gtk.cs
new file mode 100644
index 000000000..cb932935d
--- /dev/null
+++ b/ZXing.Net.Mobile/GTK/MobileBarcodeScanner.gtk.cs
@@ -0,0 +1,37 @@
+using System;
+using System.Threading.Tasks;
+
+namespace ZXing.Mobile
+{
+ public partial class MobileBarcodeScanner : MobileBarcodeScannerBase
+ {
+ NotSupportedException ex = new NotSupportedException("MobileBarcodeScanner is unsupported on this platform.");
+
+ Task PlatformScan(MobileBarcodeScanningOptions options)
+ => throw ex;
+
+ void PlatformScanContinuously(MobileBarcodeScanningOptions options, Action scanHandler)
+ => throw ex;
+
+ void PlatformCancel()
+ => throw ex;
+
+ void PlatformAutoFocus()
+ => throw ex;
+
+ void PlatformTorch(bool on)
+ => throw ex;
+
+ void PlatformToggleTorch()
+ => throw ex;
+
+ void PlatformPauseAnalysis()
+ => throw ex;
+
+ void PlatformResumeAnalysis()
+ => throw ex;
+
+ bool PlatformIsTorchOn
+ => throw ex;
+ }
+}
diff --git a/ZXing.Net.Mobile/ZXing.Net.Mobile.csproj b/ZXing.Net.Mobile/ZXing.Net.Mobile.csproj
index da2d0b1ab..9d05a6c9e 100644
--- a/ZXing.Net.Mobile/ZXing.Net.Mobile.csproj
+++ b/ZXing.Net.Mobile/ZXing.Net.Mobile.csproj
@@ -1,6 +1,6 @@
- netstandard2.0;Xamarin.iOS10;Xamarin.Mac20;MonoAndroid10.0;tizen40
+ netstandard2.0;Xamarin.iOS10;Xamarin.Mac20;MonoAndroid10.0;tizen40;net461
$(TargetFrameworks);uap10.0.16299;
ZXingNetMobile
ZXing.Net.Mobile
@@ -87,7 +87,7 @@
-
+
@@ -104,8 +104,21 @@
+
+
+ GTK\Libs\gtk-sharp\gtk-sharp-2.0\gtk-sharp.dll
+
+
+ GTK\Libs\gtk-sharp\gtk-sharp-2.0\gdk-sharp.dll
+
+
+ GTK\Libs\gtk-sharp\Mono.Cairo\Mono.Cairo.dll
+
+
+
+
-
+
\ No newline at end of file
diff --git a/readme.md b/readme.md
index a2a77c81e..c890f2c45 100644
--- a/readme.md
+++ b/readme.md
@@ -88,6 +88,14 @@ In your `AppDelegate`'s `FinishedLaunching (..)` implementation, call:
ZXing.Net.Mobile.Forms.MacOS.Platform.Init();
```
+##### GTK
+
+In your `MainClass`'s `Main (..)` implementation, call:
+
+```csharp
+ZXing.Net.Mobile.Forms.GTK.Platform.Init();
+```
+
### Features
- Xamarin.iOS
@@ -95,6 +103,7 @@ ZXing.Net.Mobile.Forms.MacOS.Platform.Init();
- Tizen
- UWP
- Xamarin.Mac (rendering only, not scanning)
+- GTK# (rendering only, not scanning)
- Simple API - Scan in as little as 2 lines of code!
- Scanner as a View - UIView (iOS) / Fragment (Android) / Control (WP)