subroutineexplained_badgeprivate
subroutine explained_badge(text, explanation, b)
Write text as a badge, with an explanation for when the pointer is over it.
Arguments
| Name | Type | Intent | Attributes | Description |
|---|---|---|---|---|
| text | character(len=*) | in | the attribute | |
| explanation | character(len=*) | in | what it means | |
| b | type(buffer_t) | inout | the HTML |
Calls
Source
Show the code
subroutine explained_badge(text, explanation, b)
character(len=*), intent(in) :: text !! the attribute
character(len=*), intent(in) :: explanation !! what it means
type(buffer_t), intent(inout) :: b !! the HTML
type(buffer_t) :: item
character(len=:), allocatable :: html
call badge(text, item)
call take(item, html)
call add(b, html(:index(html, '>') - 1)//' title="'//explanation//'"'//html(index(html, '>'):))
end subroutine explained_badge