Giter Club home page Giter Club logo

fontawesome.sharp's People

Contributors

dependabot[bot] avatar foxcouncil avatar mkoertgen avatar voidvolker avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

fontawesome.sharp's Issues

Getting the Image

Is there a way one can get the currently set FontAwesome Image/Icon?
As of currently, there seems to be no way.

Seems the base Image doesn't return the applied FontAwesome Icon since it's serialization is hidden.

Icon positioning in center bug

I get issue with centering icon. Looks like it rendering not very accurate with paddings. Here the example:
image

Icons have size 100x100 pixels. Control is inherited from IconPictureBox.

Please Sign FontAwesome.Sharp

Warning CS8002 Referenced assembly 'FontAwesome.Sharp, Version=4.7.1.0, Culture=neutral, PublicKeyToken=null' does not have a strong name.

AddIcons causes UI glitches [Winforms]

Hi,

First I would like to thank you for creating and supporting this project.

My problem is as follows. Once I use AddIcons extension method from FormsIconHelper, all labels in my app get ellipses as if there is not enough space to render all text labels. As if AddIcons causes reevaluation of the layout.

Here is the normal app:
okay

Here is the app after AddIcons
ellipses

Any help would be appreciated.

Exception HRESULT: 0x800A01E1 (CTL_E_INVALIDPICTURE) while changing IconChar

We experienced exception on installed software

************** Exception Text **************
System.Runtime.InteropServices.COMException (0x800A01E1): Exception from HRESULT: 0x800A01E1 (CTL_E_INVALIDPICTURE)
at System.Windows.Forms.UnsafeNativeMethods.IPersistStream.Load(IStream pstm)
at System.Windows.Forms.Cursor.LoadPicture(IStream stream)

when we try to change Icon of the button like code below
markQuestionBtn.IconChar = FontAwesome.Sharp.IconChar.CheckSquare;

What could be the issue?
OS Windows 10 Home and It's working fine on Windows 10 pro but having issue on Home edition only.

icon not centered

in previous version 5.13 icon was center but now in this 5.14 icon slightly right side
5 13
5 14

Icons for WPF buttons do not show up in designer.

I am using FontAwesome.Sharp to place icons on my buttons in a wpf application. When executing the application the icons show just fine, but in the designer only empty rectangles are visible.

I have added FontAwesome.Sharp as nuget dependency and use it for example with the following button declaration in my xaml:
<ToggleButton IsChecked="{Binding CrosshairVisible}" ToolTip="Show crosshair" Content="{fa:Icon Crosshairs}"/>

If I open the sample application TestWPF the icons show up in the designer. The major difference I can see is that TestWPF uses a project dependency and I use the nuget package.

Font Awesome Pro ?

Hello,
I managed to implement this into our application, but now I am wondering, if you support FA Pro as well.
As our designer used almost Pro Icons only, this would be great. I could not find information about this in the project.

Greetings,
Maik

Icons not loading on .Net 5.0 preview 7

Hello,
I've been migrating my code to .net 5.0 and found that font awesome sharp icons (not all but most of them) not load at all .
For example the icons ideal and faucet are working however the cogs and settings aren't.
I've tried sorting the problem but without any luck.

For .Net Core

Is it too early to ask if we can use it for windows form .Net Core..?

How can I add Icons ?

I created a tool that shows
FontAwesomeclientAssistant

I searched for some Icons related to Database Operations, UI Operations I don't think they exist in the Repository; In case I want to Add Icons of my Own what is the way to do this.

I can't see elements in toolbox

Hi, It's probably that I don't know how do it...but, how Can I show the objects (for example "IconButton") in the toolbox of visual studio?

I have realized that I can put an IconButton making a copy-paste from the project sample, but I don't see IconButton in toolbox.

Thanks in advance!

IconPictureBox reduces scale of entire application

When an IconPictureBox is instantiated on a form in a WinForms application, it reduces the display scale of the ENTIRE application to the Windows out-of-the-box standard 96 dpi. This is a rather annoying issue for users who prefer to run at a higher logical dpi.

