IAR配置keil代码风格2021-02-04

IAR配置keil代码风格

学嵌入式入门一般都是用keil,学者看惯了keil风格

还有一款编译器虽然界面配置有点别扭,但是功能上却不比keil鸡肋,甚至在本人看来有过之!下面来和大家配置一下IAR的界面~

本人采用的IAR版本为

IAR Embedded Workbench8051v10.10.1
IAR配置keil代码风格2021-02-04

效果展示

IAR配置keil代码风格2021-02-04

配置IAR界面

在选项栏中 Tools>Options

IAR配置keil代码风格2021-02-04

Editor>colors and font,在这里我们可以配置自己喜欢的一种style
IAR配置keil代码风格2021-02-04

xml文件修改

在目录:C:\Users\Administrator\AppData\Roaming\IAR Embedded Workbench里面有个xml结尾的文件

user为用户

Administrator为当前系统的登录用户

AppData为隐藏文件,这个需要打开权限,如下图

IAR配置keil代码风格2021-02-04

我们其实在修改图二中的属性的时候,就是对图三中xml文件的修改!

说白了就是这个文件存储我们IAR界面的配置信息

那么我们就可以修改这个文件,来配置我们IAR属性。

下面展示得是本人的 Iarlde.xml文件

// An highlighted block
<?xml version="1.0"?>
<settings>
    <LanguageSettings>
        <CurrentLanguage>_ "ENU"</CurrentLanguage>
    </LanguageSettings>
    <Common>
        <Fonts>_ -13 0 0 0 400 0 0 0 0 3 2 1 49 "Courier New" -17 0 0 0 400 0 0 0 0 3 2 1 49 "Courier New"</Fonts>
    </Common>
    <Accelerators8>
        <Prim60>_ 3 123 "projectmanagergui.dll" 33839 "Go to Definition" "Go to the definition of the selected symbol"</Prim60>
        <Prim0>_ 11 3 "projectmanagergui.dll" 33037 "Stop Build" "Stop the currently running build job"</Prim0>
        <Prim1>_ 11 32 "texteditor.dll" 33308 "Complete Code" "List member functions and variables"</Prim1>
        <Prim2>_ 15 32 "texteditor.dll" 33281 "Parameter Hint" "Show function parameters"</Prim2>
        <Prim3>_ 27 32 "texteditor.dll" 33280 "Complete Word" "Suggest a completion of the typed word"</Prim3>
        <Prim4>_ 19 37 "texteditor.dll" 33053 "" ""</Prim4>
        <Prim5>_ 19 39 "texteditor.dll" 33054 "" ""</Prim5>
        <Prim6>_ 11 65 "iaridepm.dll" 57642 "Select All" "Select the entire document"</Prim6>
        <Prim7>_ 11 66 "texteditor.dll" 33300 "Match Brackets" "Grow the selection to the next level of matching brackets"</Prim7>
        <Prim8>_ 15 66 "texteditor.dll" 33301 "Match Brackets (shrink)" "Shrink the selection to the previous level of matching brackets/select content"</Prim8>
        <Prim9>_ 27 66 "texteditor.dll" 33306 "Match All Brackets" "Grow the selection to the next level of any matching brackets"</Prim9>
        <Prim10>_ 31 66 "texteditor.dll" 33307 "Match All Brackets (shrink)" "Shrink the selection to the previous level of any matching brackets/select content"</Prim10>
        <Prim11>_ 11 67 "iaridepm.dll" 57634 "Copy" "Copy the selection and put it on the Clipboard"</Prim11>
        <Prim12>_ 11 68 "projectmanagergui.dll" 33038 "Download and Debug" "Download the application and start the debugger"</Prim12>
        <Prim13>_ 15 68 "iaridepm.dll" 33094 "" ""</Prim13>
        <Prim14>_ 11 70 "iaridepm.dll" 57636 "Find" "Find the specified text"</Prim14>
        <Prim15>_ 27 70 "texteditor.dll" 33327 "Collapse/Expand All Folds" "Collapse or expand all folds in the current document"</Prim15>
        <Prim16>_ 11 71 "iaridepm.dll" 33026 "Go To" "Move to a specified location"</Prim16>
        <Prim17>_ 15 71 "texteditor.dll" 33309 "" ""</Prim17>
        <Prim18>_ 11 72 "iaridepm.dll" 57641 "Replace" "Replace specific text with different text"</Prim18>
        <Prim19>_ 15 72 "projectmanagergui.dll" 33873 "Open file" "Open the header or source file with the same name as the current file"</Prim19>
        <Prim20>_ 31 72 "iaridepm.dll" 33087 "Replace in Files" "Search and replace a specified text in multiple files"</Prim20>
        <Prim21>_ 11 73 "iaridepm.dll" 32811 "Incremental search" "Incremental search"</Prim21>
        <Prim22>_ 11 75 "texteditor.dll" 33304 "Block Comment" "Comment out a block of text"</Prim22>
        <Prim23>_ 15 75 "texteditor.dll" 33305 "Block Uncomment" "Uncomment a block of text"</Prim23>
        <Prim24>_ 11 78 "iaridepm.dll" 57600 "New Document" "Create a new text document"</Prim24>
        <Prim25>_ 11 79 "iaridepm.dll" 57601 "Open" "Open an existing document"</Prim25>
        <Prim26>_ 11 80 "iaridepm.dll" 57607 "Print" "Print the active document"</Prim26>
        <Prim27>_ 11 82 "projectmanagergui.dll" 33055 "Make &amp; Restart Debugger" "Make the active project, download the application and restart the debugger"</Prim27>
        <Prim28>_ 15 82 "projectmanagergui.dll" 33056 "Restart Debugger" "Restart the debugger without downloading the application"</Prim28>
        <Prim29>_ 11 83 "iaridepm.dll" 57603 "Save" "Save the active document"</Prim29>
        <Prim30>_ 11 84 "texteditor.dll" 33302 "Auto Indent" "Formats the selected text according to the auto indent settings"</Prim30>
        <Prim31>_ 27 84 "" 33025 "Find in Files" "Search for specified text in multiple files"</Prim31>
        <Prim32>_ 11 86 "iaridepm.dll" 57637 "Paste" "Insert Clipboard contents"</Prim32>
        <Prim33>_ 27 86 "texteditor.dll" 33081 "Show a list of template texts to insert into the current document" "Show a list of template texts to insert into the current document"</Prim33>
        <Prim34>_ 11 88 "iaridepm.dll" 57635 "Cut" "Cut the selection and put it on the Clipboard"</Prim34>
        <Prim35>_ 11 89 "iaridepm.dll" 57644 "Redo" "Redo the previously undone action"</Prim35>
        <Prim36>_ 11 90 "iaridepm.dll" 57643 "Undo" "Undo the last action"</Prim36>
        <Prim37>_ 3 113 "texteditor.dll" 33064 "Next Bookmark" "Go to the next bookmark"</Prim37>
        <Prim38>_ 7 113 "texteditor.dll" 33065 "Previous Bookmark" "Go to the previous bookmark"</Prim38>
        <Prim39>_ 11 113 "texteditor.dll" 33063 "Toggle Bookmark" "Add or remove a bookmark at the caret position"</Prim39>
        <Prim40>_ 3 114 "iaridepm.dll" 57640 "Find Next" "Find next occurrence of the specified text"</Prim40>
        <Prim41>_ 7 114 "iaridepm.dll" 33057 "Find Previous" "Find previous occurrence of the specified text"</Prim41>
        <Prim42>_ 11 114 "iaridepm.dll" 33058 "Find Next (Selected)" "Find next occurrence of selected text or word around the insertion point"</Prim42>
        <Prim43>_ 15 114 "iaridepm.dll" 33059 "Find Previous (Selected)" "Find previous occurrence of selected text or word around the insertion point"</Prim43>
        <Prim44>_ 3 115 "ideframework.dll" 33097 "" ""</Prim44>
        <Prim45>_ 7 115 "ideframework.dll" 33098 "" ""</Prim45>
        <Prim46>_ 11 115 "iaridepm.dll" 33050 "Close active tab" "Close the active tab"</Prim46>
        <Prim47>_ 3 116 "debuggergui.dll" 34320 "Go" "Run the program in the debugger"</Prim47>
        <Prim48>_ 3 118 "projectmanagergui.dll" 33036 "Make" "Make the active project (build files as needed)"</Prim48>
        <Prim49>_ 7 118 "projectmanagergui.dll" 33916 "" ""</Prim49>
        <Prim50>_ 11 118 "projectmanagergui.dll" 33035 "Compile" "Compile the selected file"</Prim50>
        <Prim51>_ 15 118 "projectmanagergui.dll" 33917 "" ""</Prim51>
        <Prim52>_ 19 118 "projectmanagergui.dll" 33806 "Options" "Edit options for the selected item"</Prim52>
        <Prim53>_ 3 119 "projectmanagergui.dll" 33841 "Batch build" "Open the batch build dialog"</Prim53>
        <Prim54>_ 3 120 "debuggergui.dll" 34399 "Toggle Breakpoint" "Toggle a breakpoint at the insertion point"</Prim54>
        <Prim55>_ 11 120 "debuggergui.dll" 34407 "Enable/Disable Breakpoint" "Enable or disable a breakpoint at the insertion point"</Prim55>
        <Prim56>_ 3 121 "debuggergui.dll" 34390 "Step Over" "Step over the current step point"</Prim56>
        <Prim57>_ 3 122 "debuggergui.dll" 34323 "Step Into" "Step into the current step point"</Prim57>
        <Prim58>_ 7 122 "debuggergui.dll" 34398 "Step Out" "Step out of the current function"</Prim58>
        <Prim59>_ 3 123 "projectmanagergui.dll" 33839 "Go to Definition" "Go to the definition of the selected symbol"</Prim59>
        <Sec0>_ 11 87 "iaridepm.dll" 33050 "Close active tab" "Close the active tab"</Sec0>
        <nSecondary>_ 1</nSecondary>
        <nPrimary>_ 60</nPrimary>
    </Accelerators8>
    <ProjectManager>
        <StopBuildOn>2</StopBuildOn>
        <EditorSave>2</EditorSave>
        <SaveWorkspaceBeforeBuild>2</SaveWorkspaceBeforeBuild>
        <MakeBeforeDebug>2</MakeBeforeDebug>
        <PlaySoundAfterBuild>1</PlaySoundAfterBuild>
        <BrowseInfo>1</BrowseInfo>
        <EnableAutoImport2>1</EnableAutoImport2>
        <EnableParallelBuild>1</EnableParallelBuild>
        <NumInParallel>8</NumInParallel>
        <ReloadLastWorkspace>_ 0</ReloadLastWorkspace>
    </ProjectManager>
    <WindowPlacement>
        <MainWindowRect>19010000E6000000B9060000D2030000</MainWindowRect>
        <Flags>2</Flags>
        <ShowCmd>3</ShowCmd>
    </WindowPlacement>
    <ExternalTools>
        <nNrOfEntries>_ 0</nNrOfEntries>
    </ExternalTools>
    <TextEditor>
        <Font0>_ 0 400 0 0 0</Font0>
        <Font1>_ 0 400 0 16711680 0</Font1>
        <Font2>_ 0 400 0 0 0</Font2>
        <Font3>_ 0 400 0 32768 0</Font3>
        <Font4>_ 0 400 0 32768 0</Font4>
        <Font5>_ 0 400 0 32512 0</Font5>
        <Font6>_ 0 400 0 0 0</Font6>
        <Font7>_ 0 400 0 0 0</Font7>
        <Font8>_ 0 400 0 0 0</Font8>
        <Font9>_ 0 400 0 32512 0</Font9>
        <Font10>_ 0 400 0 32512 0</Font10>
        <Font11>_ 0 400 0 32768 0</Font11>
        <Font12>_ 0 400 0 32768 0</Font12>
        <Font13>_ 0 700 0 0 1</Font13>
        <Font14>_ 0 400 0 10485760 0</Font14>
        <FontsEx>_ 0 0 0 0 0 0 0 16777215 0</FontsEx>
        <Fonts>_ -17 400 3 2 1 49 "Courier New" 15</Fonts>
        <IndentSize>_ 4</IndentSize>
        <TabSize>_ 8</TabSize>
        <AutoIndent>_ 1</AutoIndent>
        <BraceIndent>_ 0</BraceIndent>
        <BodyIndent>_ 2</BodyIndent>
        <LabelIndent>_ 0</LabelIndent>
        <RealTabs>_ 0</RealTabs>
        <SyntaxHLight>_ 1</SyntaxHLight>
        <ShowBookmarks>_ 1</ShowBookmarks>
        <ShowLineNumbers>_ 1</ShowLineNumbers>
        <ShowFoldsMargin>_ 1</ShowFoldsMargin>
        <ScanForChangedFiles>_ 1</ScanForChangedFiles>
        <VirtualSpace>_ 0</VirtualSpace>
        <CmdLineApp>_ ""</CmdLineApp>
        <CmdLineArgs>_ ""</CmdLineArgs>
        <DdeApp>_ ""</DdeApp>
        <DdeServiceName>_ ""</DdeServiceName>
        <FindFlags>_ 6</FindFlags>
        <LineBreakUsage>_ 0</LineBreakUsage>
        <TrimTrailingBlanks>_ 0</TrimTrailingBlanks>
        <UseUserKeyWordFile>_ 0</UseUserKeyWordFile>
        <UserKeyWordFile>_ ""</UserKeyWordFile>
        <UseCodeTemplates>_ 1</UseCodeTemplates>
        <CodeTemplateFile>_ "C:\Users\Administrator\AppData\Roaming\IAR Embedded Workbench\CodeTemplates.ENU.txt"</CodeTemplateFile>
        <ShowRightMargin>_ 1</ShowRightMargin>
        <UsePrinterMargin>_ 0</UsePrinterMargin>
        <RightMarginPos>_ 80</RightMarginPos>
        <AutoCompletion>_ 1</AutoCompletion>
        <AutoDetectEncoding>_ 0</AutoDetectEncoding>
        <DefaultEncoding>_ "System"</DefaultEncoding>
        <ShowLineBreaks>_ 0</ShowLineBreaks>
        <ShowSourceBrowserToolTips>_ 1</ShowSourceBrowserToolTips>
        <ShowVisibleWhitespace>_ 0</ShowVisibleWhitespace>
        <SyntaxHighlightRubyFiles>_ 1</SyntaxHighlightRubyFiles>
        <DdeCmdStr>_ 0</DdeCmdStr>
    </TextEditor>
    <DontAskAgain>
        <hidden>_ 0</hidden>
    </DontAskAgain>
    <RecentWorkspace>
        <PathE--Program-Files-_x86_-IAR-Systems-common-bin-IarIdePm.exe>C:\Users\Administrator\Desktop\cc2530\qq\ED_ZStack-2.5.1a\Projects\zstack\Utilities\SerialApp\CC2530DB\SerialApp.eww</PathE--Program-Files-_x86_-IAR-Systems-common-bin-IarIdePm.exe>
    </RecentWorkspace>
    <DebugOptions>
        <UseColors>_ 1</UseColors>
        <GlobalIntegerFormat>_ 2</GlobalIntegerFormat>
        <MemoryWindowUpdateInterval>_ 1000</MemoryWindowUpdateInterval>
        <UpdateInterval>_ 1000</UpdateInterval>
        <StlDepth>_ 10</StlDepth>
        <StepMode>_ 1</StepMode>
        <SrcClr>_ 0 0 0 0</SrcClr>
        <SrcClrAuto>_ 1</SrcClrAuto>
        <AlwaysPickAllInstances>_ 0</AlwaysPickAllInstances>
    </DebugOptions>
    <AutoStep>
        <AutoMode>0</AutoMode>
        <AutoTime>1000</AutoTime>
    </AutoStep>
    <FindInFiles>
        <MatchCase>0</MatchCase>
        <WholeWord>0</WholeWord>
        <MatchRegExp>0</MatchRegExp>
        <AllProjInWorkspace>0</AllProjInWorkspace>
        <LookInSubdirs>1</LookInSubdirs>
        <LookWhereSelection>0</LookWhereSelection>
        <RecentDirSelection>4294967295</RecentDirSelection>
        <RecentDir0 />
        <RecentDir1 />
        <RecentDir2 />
        <RecentDir3 />
        <RecentDir4 />
        <RecentFiter0 />
        <RecentFiter1 />
        <RecentFiter2 />
        <RecentFiter3 />
        <FilterSelection>0</FilterSelection>
    </FindInFiles>
    <GlobalOptionsSection>
        <GlobalOptionsPageKey>Language</GlobalOptionsPageKey>
    </GlobalOptionsSection>
    <EditorType>
        <Type>_ 0</Type>
    </EditorType>
    <DDEEditor>
        <DdeApp>_ ""</DdeApp>
        <DdeService>_ ""</DdeService>
        <DdeNumCmdString>_ 0</DdeNumCmdString>
    </DDEEditor>
    <CmdLineEditor>
        <Application>_ ""</Application>
        <Arguments>_ ""</Arguments>
    </CmdLineEditor>
</settings>

读者可以复制到自己的工程里面去

参考链接: 参考文章

上一篇:js 判断闰年


下一篇:struts2中错误There is no Action mapped for namespace [/] and action name [] associated with context path