我在Emacs 24.3.1上.我安装了MELPA版本的plantuml-modevia
M-x package-install RET plantuml-mode RET.
当我尝试打开plantuml-mode缓冲区时,出现以下错误:
Wrong type argument: stringp, nil
Run Code Online (Sandbox Code Playgroud)
试图找到其他安装说明,我查看了plantuml-mode.el源代码中的"评论"部分,但它只是require对包说,我正在这样做.
我该如何解决这个问题?
我们可以在块中应用不同的Align方向吗?(正如标题所说)
例如,在状态图中:
State_1和State_2都有两个内部状态State_1.x和State_2.y(x = 1..2,y = 1..2)
@startuml
[*] --> State_1
State_1 --> State_2
state State_1 {
left to right direction
[*] --> State_1.1
[*] --> State_1.2
}
state State_2 {
top to bottom direction
[*] --> State_2.1
[*] --> State_2.2
}
@enduml
Run Code Online (Sandbox Code Playgroud)
我已经尝试过上面的代码,它不起作用.我们可以限制命令"从上到下"的影响区域吗?
我也尝试了以下代码.
@startuml
[*] --> State_1
State_1 --> State_2
state State_1 {
/‘not good..'/
[*] -> State_1.1
[*] -> State_1.2
[*] -> State_1.3
/‘not good either'/
[*] -right-> State_1.1
[*] -right-> State_1.2
[*] -right-> State_1.3 …Run Code Online (Sandbox Code Playgroud) 我不知道任何Ruby,但我喜欢asciidoctor(和gradle插件)。有没有一种简单的方法来使插件生成Plantuml图?
我查看了基本的asciidoctor-diagrams功能,该功能似乎特定于使用本机/红宝石asciidoctor扩展(我没有,并且因为我喜欢使用gradle插件而不想安装)。
做得很好的asciidoctor-gradle-plugin文档页面显示,它接受requiresRuby模块的选项,但是在Ruby中没有任何基础,我不确定这是否是我需要的。
我尝试了阻力最小的路径,即:
asciidoctor {
logDocuments = true
separateOutputDirs = false
sourceDir = file("src")
outputDir = file("$buildDir/html")
backends = [ 'html5' ]
requires "asciidoctor-diagram"
}
Run Code Online (Sandbox Code Playgroud)
针对我的基本plantuml测试:
.The PlantUML block extension class
[plantuml, sample-plantuml-diagram, alt="Class diagram", width=135, height=118]
----
class BlockProcessor
class PlantUmlBlock
BlockProcessor <|-- PlantUmlBlock
----
Run Code Online (Sandbox Code Playgroud)
但是得到了:
* What went wrong:
Execution failed for task ':asciidoctor'.
> (LoadError) no such file to load -- asciidoctor-diagram
Run Code Online (Sandbox Code Playgroud)
在配置阶段。
如何配置asciidoctor-gradle-plugin以处理植物?
据我所知,PlantUML 自动检测给定文档的图类型(序列图、用例图、类图、活动图等)。这似乎工作得相当好,但我有时发现在编辑图表时我会做出一些看似很小的更改,突然我的活动图变成了类图(例如)。
我想以某种方式告诉 PlantUML 图类型是什么,如果语法对所选的图类型无效,则编译失败,但我在 PlantUML 文档中找不到类似的内容。是否存在这样的图表类型标识符?
有没有办法在图表结束之前结束序列图中参与者的行?例如,如果我想显示数据库存储过程如何相互调用:
@startuml
participant SP0
SP0 -> SP0 : Do minor stuff
create participant SP2
SP0 -> SP2 : Exec SP2
SP2 -> SP2 : Insert into table Tbl
SP2 -> SP2 : Do other stuff
SP2 -> SP0
SP0 -> SP0 : Do minor stuff
@enduml
Run Code Online (Sandbox Code Playgroud)
我想在 SP2 将处理返回到 SP0 后立即终止它的线路。此外,如果我稍后从 SP0 调用一个复杂的过程 SP3,我想将它垂直放置在与 SP2 相同的级别上。
我可以删除页脚,hide footbox但该行仍然保留在那里。另外activate,destroy不要结束这一行。
谢谢!
我正在尝试使用 Plantuml 组件图构建“硬件架构”图,但我正在努力解决布局问题。
我的图表变得非常复杂,我注意到 Plantuml 不断从左到右添加框架,使图表水平增长。
例如从这个代码
@startuml
' -----------------------------------------------------
skinparam defaultTextAlignment center
' -----------------------------------------------------
top to bottom direction
frame Pippo as pippo {
frame "Pippo Deploy" {
node "xxx1\nfoo" <<windows 7>>
}
frame "Pippo Core" {
node "===xxx2\nbar" <<amiga>>
node "===xxx2\nbar" <<amiga>>
node "===xxx3\nbar" <<amiga>>
node "===xxx4\nbar" <<amiga>>
node "===xxx5\nbar" <<amiga>>
node "===xxx6\nbar" <<amiga>>
node "===xxx7\nbar" <<amiga>>
}
frame "Pippo Additional Servers" {
node "===xxx8\nfoo" <<windows 7>>
node "===xxx9\nfoo" <<windows 7>>
node "===xxx10\nfoo" <<windows 7>>
node "===xxx11\nfoo" <<windows 7>> …Run Code Online (Sandbox Code Playgroud) https://github.com/KevReed/DocFx.Plugins.PlantUml
我通过nuget为docfx插件安装了plantUml.通过nuget install DocFx.Plugins.PlantUml -ExcludeVersion -OutputDirectory .命令,之后我在构建docfx之后获得了这个结果,并且我在localhost上检查了index.html但它没有用.我看不到plantuml图只有带文字的纯文本.如果您有任何想法,请帮助我.我检查了<code class="lang-plantuml">builed html上的标签.
这是我的环境.
macOS Sierra 10.12.6
NuGet Version: 4.7.0.5148
docfx Version: 2.38.1.0
Run Code Online (Sandbox Code Playgroud)
[路径]
(projectfolder)/docfx.json
(projectfolder)/plantuml.jar
(projectfolder)/DocFx.Plugins.PlantUml
Run Code Online (Sandbox Code Playgroud)
[docfx.json]
{
"metadata": [
{
"src": [
{
"files": [
"**/**.cs"
],
"src":"../localizedstring"
}
],
"dest": "api",
"disableGitFeatures": false,
"disableDefaultFilter": false
}
],
"build": {
"content": [
{
"files": [
"api/**.yml",
"api/index.md"
]
},
{
"files": [
"articles/**.md",
"articles/**/toc.yml",
"toc.yml",
"*.md"
]
}
],
"resource": [
{
"files": [
"images/**"
]
}
], …Run Code Online (Sandbox Code Playgroud) 我已经在Windows的Visual Studio Code中安装了PlantUML扩展(由jebbs开发),并且对于序列图来说一切都工作正常。
但是,当我尝试呈现一个类图时,我得到消息:
点可执行文件:\ opt \ local \ bin \ dot
文件不存在
找不到Graphviz
完整错误消息的屏幕截图:
当我尝试@startuml testdot @enduml指定的示例代码时,出现以下错误:
环境变量GRAPHVIZ_DOT已设置为/ opt / local / bin / dot。
点可执行文件为\ opt \ local \ bin \ dot
完整错误消息的屏幕截图:
有什么想法可以指定它,以便我可以覆盖它(假设这是问题所在)?我尚未看到它尚未添加到系统或用户环境变量中的信息。
I\xc2\xb4m 在 PlantUML 中有一个图表(在 VSCode@Windows 10 中编辑)并且有一个
\n!include https://raw.githubusercontent.com/plantuml-stdlib/C4-PlantUML/master/C4_Deployment.puml\nRun Code Online (Sandbox Code Playgroud)\n在里面。Im\xc2\xb4m 有插件
\nPlantUML\nv2.16.0\nRun Code Online (Sandbox Code Playgroud)\n安装并现在尝试用它预览它。我\xc2\xb4m 得到的是一个错误
\nCannot open URL https://raw.githubusercontent.com/plantuml-stdlib/C4-PlantUML/master/C4_Deployment.puml\nRun Code Online (Sandbox Code Playgroud)\n当我通过 VSCode 终端卷曲该地址时,我\xc2\xb4m 得到结果。VSCode 设置
\nUse the proxy support for extensions.\nRun Code Online (Sandbox Code Playgroud)\n已开启
\n\n\n“覆盖”
\n
由于 I\xc2\xb4m 在公司环境中工作,我指定
\n"plantuml.commandArgs": [\n "-Dhttp_proxy='http://localhost:3128/'",\n "-Dhttps_proxy='http://localhost:3128/'"\n ]\nRun Code Online (Sandbox Code Playgroud)\n在插件设置中(这在我的环境中是正确的)
\n我还能尝试什么?
\nPlantUML 中切换箭头方向的语法很清晰。可以使用 -left->、-right->、-up->、-down-> 分别实现左、右、上、下方向性。该文档同样清楚地表明,在语法上可以通过增加 UML 代码中箭头中的虚线数量来增加渲染时箭头的长度(例如 --> 增加为 ---> 或 ----> )。
当还包含方向性时,这似乎不起作用(至少在 Jebbs 的 Visual Studio Code 扩展中)。因此,例如 -left---> 不会增加箭头的长度。这是预期的行为吗?
plantuml ×10
uml ×2
asciidoctor ×1
c# ×1
docfx ×1
emacs ×1
gradle ×1
graph ×1
graphviz ×1
installation ×1
major-mode ×1
ruby ×1
windows ×1