Skip to content

Commit 0997ba6

Browse files
committed
enh var fact printing
1 parent 9859647 commit 0997ba6

File tree

1 file changed

+16
-11
lines changed

1 file changed

+16
-11
lines changed

src/services/CustomPrinting.jl

Lines changed: 16 additions & 11 deletions
Original file line numberDiff line numberDiff line change
@@ -30,7 +30,10 @@ function printVariable( io::IO, vert::DFGVariable;
3030
end
3131
vnd = getSolverData(vert, :default)
3232
println(ioc, " timestamp: ", vert.timestamp)
33-
println(ioc, " label: ", vert.label)
33+
println(ioc, " nstime: ", vert.nstime)
34+
print(ioc, " label: ")
35+
printstyled(ioc, vert.label, bold=true)
36+
println(ioc)
3437
println(ioc, " solvable: ", getSolvable(vert))
3538
println(ioc, " tags: ", getTags(vert))
3639
solk = listSolveKeys(vert) |> collect
@@ -105,20 +108,22 @@ function printFactor( io::IO, vert::DFGFactor;
105108
opmemt = (getSolverData(vert).fnc |> typeof).name
106109
fct = getFactorType(vert)
107110
fctt = fct |> typeof
108-
printstyled(ioc, typeof(vert).name, "{",opmemt,"{",fctt.name,"...}}","\n", bold=true)
109-
println(ioc, " timestamp: ", vert.timestamp)
110-
println(ioc, " nstime: ",vert.nstime)
111-
println(ioc, " label: ", vert.label)
112-
println(ioc, " solvable: ", vert.solvable)
111+
printstyled(ioc, typeof(vert).name.name, "{",opmemt,"{",fctt.name.name,"...}}","\n", bold=true)
112+
println(ioc, " timestamp: ", vert.timestamp)
113+
println(ioc, " nstime: ", vert.nstime)
114+
print(ioc, " label: ")
115+
printstyled(ioc, vert.label, bold=true)
116+
println(ioc)
117+
println(ioc, " solvable: ", vert.solvable)
113118
println(ioc, " VariableOrder: ", vert._variableOrderSymbols)
114-
println(ioc, " multihypo: ", getSolverData(vert).multihypo) # FIXME #477
115-
println(ioc, " nullhypo: ", getSolverData(vert).nullhypo)
116-
println(ioc, " tags: ", vert.tags)
117-
printstyled(ioc, " TYPE: ", bold=true, color=:blue)
119+
println(ioc, " multihypo: ", getSolverData(vert).multihypo) # FIXME #477
120+
println(ioc, " nullhypo: ", getSolverData(vert).nullhypo)
121+
println(ioc, " tags: ", vert.tags)
122+
printstyled(ioc, " FactorType: ", bold=true, color=:blue)
118123
println(ioc, fctt)
119124
# show(ioc, fctt)
120125
for f in setdiff(fieldnames(fctt), skipfields)
121-
printstyled(ioc, f,":\n", color=:blue)
126+
printstyled(ioc, f,":\n", color=:magenta)
122127
show(ioc, getproperty(fct, f))
123128
println(ioc)
124129
end

0 commit comments

Comments
 (0)