diff --git a/ext/index/main.php b/ext/index/main.php
index 4acc663c..20820fe2 100644
--- a/ext/index/main.php
+++ b/ext/index/main.php
@@ -21,6 +21,16 @@
*
size>=500x500 -- no small images
* size<1000x1000 -- no large images
*
+ * width (=, <, >, <=, >=) width, eg
+ *
+ * - width=1024 -- find images with 1024 width
+ *
- width>2000 -- find images bigger than 2000 width
+ *
+ * height (=, <, >, <=, >=) height, eg
+ *
+ * - height=768 -- find images with 768 height
+ *
- height>1000 -- find images bigger than 1000 height
+ *
* ratio (=, <, >, <=, >=) width : height, eg
*
* - ratio=4:3, ratio=16:9 -- standard wallpaper
@@ -302,6 +312,14 @@ class Index extends Extension {
$args = array("width{$this->stpen}"=>int_escape($matches[2]), "height{$this->stpen}"=>int_escape($matches[3]));
$event->add_querylet(new Querylet("width $cmp :width{$this->stpen} AND height $cmp :height{$this->stpen}", $args));
}
+ else if(preg_match("/^width([:]?<|[:]?>|[:]?<=|[:]?>=|[:|=])(\d+)$/", $event->term, $matches)) {
+ $cmp = ltrim($matches[1], ":") ?: "=";
+ $event->add_querylet(new Querylet("width $cmp :width{$this->stpen}", array("width{$this->stpen}"=>int_escape($matches[2]))));
+ }
+ else if(preg_match("/^height([:]?<|[:]?>|[:]?<=|[:]?>=|[:|=])(\d+)$/", $event->term, $matches)) {
+ $cmp = ltrim($matches[1], ":") ?: "=";
+ $event->add_querylet(new Querylet("height $cmp :height{$this->stpen}",array("height{$this->stpen}"=>int_escape($matches[2]))));
+ }
$this->stpen++;
}