Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
S
StarUML Evológica Plugin
Project
Project
Details
Activity
Releases
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
3
Merge Requests
3
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Registry
Registry
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
evologica
StarUML Evológica Plugin
Commits
180b792e
Commit
180b792e
authored
Nov 06, 2020
by
Jucelino Fonseca
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
ajustes e testes
parent
37ef70c6
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
32 additions
and
9 deletions
+32
-9
ituExplorerV2.pas
EvoUMLPlugin/src/ituExplorerV2.pas
+32
-9
No files found.
EvoUMLPlugin/src/ituExplorerV2.pas
View file @
180b792e
...
...
@@ -181,7 +181,7 @@ type
//
function
RetirarPalavraChaveOLQ
(
piSynEdit
:
TSynEdit
;
opEve
:
TFaOpenEvent
):
string
;
function
IsKeyword
(
piItem
:
string
):
boolean
;
function
GetTextBetweenWord
(
piSynEdit
:
TSynEdit
;
piWord
:
string
)
:
string
;
function
GetTextBetweenWord
(
piSynEdit
:
TSynEdit
;
piWord
Pos
:
TPoint
;
piWord
:
string
)
:
string
;
protected
procedure
CreateParams
(
var
Params
:
TCreateParams
);
override
;
...
...
@@ -1220,11 +1220,13 @@ var lWord,
ls_espaco
,
ls_aux
:
string
;
li_Pos
:
integer
;
p2
,
p1
,
zeroPoint
:
TPoint
;
begin
result
:=
''
;
lWord
:=
trim
(
piSynEdit
.
GetWordAtRowCol
(
piSynEdit
.
PrevWordPos
));
lText
:=
GetTextBetweenWord
(
piSynEdit
,
lWord
);
p2
:=
piSynEdit
.
PrevWordPos
;
lWord
:=
trim
(
piSynEdit
.
GetWordAtRowCol
(
p2
));
lText
:=
GetTextBetweenWord
(
piSynEdit
,
p2
,
lWord
);
if
not
IsKeyword
(
lWord
)
then
begin
if
(
opEve
=
fopEvenSelectCompleto
)
or
...
...
@@ -1344,18 +1346,39 @@ begin
end
;
function
TExplorerV2
.
GetTextBetweenWord
(
piSynEdit
:
TSynEdit
;
piWord
:
string
):
string
;
var
p1
:
TPoint
;
li_Pos
:
integer
;
function
TExplorerV2
.
GetTextBetweenWord
(
piSynEdit
:
TSynEdit
;
piWord
Pos
:
TPoint
;
piWord
:
string
):
string
;
var
p1
,
p2
:
TPoint
;
//
li_Pos : integer;
begin
li_Pos
:=
Pos
(
piWord
,
piSynEdit
.
LineText
);
if
trim
(
piWord
)
=
''
then
begin
p1
:=
piWordPos
;
p2
:=
piSynEdit
.
CaretXY
;
result
:=
''
;
while
(
result
=
''
)
and
(
p1
.
Y
>
0
)
do
begin
p1
.
Y
:=
p1
.
Y
-
1
;
result
:=
piSynEdit
.
TextBetweenPoints
[
p1
,
p2
];
end
;
end
else
begin
p1
:=
piWordPos
;
p2
:=
piSynEdit
.
CaretXY
;
if
p2
.
Y
<>
p1
.
Y
then
begin
p1
.
X
:=
p1
.
X
-
Length
(
piWord
);
end
;
result
:=
piSynEdit
.
TextBetweenPoints
[
p1
,
p2
];
end
;
{li_Pos := Pos(piWord,piSynEdit.LineText);
p1 := piSynEdit.CaretXY;
if li_pos > 0 then
begin
p1.X:= li_Pos;
end;
result
:=
piSynEdit
.
TextBetweenPoints
[
p1
,
piSynEdit
.
CaretXY
];
result := piSynEdit.TextBetweenPoints[p1, piSynEdit.CaretXY]; }
end
;
procedure
TExplorerV2
.
CreateParams
(
var
Params
:
TCreateParams
);
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment