FazBrowse GitHub Viewer
|
Trending
|
URL:
|
Home
Tools:
[Download Repo ZIP]
[View Raw Code]
[Original HTTPS Page]
EmmyLuaCodeStyle/CodeService/src/LuaCodeStyleOptions.cpp at master · Endll/EmmyLuaCodeStyle · GitHub
Endll
EmmyLuaCodeStyle
Repository navigation
Code
Pull requests
Actions
Projects
Security and quality
Insights
Expand file tree
Breadcrumbs
EmmyLuaCodeStyle
/
CodeService
/
src
/
LuaCodeStyleOptions.cpp
Copy path
More file actions
More file actions
Latest commit
History
History
History
43 lines (40 loc) · 1.76 KB
Breadcrumbs
EmmyLuaCodeStyle
/
CodeService
/
src
/
LuaCodeStyleOptions.cpp
Copy path
File metadata and controls
43 lines (40 loc) · 1.76 KB
Raw
Copy raw file
Download raw file
Open symbols panel
Edit and raw actions
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
#
include
"
CodeService/LuaCodeStyleOptions.h
"
#
include
"
CodeService/FormatElement/MinLineElement.h
"
#
include
"
CodeService/FormatElement/KeepLineElement.h
"
#
include
"
CodeService/NameStyle/NameStyleRuleMatcher.h
"
std::string
GetIndentStyleName
(IndentStyle style)
{
switch
(style)
{
case
IndentStyle::Tab:
{
return
"
tab
"
;
}
case
IndentStyle::Space:
{
return
"
space
"
;
}
}
return
"
unknown
"
;
}
LuaCodeStyleOptions::LuaCodeStyleOptions
()
:
keep_line_after_if_statement(std::make_shared<MinLineElement>(
0
)),
keep_line_after_do_statement(std::make_shared<MinLineElement>(
0
)),
keep_line_after_while_statement(std::make_shared<MinLineElement>(
0
)),
keep_line_after_repeat_statement(std::make_shared<MinLineElement>(
0
)),
keep_line_after_for_statement(std::make_shared<MinLineElement>(
0
)),
keep_line_after_local_or_assign_statement(std::make_shared<KeepLineElement>()),
keep_line_after_function_define_statement(std::make_shared<KeepLineElement>(
1
)),
keep_line_after_expression_statement(std::make_shared<KeepLineElement>()),
local_name_define_style(std::make_shared<NameStyleRuleMatcher>(
"
Local
"
)),
function_param_name_style(std::make_shared<NameStyleRuleMatcher>(
"
Parameters
"
)),
function_name_define_style(std::make_shared<NameStyleRuleMatcher>(
"
Class and module method
"
)),
local_function_name_define_style(std::make_shared<NameStyleRuleMatcher>(
"
Local method
"
)),
table_field_name_define_style(std::make_shared<NameStyleRuleMatcher>(
"
Table field
"
)),
global_variable_name_define_style(std::make_shared<NameStyleRuleMatcher>(
"
Global
"
)),
module_name_define_style(std::make_shared<NameStyleRuleMatcher>(
"
Module
"
)),
require_module_name_style(std::make_shared<NameStyleRuleMatcher>(
"
Require module
"
)),
class_name_define_style(std::make_shared<NameStyleRuleMatcher>(
"
Class
"
))
{
}
Back
|
FazBrowse Home
|
New Git URL