functionhas_graphprivate
logical function has_graph(site, id, title)
True if entity id has a graph titled title.
Arguments
| Name | Type | Intent | Attributes | Description |
|---|---|---|---|---|
| site | type(site_t) | in | the site | |
| id | integer | in | the entity | |
| title | character(len=*) | in | the title |
Result
| Name | Type | Attributes | Description |
|---|---|---|---|
| has_graph | logical |
Called by
Source
Show the code
logical function has_graph(site, id, title)
type(site_t), intent(in) :: site !! the site
integer, intent(in) :: id !! the entity
character(len=*), intent(in) :: title !! the title
integer :: k
has_graph = .false.
if (.not. allocated(site%graphs_of(id)%ids)) return
do k = 1, size(site%graphs_of(id)%ids)
associate (g => site%graphs%graphs(site%graphs_of(id)%ids(k)))
if (g%title == title .and. len(g%svg) > 0) has_graph = .true.
end associate
end do
end function has_graph