Roundcube Community Forum

Third Party Contributions => API Based Plugins => Topic started by: corbosman on June 22, 2010, 10:18:24 AM

Title: new plugin: message highlighting
Post by: corbosman on June 22, 2010, 10:18:24 AM
Ive created a new plugin named Message Highlight. It allows you to match a string on from/subject/to/cc and change the background color of the message index for that match. For example all emails from the roundcube dev list get a yellow background in the message index row.

This is a first beta release, feedback and comments are welcome.

Important: this only works with 0.4-STABLE (not beta)

You can get it here:  Downloads - roundcube-plugins - Project Hosting on Google Code (http://code.google.com/p/roundcube-plugins/downloads/list)

Screenshot:

(http://grab.by/5IzC)
Title: new plugin: message highlighting
Post by: dziobak on June 22, 2010, 10:25:15 AM
I'll try it!
Title: new plugin: message highlighting
Post by: dziobak on June 22, 2010, 10:53:52 AM
1. The highlight doesn't work on FF 3.6.3
2. The highlighting looks terrible for me. When using dark colors I can't see letters... Maybe you can change it from highlight to text color and disable from choosing bright colors.
3. Change the choosing color popup to this like in Rosali's calendar. It fits more to RC
4. Attached polish translation
Title: new plugin: message highlighting
Post by: corbosman on June 22, 2010, 02:24:13 PM
The highlighting works fine on FF 3.6.3. Ive been doing all development on FF 3.6.3. Just tried it on windows as well, no problem. Also works in Safari, Chrome and IE. At least for me it does. As long as you have current SVN (as in, today's SVN would be fine).

What about just using light colors instead of dark colors :)  If you pick only light colors, does that make you happier? I may be able to limit the colors to light colors.  I dont think it's a good idea to use the font color instead of the row color. You can not see different shades of a color well in font colors.  I think it looks fine with light colors.

Im not quite sure what makes a specific color picker 'fit rc more'. I hadnt seen the one in the calendar plugin, but im more than happy to give that one a go, especially because it looks like that one is easier to limit to light colors. But it kind of annoys me to use a color picker that just fills in a form with hex codes. I think it's designwise nicer to not show the end user the sadness of HTML hex color numbers.  Does your mother understand hex color codes?

Also, I really dont like how you have to click twice in that color picker. You have to click to lock in a color, and then click again outside the color picker to close the picker. It's not very intuitive.

What is 'more rc' about it? Or what dont you like about this one?
Title: new plugin: message highlighting
Post by: corbosman on June 22, 2010, 03:56:39 PM
If you'd like to try, check out this css file, some changes that may help:

http://wa.ter.net/download/message_highlight.css

Just replace the original css file and shift-reload.
Title: new plugin: message highlighting
Post by: dziobak on June 23, 2010, 12:47:42 AM
1. You are right with FF. I had to have something wrong with cache... it works
2. Yes I set the lithe colors and it looks better. it should be limited to light colors.
3. There should be used color pickup box the same in all plugins. This looks bad when one plugin use different box then the other... Maybe put it to core?
4. The new css looks better
Title: new plugin: message highlighting
Post by: dziobak on June 23, 2010, 01:04:56 AM
What do you thing about setting highlight from addressbook too? Setting a color to specific contact
Title: new plugin: message highlighting
Post by: corbosman on June 23, 2010, 01:09:51 AM
1. Ok, cool, phew :) I had a similar issue in Chrome that was fixed when I reloaded
2. With the new css it's limited to light colors. The only darkish color is in the blues, but even those seem light enough.

3. I agree it would be nice to have consistent UI elements. As a matter of fact, I just posted a feature request on the RC tracker a few days ago to have RC support Jquery-UI. (#1486809 (jquery UI support) ? Roundcube Webmail (http://trac.roundcube.net/ticket/1486809)) from the core, so plugins dont all load their own versions of jquery-ui and possibly even wrongly interact with eachother. (what happens if 5 plugins load different versions of jquery-ui?). The calendar color picker isn't jquery based. That doesnt have to be bad, but i would personally prefer a community supported jquery color picker. (mine doesnt seem to be actively developed either, and the only reason I used it is cause I thought it looked the least invasive of all the jquery color pickers I could find). Im perfectly happy using a different color picker if RC would suggest using a specific one.

4. I released a 0.11 version with the new css.
Title: new plugin: message highlighting
Post by: corbosman on June 23, 2010, 01:20:00 AM
Where in the addressbook? In the 'Edit Contact' frame? I suppose it's possible to hook in there using render_page. But what would you match on? Display Name? First/Last? Email?
Title: new plugin: message highlighting
Post by: dziobak on June 23, 2010, 01:50:43 AM
Yes, in the 'Edit Contact' frame.
I would match email. The plugin works correctly when using names ("Test user" ) and email address ("Test user" ). It could check both ;-)
Title: new plugin: message highlighting
Post by: corbosman on June 23, 2010, 01:59:46 AM
Oh, it also works in FF 3.6.4 :)
Title: new plugin: message highlighting
Post by: corbosman on August 01, 2010, 07:00:13 AM
I released a new version 1.0 of the Message Highlight plugin. This version should be compatible with the upcoming roundcube 0.4-stable.

