Announcement

Collapse

Looking for a User App or Add-On built by the NinjaTrader community?

Visit NinjaTrader EcoSystem and our free User App Share!

Have a question for the NinjaScript developer community? Open a new thread in our NinjaScript File Sharing Discussion Forum!
See more
See less

Partner 728x90

Collapse

NinjaTrader 8 Icon Dictionary

Collapse
X
 
  • Filter
  • Time
  • Show
Clear All
new posts

  • ruppschtaler
    replied
    Hello aligator, Hello Jesse,
    Just the reference to the 'IconsFamily' custom font was missing - now it's working perfect.
    Thanks for your support!

    Leave a comment:


  • aligator
    replied
    Originally posted by ruppschtaler View Post
    Hi there,

    I'm wondering if you can provide some information how to access these custom font icons (NInjaTrader.Gui.Tools.Icons) in an Add-On by now?

    Thank you!
    ruppschtaler, Hi

    There is no such documented information available, at least not that I know.

    When I was writing the code for mahToolBar2 (https://ninjatrader.com/support/foru...ks.php?catid=7),
    I simply got the list from Ninja Inteliprompt list box here:



    So, in editor type: NInjaTrader.Gui.Tools.Icons. and simply pick the icon that you want from the drop down list box.

    Hope this help.

    Cheers!
    Last edited by aligator; 12-08-2017, 07:22 PM.

    Leave a comment:


  • aligator
    replied
    Originally posted by NinjaTrader_Jesse View Post
    Hello,

    Thank you for the post.

    The answer to this question was provided in a previous post:

    Code:
    btnRay = new System.Windows.Controls.Button { [B]Content = NinjaTrader.Gui.Tools.Icons.DrawRay[/B], };
    The Content of the control in question would be set to the string for the icon you want like shown in this example.

    Are you unable to use the icon as a content for a specific control in an addon?

    The control being used needs to allow for Fonts to be used and have the custom font as its selected font, please see this post for an example of the syntax: https://ninjatrader.com/support/foru...10&postcount=4

    I look forward to being of further assistance.
    Hi Jessie,

    I am able to implement a button for many icons such as Ray as I have defined above:


    Code:
    btnRay = new System.Windows.Controls.Button { [B]Content = NinjaTrader.Gui.Tools.Icons.DrawRay[/B], };
    Without making it too complicated please , can you provide a similar statement for a button for Chart Trader (Hidden) option Icon which is a sub-menu item in the main tool bar?

    The following:

    Code:
    btnChartTraderHidden = new System.Windows.Controls.Button { [B]Content = NinjaTrader.Gui.Tools.Icons.ChartTraderHidden[/B], };
    works fine and will draw the Icon, but because it is a sub-menu item it depends on the status of Chart Trader Icon on main toolbar. Once this button is clicked, it will hide the Chart Trader, but will not reverse the action if clicked again.

    Many Thanks
    Last edited by aligator; 12-08-2017, 07:00 PM.

    Leave a comment:


  • NinjaTrader_Jesse
    replied
    Hello,

    Thank you for the post.

    The answer to this question was provided in a previous post:

    Code:
    btnRay = new System.Windows.Controls.Button { [B]Content = NinjaTrader.Gui.Tools.Icons.DrawRay[/B], };
    The Content of the control in question would be set to the string for the icon you want like shown in this example.

    Are you unable to use the icon as a content for a specific control in an addon?

    The control being used needs to allow for Fonts to be used and have the custom font as its selected font, please see this post for an example of the syntax: https://ninjatrader.com/support/foru...10&postcount=4

    I look forward to being of further assistance.

    Leave a comment:


  • ruppschtaler
    replied
    Hi there,

    I'm wondering if you can provide some information how to access these custom font icons (NInjaTrader.Gui.Tools.Icons) in an Add-On by now?

    Thank you!

    Leave a comment:


  • NinjaTrader_Jesse
    replied
    Hello
    .
    I just wanted to reply back on this item.

    Yes internally there is a set of icons used, it appears these are Font Icons in a custom font and not resources. This means that most items internally seem to use a specific font and then a specific code for the image. At this time I have been unable to retrieve a list or any other information regarding how to access these icons from NinjaScript. I have put in a feature request to gather further information on this subject. For the time being including your own resources or images would likely be the only way to accomplish this.

    I look forward to being of further assistance.

    Leave a comment:


  • aligator
    replied
    Originally posted by NinjaTrader_Jesse View Post
    Hello aligator,

    Thank you for the post.

    I am unsure of a specific resource we offer that lists all of these resource keys, I will need to further research this to see what I can locate.

    For the time being, you may look into using an approach similar to the following forum item. The poster used images that are included in the download, this is not necessarily optimal but could get you results for the time being. http://ninjatrader.com/support/forum...d=9&linkid=781

    Once I have further information on this I will reply back here.

    I look forward to being of further assistance.
    Thank you Jesse,

    The link helps, but it introduces Bitmap and .jpg buttons that will takes things a little beyond the scope of what I am coding.

    I assume that Ninja has definitions for all Icons as part of the main toolbar and its sub-menus. I was able to find definitions for all drawing tools such as:

    Code:
    btnRay = new System.Windows.Controls.Button { Content = NinjaTrader.Gui.Tools.Icons.DrawRay, };
    for DrawRay.

    So, I am trying to find a similar content definition for other items in the drop down menu under the Drawing Tools, i.e. DeleteAllDrawingObjecs or SnapMode icons.

    Many thanks.

    Leave a comment:


  • NinjaTrader_Jesse
    replied
    Hello aligator,

    Thank you for the post.

    I am unsure of a specific resource we offer that lists all of these resource keys, I will need to further research this to see what I can locate.

    For the time being, you may look into using an approach similar to the following forum item. The poster used images that are included in the download, this is not necessarily optimal but could get you results for the time being. http://ninjatrader.com/support/forum...d=9&linkid=781

    Once I have further information on this I will reply back here.

    I look forward to being of further assistance.

    Leave a comment:


  • aligator
    started a topic NinjaTrader 8 Icon Dictionary

    NinjaTrader 8 Icon Dictionary

    Dear Support,

    Looking for a reference that provides a list or a dictionary of NT8 Icon definitions similar to the following:

    "AndrewsPitchfork", NinjaTrader.Gui.Tools.Icons.DrawAndrewsPitchfork ,etc.

    A few of specific definitions for Icons of interest are:

    Delete All Drawing Objects,
    Snap Mode
    Stay in Draw Mode

    Thank you.

Latest Posts

Collapse

Topics Statistics Last Post
Started by proptrade13, Today, 11:06 AM
1 response
5 views
0 likes
Last Post NinjaTrader_Clayton  
Started by quantismo, 04-17-2024, 05:13 PM
4 responses
31 views
0 likes
Last Post quantismo  
Started by love2code2trade, 04-17-2024, 01:45 PM
4 responses
32 views
0 likes
Last Post love2code2trade  
Started by cls71, Today, 04:45 AM
2 responses
10 views
0 likes
Last Post eDanny
by eDanny
 
Started by kulwinder73, Today, 10:31 AM
1 response
10 views
0 likes
Last Post NinjaTrader_Erick  
Working...
X