简体   繁体   English

如何在图形中为一个顶点插入settooltiptext?

[英]how to insert settooltiptext for one vertex in a graph?

I would like to move the mouse over an vertex which was plotted on a JFrame using JUng class and displaying some additional message for that vertex. 我想将鼠标移到使用JUng类绘制在JFrame上的顶点上,并显示该顶点的其他消息。 But I don't know how to set setToolTipText for a vertex. 但是我不知道如何为顶点设置setToolTipText。 Is there any way? 有什么办法吗? please help me with this 请在这件事上给予我帮助

You can add the following command to insert setToolTipbox to your graph 您可以添加以下命令以将setToolTipbox插入图形中

vv.setToolTipText("<html><center>Breast Neoplasms<p>"
            + "Gene interactions</p> </center></html>");

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

相关问题 在图内插入顶点 - Insert vertex inside a Graph Java-如何为JFrame设置setToolTipText - Java- How to set setToolTipText for JFrame 如何知道我的图中是否存在顶点? - How to know whether a vertex exists in my graph? 如何在图中找到特定顶点的度数? - How to find the degree of a particular vertex in graph? 如何使用Java查找图的中心(顶点,该顶点与其他每个顶点相连,但边指向图的中心) - how to Find the center of graph (vertex, that is connected with every other vertex, but edges are directed to the center of graph) with java 将 Vertex[] 转换为图形 - Converting Vertex[] to graph 如何在Titan Graph数据库中使用Java API在新顶点和现有顶点之间创建边 - how to create edge between new vertex and existing vertex using Java API in Titan Graph database 如何在来自特定顶点的有向图中执行 BFS 或 DFS,某些顶点的出度为 0? - How to do a BFS or DFS in directed graph from particular vertex with some vertex having outdegree 0? 如何以tinkerpop / gremlin格式而不是DSE图形格式返回Vertex? - How to return a Vertex in the tinkerpop/gremlin format instead of the DSE graph format? Jung Java Graph如何在视图中设置顶点的ID - Jung Java Graph How to set ID on vertex in view
 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM