Skip to content

Commit 4d33df0

Browse files
committed
Updated NuGet package specification to new standards
Added NuGet readme, replaced PackageIconUrl by PackageIcon, etc.
1 parent 34f7714 commit 4d33df0

File tree

3 files changed

+66
-5
lines changed

3 files changed

+66
-5
lines changed

QRCoder/Assets/nuget-icon.png

22.4 KB
Loading

QRCoder/Assets/nuget-readme.md

Lines changed: 54 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,54 @@
1+
## About
2+
3+
QRCoder is a simple library, written in C#.NET, which enables you to create QR codes. It hasn't any dependencies to other libraries and is available as .NET Framework and .NET Core PCL version on NuGet.
4+
5+
***
6+
7+
## Documentation
8+
9+
👉 *Your first place to go should be our wiki. Here you can find a detailed documentation of the QRCoder and its functions.*
10+
* [**QRCode Wiki**](https://github.com/codebude/QRCoder/wiki)
11+
* [Creator's blog (english)](http://en.code-bude.net/2013/10/17/qrcoder-an-open-source-qr-code-generator-implementation-in-csharp/)
12+
* [Creator's blog (german)](http://code-bude.net/2013/10/17/qrcoder-eine-open-source-qr-code-implementierung-in-csharp/)
13+
14+
15+
## Usage / Quick start
16+
17+
You only need five lines of code, to generate and view your first QR code.
18+
19+
```csharp
20+
QRCodeGenerator qrGenerator = new QRCodeGenerator();
21+
QRCodeData qrCodeData = qrGenerator.CreateQrCode("The text which should be encoded.", QRCodeGenerator.ECCLevel.Q);
22+
QRCode qrCode = new QRCode(qrCodeData);
23+
Bitmap qrCodeImage = qrCode.GetGraphic(20);
24+
```
25+
26+
### Optional parameters and overloads
27+
28+
The GetGraphics-method has some more overloads. The first two enable you to set the color of the QR code graphic. One uses Color-class-types, the other HTML hex color notation.
29+
30+
```csharp
31+
//Set color by using Color-class types
32+
Bitmap qrCodeImage = qrCode.GetGraphic(20, Color.DarkRed, Color.PaleGreen, true);
33+
34+
//Set color by using HTML hex color notation
35+
Bitmap qrCodeImage = qrCode.GetGraphic(20, "#000ff0", "#0ff000");
36+
```
37+
38+
The other overload enables you to render a logo/image in the center of the QR code.
39+
40+
```csharp
41+
Bitmap qrCodeImage = qrCode.GetGraphic(20, Color.Black, Color.White, (Bitmap)Bitmap.FromFile("C:\\myimage.png"));
42+
```
43+
44+
There are a plenty of other options. So feel free to read more on that in our wiki: [Wiki: How to use QRCoder](https://github.com/codebude/QRCoder/wiki/How-to-use-QRCoder)
45+
46+
## Help & Issues
47+
48+
If you think you have a bug or have new ideas/feature requests, then feel free to open a new issues: https://github.com/codebude/QRCoder/issues
49+
In case you have a question about using the library (and couldn't find an answer in our wiki), feel free to open a new question/discussion: https://github.com/codebude/QRCoder/discussions
50+
51+
52+
## Legal information and credits
53+
54+
QRCoder is a project by [Raffael Herrmann](https://raffaelherrmann.de) and was first released in 10/2013. It's licensed under the [MIT license](https://github.com/codebude/QRCoder/blob/master/LICENSE.txt).

QRCoder/QRCoder.csproj

Lines changed: 12 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -16,22 +16,31 @@
1616
<PropertyGroup>
1717
<GenerateAssemblyInfo>false</GenerateAssemblyInfo>
1818
<PackageId>QRCoder</PackageId>
19-
<Version>1.4.1</Version>
19+
<Version>1.4.2</Version>
2020
<Authors>Raffael Herrmann</Authors>
21+
<PackageOwners>Raffael Herrmann</PackageOwners>
2122
<AssemblyName>QRCoder</AssemblyName>
2223
<PackageLicenseExpression>MIT</PackageLicenseExpression>
2324
<PackageProjectUrl>https://github.com/codebude/QRCoder/</PackageProjectUrl>
24-
<PackageIconUrl>http://code-bude.net/downloads/qrcoder-logo.png</PackageIconUrl>
25+
<PackageIcon>nuget-icon.png</PackageIcon>
26+
<PackageReadmeFile>nuget-readme.md</PackageReadmeFile>
2527
<PackageTags>c# csharp qr qrcoder qrcode qr-generator qr-code-generator</PackageTags>
2628
<RepositoryUrl>https://github.com/codebude/QRCoder.git</RepositoryUrl>
29+
<RepositoryType>git</RepositoryType>
30+
<Description>QRCoder is a simple library, written in C#.NET, which enables you to create QR codes.</Description>
2731
</PropertyGroup>
2832

33+
<ItemGroup>
34+
<None Include="Assets\nuget-icon.png" Pack="true" PackagePath="\" />
35+
<None Include="Assets\nuget-readme.md" Pack="true" PackagePath="\" />
36+
</ItemGroup>
37+
2938
<ItemGroup Condition=" '$(TargetFramework)' == 'net35' or '$(TargetFramework)' == 'net40' ">
3039
<Reference Include="PresentationCore" />
3140
<Reference Include="PresentationFramework" />
3241
<Reference Include="WindowsBase" />
3342
</ItemGroup>
34-
43+
3544
<ItemGroup Condition=" '$(TargetFramework)' == 'netstandard2.0' or '$(TargetFramework)' == 'net5.0' ">
3645
<PackageReference Include="System.Drawing.Common" Version="4.7.0" />
3746
</ItemGroup>
@@ -43,5 +52,3 @@
4352
<AssemblyOriginatorKeyFile>QRCoderStrongName.snk</AssemblyOriginatorKeyFile>
4453
<DelaySign>false</DelaySign>
4554
</PropertyGroup>
46-
47-
</Project>

0 commit comments

Comments
 (0)