<commit_before>![RQM logo](http://ir_wp.s3.amazonaws.com/wp-content/uploads/sites/9/2013/07/rmq_logo.png)

# RubyMotionQuery - RMQ
A light, muggle, nonpolluting, jQuery-like library for [RubyMotion](http://rubymotion.com).

**The [RMQ Introductory Guide and other info][1] is a great place to start.**

[![Dependency Status](https://gemnasium.com/infinitered/rmq.png)](https://gemnasium.com/infinitered/rmq)
[![Build Status](https://travis-ci.org/infinitered/rmq.png?branch=master)](https://travis-ci.org/infinitered/rmq)


## General

### Some of the very cool features:
 - **selecting** (*querying*) views
 - **traversal** through view hierarchy (moving around the tree)
 - tagging
 - **events and gestures**
 - animations
 - **stylers and stylesheets**
 - colors
 - fonts
 - image utilities
 - app
 - device

----------

**Tested only on iOS only, not OS X (nor is there any OS X specific code)**

----------

### Other wrapper libraries
There are a lot of great wrappers out there such as Teacup and Sugarcube. I've used these and I enjoy them. However, many of the wrappers heavily pollute the standard classes, which is great if you like that sort of thing. RMQ is designed to have minimal pollution, to be very simple and high performance (it will be when it's done). RMQ shouldn't conflict with anything.

RMQ **doesn't require any** other wrapper or gem. 

> If you preferred jQuery over Prototype, you'll love RMQ.

Some of the code in RMQ came from BubbleWrap and Sugarcube. Not too much but some did. I thank you BubbleWrap and Sugarcube teams for your work.

## Quick Start
- `gem install ruby_motion_query`
- `rmq create my_app`
- `cd my_app`
- `bundle`
- `rake retina=4`

## Installation

RMQ **requires no other gems**. If you use stuff like **scale** and certain animations it will require some frameworks (like QuartzCore or CoreGraphics)

- `gem install ruby_motion_query`
- `require 'ruby_motion_query'`

or add it to your `Gemfile`:

- `gem 'ruby_motion_query'`

for **bleeding edge**, add this to your `Gemfile`:

- `gem 'ruby_motion_query', :git => '<EMAIL>:infinitered/rmq.git'`

## Usage

### Example App
*Clone this repo and run the example app to see an example of use.*

	git clone <EMAIL>:infinitered/rmq.git
	cd rmq
	rake retina=4

The example app works in any orientation, on both iPhone and iPad. Notice how the benchmark popup is done with RMQ, then think about how you'd do that without it.

### What's an rmq instance?

 - an rmq instance is an array-like object containing UIViews
 - rmq() never returns nil. If nothing is selected, it's an empty [ ] array-like
   object   
 - an rmq object always (almost always) returns either itself or a new
   rmq object. This is  how chaining works. You do not need to worry if
   an rmq is blank or not, everything  always works without throwing a
   nil exception
 - jQuery uses the DOM, what is rmq using for the "DOM"? It uses the
   controller it was  called in. The "DOM" is the controller's subview
   tree. If you call rmq inside a view, it will  attach to the
   controller that the view is currently in or to the current screen's<commit_msg>documenting debug flag<commit_after>![RQM logo](http://ir_wp.s3.amazonaws.com/wp-content/uploads/sites/9/2013/07/rmq_logo.png)

# RubyMotionQuery - RMQ
A light, muggle, nonpolluting, jQuery-like library for [RubyMotion](http://rubymotion.com).

**The [RMQ Introductory Guide and other info][1] is a great place to start.**

[![Dependency Status](https://gemnasium.com/infinitered/rmq.png)](https://gemnasium.com/infinitered/rmq)
[![Build Status](https://travis-ci.org/infinitered/rmq.png?branch=master)](https://travis-ci.org/infinitered/rmq)


## General

### Some of the very cool features:
 - **selecting** (*querying*) views
 - **traversal** through view hierarchy (moving around the tree)
 - tagging
 - **events and gestures**
 - animations
 - **stylers and stylesheets**
 - colors
 - fonts
 - image utilities
 - app
 - device

----------

**Tested only on iOS only, not OS X (nor is there any OS X specific code)**

----------

### Other wrapper libraries
There are a lot of great wrappers out there such as Teacup and Sugarcube. I've used these and I enjoy them. However, many of the wrappers heavily pollute the standard classes, which is great if you like that sort of thing. RMQ is designed to have minimal pollution, to be very simple and high performance (it will be when it's done). RMQ shouldn't conflict with anything.

RMQ **doesn't require any** other wrapper or gem. 

> If you preferred jQuery over Prototype, you'll love RMQ.

Some of the code in RMQ came from BubbleWrap and Sugarcube. Not too much but some did. I thank you BubbleWrap and Sugarcube teams for your work.

## Quick Start
- `gem install ruby_motion_query`
- `rmq create my_app`
- `cd my_app`
- `bundle`
- `rake rmq_debug=true`

Adding `rmq_debug=true` to rake turns on some debugging features that are too slow or verbose to include in a normal build.  It's great for normal use in the simulator, but you'll want to leave it off if you're measuring performance.

## Installation

RMQ **requires no other gems**. If you use stuff like **scale** and certain animations it will require some frameworks (like QuartzCore or CoreGraphics)

- `gem install ruby_motion_query`
- `require 'ruby_motion_query'`

or add it to your `Gemfile`:

- `gem 'ruby_motion_query'`

for **bleeding edge**, add this to your `Gemfile`:

- `gem 'ruby_motion_query', :git => '<EMAIL>:infinitered/rmq.git'`

## Usage

### Example App
*Clone this repo and run the example app to see an example of use.*

	git clone <EMAIL>:infinitered/rmq.git
	cd rmq
	rake rmq_debug=true

The example app works in any orientation, on both iPhone and iPad. Notice how the benchmark popup is done with RMQ, then think about how you'd do that without it.

### What's an rmq instance?

 - an rmq instance is an array-like object containing UIViews
 - rmq() never returns nil. If nothing is selected, it's an empty [ ] array-like
   object   
 - an rmq object always (almost always) returns either itself or a new
   rmq object. This is  how chaining works. You do not need to worry if
   an rmq is blank or not, everything  always works without throwing a
   nil exception
 - jQuery uses the DOM, what is rmq using for the "DOM"? It uses the
   controller it was  called in. The "DOM" is the controller's subview
   tree. If you call rmq inside a view, it will  attach to the
   controller that the view is currently in or to the current screen's
{'fraction_non_alphanumeric': 0.0978494623655914, 'fraction_numerical': 0.0030721966205837174, 'mean_word_length': 3.8408921933085503, 'pattern_counts': {'":': 0, '<': 7, '<?xml version=': 0, '>': 11, 'https://': 8, 'lorem ipsum': 0, 'www.': 0, 'xml': 0}, 'pii_count': 0, 'substrings_counts': 0, 'word_list_counts': {'cursed_substrings.json': 0, 'profanity_word_list.json': 0, 'sexual_word_list.json': 0, 'zh_pornsignals.json': 0}}
{'dir': 'git-commits-cleaned', 'id': '1807971', 'n_tokens_mistral': 2072, 'n_tokens_neox': 1924, 'n_words': 885}