Board index Themes subtome icon replacement

Skinning and designing Serendipity (CSS, HTML, Smarty)
User avatar
Don Chambers
Regular
 
Posts: 3574
Joined: Mon Feb 13, 2006 3:40 am
Location: Chicago, IL, USA

Postby Don Chambers » Wed Mar 04, 2015 6:37 am

We have the ability to replace the xml icon by simply placing a replacement in /templates/yourtheme/img/xml.gif. (or I think we did have this ability). I cannot do this with the subtome icon, which seems to be hardcoded to 2k11.

Am I doing something wrong by simply placing a replacement subtome.png in the template's img folder, or is this not implemented the same way xml icons were?

EDIT: Now that I am looking at it, it seems the category list icons are also hard coded to 2k11... or am I mistaken?

User avatar
yellowled
Regular
 
Posts: 6815
Joined: Fri Jan 13, 2006 12:46 pm
Location: Eutin, Germany

Postby yellowled » Wed Mar 04, 2015 10:15 am

Don Chambers wrote:We have the ability to replace the xml icon by simply placing a replacement in /templates/yourtheme/img/xml.gif. (or I think we did have this ability). I cannot do this with the subtome icon, which seems to be hardcoded to 2k11.

It's not. The subtome icon was placed in 2k11's img folder (don't remember why), but there is no reference to it in 2k11's tpl or CSS files.

To replace that icon, the path to it needs to be changed in the syndication plugin's config.

Don Chambers wrote:Now that I am looking at it, it seems the category list icons are also hard coded to 2k11... or am I mistaken?

Same here, the path to the icon needs to be changed in the plugin's config. I'm pretty sure it's always been that way.

YL
amazon Wishlist - Serendipity-Podcast (German only, sorry)

User avatar
Don Chambers
Regular
 
Posts: 3574
Joined: Mon Feb 13, 2006 3:40 am
Location: Chicago, IL, USA

Postby Don Chambers » Wed Mar 04, 2015 3:06 pm

yellowled wrote:Same here, the path to the icon needs to be changed in the plugin's config. I'm pretty sure it's always been that way.


freetag definitely uses a template's rss icon if it exists as /templates/mytemplate/img/xml.gif. I thought for sure the categories plugin did the same thing at some point in the past, but perhaps we just substituted the image using css (ie, bulletproof).

If the category plugin never did recognize a template's rss icon, I personally feel it should. The same goes for subtome icon. Anyone up for implementing this, or am I the only one that thinks it would be a good idea?

User avatar
yellowled
Regular
 
Posts: 6815
Joined: Fri Jan 13, 2006 12:46 pm
Location: Eutin, Germany

Postby yellowled » Wed Mar 04, 2015 3:29 pm

Don Chambers wrote:If the category plugin never did recognize a template's rss icon, I personally feel it should. The same goes for subtome icon. Anyone up for implementing this, or am I the only one that thinks it would be a good idea?

I'm pretty sure we're going to need even more flexibility for these in the near future. As of now, the possibilities are either providing a raster image (GIF/PNG) and users having to switch or providing a .tpl files (if supported by the sidebar plugin) and users having to switch that.

If a theme author wants to provide anything but a raster image, they pretty much have to got the .tpl way already. For example, if a theme should use iconfont icons here. Or SVG icons. Or background images of whatever type, which currently leads to having to overwrite styles.

Honestly, I'm not actually sure if providing a category- or tags-based RSS feed is even necessary these days. I know that I have never subscribed to just a category of a blog …

YL
amazon Wishlist - Serendipity-Podcast (German only, sorry)

User avatar
Don Chambers
Regular
 
Posts: 3574
Joined: Mon Feb 13, 2006 3:40 am
Location: Chicago, IL, USA

Postby Don Chambers » Wed Mar 04, 2015 5:04 pm

I was correct in that bulletproof, and all of its decendants, use css to substitute the rss icons. Which actually now leads to a problem with subtome.

The subtome icon is also emitting the class .serendipity_xml_icon (in addition to serendipity_subtome). Bulletproof, and every template/colorset built on it (this could be a LOT) use the following technique to substitute the xml icon:

Code: Select all
.serendipity_xml_icon {
    background: url('img/purple_xml.png') center center no-repeat;
    padding: 10px 0;
    margin: 0;
    visibility: visible;
}

 .serendipity_xml_icon img {
    visibility: hidden;
}


So, if using bulletproof's purple colorset, or any derivative theme/colorset, the subtome icon looks like this:

Image

1) I do not think the subtome icon should be emitting the .serendipity_xml_icon class. This is very easy to fix, and I can do it if no one objects.

2) I do not think the subtome icon should be used if the option to use subtome is false. If not using subtome, the icon should fall back to a standard rss icon (which the subtome icon is not).

3) The freetag plugin, and the comments rss icon, will use a template's /img/xml.gif if it exists, falling back down the template path hierarchy until it is found, presumably in 2k11. Before subtome, when we had a list all selected rss feeds, those icons worked this way too. I think subtome should be configured to work this way as well, using /img/subtome.png if it exists in the current template

4) The category plugin should also be modified to use a template's /img/xml.gif if it exists, and not hard coded to 2k11.

5) I would be more than happy to suggest xml.gif be changed to xml.png in all these cases, unless that creates problems for old themes. Gif died ages ago.

Thoughts?

User avatar
onli
Regular
 
Posts: 2071
Joined: Tue Sep 09, 2008 10:04 pm

Postby onli » Wed Mar 04, 2015 5:35 pm

I'm ok with pretty much all of it. We can set the icon paths to be generic and fetch it via serendipity_getfile, so templates can overwrite the default. And we should use the pngs by default everywhere.

I do not think the subtome icon should be used if the option to use subtome is false. If not using subtome, the icon should fall back to a standard rss icon (which the subtome icon is not).

We don't have a big one though, we'd have to add it.

yellowled wrote:Honestly, I'm not actually sure if providing a category- or tags-based RSS feed is even necessary these days. I know that I have never subscribed to just a category of a blog …

It's a very important feature if you want to have only specific articles in a planet. The icons in the sidebar are less important, but using RSS is what makes a blog a blog, so we should show it as well.

User avatar
Don Chambers
Regular
 
Posts: 3574
Joined: Mon Feb 13, 2006 3:40 am
Location: Chicago, IL, USA

Postby Don Chambers » Wed Mar 04, 2015 7:52 pm

onli wrote:
Don Chambers wrote:I do not think the subtome icon should be used if the option to use subtome is false. If not using subtome, the icon should fall back to a standard rss icon (which the subtome icon is not).

We don't have a big one though, we'd have to add it..


Why does it have to be a huge icon? I am not opposed to large icons - in fact, I like them... but it does look a little ridiculous when the comments rss is switched on:

Image

Perhaps there should be an option to use large icon only vs. small with words?

Then again, who feeds just comments?!!!! I know, I know, its a blog and feeds are a big part of blogs. Actually, I have an idea for a large icon. I'll post back later if I find the time to implement that idea.

User avatar
onli
Regular
 
Posts: 2071
Joined: Tue Sep 09, 2008 10:04 pm

Postby onli » Wed Mar 04, 2015 9:34 pm

Then again, who feeds just comments?

Actually, I think no one. The new default is to not show that button.

Perhaps there should be an option to use large icon only vs. small with words?

There is! Just set the Feed Icon option to "none".

Oh, and seeing again how this is implemented: It will be highly problematic to set the big icon only to a subtome-icon when subtome is on, as the icon is set by a config option specifically. We should let this one to the user.



Return to Themes

Who is online

Users browsing this forum: No registered users and 1 guest

cron