This plugin is not supported in any versions older than 0.4-stable as it depends on features only available in 0.4.

Find it here:  Roundcube Plugins | Underwater World (http://underwa.ter.net/roundcube-plugins/)
Title: new plugin: message highlighting
Post by: bagu on August 01, 2010, 07:01:32 PM
Hi,

I have the latest trunk of roundcube and both latest jqueriui and message_highlight plugin, and the colorpicker is blank even the cursor show a color in the box in corner bottom left.

I use firefox 3.6.8 but the problem is the same in ie 8.

Is there something i do wrong ?

EDIT : here is the french traduction
Title: new plugin: message highlighting
Post by: corbosman on August 01, 2010, 07:14:57 PM
What OS?  1.0 works ok for me in 3.6.8 on mac, safari on mac, and chrome.

It doesnt need jqueryui.
Title: new plugin: message highlighting
Post by: bagu on August 01, 2010, 08:25:40 PM
I'm on windows 7 pro 64bits.
But the problem is the same on windows xp pro 32bits.
Title: new plugin: message highlighting
Post by: corbosman on August 01, 2010, 08:37:27 PM
i cant reproduce this so far. I have a windows 7 64, using IE8. No problems.
Title: new plugin: message highlighting
Post by: bagu on August 02, 2010, 06:33:53 AM
Here is the error message i have in my error log (php) :

Code: [Select]
[02-Aug-2010 00:56:15] PHP Warning:  Invalid argument supplied for foreach() in \roundcube\plugins\message_highlight\message_highlight.php on line 37

And here is what i get :
(http://img227.imageshack.us/img227/5048/problemeroundcubemessag.png) (http://img227.imageshack.us/i/problemeroundcubemessag.png/)

Is there something this plugin need to work ?
Title: new plugin: message highlighting
Post by: corbosman on August 02, 2010, 09:40:16 AM
Is your folder perhaps empty?  That might explain the error.
Title: new plugin: message highlighting
Post by: bagu on August 02, 2010, 11:01:54 AM
No, there are 3 messages.
But i don't think the error have something to deal with the lack of colorpicker image.

I'll try to re-upload the plugin.

EDIT : Re-upload done : no image of colorpicker shown
Title: new plugin: message highlighting
Post by: corbosman on August 03, 2010, 04:15:49 AM
I really cant reproduce it. That error could happen if there are no msgs. Thats a bug. But if you have 3 msgs that error shouldnt happen.

Do you always see that error?
Title: new plugin: message highlighting
Post by: corbosman on August 03, 2010, 04:27:40 AM
I released a new version of this plugin fixing a minor issue with empty folders. Version 1.0.1 can be downloaded here:  Roundcube Plugins | Underwater World (http://underwa.ter.net/roundcube-plugins/)
Title: new plugin: message highlighting
Post by: corbosman on August 03, 2010, 04:53:45 AM
I think I know what the problem is.  Is your roundcube installation perhaps installed in a subdirectory of your website? Not in the document root?
Title: new plugin: message highlighting
Post by: corbosman on August 03, 2010, 05:03:21 AM
Well, that was a short release :)

I released version 1.0.2, this should hopefully fix the colorpicker problem.

Roundcube Plugins | Underwater World (http://underwa.ter.net/roundcube-plugins/)
Title: new plugin: message highlighting
Post by: bagu on August 03, 2010, 07:03:56 AM
Work great ! ;)

Yes, my roundcube install is make to be an alias for all my vhosts
So with one install of rouncube, i just access it by http://everything/mail
Title: new plugin: message highlighting
Post by: denny on August 04, 2010, 06:02:27 AM
hi,

I have 0.4Beta installed and the message_highlight plugin, but it seems, that it doesn't work. Some error messages in error.log, but I think, that was a permission problem. After chown this messages disappears. User config works, latest Opera, Firefox 3.6.8, but no highlight.

[update]

I red, that I need a SVN version, that maybe the problem. ...

cu denny

Code: [Select]
[04-Aug-2010 11:37:13 +0200]: PHP Error: Failed to load plugin file /var/www/htdocs/mail/plugins//message_highlight/message_highlight.php in /var/www/htdocs/mail/program/include/rcube_plugin_api.php on line 106 (POST /mail/?_task=&_action=login)
[04-Aug-2010 11:37:25 +0200]: PHP Error: Failed to load plugin file /var/www/htdocs/mail/plugins//message_highlight/message_highlight.php in /var/www/htdocs/mail/program/include/rcube_plugin_api.php on line 106 (POST /mail/?_task=&_action=login)
[04-Aug-2010 11:37:25 +0200]: PHP Error: Failed to load plugin file /var/www/htdocs/mail/plugins//message_highlight/message_highlight.php in /var/www/htdocs/mail/program/include/rcube_plugin_api.php on line 106 (GET /mail/?_task=login)
[04-Aug-2010 11:37:26 +0200]: PHP Error: Failed to load plugin file /var/www/htdocs/mail/plugins//message_highlight/message_highlight.php in /var/www/htdocs/mail/program/include/rcube_plugin_api.php on line 106 (GET /mail/?_task=mail&_action=getunread&_remote=1&_=1280914649413&_unlock=0)
[04-Aug-2010 11:37:26 +0200]: PHP Error: Failed to load plugin file /var/www/h
Title: new plugin: message highlighting
Post by: corbosman on August 04, 2010, 06:55:16 AM
this plugin only works on either a very recent SVN version, or 0.4-stable which is due to be released today.
Title: new plugin: message highlighting
Post by: corbosman on August 08, 2010, 04:59:28 AM
With the stable release that was released today this plugin should work nicely.
Title: new plugin: message highlighting
Post by: ABerglund on August 08, 2010, 08:38:56 PM
I can confirm that, it works fine in 0.4-stable.
Title: new plugin: message highlighting
Post by: samyray on September 10, 2010, 06:20:47 AM
Hello
I understand that this is pretty easy,but I hope it will help somebody:
Here is Russian locale for your plugin.
Thank you.
Title: new plugin: message highlighting
Post by: corbosman on September 11, 2010, 04:18:12 AM
thank you!
Title: new plugin: message highlighting
Post by: xrxca on September 18, 2010, 08:01:37 PM
I have a some issues with the color selection method, I am trying this plugin as a way to differentiate between client sites in my email, and the concept is great, however the color picker is persnickety and makes it difficult to set a new entry to the same color as an older one unless you happen to know what the hex value for the old color was.
When you come into the settings, and click on an EXISTING color swatch to change/view the color the picker defaults to #ffffff rather than to the existing color of the swatch.
If you click on a swatch after changing it during the editing session it shows the correct value, but not if you come back to it later.

Oh, and it would be nice if you could change the order of the rules, I want to add a rule that all messages with the words "License Expiring" in the subject are red, but if I already have rules in place, the first rule hit is what is used so I'd like to move the new rult to the top...
Title: new plugin: message highlighting
Post by: corbosman on September 19, 2010, 03:32:25 AM
I see the #ffffff bug as well, i'll look into it. Thanks.
Title: new plugin: message highlighting
Post by: corbosman on September 20, 2010, 07:11:39 AM
I fixed the #ffffff bug. It was a bug in the original color picker. Fixed in 1.0.3.

Get it here: Roundcube Plugins | Underwater World (http://underwa.ter.net/roundcube-plugins/)
Title: new plugin: message highlighting
Post by: bagu on September 20, 2010, 10:46:22 AM
Here is french translation
Title: new plugin: message highlighting
Post by: corbosman on September 22, 2010, 07:38:15 AM
Thanks bagu. Will be added in 1.04
Title: new plugin: message highlighting
Post by: bagu on September 22, 2010, 08:00:32 AM
Be careful, file is in utf8 to make é à è viewable ;) (some others of my contribution forgot this :P )
Title: new plugin: message highlighting
Post by: corbosman on September 22, 2010, 10:20:54 AM
There is a new version, 1.0.4.  This version allows you to add rules at specific places instead of always on the bottom. This lets you finetune the matching better.

Also added .fr and .ru translations.  There are extra strings though, so new translations would be nice.

Get it here:  Roundcube Plugins | Underwater World (http://underwa.ter.net/roundcube-plugins/)
Title: new plugin: message highlighting
Post by: bagu on September 22, 2010, 11:10:25 AM
Ok, so, here is the french translation for this version ;)
Title: new plugin: message highlighting
Post by: rosali on September 23, 2010, 01:34:55 AM
Cor,

please update deprecated hooks:


    $this->add_hook('preferences_list', array($this, 'mh_preferences'));
    $this->add_hook('preferences_save', array($this, 'mh_save'));
    $this->add_hook('preferences_sections_list',array($this, 'mh_preferences_section'));
Title: message highlighting moves icons
Post by: loscas on September 28, 2010, 02:47:10 AM
First excuse my english
My problem is that installing the plugin message_highlight, icons on the homepage of the mail and on filters page was moved.
my roundcube version 0.4-stable on centos 5.5, plugin version 1.0.4
Without plugin
(http://medusa.acatlan.unam.mx/withoutMessageHighlighingMainpage.png)
with plugin
(http://medusa.acatlan.unam.mx/withMessageHighlighingMmainpage.png)
without plugin filters page
(http://medusa.acatlan.unam.mx/withoutMessageHighlighingFiltersPage.png)
with plugin filters page
(http://medusa.acatlan.unam.mx/withMessageHighlighingFiltersPage.png)
My installed plugins
$rcmail_config['plugins'] = array("password","managesieve","jqueryui","contextmenu","globaladdressbook","calendar","message_highlight",);
I hope someone has seen this problem for comments
thanks in advance
Title: new plugin: message highlighting
Post by: corbosman on September 28, 2010, 05:13:49 AM
yes, ive fixed that bug already. i'll release a new version asap.
Title: new plugin: message highlighting
Post by: corbosman on September 28, 2010, 06:23:31 AM
I released version 1.0.5 which fixes an interaction bug with the main screen buttons. Also updated fr translation.  

get it here: http://underwa.ter.net/roundcube-plugins/
Title: new plugin: message highlighting
Post by: corbosman on October 19, 2010, 01:20:47 PM
I released version 1.0.6 which fixes an IE8 bug.

get it here:  Roundcube Plugins | Underwater World (http://underwa.ter.net/roundcube-plugins/)
Title: new plugin: message highlighting
Post by: corbosman on October 23, 2010, 09:03:52 AM
I released a new version 1.0.7. This should only be used with 0.4.2 or new SVN versions. For anything older, use 1.0.6.

Get it here:  Roundcube Plugins | Underwater World (http://underwa.ter.net/roundcube-plugins/)
Title: new plugin: message highlighting
Post by: DC187 on October 27, 2010, 10:31:20 AM
Nice work, just installed this and works a treat.

However you may or may not be interested to know that this doesn't appear to work in FF 4.0 Beta 6 - when picking the color and clicking save I receive an error "Invalid color"
However if I pick the color in FF3.6 or IE8, then FF 4 Beta 6 does indeed show the highlights correctly.

You may or may not care since FF4 is still beta, just thought I'd share :)
Title: new plugin: message highlighting
Post by: corbosman on October 27, 2010, 04:00:06 PM
I think i'll pass on supporting beta versions. It's hard enough as it is supporting stable versions!
Title: new plugin: message highlighting
Post by: Kube on October 31, 2010, 09:01:08 AM
After installing the plugin it all appears as expected, but when I try to add a row in the settings the "loading..." message appears and never moves on. I don't see any errors logged in the "errors" file and I can continue by clicking onto another menu, but I can't save any of the changes required.

Any ideas?

PS: RC 0.4.2
Title: new plugin: message highlighting
Post by: corbosman on October 31, 2010, 10:47:56 AM
For 0.4.2 you need the last version of my plugin, 1.0.7.
Title: new plugin: message highlighting
Post by: Kube on October 31, 2010, 11:21:55 AM
Quote from: corbosman;31019
For 0.4.2 you need the last version of my plugin, 1.0.7.


Thanks for the quick response. I downloaded 1.0.7 from here

message_highlight-1.0.7.tgz - roundcube-plugins - Message Highlighting (compatible with 0.4.2-stable and up) - Project Hosting on Google Code (http://code.google.com/p/roundcube-plugins/downloads/detail?name=message_highlight-1.0.7.tgz&can=2&q=)

But it has 1.0.5 in it if you look at the comments in the file.
Title: new plugin: message highlighting
Post by: corbosman on October 31, 2010, 12:04:53 PM
Thats ok. Just forgot to update that number. The 1.0.7 file is the right version. If you are running that version and still have problems then I dont know whats up. Maybe shift-reload to make sure.
Title: Adding a row doesn't work
Post by: ebiel on November 04, 2010, 02:18:54 PM
After installation of the plugin everything seems to work, but if I try to add a row in the configuration dialog, an additional row is added and the "Loading..." message appears and never dissappears. I can move away from the menu by clicking anywhere, but cannot save the configuration. It is not possible to add another row and thus I cannot use the plugin.

That's really a pity b/c I like the idea and I also use some other plugins by you. The user Kube seems to have the same experience. Could you have a look? If so do you require any further information than the one given below?

RC: 0.42
Firefox: 3.6.12
Message Highlighting: 1.07

Cheers,
Ebiel
Title: new plugin: message highlighting
Post by: corbosman on November 05, 2010, 12:31:13 AM
Try 1.0.6 or 1.0.5.   It looks like the changes in RC that required 1.0.7 were done after 0.4.2.
Title: new plugin: message highlighting
Post by: ebiel on November 05, 2010, 09:17:07 AM
Thanks a lot for your quick answer. Using 1.0.6 fixed the problem for me.

Keep up the good work :)

Cheers,
Ebiel
Title: new plugin: message highlighting
Post by: HiperGlow on November 06, 2010, 08:18:48 AM
Danish translation
Title: Spanish localization
Post by: Italux on November 30, 2010, 07:08:48 AM
I had the same problem as ebiel, with version 1.0.7 and RC 0.4.2. Version 1.0.6 fixed the issue.

Here I provide the Spanish localization file for the plugin.

Nice and useful plugin by the way!

Title: highlight by priority
Post by: mikelsoft on December 07, 2010, 11:36:58 PM
PLease forgive me for being a total newb.

but is the any way we can highlight by priority of the email.???:D
Title: Spanish Argentine
Post by: falvarez on December 09, 2010, 04:55:59 PM
I had the same problem as ebiel and Italux.  The Version 1.0.6 fixed the issue. :)

Here I provide the Spanish Argentine localization file for the plugin.



Title: new plugin: message highlighting
Post by: ddecjc on February 11, 2011, 06:07:25 AM
Great plugin! I had a similar plugin running in Squirrel Mail, and the lack of that functionality was one of the things holding me back from switching to Roundcube.

Does the highlighting work if an email address is only on of many in the "To" or "Cc"? For me (WinXP Pro, FF 3.6.13), it doesn't seem to highlight any messages where my email address is one of many in the "Cc" even though I have a "copy" rule set up for that email address.

One request for a future enhancement would be to have the ability to handle "To or Cc" in the same rule.
Title: new plugin: message highlighting
Post by: corbosman on February 11, 2011, 06:44:56 AM
It only does To now. I'll fix that, so it works with CC as well. Im thinking maybe 'Recipient' should check both TO and CC, and not worry about them individually. Does one really want to highlight a TO and CC differently?
Title: new plugin: message highlighting
Post by: HiperGlow on February 11, 2011, 07:16:35 AM
Quote from: corbosman;33118
It only does To now. I'll fix that, so it works with CC as well. Im thinking maybe 'Recipient' should check both TO and CC, and not worry about them individually. Does one really want to highlight a TO and CC differently?


Yes, it is good to know if the mail is TO you, or you are CC'ed (information), or maybe it's just a group or something else.
Title: new plugin: message highlighting
Post by: corbosman on March 29, 2011, 06:01:08 AM
I released a new version 1.1 that works with RC 0.5. You can get it here:  Roundcube Plugins | Underwater World (http://underwa.ter.net/roundcube-plugins/)
Title: new plugin: message highlighting
Post by: corbosman on March 29, 2011, 06:34:39 AM
Sorry, released another version right away. 1.11.  This fixes the issue from the thread above regarding not finding CC.   This was due to RC not fetching the CC header for the message list. I add it now to the headers to be fetched, and that fixes the issue.
Title: new plugin: message highlighting
Post by: leduc on April 05, 2011, 11:27:02 AM
Hello, this plugin runs really great, but I have a request :

Is it possible to use your plugin in complement to the flags plugin ?

This plugin put flags in the headers message but don't color the row.

To make like the flags in Thunderbird.
Title: new plugin: message highlighting
Post by: SKaero on April 05, 2011, 11:33:13 AM
Quote from: leduc;34108
Hello, this plugin runs really great, but I have a request :

Is it possible to use your plugin in complement to the flags plugin ?

This plugin put flags in the headers message but don't color the row.

To make like the flags in Thunderbird.

Sounds like you want this plugin: http://www.roundcubeforum.net/7-third-party-contributions/46-api-based-plugins/8207-new-plugin-beta-labels.html
Title: new plugin: message highlighting
Post by: corbosman on April 06, 2011, 09:05:50 PM
Cant you just use both plugins? One for flags, one for colors?
Title: new plugin: message highlighting
Post by: xpresshred on April 09, 2011, 02:20:46 AM
Hi,thanks for sharing the information here....

Denver industrial paper shredder  (http://www.xpresshred.com)
       Denver Paper Shredding (http://www.xpresshred.com)
Title: new plugin: message highlighting
Post by: leduc on April 13, 2011, 05:35:09 AM
I already use both, but the flags plugin doesn't colorised row.

In fact, I would now how to get the header flag  from Imap to add in your plugin, anybody know ?

And after configure the color for the different flag with the plugin like any other possibility (object, from ... and flag :) ).
Title: new plugin: message highlighting
Post by: corbosman on April 13, 2011, 07:54:18 AM
so you want row colors based on flags? You'd have to ask the flags plugin author to add row colors.
Title: chinese translation
Post by: Joinon on May 21, 2011, 12:54:27 AM
Hi, this is the chinese translation for V1.11
Title: new plugin: message highlighting
Post by: Mighty on July 25, 2011, 06:25:45 PM
Color picker still doesn't work in Firefox v5.0 release.

I'm an experienced programmer, but new to JQuery.  I've skimmed the code, but nothing obvious is jumping out at me.  I threw a debug statement into the Save method and apparently the color array is coming back empty.

Can anyone point me at a quick fix?  Maybe a pointer to a likely area that might cause this issue?  Or, to an alternate color picker that will slip in easily?

I may just rip out the picker and change it to a text field, for now.  Didn't think of that last night when I was tired.

Anyway.  Maybe the author can take a look at this.  Or, if anyone has any suggestions and I get it working then I'll post back with my changes.

Drake

P.S. Oh, yeah.  Brand new install, 0.5.3.  message_highlight is the first plugin I have installed.  It's the only one installed, so far.
Title: new plugin: message highlighting
Post by: rosali on July 26, 2011, 12:25:31 AM
Cor, there is another bug.

If I have only one highlight definition and try to delete it, I get back an empty settings iframe. When entering the highlight settings section again. The item is shown again. So, it looks like it isn't possible to delete the last remaining item.
Title: new plugin: message highlighting
Post by: Mighty on July 26, 2011, 02:28:39 AM
Here's a brute-force workaround for Firefox, to remove the color picker and just have a text box.  I only had to touch three spots in the file message_highlight.php:

Line 25:
Comment out the color picker Javascript file
Code: [Select]
// myt    $this->include_script('colorpicker/mColorPicker.js');

Line 109:
Change the control to a text field
Code: [Select]
// myt    $color = html::tag('input', array('id' => uniqid() ,'name' => '_mh_color[]' ,'type' => 'color' ,'text' => 'hidden', 'class' => 'mh_color_input', 'value' => $color));
$color = new html_inputfield(array('name' => '_mh_color[]', 'class' => 'rcmfd_mh_input', 'type' => 'text', 'autocomplete' => 'off', 'value' => $color));


Line 121:
Change the method to extract the data from the control
Code: [Select]
// myt      html::span('mh_color', Q($this->gettext('mh_color'))) .
// myt      $color .
      $color->show() .


These changes will work in any browser that Roundcube works in to begin with.

Just as a bit of feedback.  I was able to try the color picker, even though it wouldn't actually save the values.  I found it pretty awkward to use.  When typing in values, if I accidentally moved the mouse over the swatch while moving to the "Add Row" or "Save" buttons it would change the value, losing my data.  If I clicked outside of the picker to make it go away, it would often discard my change.  And just trying to decide exactly where to click in the box didn't seem to have enough feedback.  It felt random.

Golden Rule of Programming:  Don't lose the user's data.

I don't know if you've seen Squirrelmail's message highlight color picker.  It's pretty brute-force, but very easy to use.  In addition to the text field to type in a value, there are either 32 or 64 common colors shown as labels to radio buttons.  It takes up a lot of screen space, and it's not elegant, but it's bullet-proof.  And, it makes it much easier to repeat colors from one entry to the next.

And I guess this would count as a feature request.  One other thing that their picker had was a label you could add to each highlight entry.  I would use this as a reminder of what a particular entry was there for, so that I didn't have to look at the match criterion and try to decipher it and remember what I was checking for.

Drake
Title: new plugin: message highlighting
Post by: corbosman on July 26, 2011, 07:50:58 AM
On which OS do you see these issues? On OSX with Firefox 5.01 it works for me.  The color picker isnt the greatest, but i couldnt immediately find a nicer one. It would be nice if roundcube offered a default color picker to use. I think the squirrelmail solution is ugly as sin and not suitable for a modern webmail client like roundcube :)  

One thing I dont understand though. In my browser (FF 5.01 on OSX 10.6.8) the color picker disappears once I pick a color. It doesnt linger around for you to accidentally hover over it. And if you actually click on a color in a row that already exists, and hover over the picker, the color picker will indeed change colors, but the moment the mouse moves out of the picker, your color goes back to normal. This is how it should work, and how it works for me right now. I never intend to change anything unless you click to pick the color.
Title: new plugin: message highlighting
Post by: corbosman on July 26, 2011, 07:58:20 AM
Quote from: rosali;35871
Cor, there is another bug.

If I have only one highlight definition and try to delete it, I get back an empty settings iframe. When entering the highlight settings section again. The item is shown again. So, it looks like it isn't possible to delete the last remaining item.


Can you explain this a bit more? I can delete the last remaining item just fine. Once the last remaining item is deleted, you're presented with an empty row that you can fill out. Sort of a first row that you can fill out to start.  I did not know of a better way to do that. I think I copied some of these UI choices from the sieve filter plugin.
Title: new plugin: message highlighting
Post by: Mighty on July 26, 2011, 03:21:56 PM
Quote from: corbosman;35884
On which OS do you see these issues?

 
I'm running Win7 64-bit.

Yeah, I expected it to go away when I picked a color, or typed in a value and hit enter.

It sounds like this behavior is related to the empty color array.  It's never executing the code to actually pull the value out of the control and hide it.

I'm comfortable just typing in the hex values, so my text field hack works for me.  I've already got my highlights moved over from my old system.  I'm subscribed to this thread, so if you come up with something that you'd like me to test then I'm happy to do that for you.

Drake
Title: new plugin: message highlighting
Post by: Mighty on August 07, 2011, 11:59:30 PM
Doh!  I misread your download page and overlooked the current version.  I was using an old version.  (I saw two right next to each other and took the latest of those.  I missed that it wasn't in alphabetical order.)  The latest works as expected.

My profuse apologies.

Drake
Title: new plugin: message highlighting
Post by: corbosman on August 08, 2011, 01:53:32 AM
Np, glad to hear it was just a misunderstanding.  I think the google code pages sort to your own preference. For me it sorts by date currently. So the latest versions are on top. We really need a better plugin repository.
Title: Re: new plugin: message highlighting
Post by: corbosman on June 17, 2012, 04:38:03 AM
I just released a new version of this plugin, version 2.0 which is compatible with roundcube 0.8 and larry skin

http://code.google.com/p/roundcube-plugins/downloads/list
Title: Re: new plugin: message highlighting
Post by: Yoni on June 17, 2012, 05:07:10 PM
Thanks :) I was really missing it a bit too much already.
Title: Re: new plugin: message highlighting
Post by: corbosman on October 22, 2012, 07:45:56 AM
I have moved this plugin to github and made some minor changes. You can get the github version here:

https://github.com/corbosman/message_highlight
Title: Re: new plugin: message highlighting
Post by: darknior on February 26, 2013, 10:42:34 AM
Try it on roundCube 0.9beta and works very fine ;)

Only the icon menu is missing for default and larry skin ...
And i don't know the API to understand how to add it ?

Thanks
Title: Re: new plugin: message highlighting
Post by: corbosman on April 10, 2013, 02:52:43 PM
I released a new version 2.1, which has some larry fixes including an icon. https://github.com/corbosman/message_highlight/tags
Title: Re: new plugin: message highlighting
Post by: darknior on April 10, 2013, 03:25:38 PM
Thanks a lot :D
Title: Re: new plugin: message highlighting
Post by: corbosman on April 11, 2013, 05:06:34 AM
Had a small error in 2.1, so i released 2.2.
Title: Re: new plugin: message highlighting
Post by: corbosman on May 26, 2013, 03:39:01 AM
New version 2.3 with a bugfix on github. Should be pushed to plugins.roundcube.net soon.
Title: Re: new plugin: message highlighting
Post by: shearer on June 13, 2013, 05:29:04 AM
where can i download newest version ?
Title: Re: new plugin: message highlighting
Post by: corbosman on June 13, 2013, 06:38:25 AM
If you want to get it from github:  https://github.com/corbosman/message_highlight/tags
 
Or through composer:  http://plugins.roundcube.net/packages/cor/message_highlight  (read the docs at http://plugins.roundcube.net/)

cor


Title: Re: new plugin: message highlighting
Post by: krelvinaz on September 21, 2013, 11:33:21 AM
I am attempting to use this on 0.9.4 without any success.

The notes say: Go to roundcube settings area and select rules to highlight emails in your mailview.

I see the plugin enabled, but can't see anywhere the rules can be set using either Larry or the default skin types.
Title: Re: new plugin: message highlighting
Post by: ABerglund on September 21, 2013, 05:42:32 PM
I see the plugin enabled, but can't see anywhere the rules can be set using either Larry or the default skin types.
You don't see this?
Title: Re: new plugin: message highlighting
Post by: krelvinaz on September 21, 2013, 07:20:13 PM
No...  Nothing shows up in either skin.

PHP Version 5.4.16
Title: Re: new plugin: message highlighting
Post by: krelvinaz on September 23, 2013, 09:48:47 AM
Figured it out.  I had the plugin in the directory message_highlights-master and had enabled it that way.  I changed the directory to just message_highlights and enabled that name and it works.
Title: Re: new plugin: message highlighting
Post by: corbosman on February 05, 2014, 04:57:44 AM
New version 2.4 fixes removes jquery live() dependancy which has been deprecated. This version is needed for the 1.0 release of roundcube.

https://github.com/corbosman/message_highlight/releases or use composer.
Title: Re: new plugin: message highlighting
Post by: ABerglund on February 05, 2014, 02:23:35 PM
Here's an odd deal - I installed and enabled version 2.4 in my test 1.0-rc install. It works fine, except it seems to (somehow) interfere with displaying contacts in the Compose window. If I enable the plugin, selecting one of the addressbooks (either LDAP or SQL) in a compose window displays one or at most two contacts, and the status message of "Loading..." never goes away. Disabling the plugin reverts behavior to normal. No errors in the logs (even the ldap log) are seen.

No idea why it should interfere with the display of contacts in the Compose window, not sure what functions the plugin might leverage or share with the listing of contacts.
Title: Re: new plugin: message highlighting
Post by: corbosman on February 05, 2014, 02:46:29 PM
Hmm, there is a javascript error. Weird. Hopefully found and fixed asap,

Cor
Title: Re: new plugin: message highlighting
Post by: corbosman on February 05, 2014, 02:59:27 PM
Better? Version 2.5.1 should fix it. Suddenly I was seeing insertrow events in the addressbook.  Wonder if there is an event that just triggers in the message view.

Cor
Title: Re: new plugin: message highlighting
Post by: ABerglund on February 05, 2014, 04:16:24 PM
Indeed, 2.5.1 fixed it. Nice quick work!
Title: Re: new plugin: message highlighting
Post by: elchava79 on July 20, 2023, 09:28:07 AM
When I delete the last rule and try to save, it gives me an error and it doesn't delete the rule. (does not add the blank rule)
Can someone explain to me how to fix it.

Thank you all