Changeset 47c44f0 in sasview


Ignore:
Timestamp:
Apr 9, 2018 4:07:25 AM (4 years ago)
Author:
wojciech
Branches:
master, magnetic_scatt, release-4.2.2, ticket-1009, ticket-1094-headless, ticket-1242-2d-resolution, ticket-1243, ticket-1249, unittest-saveload
Children:
3b070a0
Parents:
a8e368b
Message:

Reverting Windows page layout

File:
1 edited

Legend:

Unmodified
Added
Removed
  • src/sas/sascalc/fit/pagestate.py

    ra8e368b r47c44f0  
    646646                    name = value.split(':', 1)[1].strip() 
    647647                    file_value = "File name:" + name 
    648                     if len(file_value) > 50: 
    649                         file_value = "File name:.."+file_value[-40:] 
     648                    #Truncating string so print doesn't complain of being outside margins 
     649                    if sys.platform != "win32": 
     650                        MAX_STRING_LENGHT = 50 
     651                        if len(file_value) > MAX_STRING_LENGHT: 
     652                            file_value = "File name:.."+file_value[-MAX_STRING_LENGHT+10:] 
    650653                    file_name = CENTRE % file_value 
    651654                    if len(title) == 0: 
     
    723726        html_str, text_str, title = self._get_report_string() 
    724727        # Allow 2 figures to append 
    725         image_links = [FEET_2%fig for fig in fig_urls] 
    726  
     728        #Constraining image width for OSX and linux, so print doesn't complain of being outside margins 
     729        if sys.platform == "win32": 
     730            image_links = [FEET_2%fig for fig in fig_urls] 
     731        else: 
     732            image_links = [FEET_2_unix%fig for fig in fig_urls] 
    727733        # final report html strings 
    728734        report_str = html_str + ELINE.join(image_links) 
     
    13721378"""<img src="%s" width="540"></img> 
    13731379""" 
     1380FEET_2_unix = \ 
     1381"""<img src="%s" width="540"></img> 
     1382""" 
    13741383FEET_3 = \ 
    13751384"""</center> 
Note: See TracChangeset for help on using the changeset viewer.