Skip to content
GitLab
Explore
Sign in
Register
Primary navigation
Search or go to…
Project
gmsh
Manage
Activity
Members
Labels
Plan
Issues
Issue boards
Milestones
Wiki
Code
Merge requests
Repository
Branches
Commits
Tags
Repository graph
Compare revisions
Snippets
Build
Pipelines
Jobs
Pipeline schedules
Artifacts
Deploy
Releases
Model registry
Operate
Environments
Monitor
Incidents
Analyze
Value stream analytics
Contributor analytics
CI/CD analytics
Repository analytics
Model experiments
Help
Help
Support
GitLab documentation
Compare GitLab plans
Community forum
Contribute to GitLab
Provide feedback
Terms and privacy
Keyboard shortcuts
?
Snippets
Groups
Projects
Show more breadcrumbs
Larry Price
gmsh
Commits
8c3ee278
Commit
8c3ee278
authored
9 years ago
by
Christophe Geuzaine
Browse files
Options
Downloads
Patches
Plain Diff
remove leading white space in GetShortName
parent
ffcf60e9
No related branches found
No related tags found
No related merge requests found
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
Common/onelab.h
+4
-1
4 additions, 1 deletion
Common/onelab.h
with
4 additions
and
1 deletion
Common/onelab.h
+
4
−
1
View file @
8c3ee278
...
@@ -140,9 +140,12 @@ namespace onelab{
...
@@ -140,9 +140,12 @@ namespace onelab{
std
::
string
::
size_type
last
=
_name
.
find_last_of
(
'/'
);
std
::
string
::
size_type
last
=
_name
.
find_last_of
(
'/'
);
if
(
last
!=
std
::
string
::
npos
)
if
(
last
!=
std
::
string
::
npos
)
s
=
_name
.
substr
(
last
+
1
);
s
=
_name
.
substr
(
last
+
1
);
// remove starting white space
while
(
s
.
size
()
&&
s
[
0
]
==
' '
)
s
=
s
.
substr
(
1
);
// remove starting braces: can be used to order parameters 'from the end',
// remove starting braces: can be used to order parameters 'from the end',
// as the ASCII code is after numbers and letters
// as the ASCII code is after numbers and letters
while
(
s
.
size
()
&&
(
s
[
0
]
==
'}'
||
s
[
0
]
==
'{'
||
s
[
0
]
==
'{'
))
while
(
s
.
size
()
&&
(
s
[
0
]
==
'}'
||
s
[
0
]
==
'{'
))
s
=
s
.
substr
(
1
);
s
=
s
.
substr
(
1
);
// remove starting numbers: can be used to order parameters 'from the
// remove starting numbers: can be used to order parameters 'from the
// start'
// start'
...
...
This diff is collapsed.
Click to expand it.
Preview
0%
Loading
Try again
or
attach a new file
.
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Save comment
Cancel
Please
register
or
sign in
to comment