@Override
			public String getTooltip(MarkerLocation loc) {
				Bookmark[] bookmarks = bookmarkMgr.getBookmarks(loc.getAddr(), type);
				if (bookmarks == null) {
					return BookmarkNavigator.this.type;
				}
				StringBuilder buffy = new StringBuilder();
				for (int i = 0; i < bookmarks.length; i++) {
					if (i != 0) {
						buffy.append("<br>");
					}

					buffy.append(BookmarkNavigator.this.type);
					String cat = bookmarks[i].getCategory();
					if (!StringUtils.isBlank(cat)) {
						buffy.append(" [");
						buffy.append(HTMLUtilities.escapeHTML(cat));
						buffy.append("]");
					}
					buffy.append(": ");
					buffy.append(HTMLUtilities.escapeHTML(bookmarks[i].getComment()));
				}
				return buffy.toString();
			}
Handles navigation/display of bookmarks in the browser marker margins.
Ghidra/Features/Base/src/main/java/ghidra/app/plugin/core/bookmark/BookmarkNavigator.java