To reproduce, make sure your system settings are as follows, before running your application:

System: Windows 10
System fundamental dpi: 96
Monitor scaling: 125% (120 dpi)
App forms are set to AutoScaleMode = Font

When you run your application, as soon as an IconPictureBox is instantiated with new in the designer file's InitializeComponent method, the application will immediately shrink to the system dpi for the remainder of the time the application is running.

FontAwesome Sharp on high DPI Screens

Hello,
How to use FontAwesome Sharp on high DPI screens?
I have an application developed in 1080p screen and now on 4K screen the icon buttons changes then whole forms look to very tiny and compact windows forms.
when I remove the icon button and add the normal windows forms button everything is work and looks fine as it should be.
is there any guide that I can look at to set the icon buttons or icon picture box work on any DPI screen.

Looking forward to hearing from you. Thanks

Material Design Icons Switching

Hi,

Great job with this library. Many thanks.
Could you allow switching between FontAwesome and MaterialDesign icons since they all work the same way in terms of parsing the icons from font; only the icons-list or IconChar enumeration will be modified.

We can then use a property such as:
IconLibrary = IconLibraries.Material; or IconLibrary = IconLibraries.FontAwesome;

This would really come in handy as an addition. Any help will be appreciated.

Update to v5.8.2

Thanks for the fantastic work so far.
There's a new FontAwesome update, v5.8 with 118 new icons and brands.

Solid Style with nuget?

How can I change the lookup-order of chars with the nuget package?
I very much like the left char (solid) over the one on the right (regular):
image

ToChar().Single Issue

I'm using markdown icons with your guys' library- first of all, great job! It's great to have something like this that supports WinForms.

I'm running into an issue where getting a bitmap of the icon is throwing a 'Sequence contains multiple elements' exception. Since your project is open source, I looked into the method and troubleshooted (troubleshot? idk..) the issue down to the ToChar() method. It uses the .Single() instead of the .First() linq command (which is arguably more correct).

I'd love your guys' input!
Thanks!
Greg

FontAwesome icon NOT vertically aligned on controls

Source: NuGet
Package: FontAwesome.Sharp
Version: v5.13
Platform: Windows Forms desktop application

