#Rationale Version 130.55 can_be_loaded_by 120.53 uses_features_from 120.53 #-- Start of Prelude -- Node = None Views = [] Loading = True canSetScratchpadText = True if not CurrentFileFormat.IsLaterThan(130, 54): morphTarget = None if not CurrentFileFormat.IsLaterThan(130, 55): canSetScratchpadText = False def Create(type): global Node if morphTarget == None: Node = app.Create(type) else: Morph(morphTarget, type) Node = morphTarget return Node def CreateChild(parent, type): global Node Node = app.CreateChild(parent, type) return Node def CreateAnnotation(parent, type): global Node Node = app.CreateAnnotation(parent, type) return Node def SetText(text): app.SetText(Node, text) def SetEvaluation(evaluation): app.SetEvaluation(Node, evaluation) def SetTint(tint): app.SetTint(Node, tint) def StringToImage(guid, imageAsString): return app.StringToImage(guid, imageAsString) def Morph(node, flavor): global Node app.Morph(node, flavor) Node = node def GetFernViews(): global Views global View global Loading Views = [v for v in app.Views if v.TypeName == "FernView"] Loading = len(Views) == 0 if Loading: View = app.Gui.CreateView("FernView") Views = [ View ] def SetLocation(node, x, y): # if Loading: # View.SetLocation(node, x, y) # else: for v in Views: v.SetLocation(node, x, y) def SetOffset(offsetFrom, node, x, y): if Loading: View.SetOffset(offsetFrom, node, x, y) else: for v in Views: v.SetOffset(offsetFrom, node, x, y) def SetSize(node, width, height): if Loading: View.SetSize(node, width, height) else: for v in Views: v.SetSize(node, width, height) def ShowPrintPagePreview(show): if Loading: View.ShowPrintPagePreview(show, False) def SetBackgroundImage(image): if Loading: View.SetBackgroundImage(image, False) def SetOpacity(opacity): if Loading: View.SetOpacity(opacity) def SetSelection(node): if Loading: View.SetSelection(node) def SetScratchpadText(text): if canSetScratchpadText: app.Gui.SetScratchpadText(text) #-- End of Prelude -- map0_0 = Create("Claim") SetText("You should smoke cigarettes") SetEvaluation("Reject") map0_1 = CreateChild(map0_0, "Reason") SetText("Smoking is good for your health") SetEvaluation("MakesNoDifference") map0_2 = CreateChild(map0_1, "Basis") SetText("*Publication*\n\"Big Tobacco Company Marketing Report\", 1936") SetEvaluation("Reject") map0_3 = CreateAnnotation(map0_2, "Note") SetText("An untrustworthy, biased source that is many years out of date.") SetTint(3) map0_4 = CreateAnnotation(map0_1, "Note") SetText("Since we have no faith in the reason, it gives the position no support.") SetTint(3) map0_5 = CreateChild(map0_0, "Reason") SetText("Smoking makes you look more sophisticated") SetEvaluation("MakesNoDifference") map0_6 = CreateChild(map0_5, "Basis") SetText("*Quote*\n\"Smoking shows I'm a woman of the world\", Jayne Bombshell, Miss Hollywood 1942") SetEvaluation("Reject") map0_7 = CreateAnnotation(map0_6, "Note") SetText("We shouldn't agree that it makes you look sophisticated, just because Miss Hollywood 1942 said so.") SetTint(3) map0_8 = CreateAnnotation(map0_5, "Note") SetText("The basis gave nil support, and there don't seem to be any other reasons to accept this claim nowadays (though perhaps in 1942 quite a few people thought it was true).") SetTint(3) map0_9 = CreateChild(map0_0, "Reason") SetText("John enjoys smoking") SetEvaluation("MakesNoDifference") map0_10 = CreateChild(map0_9, "Basis") SetText("*Assertion*\nJohn said this earlier today") SetEvaluation("Accept") map0_11 = CreateAnnotation(map0_10, "Note") SetText("He's a reliable source of information about his own likes and dislikes.") SetTint(3) map0_12 = CreateAnnotation(map0_9, "Note") SetText("Although the basis is good, this isn't relevant for deciding what you should do - especially if John enjoys doing something silly or dangerous.") SetTint(3) map0_13 = CreateAnnotation(map0_0, "Note") SetText("We should reject the position as none of the reasons provide support for it.") SetTint(3) GetFernViews() SetLocation(map0_0, 736, -119) SetSize(map0_0, 156, 54) SetSize(map0_1, 156, 53) SetSize(map0_2, 115, 158) SetOffset(map0_2, map0_3, 250, -128) SetSize(map0_3, 161, 106) SetOffset(map0_1, map0_4, 249, 41) SetSize(map0_4, 167, 106) SetSize(map0_5, 200, 53) SetSize(map0_6, 193, 164) SetOffset(map0_6, map0_7, -131, -203) SetSize(map0_7, 259, 106) SetOffset(map0_5, map0_8, -199, 343) SetSize(map0_8, 156, 239) SetSize(map0_9, 165, 56) SetSize(map0_10, 101, 113) SetOffset(map0_10, map0_11, -169, -19) SetSize(map0_11, 204, 83) SetOffset(map0_9, map0_12, -209, 124) SetSize(map0_12, 229, 150) SetOffset(map0_0, map0_13, 221, 99) SetSize(map0_13, 156, 128) ShowPrintPagePreview(False)