Rotating icons
Moderators: Developers, Moderators
Rotating icons
Hey,
Is it possible to rotate the icons?
Pozdrawiam
Gadzet21
Is it possible to rotate the icons?
Pozdrawiam
Gadzet21
- Howie
- Cacti Guru User
- Posts: 5508
- Joined: Thu Sep 16, 2004 5:53 am
- Location: United Kingdom
- Contact:
Re: Rotating icons
Not currently. What's your use-case? And do you mean by a few degrees or 90/180?
Weathermap 0.98a is out! & QuickTree 1.0. Superlinks is over there now (and built-in to Cacti 1.x).
Some Other Cacti tweaks, including strip-graphs, icons and snmp/netflow stuff.
(Let me know if you have UK DevOps or Network Ops opportunities, too!)
Some Other Cacti tweaks, including strip-graphs, icons and snmp/netflow stuff.
(Let me know if you have UK DevOps or Network Ops opportunities, too!)
- camerabob
- Cacti User
- Posts: 386
- Joined: Fri Feb 10, 2017 2:45 pm
- Location: Long Island, New York, USA
- Contact:
Re: Rotating icons
I believe the OP means taking a single icon and 'spinning' it x degrees.
Prod: Cacti 1.2.15 @ CentOS Linux release 7.9.2009 (Core) & PHP 5.4.16-48.el7
Maint @ 1.2
Monitor @ 2.3.6
Thold @ 1.2.4
Temp: Cacti 1.2.3 @ CentOS Linux release 7.9.2009 (Core) & PHP 5.4.16-48.el7
Flowview @ 2.1
Mactrack @ 4.2
Maint @ 1.2
Monitor @ 2.3.6
Router Configs @ 1.3.4
Syslog Monitoring @ 2.1
Thold @ 1.2.4
Maint @ 1.2
Monitor @ 2.3.6
Thold @ 1.2.4
Temp: Cacti 1.2.3 @ CentOS Linux release 7.9.2009 (Core) & PHP 5.4.16-48.el7
Flowview @ 2.1
Mactrack @ 4.2
Maint @ 1.2
Monitor @ 2.3.6
Router Configs @ 1.3.4
Syslog Monitoring @ 2.1
Thold @ 1.2.4
- Howie
- Cacti Guru User
- Posts: 5508
- Joined: Thu Sep 16, 2004 5:53 am
- Location: United Kingdom
- Contact:
Re: Rotating icons
I understood the word 'rotate'camerabob wrote:I believe the OP means taking a single icon and 'spinning' it x degrees.
But 90 degree increments look nicer, and are potentially easier. Rotating a bitmap by 3 degrees usually looks pretty crappy, especially without antialiasing.
And I'm still curious why - are they expecting it to rotate based on a value? or something else (e.g. just saving on having an up and down arrow)?
Weathermap 0.98a is out! & QuickTree 1.0. Superlinks is over there now (and built-in to Cacti 1.x).
Some Other Cacti tweaks, including strip-graphs, icons and snmp/netflow stuff.
(Let me know if you have UK DevOps or Network Ops opportunities, too!)
Some Other Cacti tweaks, including strip-graphs, icons and snmp/netflow stuff.
(Let me know if you have UK DevOps or Network Ops opportunities, too!)
Re: Rotating icons
Yes - exactly
Due to the increase in "links", I would like it to be more readable and apply arrows (in different colors) in the right direction.
Due to the increase in "links", I would like it to be more readable and apply arrows (in different colors) in the right direction.
- Howie
- Cacti Guru User
- Posts: 5508
- Joined: Thu Sep 16, 2004 5:53 am
- Location: United Kingdom
- Contact:
Re: Rotating icons
But the questions:gadzet21 wrote:Yes - exactly
Due to the increase in "links", I would like it to be more readable and apply arrows (in different colors) in the right direction.
1) At any angle? (sounds like yes)
2) Varying based on current data?
If you are literally talking about arrows, you can probably achieve it right now with oneway links.
Weathermap 0.98a is out! & QuickTree 1.0. Superlinks is over there now (and built-in to Cacti 1.x).
Some Other Cacti tweaks, including strip-graphs, icons and snmp/netflow stuff.
(Let me know if you have UK DevOps or Network Ops opportunities, too!)
Some Other Cacti tweaks, including strip-graphs, icons and snmp/netflow stuff.
(Let me know if you have UK DevOps or Network Ops opportunities, too!)
- camerabob
- Cacti User
- Posts: 386
- Joined: Fri Feb 10, 2017 2:45 pm
- Location: Long Island, New York, USA
- Contact:
Re: Rotating icons
Sorry, but it may have been ambiguous with rotating between a number of images.Howie wrote:I understood the word 'rotate'camerabob wrote:I believe the OP means taking a single icon and 'spinning' it x degrees.
Crappy is an understatementHowie wrote:But 90 degree increments look nicer, and are potentially easier. Rotating a bitmap by 3 degrees usually looks pretty crappy, especially without antialiasing.
Prod: Cacti 1.2.15 @ CentOS Linux release 7.9.2009 (Core) & PHP 5.4.16-48.el7
Maint @ 1.2
Monitor @ 2.3.6
Thold @ 1.2.4
Temp: Cacti 1.2.3 @ CentOS Linux release 7.9.2009 (Core) & PHP 5.4.16-48.el7
Flowview @ 2.1
Mactrack @ 4.2
Maint @ 1.2
Monitor @ 2.3.6
Router Configs @ 1.3.4
Syslog Monitoring @ 2.1
Thold @ 1.2.4
Maint @ 1.2
Monitor @ 2.3.6
Thold @ 1.2.4
Temp: Cacti 1.2.3 @ CentOS Linux release 7.9.2009 (Core) & PHP 5.4.16-48.el7
Flowview @ 2.1
Mactrack @ 4.2
Maint @ 1.2
Monitor @ 2.3.6
Router Configs @ 1.3.4
Syslog Monitoring @ 2.1
Thold @ 1.2.4
Re: Rotating icons
Goog idea.If you are literally talking about arrows, you can probably achieve it right now with oneway links
I used:
Code: Select all
NODE ...
LABELOUTLINECOLOR none
ICON 10 10 images/ball-green.png
LABELOFFSET -5 -5
LINK ...
ARROWSTYLE classic
LINKSTYLE oneway
This solution is OK - thank you for the hint.
- Attachments
-
- cacti-weathermap.jpg (271.91 KiB) Viewed 2522 times
- Howie
- Cacti Guru User
- Posts: 5508
- Joined: Thu Sep 16, 2004 5:53 am
- Location: United Kingdom
- Contact:
Re: Rotating icons
So two other things that you may not know:
1) You can use angled links instead of curved ones, so that they turn sharply (at 90 degrees if you place the VIA well)
2) You can adjust where the ends of the link start, relative to the node:
So that the end at the bigger node starts 10 pixels to the left, and 10 down from the centre of the node. With a bit of basic maths, you can make a series of parallel links coming from the side of the node this way.
Here's a quick demo of that:
1) You can use angled links instead of curved ones, so that they turn sharply (at 90 degrees if you place the VIA well)
2) You can adjust where the ends of the link start, relative to the node:
Code: Select all
LINK link1
NODES bignode:10:10 smallnode
VIASTYLE angled
LINKSTYLE oneway
VIA 300 4000
Here's a quick demo of that:
Code: Select all
WIDTH 300
HEIGHT 300
LINK DEFAULT
WIDTH 3
VIASTYLE angled
LINKSTYLE oneway
BWFONT 1
NODE big
POSITION 100 200
ICON images/WorkgroupSwitch.png
NODE small1
POSITION 200 100
ICON 16 16 images/green-ball-64.png
NODE small2
POSITION 220 100
ICON 16 16 images/green-ball-64.png
NODE small3
POSITION 240 100
ICON 16 16 images/green-ball-64.png
NODE small4
POSITION 260 100
ICON 16 16 images/green-ball-64.png
LINK l1
NODES big:40:-20 small1
VIA 200 180
# via X matches small1's X
# via Y matches big's X + the Y offset of -20
LINK l2
NODES big:40:-10 small2
VIA 220 190
LINK l3
NODES big:40:10 small3
VIA 240 210
LINK l4
NODES big:40:20 small4
VIA 260 220
- Attachments
-
- weathermap.png (5.01 KiB) Viewed 2514 times
Weathermap 0.98a is out! & QuickTree 1.0. Superlinks is over there now (and built-in to Cacti 1.x).
Some Other Cacti tweaks, including strip-graphs, icons and snmp/netflow stuff.
(Let me know if you have UK DevOps or Network Ops opportunities, too!)
Some Other Cacti tweaks, including strip-graphs, icons and snmp/netflow stuff.
(Let me know if you have UK DevOps or Network Ops opportunities, too!)
Re: Rotating icons
I am so going to be tapping into your expertise once the 1.x version is ready
Cacti Developer & Release Manager
The Cacti Group
Director
BV IT Solutions Ltd
+--------------------------------------------------------------------------+
Cacti Resources:
Cacti Website (including releases)
Cacti Issues
Cacti Development Releases
Cacti Development Documentation
The Cacti Group
Director
BV IT Solutions Ltd
+--------------------------------------------------------------------------+
Cacti Resources:
Cacti Website (including releases)
Cacti Issues
Cacti Development Releases
Cacti Development Documentation
Re: Rotating icons
Thanks Howie.
Through the last dynamic changes on the map, there was no time to do it. I will try to use your tips soon.
It is a pity that these functions are not available in the editor itself (but manually entered) - it would speed up the work.
Through the last dynamic changes on the map, there was no time to do it. I will try to use your tips soon.
It is a pity that these functions are not available in the editor itself (but manually entered) - it would speed up the work.
- Howie
- Cacti Guru User
- Posts: 5508
- Joined: Thu Sep 16, 2004 5:53 am
- Location: United Kingdom
- Contact:
Re: Rotating icons
They are. Just click on a link, and then the Edit button.gadzet21 wrote:Thanks Howie.
Through the last dynamic changes on the map, there was no time to do it. I will try to use your tips soon.
It is a pity that these functions are not available in the editor itself (but manually entered) - it would speed up the work.
It wouldn't be very hard to make a "make this a right-angled VIA" button actually, a bit like the existing Tidy option.
Weathermap 0.98a is out! & QuickTree 1.0. Superlinks is over there now (and built-in to Cacti 1.x).
Some Other Cacti tweaks, including strip-graphs, icons and snmp/netflow stuff.
(Let me know if you have UK DevOps or Network Ops opportunities, too!)
Some Other Cacti tweaks, including strip-graphs, icons and snmp/netflow stuff.
(Let me know if you have UK DevOps or Network Ops opportunities, too!)
Who is online
Users browsing this forum: No registered users and 5 guests