!7 concept Distinction { S concept, cases; } module Distinctions > DynCRUD { *() { super(Distinction); } afterVisualize { replaceComponent(crud.tableSearcher.tfInput, func(JComponent c) -> JComponent { centerAndEastWithMargin(c, jbutton("Add distinction...", rThread { define(searchTerm()) })) }); onEnter(crud.tableSearcher.tfInput, rThread { define(searchTerm()) }); } void define(fS term) enter { final JTextField tfConcept = jtextfield(or2(term, dm_topInput())), tfCases = jtextfield(); showFormTitled("Add Rule", "Concept:", tfConcept, "Cases (use slashes):", tfCases, rThread { S concept = gtt(tfConcept), cases = gtt(tfCases); uniq_sync(Distinction, +concept, +cases); }); focus(nempty(term) ? tfCases : tfConcept); } }