프로젝트

일반

사용자정보

개정판 a31687ed

IDa31687ed52b7480990e02ff2afa4a790ddbcdc8e
상위 68b728ee
하위 df0ec478

함의성이(가) 약 6년 전에 추가함

issue #501: remove scene dependency note data

차이점 보기:

DTI_PID/DTI_PID/Shapes/EngineeringNoteItem.py
51 51
                                            else-statement changed, if text starts with new LineNo header, do break
52 52
                                            Moved from ResultTreeWidget
53 53
                    2018.05.02  Jeongwoo    Add if-statement. Append text to list when Regex start position is not 0
54
                    2018.12.10 euisung      remove scene dependency
54 55
    '''
55 56
    def findNoteContents(self, noteNoText):
56 57
        res = {}
......
59 60
        notesArea = AppDocData.instance().getArea('Note')
60 61
        if not notesArea: return res
61 62
        # Get all note contents
62
        items = self.scene().items(QRectF(notesArea.x, notesArea.y, notesArea.x + notesArea.width, notesArea.y + notesArea.height))
63
        items = [note for note in AppDocData.instance().texts if note.area == 'Note']
63 64
        items = [item for item in items if type(item) is QEngineeringTextItem] # Filtering QEngineeringTextItem
64 65
        items.sort(key=lambda item:item.loc[1]) # Compare with loc[1] (Y-Coord)
65 66
        results = re.findall("\d+", noteNoText)

내보내기 Unified diff

클립보드 이미지 추가 (최대 크기: 500 MB)