X-Git-Url: http://koha-dev.rot13.org:8081/gitweb/?a=blobdiff_plain;f=C4%2FPatroncards%2FLib.pm;h=a02fb4818ab5ffaf9839041185d42f4f1c54758b;hb=d8aa557fc92a7030eb9628dc5fcce3fef99046dc;hp=b0061aec52e4ace84977e6eaadb980657fe58721;hpb=8e0b1fe58f7e4f6e595b18d43c939c203833dac1;p=koha_gimpoz diff --git a/C4/Patroncards/Lib.pm b/C4/Patroncards/Lib.pm index b0061aec52..a02fb4818a 100644 --- a/C4/Patroncards/Lib.pm +++ b/C4/Patroncards/Lib.pm @@ -13,9 +13,9 @@ package C4::Patroncards::Lib; # WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS FOR # A PARTICULAR PURPOSE. See the GNU General Public License for more details. # -# You should have received a copy of the GNU General Public License along with -# Koha; if not, write to the Free Software Foundation, Inc., 59 Temple Place, -# Suite 330, Boston, MA 02111-1307 USA +# You should have received a copy of the GNU General Public License along +# with Koha; if not, write to the Free Software Foundation, Inc., +# 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA. use strict; use warnings; @@ -28,14 +28,14 @@ use C4::Debug; BEGIN { use version; our $VERSION = qv('1.0.0_1'); use base qw(Exporter); - our @EXPORT_OK = qw(unpack_UTF8 - text_alignment - leading - box - get_borrower_attributes - put_image - get_image - rm_image + our @EXPORT = qw(unpack_UTF8 + text_alignment + leading + box + get_borrower_attributes + put_image + get_image + rm_image ); } @@ -58,12 +58,12 @@ sub text_alignment { return $origin_llx, $Tw; } elsif ($alignment eq 'C') { - my $center_margin = ($text_box_width / 2) + $text_llx; + my $center_margin = ($text_box_width / 2) + ($origin_llx - $text_llx); $Tx = $center_margin - ($string_width / 2); return $Tx, $Tw; } elsif ($alignment eq 'R') { - $Tx = ($text_box_width - $string_width) + ($text_llx / 2); + $Tx = ($text_box_width - $string_width) + (($origin_llx - $text_llx) / 2); return $Tx, $Tw; } elsif ($alignment eq 'L') {