For me, Manual Crop won't work. Either a «Crop» button or a manualcrop thumbnail does appear after image upload. But clicking on it won't do anything. :(

Firebug console reports:

ReferenceError: ManualCrop is not defined
ManualCrop.showCroptool("field-image", "manualcrop", 214);

I don't have the media module installed (#1799078: Uncaught ReferenceError: ManualCrop is not defined ).
This issue might be a clone of (#1803840: The crop selection area does not appear in theme Zen (at least in the responsive version of it)).

Comments

matthijs’s picture

Hi,

I'm sorry you can't get it to work. Could you please try following:

  1. Upload a new image;
  2. Save the node/entity without cropping the image;
  3. Go back to the node/entity edit form and try cropping the image.

If this work than there's a problem with the ajax-based loading of the Manual Crop javascript file. If that would be the case please try again without any other contrib modules nor themes.

Matthijs

matthijs’s picture

Status: Active » Postponed (maintainer needs more info)
lolmaus’s picture

Status: Postponed (maintainer needs more info) » Active

Okay, i've got a brand new website.

I've enabled some modules, including Manual Crop. Created a Manual Crop image style and enabled Manual Crop in field settings.

Then did as you said. No crop interface appears at all.

Previously i could say that Manual Crop is at least trying to do something by enabling the "List thumbs" Manual Crop option. That would change the display of a thumbnail. Now even that option won't do anything.

Consider setting this to critical: the module won't work at all.

Drupal 7.17.

matthijs’s picture

Hi,

I still can't reproduce this (also Drupal 7.17, a new install). Could you give me a list of installed third-party modules?

Matthijs

lolmaus’s picture

aegir@sea:~/platforms/drupal-7.17/sites/all/themes/amt_boron$ drush up -l amt.alfamb.ru
Update information last refreshed: Fri, 11/09/2012 - 21:43

Update status information on all installed and enabled Drupal projects:
 Name                           Installed version  Proposed version  Status
 Administration menu            7.x-3.0-rc3        7.x-3.0-rc3       Up to date
 Advanced help                  7.x-1.0            7.x-1.0           Up to date
 Advanced Menu                  7.x-1.9            7.x-1.9           Up to date
 Allow All File Extensions      7.x-1.1            7.x-1.1           Up to date
 Better Formats                 7.x-1.0-beta1      7.x-1.0-beta1     Up to date
 Drupal core                    7.17               7.17              Up to date
 Block Access                   7.x-1.0            7.x-1.0           Up to date
 Block Class                    7.x-1.2            7.x-1.2           Up to date
 Borealis                       7.x-1.0-rc8        7.x-1.0-rc8       Up to date
 BUEditor                       7.x-1.4            7.x-1.4           Up to date
 CAPTCHA                        7.x-1.0-beta2      7.x-1.0-beta2     Up to date
 Colorbox                       7.x-1.4            7.x-1.4           Up to date
 Chaos tool suite (ctools)      7.x-1.2            7.x-1.2           Up to date
 Email Field                    7.x-1.2            7.x-1.2           Up to date
 Empty Page                     7.x-1.0            7.x-1.0           Up to date
 Entity API                     7.x-1.0-rc3        7.x-1.0-rc3       Up to date
 Field group                    7.x-1.1            7.x-1.1           Up to date
 FileField Sources              7.x-1.7            7.x-1.7           Up to date
 Global Redirect                7.x-1.5            7.x-1.5           Up to date
 Localization update            7.x-1.0-beta3      7.x-1.0-beta3     Up to date
 Markdown filter                7.x-1.0            7.x-1.0           Up to date
 Markdown editor for BUEditor   7.x-1.0            7.x-1.0           Up to date
 Module Filter                  7.x-1.7            7.x-1.7           Up to date
 Multiupload Filefield Widget   7.x-1.11           7.x-1.11          Up to date
 Multiupload Imagefield Widget  7.x-1.0+2-dev      7.x-1.0           Up to date
 Pathauto                       7.x-1.2            7.x-1.2           Up to date
 Publish Content                7.x-1.0            7.x-1.0           Up to date
 reCAPTCHA                      7.x-1.8            7.x-1.8           Up to date
 Rules                          7.x-2.2            7.x-2.2           Up to date
 Submitted By                   7.x-1.x-dev        7.x-1.x-dev       Up to date
 Token                          7.x-1.4            7.x-1.4           Up to date
 Transliteration                7.x-3.1            7.x-3.1           Up to date
 Views                          7.x-3.5            7.x-3.5           Up to date
 Boron (HTML5 base theme)       7.x-1.4            7.x-1.4           Up to date
 Language Neutral Paths         Unknown            Unknown           Project was not packaged by drupal.org
                                                                     but obtained from git. You need to
                                                                     enable git_deploy module
 AMT Boron Subtheme             Unknown            Unknown           Project was not packaged by drupal.org
                                                                     but obtained from git. You need to
                                                                     enable git_deploy module


No code updates available.

Multiuploads were not enabled for the field. FileField Sources was enabled, but the issue persists even when a filed is upload in a traditional way.

Okay, i tried disabling FileField Sources completely, still no luck!

bjalford’s picture

Seeing the same thing. The crop button appears when uploading a new image but not when editing a node.

lolmaus’s picture

I don't see the crop button at all.

bjalford’s picture

My settings:

Image Style
Crop and scale manually with allow upscaling.

Image field on node
All checkboxes selected

When I upload an image the crop option appears and works and I can save the node. When I got back and edit the node there are no options - same as default image field.

bjalford’s picture

I've noticed that clicking on the upload button (the field is set to unlimited) without attaching a new image triggers the crop. I've tried the setting to show button rather than thumbnails and get the same thing.

matthijs’s picture

Assigned: Unassigned » matthijs
Priority: Normal » Major

Hi guys,

I'll be looking into this soon (normally/hopefully tomorrow).

@bjalford: Could you give me a list of your installed third-party modules?

If possible, can I test this somewhere?

Thanks!

Matthijs

matthijs’s picture

Status: Active » Postponed (maintainer needs more info)

I still can't reproduce this, anything else important I should know?

lolmaus’s picture

Tried again, new absolutely clean site, Manual Crop the only module enabled above core — won't work.

I can film a video reproducing that it won't work. Want me to?

lolmaus’s picture

The only visible effect of having Manual Crop set up is that the attached image (without being hard-resized) is CSS-resized to dimensions set as minimum for "Manual Crop" image style.

Example. I set my "Manual Crop" image style to have 12x12 px minimum dimensions. When i create/edit a node, it has no cropping screen, but the image is displayed 12x12 px, while it's source file being larger.

matthijs’s picture

Could you give me a dump of your site database? Than I can import it and try it myself with your settings :-)

Thanks in advance!

Matthijs

lolmaus’s picture

Title: Crop interface would not appear, "ManualCrop is not defined" error » Crop interface would not appear
Category: bug » support
Priority: Major » Normal
Status: Postponed (maintainer needs more info) » Closed (works as designed)

I fucking got it!

There's an option "Select the styles to be shown..." I've been selecting it all the time.

It actually says "Select the styles to be shown OR EXCLUDED, as selected above", and the default above selection is exclusion!

So it actually had no styles to crop.

Sorry for that! I was inattentive. On the other hand, the configuration interface was provoking me to make this mistake.

I've got another issue though. I've set Display to my manualcrop style. It would display the image with its source file correctly cropped, but with style's minimum width and height hardcoded to HTML!

<img typeof="foaf:Image" src="http://example.com/sites/example.com/files/styles/manual-crop/public/pic..." width="12" height="12" alt=""/>

Should i open a separate issue thread for that?

matthijs’s picture

I'm glad you found it! The exclude/include options where added later, before an exclude was hard coded so that's why it remained the default.

Concerning your other issue: is this what you're looking for or did I misunderstood? #1556244: Using 'manual crop' style, and leaving the minimum height and/or width fields blank results in missing image attributes

lolmaus’s picture

My issue does not correspond to your link's issue description as i'm providing both values.

But the workaround CSS solution should fix my issue too, so it might be the same issue, i dunno.

More specific description:

I've used the "Manual Crop" image style. Set the values to 12px and 12px. According to style's description those are minimum values for cropping. I. e. user cannot crop an image to a smaller size than 12x12.

The image results cropped correctly. But those minimal values are hardcoded into the HTML, and the cropped image gets resized by browser.

matthijs’s picture

I see what you mean.. That's indeed a bug, could you please open a new issue for it?

Thanks!