프로젝트

일반

사용자정보

개정판 e215fb87

IDe215fb87632c27a25bee4eec8d714204e5faa160
상위 7cdf0e9a
하위 3f1aaa2d, 423d6366

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

issue #000: add default line type to template db and end break on going and fix connecter graphic

Change-Id: I9126002c0c3dfe6f23ee60a3ec5ca54d2803d0b6

차이점 보기:

DTI_PID/DTI_PID/LineNoTracer.py
476 476
            #for line in lines: line.lineType = 'Primary'
477 477
            for line in lines: line.update_line_type()
478 478

  
479
        """make line end break"""
479
        """make end break"""
480 480
        end_breaks = []
481 481
        for lineNo in lineNos:
482 482
            for end_break in lineNo.end_break():
......
485 485
            for end_break in end_breaks:
486 486
                end_break.addSvgItemToScene(worker.graphicsView.scene)
487 487

  
488
        if end_breaks:
489
            # check dulplication
490
            dupl = set()
491
            for i in range(len(end_breaks)):
492
                for j in range(len(end_breaks)):
493
                    if i == j:
494
                        continue
495
                    else:
496
                        setI = set([end_breaks[i].owner, end_breaks[i].prop('Connected Item')])
497
                        setJ = set([end_breaks[j].owner, end_breaks[j].prop('Connected Item')])
498
                        if not (setI - setJ):
499
                            index = [i, j]
500
                            index.sort()
501
                            index = tuple(index)
502
                            dupl.add(index)
503

  
504
            dupl = [indexSet[1] for indexSet in list(dupl)]
505
            dupl.sort(reverse=True)
506
            for index in dupl:
507
                end_breaks.pop(index)
508

  
488 509
    except Exception as ex:
489 510
        from App import App 
490 511
        message = 'error occured({}) in {}:{}'.format(ex, sys.exc_info()[-1].tb_frame.f_code.co_filename, sys.exc_info()[-1].tb_lineno)

내보내기 Unified diff

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