Skip to content
GitLab
Menu
Projects
Groups
Snippets
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
Menu
Open sidebar
Benoit Barbot
GraphEditor
Commits
d6bd354b
Commit
d6bd354b
authored
Jun 23, 2021
by
Benoît Barbot
Browse files
improve_layout
parent
6ecf231b
Changes
2
Hide whitespace changes
Inline
Side-by-side
editor/graphDrawing.ml
View file @
d6bd354b
...
...
@@ -467,7 +467,7 @@ let rec html_of_attr s attr nattr cb =
td
[
color_input
~
on_change
:
(
callback
id
v
)
str
];
td
[
delbutton
]]
)
attr
in
let
new_attr
=
tr
[
td
[
choice_input
~
init_value
:
(
Some
"New Attribute"
)
~
on_change
:
(
fun
x
->
cb
x
)
nattr
];
td
[]
]
in
let
new_attr
=
tr
[
td
~
colspan
:
2
[
choice_input
~
init_value
:
(
Some
"New Attribute"
)
~
on_change
:
(
fun
x
->
cb
x
)
nattr
];
td
[]
;
]
in
(
attr_tr
@
(
if
nattr
<>
[]
then
[
new_attr
]
else
[]
))
and
set_selected
s
sobj
mouse_pos
=
...
...
editor/utilsWeb.ml
View file @
d6bd354b
...
...
@@ -26,9 +26,12 @@ let tr ?id items =
List
.
iter
(
append_node
tr
)
items
;
(
tr
:>
t
)
let
td
?
id
items
=
let
td
?
colspan
?
id
items
=
let
td
=
Dom_html
.(
createTd
document
)
in
(
match
id
with
None
->
()
|
Some
ids
->
td
##.
id
:=
Js
.
string
ids
);
(
match
id
with
None
->
()
|
Some
ids
->
td
##.
id
:=
Js
.
string
ids
);
(
match
colspan
with
Some
x
->
td
##.
colSpan
:=
x
|
None
->
()
);
List
.
iter
(
append_node
td
)
items
;
(
td
:>
t
)
...
...
Write
Preview
Supports
Markdown
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