C# 클래스 SIL.FieldWorks.Resources.ResourceHelper

Provides access to resources
The non-static methods and fields are in a separate class so that clients can use this class without the need for a reference to Windows.Forms if all they need is to get some strings.
파일 보기 프로젝트 열기: sillsdev/FieldWorks 1 사용 예제들

Private Properties

프로퍼티 타입 설명
ResourceHelper System

공개 메소드들

메소드 설명
BuildFileFilter ( ) : string

Builds a filter specification for multiple file types for a SaveFileDialog or OpenFileDialog.

BuildFileFilter ( IEnumerable types ) : string

Builds a filter specification for multiple file types for a SaveFileDialog or OpenFileDialog.

FileFilter ( FileFilterType type ) : string

Builds a filter specification for a single file type for SaveFileDialog or OpenFileDialog.

FormatResourceString ( string stid ) : string

Return a string from a resource ID, with formatting placeholders replaced by the supplied parameters.

GetHelpString ( string stid ) : string

Return a help topic or help file path.

GetResourceString ( string stid ) : string

Return a string from a resource ID.

MakeUndoRedoLabels ( string stid, string &stUndo, string &stRedo ) : void

Function to create appropriate labels for Undo tasks, with the action names coming from the stid.

ReplaceTransparentColor ( Image img, Color replaceColor ) : Bitmap

Replace all of the transparent pixels in the image with the given color

ShutdownHelper ( ) : void

Shut down the one instance of ResourceHelper.

This should be called once when the application shuts down.

비공개 메소드들

메소드 설명
ResourceHelper ( ) : System

Constructor for ResourceHelper

메소드 상세

BuildFileFilter() 공개 정적인 메소드

Builds a filter specification for multiple file types for a SaveFileDialog or OpenFileDialog.
public static BuildFileFilter ( ) : string
리턴 string

BuildFileFilter() 공개 정적인 메소드

Builds a filter specification for multiple file types for a SaveFileDialog or OpenFileDialog.
public static BuildFileFilter ( IEnumerable types ) : string
types IEnumerable The types of files to include in the filter, in the order they /// should be included. Do not use any of the enumeration values starting with "All" /// for a filter intended to be used in a SaveFileDialog.
리턴 string

FileFilter() 공개 정적인 메소드

Builds a filter specification for a single file type for SaveFileDialog or OpenFileDialog.
public static FileFilter ( FileFilterType type ) : string
type FileFilterType The type of files to include in the filter. Do not use any of the /// enumeration values starting with "All" for a filter intended to be used in a /// SaveFileDialog.
리턴 string

FormatResourceString() 정적인 공개 메소드

Return a string from a resource ID, with formatting placeholders replaced by the supplied parameters.
static public FormatResourceString ( string stid ) : string
stid string String resource id
리턴 string

GetHelpString() 정적인 공개 메소드

Return a help topic or help file path.
static public GetHelpString ( string stid ) : string
stid string String resource id
리턴 string

GetResourceString() 정적인 공개 메소드

Return a string from a resource ID.
static public GetResourceString ( string stid ) : string
stid string String resource id
리턴 string

MakeUndoRedoLabels() 공개 정적인 메소드

Function to create appropriate labels for Undo tasks, with the action names coming from the stid.
public static MakeUndoRedoLabels ( string stid, string &stUndo, string &stRedo ) : void
stid string String resource id
stUndo string Returns string for Undo task
stRedo string Returns string for Redo task
리턴 void

ReplaceTransparentColor() 공개 정적인 메소드

Replace all of the transparent pixels in the image with the given color
public static ReplaceTransparentColor ( Image img, Color replaceColor ) : Bitmap
img Image
replaceColor Color
리턴 System.Drawing.Bitmap

ShutdownHelper() 공개 정적인 메소드

Shut down the one instance of ResourceHelper.
This should be called once when the application shuts down.
public static ShutdownHelper ( ) : void
리턴 void