I am using the FontAwesome.Sharp NuGet on my .NET (C#) Winforms project. I have used it to show FA icons on ToolStripMenuItems and Buttons and noticed that the icon is NOT vertically aligned on System.Windows.Forms controls. When the icon is displayed on the control, the icon looks shifted down so it does not look 'awesome'.

Choosing icon using properties window in WinForms is not sorted alphabetically, and one cannot search it

Hi,

To start, nice work!
I noticed though that once you add the control in winforms (IconPictureBox), and then you try to use the "Properties" window to set the IconChar, there are few issues:

  • Dropdown list opens, but the list is not ordered alphabetically.
  • You can't search by starting to type, as it just uses the first letter (i.e. start typing "github", you get first GitAlt, then Inbox etc)
  • OK, I'll type it manually - not allowed.

Not a big problem, I just select it in code, but I think the solution is just to sort it alphabetically or to do the parsing or whatever is done in this window when one types in something.

overloading ToBitmap with width/height params

FormsIconHelper's ToBitmap method only accepts a single size param.
For underlying fonts that are much wider than tall (or vice versa), it creates a much smaller image than intended.
Exposing a way to explicitly set the width and height would be helpful.

I created a fork with this change if you'd like to merge it.

Want to Create an Application showing Images

I am trying to Create a WindowsForm Core Application that shows all the Images with Name in the form and keep it as Reference because dropdown calls for a lengthy search.
Can I get some help?
When you Open my Application you will have an Alphabet Selector based on this
I want to show PictureBoxes with the Image(IconChar) and a Label below that has its name use this as a quick reference while using your Framework.

XML Namespace

Hi,
I had to add this to my Window tag:
xmlns:fa="http://schemas.awesome.incremented/wpf/xaml/fontawesome.sharp"

in my XAML file before I could use :

<fa:IconBlock Icon="Info" Foreground="Chocolate"/>

Is that still the correct namespace URL to use? I found it here.

And, you should update your README to include the above step because it is not mentioned.

CVE-2018-1000210 High Severity Vulnerability detected by WhiteSource

CVE-2018-1000210 - High Severity Vulnerability

Vulnerable Library - gitversiontask.4.0.0.nupkg

Stamps an assembly with git information based on SemVer.

path: /FontAwesome.Sharp/FontEnumGenerator/packages.config,/FontAwesome.Sharp/TestWpf/packages.config,/FontAwesome.Sharp/FontAwesome.Sharp/packages.config,/FontAwesome.Sharp/FontAwesome.Sharp.Tests/packages.config,/FontAwesome.Sharp/TestForms/packages.config

Library home page: https://api.nuget.org/packages/gitversiontask.4.0.0.nupkg

Dependency Hierarchy:

  • gitversiontask.4.0.0.nupkg (Vulnerable Library)

Vulnerability Details

YamlDotNet version 4.3.2 and earlier contains a Insecure Direct Object Reference vulnerability in The default behavior of Deserializer.Deserialize() will deserialize user-controlled types in the line "currentType = Type.GetType(nodeEvent.Tag.Substring(1), throwOnError: false);" and blindly instantiates them. that can result in Code execution in the context of the running process. This attack appear to be exploitable via Victim must parse a specially-crafted YAML file. This vulnerability appears to have been fixed in 5.0.0.

Publish Date: 2018-07-13

URL: CVE-2018-1000210

CVSS 3 Score Details (7.8)

Base Score Metrics:

  • Exploitability Metrics:
    • Attack Vector: Local
    • Attack Complexity: Low
    • Privileges Required: None
    • User Interaction: Required
    • Scope: Unchanged
  • Impact Metrics:
    • Confidentiality Impact: High
    • Integrity Impact: High
    • Availability Impact: High

For more information on CVSS3 Scores, click here.


Step up your Open Source Security Game with WhiteSource here

Specify IconFont when using IconChar.ToBitmap() [WinForms]

Hi!
would it be possible to add an (optional?) parameter to the .ToBitmap() fiunction which allows explicitly specifying which IconFont to use?
it currently seems to use regular (if available) - but I sometimes need the solid version (e.g. for "disk")

thanks

FontAwesome.Sharp.FormsIconHelper

Hi, I have a problem. One of my testers launched the application and threw this error out of him. Can I ask for help? I'm just learning C #. Thank you

System.TypeLoadException: Nie można załadować typu 'System.Runtime.CompilerServices.ExtensionAttribute' z zestawu 'mscorlib, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089'.

at System.ModuleHandle.ResolveMethod(RuntimeModule module, Int32 methodToken, IntPtr* typeInstArgs, Int32 typeInstCount, IntPtr* methodInstArgs, Int32 methodInstCount)
at System.ModuleHandle.ResolveMethodHandleInternalCore(RuntimeModule module, Int32 methodToken, IntPtr[] typeInstantiationContext, Int32 typeInstCount, IntPtr[] methodInstantiationContext, Int32 methodInstCount)
at System.ModuleHandle.ResolveMethodHandleInternal(RuntimeModule module, Int32 methodToken, RuntimeTypeHandle[] typeInstantiationContext, RuntimeTypeHandle[] methodInstantiationContext)
at System.Reflection.CustomAttributeData..ctor(RuntimeModule scope, CustomAttributeRecord caRecord)
at System.Reflection.CustomAttributeData.GetCustomAttributes(RuntimeModule module, Int32 tkTarget)
at System.Reflection.CustomAttributeData.GetCustomAttributesInternal(RuntimeAssembly target)
at System.Reflection.RuntimeAssembly.GetCustomAttributesData()
at System.Reflection.CustomAttributeData.GetCustomAttributes(Assembly target)
at System.Resources.ManifestBasedResourceGroveler.GetNeutralResourcesLanguage(Assembly a, UltimateResourceFallbackLocation& fallbackLocation)
at System.Resources.ResourceManager.CommonSatelliteAssemblyInit()
at System.Resources.ResourceManager..ctor(String baseName, Assembly assembly)
at MS.Internal.Resources.ResourceManagerWrapper.get_ResourceManager()
at MS.Internal.Resources.ResourceManagerWrapper.GetStream(String name)
at MS.Internal.AppModel.ResourcePart.GetStreamCore(FileMode mode, FileAccess access)
at System.IO.Packaging.PackagePart.GetStream(FileMode mode, FileAccess access)
at System.IO.Packaging.PackagePart.GetStream()
at System.Windows.Application.GetResourceStream(Uri uriResource)
at FontAwesome.Sharp.FormsIconHelper.GetFontBytes(String fontFile, Assembly assembly, String path)
at FontAwesome.Sharp.FormsIconHelper.AddFont(PrivateFontCollection fonts, String fontFile, Assembly assembly, String path)
at FontAwesome.Sharp.FormsIconHelper.InitializeFonts()
at FontAwesome.Sharp.FormsIconHelper..cctor()

System.TypeInitializationException: Inicjator typów zgłosił wyjątek dla typu 'FontAwesome.Sharp.FormsIconHelper'.

at FontAwesome.Sharp.FormsIconHelper.FontFamilyFor(IconChar iconChar)
at FontAwesome.Sharp.IconButton..ctor()
at Launcher.WindowInstall.InitializeComponent()
at Launcher.WindowInstall..ctor()
at Launcher.Program.Main(String[] args)

System Information

Application Launcher
Version 1.0.0.0
Date 2020-10-16 16:34:43Z
OS Windows 7 Service Pack 1
CLR 4.0.30319.1
CrashReporter.NET Version 1.5.8.0

FontAwesome v5.8.2 icons not displaying

Following up on the latest addition supporting FontAwesome v5.8.2, some icons, specifically from AngleDoubleLeft to the very last one, Stackpath, are not being displayed when selected. This seems to affect the IconPictureBox control only; the IconButton works seamlessly.

Cannot add FontAwesome.Sharp.dll V-5.8.3 to toolbox

Hello, I try to add the controls of the FontAwesome.Sharp library to the visual studio 2015 toolbox, with these steps:
add items to the tab, i.e. Choose Items -> Browse, then select $ (SolutionDir) ./ packages \ FontAwesome.Sharp.5.8.3 \ lib \ net40 \ FontAwesome.Sharp.dll

But I get the following error:

There are no items in '$ (SolutionDir) ... FontAwesome.Sharp.dll' that can be placed in the toolbox.

I get the same error in visual studio 2012-2015-2017-2019.
Although in VS 2017 and 2019 the controls are automatically added to the toolbox after installing from nuget.

add regular style font

please add regular style font char when icon are available in regular and solid style.
thank you for your great work.

Strong Name

https://www.pedrolamas.com/2016/03/01/still-strong-naming-your-assemblies-you-do-know-its-2016-right/

Please see him update:
Update: Though the information and concerns in this blog post are still very true, I’ve actually had a change of heart and I’m now advocating to Start Strong-Naming your Assemblies!!

https://www.pedrolamas.com/2018/09/11/start-strong-naming-your-assemblies/

Also, the absence of a strong signature blocks the distribution of WinForms controls with designers containing icons via NuGet

Temporary alternatives:
Signing NuGet package libs before use:

  <ItemGroup>
    <PackageReference Include="Brutal.Dev.StrongNameSigner" Version="2.7.1" GeneratePathProperty="true" IncludeAssets="none" />
    <PackageReference Include="FontAwesome.Sharp" Version="5.15.3" GeneratePathProperty="true" />
  </ItemGroup>

  <Target Name="StrongName" BeforeTargets="PrepareForBuild">
    <Exec Command="&quot;$(PkgBrutal_Dev_StrongNameSigner)\build\StrongNameSigner.Console.exe&quot; -InputDirectory &quot;$(PkgFontAwesome_Sharp)\lib&quot;" />
  </Target>

Or my StrongName NuGet package:

<PackageReference Include="FontAwesome.Sharp.StrongName" Version="5.15.3" />

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.